Skip to content

Instantly share code, notes, and snippets.

@Nav-Appaiya
Created December 21, 2021 22:13
Show Gist options
  • Select an option

  • Save Nav-Appaiya/dffd72fa80ec38085b83dc7737a2eb16 to your computer and use it in GitHub Desktop.

Select an option

Save Nav-Appaiya/dffd72fa80ec38085b83dc7737a2eb16 to your computer and use it in GitHub Desktop.
Magento 2 usefull snippets migration & installation
Please run below command in magento root directory
find . -type f -exec chmod 644 {} \;
find . -type d -exec chmod 755 {} \;
find ./var -type d -exec chmod 777 {} \;
find ./pub/media -type d -exec chmod 777 {} \;
find ./pub/static -type d -exec chmod 777 {} \;
chmod 777 ./app/etc
chmod 644 ./app/etc/*.xml
bin/magento setup:static-content:deploy does not overwrite existing files in pub/static
php bin/magento cache:clean
php bin/magento cache:flush
php bin/magento setup:upgrade
rm -rf pub/static/frontend/* pub/static/adminhtml/* var/cache/ var/generation/ var/page_cache/ var/view_preprocessed/ var/composer_home generated/
php -dmemory_limit=6G bin/magento setup:static-content:deploy -f
chmod -Rf 777 pub/ var/
php bin/magento cache:clean
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment