带有本地路径调用的Heroku Procfile如何在Windows中运行?

时间:2020-05-09 14:26:30

标签: heroku

概述

我正在使用Heroku的开放源代码项目。有两个proc文件:一个用于dev,一个用于生产。大多数团队一直在Linux上工作,没有任何问题。我正在尝试在Windows中工作。 (解决方法是我可以设置一个容器或VM;我只想看看是否可以在Windows中完成此操作)。当我尝试使用Procfile.dev时,在屏幕上出现错误。

命令

我要运行的命令是:

heroku local -f Procfile.dev

Procfile.dev

web: bin/rails server
webpack: bin/webpack-dev-server --watch

错误

web.1    |  'bin' is not recognized as an internal or external command,
web.1    |  operable program or batch file.
[DONE] Killing all processes with signal  SIGINT
webpack.1 |  'bin' is not recognized as an internal or external command,
webpack.1 |  operable program or batch file.
web.1    Exited with exit code null
webpack.1 Exited with exit code null

更改为相对路径

为解决此问题,我更新了Procfile.dev以使用相对路径。文件现在看起来像:

web: ./bin/rails server
webpack: ./bin/webpack-dev-server --watch

现在我得到了错误:

web.1    |  '.' is not recognized as an internal or external command,
web.1    |  operable program or batch file.
[DONE] Killing all processes with signal  SIGINT
webpack.1 |  '.' is not recognized as an internal or external command,
webpack.1 |  operable program or batch file.
web.1    Exited with exit code null
webpack.1 Exited with exit code null

似乎heroku无法识别路径。这适用于Linux。

我也尝试过在Git Bash和Windows Power Shell中运行它。

0 个答案:

没有答案