|
54 | 54 | #
|
55 | 55 | # REFERENCE:
|
56 | 56 | #
|
57 |
| -# system('scripts/pre-vagrant.sh') |
| 57 | +# system('scripts/before-vagrant.sh') |
58 | 58 | #
|
59 |
| -# This line calls a `pre-vagrant.sh` script to be run before |
60 |
| -# any other part of Vagrantfile is run. |
| 59 | +# This line calls a `before-vagrant.sh` script to be run |
| 60 | +# before any other part of `Vagrantfile` is run. |
61 | 61 | #
|
62 | 62 | # Currently this script generates a random non-routable IP
|
63 | 63 | # address starting with 10 and randomly selects from 0..254
|
|
111 | 111 | # WordPress but if you have the Vagrant hosts-updater plugin
|
112 | 112 | # then it will handle updating the hosts file for you.
|
113 | 113 | #
|
114 |
| -# config.vm.network 'private_network', ip: IO.readlines('IP')[0].strip |
| 114 | +# config.vm.network 'private_network', ip: IO.read('IP').strip |
115 | 115 | #
|
116 | 116 | # This line tells Vagrant what IP address to use for the VM.
|
117 | 117 | # It loads the IP address from the file named "IP" that
|
118 |
| -# previously created by File.write(). |
| 118 | +# previously created by the script `/scripts/before-vagrant.sh` |
119 | 119 | #
|
120 | 120 | # The IP file can be found in in the project root after the
|
121 | 121 | # first "vagrant up"; the project root is the same directory
|
|
255 | 255 |
|
256 | 256 | Vagrant.configure(2) do |config|
|
257 | 257 |
|
258 |
| - system('scripts/pre-vagrant.sh') |
| 258 | + system('scripts/before-vagrant.sh') |
259 | 259 |
|
260 | 260 | config.vm.box = "wplib/wplib"
|
261 | 261 | config.vm.hostname = "wplib.box"
|
262 | 262 |
|
263 |
| - config.vm.network 'private_network', ip: IO.readlines('IP')[0].strip |
| 263 | + config.vm.network 'private_network', ip: IO.read('IP').strip |
264 | 264 |
|
265 | 265 | config.vm.synced_folder "www", "/var/www"
|
266 | 266 |
|
|
0 commit comments