Skip to content

Commit 5878ff6

Browse files
committed
Moved compiler.php to after setup
1 parent ce5c7a4 commit 5878ff6

File tree

2 files changed

+10
-10
lines changed

2 files changed

+10
-10
lines changed

scripts/install-magento2

+3-7
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,8 @@ mkdir -p htdocs
1010
curl -sS https://getcomposer.org/installer | php
1111
php composer.phar install
1212

13-
cd htdocs
14-
php -f dev/tools/Magento/Tools/View/deploy.php
15-
php -f dev/tools/Magento/Tools/Di/compiler.php
16-
17-
# Use developer mode to get more detailed error diagnostics, at least for now.
18-
echo "SetEnv MAGE_MODE developer" >> .htaccess
19-
#echo "SetEnv MAGE_MODE production" >> .htaccess
13+
# Swap to developer mode for better error diagnostics
14+
echo "SetEnv MAGE_MODE production" >> .htaccess
15+
#echo "SetEnv MAGE_MODE developer" >> .htaccess
2016

2117
chown www-data:www-data -R /var/www/magento2

scripts/runserver

+7-3
Original file line numberDiff line numberDiff line change
@@ -12,13 +12,13 @@ until mysql $MYSQLAUTH -e ""; do
1212
sleep 1
1313
done
1414

15-
mysql $MYSQLAUTH -e "CREATE DATABASE IF NOT EXISTS magento2"
15+
mysql $MYSQLAUTH -e "CREATE DATABASE IF NOT EXISTS magento"
1616

17-
cd /var/www/magento2/htdocs/setup
17+
cd /var/www/magento2/htdocs
1818
php -f setup/index.php install \
1919
--cleanup_database \
2020
--db_host=mysql \
21-
--db_name=magento2 \
21+
--db_name=magento \
2222
--db_user="$MYSQL_USER" \
2323
--db_pass="$MYSQL_PASSWORD" \
2424
--backend_frontname=admin \
@@ -33,5 +33,9 @@ php -f setup/index.php install \
3333
--admin_password=admin123 \
3434
--use_secure=0
3535

36+
# In production mode we pre-compute various files
37+
php -f dev/tools/Magento/Tools/View/deploy.php
38+
php -f dev/tools/Magento/Tools/Di/compiler.php
39+
3640
# Run the web server
3741
exec /usr/sbin/apache2 -D FOREGROUND

0 commit comments

Comments
 (0)