Created
May 7, 2016 14:06
-
-
Save stamster/21c9c518f2fd6ac3521b5d671db58449 to your computer and use it in GitHub Desktop.
Magento2 INIT script
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
#!/bin/bash | |
MAG=magento #system wide symlink | |
# or absolute: | |
#MAG=/usr/share/nginx/mymagentoprojectroot/bin/magento #absolute path | |
echo "Enabling all modules with clearing static content..." | |
$MAG module:enable --all --clear-static-content | |
echo "Running setup upgrade..." | |
$MAG setup:upgrade | |
echo "Running code compiler (to avoid real time configuration and code analysis)..." | |
$MAG setup:di:compile | |
echo "Running static content deployment..." | |
$MAG setup:static-content:deploy | |
echo "Performing re-index of catalog database data..." | |
$MAG indexer:reindex | |
echo "Cleaning cache to apply all settings..." | |
$MAG cache:clean | |
$MAG cache:flush | |
echo "ALL OPERATIONS COMPLETE." | |
echo "EOF" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment