在heroku上运行bash将无法正常工作

E.S*_*.S. 2 bash heroku

我试图在heroku上运行bash来测试它并且它失败了

 $ heroku run bash
 ?    Error: No app specified
 ?    Usage: heroku run --app APP
 ?    We don't know which app to run this on.
 ?    Run this command from inside an app folder or specify which app to use with --app APP
 ?    
 ?    https://devcenter.heroku.com/articles/using-the-cli#app-commands


 $ heroku run --app bash
 ?    Usage: heroku run COMMAND
 ?    
 ?    Example: heroku run bash
Run Code Online (Sandbox Code Playgroud)

所以,这个例子说heroku run bash会起作用,但事实并非如此.我没有跑步的dynos.我觉得我错过了一些基本的东西......

小智 10

尝试运行命令:

首先你需要登录,然后你看到你的应用程序,最后运行bash

$heroku login
Run Code Online (Sandbox Code Playgroud)

插入您的用户名和密码

$heroku apps
=== user@gmail.com Apps
myaplication
Run Code Online (Sandbox Code Playgroud)

然后查看列表aps并写入

$heroku run bash --app myaplication 
Run Code Online (Sandbox Code Playgroud)


小智 5

您也可以这样做:使用获取应用程序名称;

heroku apps
Run Code Online (Sandbox Code Playgroud)

然后设置heroku远程;

heroku git:remote -a yourappname
Run Code Online (Sandbox Code Playgroud)

最后在您的应用程序上/中运行 bash

heroku run bash
Run Code Online (Sandbox Code Playgroud)