Created
August 27, 2016 03:29
-
-
Save xuboso/bf8e2d72b8a2a29c147b8abc54475ce2 to your computer and use it in GitHub Desktop.
symfony deploy script
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| echo "[pull code] update code from bitbucket repository" | |
| git pull origin master | |
| echo "[composer install] check package to install" | |
| composer install --no-dev --optimize-autoloader | |
| echo "[validate doctrine schema]" | |
| php app/console doctrine:schema:validate | |
| php app/console doctrine:ensure-production-settings | |
| echo "[update database]" | |
| php app/console doctrine:schema:update --dump-sql --force | |
| echo "[clear cache and disable debug]" | |
| php app/console cache:clear --env=prod --no-debug | |
| php app/console assetic:dump --env=prod --no-debug | |
| echo "[modify permissions] cache and log" | |
| sudo chmod -R 777 app/cache/ | |
| sudo chmod -R 777 app/logs/ | |
| sudo chmod -R 777 app/cache/prod/annotations/ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment