File tree Expand file tree Collapse file tree 3 files changed +17
-18
lines changed Expand file tree Collapse file tree 3 files changed +17
-18
lines changed Original file line number Diff line number Diff line change @@ -15,7 +15,7 @@ Vagrant.configure(2) do |config|
1515 config . vm . box = "ubuntu/trusty64"
1616
1717 config . vm . provider "virtualbox" do |vb |
18- vb . memory = 2048
18+ vb . memory = 3072 # Around 3Gb is necessary to be able to run tests
1919 end
2020 config . vm . network :private_network , ip : '192.168.10.11'
2121 config . vm . hostname = "magento2.vagrant"
Original file line number Diff line number Diff line change @@ -68,13 +68,28 @@ sed -i '/\[client\]/a \
6868user = root \
6969password =' /etc/mysql/my.cnf
7070
71+ # Install git
72+ apt-get install -y git
73+
7174# Setup Composer
7275if [ ! -f /usr/local/bin/composer ]; then
7376 cd /tmp
7477 curl -sS https://getcomposer.org/installer | php
7578 mv composer.phar /usr/local/bin/composer
7679fi
7780
81+ # Configure composer
82+ composer_auth_json=" /vagrant/local.config/composer/auth.json"
83+ if [ -f ${composer_auth_json} ]; then
84+ set +x
85+ echo " Installing composer OAuth tokens from ${composer_auth_json} ..."
86+ set -x
87+ if [ ! -d /home/vagrant/.composer ] ; then
88+ sudo -H -u vagrant bash -c ' mkdir /home/vagrant/.composer'
89+ fi
90+ cp ${composer_auth_json} /home/vagrant/.composer/auth.json
91+ fi
92+
7893# Declare path to scripts supplied with vagrant and Magento
7994magento_dir=" /var/www/magento2ce"
8095echo " export PATH=\$ PATH:/vagrant/bin:${magento_dir} /bin" >> /etc/profile
Original file line number Diff line number Diff line change @@ -39,24 +39,8 @@ for db_name in "${db_names[@]}"; do
3939 mysql -e " drop database if exists ${db_name} ; create database ${db_name} ;"
4040done
4141
42- # Install git
43- apt-get install -y git
44-
4542# Install Magento application
4643cd ${magento_dir}
47- composer_auth_json=" /vagrant/local.config/composer/auth.json"
48- if [ -f ${composer_auth_json} ]; then
49- set +x
50- echo " Installing composer OAuth tokens from ${composer_auth_json} ..."
51- set -x
52- if [ ! -d /home/vagrant/.composer ] ; then
53- sudo -H -u vagrant bash -c ' mkdir /home/vagrant/.composer'
54- fi
55- cp ${composer_auth_json} /home/vagrant/.composer/auth.json
56- sudo -H -u vagrant bash -c ' composer install'
57- else
58- sudo -H -u vagrant bash -c ' composer install --prefer-source'
59- fi
6044
6145admin_frontame=" admin"
6246install_cmd=" ./bin/magento setup:install \
@@ -77,7 +61,7 @@ install_cmd="./bin/magento setup:install \
7761 --use-rewrites=1"
7862
7963# Configure Rabbit MQ
80- if [ -d " ${magento_dir} /app/code/Magento/Amqp" ]; then
64+ if [ -f " ${magento_dir} /app/code/Magento/Amqp/registration.php " ]; then
8165 install_cmd=" ${install_cmd} \
8266 --amqp-host=localhost \
8367 --amqp-port=5672 \
You can’t perform that action at this time.
0 commit comments