|
- #!/bin/bash
- action=$1
- root_path=/www/wwwroot/cn-pricerite-magento2
- if [ "${action}" == "clean" ];then
- rm -rf ${root_path}/pub/static/frontend
- rm -rf ${root_path}/var/view_preprocessed/pub/static/frontend
- php ${root_path}/bin/magento cache:clean
- elif [ "${action}" == "upgrade" ];then
- php ${root_path}/bin/magento setup:upgrade
- elif [ "${action}" == "compile" ];then
- php /home/website/magentoee220/bin/magento setup:di:compile
- elif [ "${action}" == "deploy" ];then
- php ${root_path}/bin/magento setup:static-content:deploy -f en_US
- php ${root_path}/bin/magento setup:static-content:deploy -f zh_Hant_HK
- elif [ "${action}" == "chown" ];then
- chown -R www:www ${root_path}
- elif [ "${action}" == "chmod" ];then
- chmod -R 777 ${root_path}
- else
- php ${root_path}/bin/magento ${action}
- fi
复制代码
|
|