Changes to run vagrant from project root dir (#163)

Introduced a variable which represents current vagrantfile directory path. This way we can run vagrant directly from the Yii2 project root and do not need to store vagrant configurations separately.
This commit is contained in:
Vladimir Jelovac 2018-02-06 22:05:52 +01:00 committed by Alexander Makarov
parent 32939e2b27
commit 7942ecffee

6
Vagrantfile vendored
View File

@ -10,9 +10,11 @@ domains = {
app: 'yii2basic.dev' app: 'yii2basic.dev'
} }
vagrantfile_dir_path = File.dirname(__FILE__)
config = { config = {
local: './vagrant/config/vagrant-local.yml', local: vagrantfile_dir_path + '/vagrant/config/vagrant-local.yml',
example: './vagrant/config/vagrant-local.example.yml' example: vagrantfile_dir_path + '/vagrant/config/vagrant-local.example.yml'
} }
# copy config from example if local config not exists # copy config from example if local config not exists