Forked from juniorb2ss/gist:1bc2e1fc25c17f7b03262a735d063d3a
Created
December 10, 2018 16:42
-
-
Save zhuomingliang/e923744cca64acf46fdde787059e3adc to your computer and use it in GitHub Desktop.
Commands to ElasticBeanstalk
This file contains 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
commands: | |
00_update_composer: | |
command: export HOME=/root && export COMPOSER_HOME=/root && /usr/bin/composer.phar self-update | |
option_settings: | |
- namespace: aws:elasticbeanstalk:application:environment | |
option_name: COMPOSER_HOME | |
value: /root | |
- namespace: aws:elasticbeanstalk:application:environment | |
option_name: HOME | |
value: /root | |
container_commands: | |
01express: | |
command: "echo AWS Container Commands started, starting Composer install." | |
02installComposer: | |
command: "php /opt/elasticbeanstalk/support/composer.phar install --no-dev" | |
cwd: "/var/app/ondeck" | |
03express: | |
command: "echo Composer install completed, starting Laravel migration" | |
04storagepermissions: | |
command: "chmod -fR 755 /var/app/ondeck/storage" | |
05migrations: | |
command: "php artisan migrate --env=production --no-interaction" | |
cwd: "/var/app/ondeck" | |
ignoreErrors: true | |
06migrations_module: | |
command: "php artisan --env=production -n --force module:migrate" | |
cwd: "/var/app/ondeck" | |
ignoreErrors: true | |
07express: | |
command: "echo Completed Laravel migration, starting Laravel database seeding" | |
08seeds: | |
command: "php artisan db:seed --env=production --no-interaction" | |
cwd: "/var/app/ondeck" | |
leader_only: true | |
09express: | |
command: "echo Completed database seeting, Container Commands complete." | |
10optimize: | |
command: "/usr/bin/composer.phar dump-autoload --optimize --no-dev" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment