如何在本地运行部署在heroku中的php项目?

时间:2017-01-02 15:09:58

标签: php heroku heroku-toolbelt heroku-postgres heroku-api

操作系统:Windows。

C:\Users\vigne>cd project
C:\Users\vigne\project>heroku local //directory of cloned project from github

我收到了这个:

[WARN] No ENV file found
5:11:01 PM web.1 |  'vendor' is not recognized as an internal or external command,
5:11:01 PM web.1 |  operable program or batch file.
[DONE] Killing all processes with signal  null
5:11:01 PM web.1 Exited with exit code 1

1 个答案:

答案 0 :(得分:7)

在Procfile中添加此dyno

local: php -S localhost:8080

并使用此dyno在本地运行heroku 通过此命令启动heroku本地服务器 -

heroku local local

然后打开http://localhost:8080/