2
我剛剛更新了我的應用程序到Symfony3(包括目錄結構)。作者在升級到symfony3後在heroku上安裝失敗
在我的開發環境一切都運行完美,但部署到Heroku上後,我得到錯誤:
[RuntimeException]
An error occurred when executing the "'cache:clear --no-warmup'" command:
Could not open input file: app/console
奇怪的是,當我通過Heroku的慶典上運行相同的命令:
$ heroku run bash
$ composer install --no-dev
一切正常罰款...
我有一個要求extra
填寫在composer.json
:
"extra": {
"symfony-app-dir": "app",
"symfony-web-dir": "web",
"symfony-var-dir": "var",
"symfony-bin-dir": "bin",
"symfony-tests-dir": "tests",
"symfony-assets-install": "relative",
"incenteev-parameters": {
"file": "app/config/parameters.yml",
"env-map": {
"database_host": "MYSQL_HOST",
"database_name": "MYSQL_DB",
"database_user": "MYSQL_USER",
"database_password": "MYSQL_PASSWORD"
}
}
}
我錯過了什麼嗎?
我有'var'在我的git倉庫中。我的'.gitignore'包含:'/ var /' '!var/cache/.gitkeep' '!var/logs/.gitkeep' –
你是對的......'var/cache'中的'.gitkeep' wasn夠了。我不得不在'var'中創建另一個,然後將其添加到存儲庫。非常感謝 ! –