sh 将magento 2全部部署到本地
Posted
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了sh 将magento 2全部部署到本地相关的知识,希望对你有一定的参考价值。
#!/usr/bin/env bash
cd /var/www/vhosts/partyshowroom/production/htdocs/
echo 'Removing vendor files'
rm -rf /var/www/vhosts/partyshowroom/production/htdocs/vendor/*
echo 'Installing vendor files via composer'
composer install
echo 'Clearing magento cache...'
rm -rf /var/www/vhosts/partyshowroom/production/htdocs/var/cache/*
echo 'Clearing page cache...'
rm -rf /var/www/vhosts/partyshowroom/production/htdocs/var/page_cache/*
echo 'clearing old di files'
rm -rf /var/www/vhosts/partyshowroom/production/htdocs/var/di/*
echo 'Setting developer mode'
php /var/www/vhosts/partyshowroom/production/htdocs/bin/magento deploy:mode:set developer
echo 'Restarting Varnish service'
sudo /etc/init.d/varnish restart
echo 'Clear generation files...'
rm -rf /var/www/vhosts/partyshowroom/production/htdocs/var/generation/*
echo 'Clear view preprocessed...'
rm -rf /var/www/vhosts/partyshowroom/production/htdocs/var/view_preprocessed/*
echo 'Clear Static files...'
rm -rf /var/www/vhosts/partyshowroom/production/htdocs/pub/static/*
echo 'Upgrading modules...'
php /var/www/vhosts/partyshowroom/production/htdocs/bin/magento setup:upgrade
echo 'Running static content deploy of en_GB'
php /var/www/vhosts/partyshowroom/production/htdocs/bin/magento setup:static-content:deploy en_GB;
echo 'Running di compile'
php /var/www/vhosts/partyshowroom/production/htdocs/bin/magento setup:di:compile;
echo 'Initialise complete'
以上是关于sh 将magento 2全部部署到本地的主要内容,如果未能解决你的问题,请参考以下文章
sh 部署Magento 2个步骤
sh 部署Magento 2个步骤
sh 用于关闭magento 2模板和阻止提示的Shell脚本,将文件添加到流浪者中的〜/ bin并将权限设置为755
sh 用于打开magento 2模板和阻止提示的Shell脚本,将文件添加到流浪者中的〜/ bin并将权限设置为755
麦进斗Magento2转移网站
如何将实时 Magento 站点复制到本地机器以测试新主题