You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have been using vagrant-env to set ip addresses for the VM's but not being able to set in some use cases, and vagrant up fails with the following error:
Bringing machine 'server' up with 'libvirt' provider...
/usr/share/ruby/ipaddr.rb:560:in `in6_addr': invalid address (IPAddr::InvalidAddressError)
from /usr/share/ruby/ipaddr.rb:497:in `initialize'
from /home/technoman/.vagrant.d/gems/gems/vagrant-libvirt-0.0.36/lib/vagrant-libvirt/action/create_networks.rb:264:in `new'
from /home/technoman/.vagrant.d/gems/gems/vagrant-libvirt-0.0.36/lib/vagrant-libvirt/action/create_networks.rb:264:in `get_host_ip_addr'
from /home/technoman/.vagrant.d/gems/gems/vagrant-libvirt-0.0.36/lib/vagrant-libvirt/action/create_networks.rb:126:in `handle_ip_option'
from /home/technoman/.vagrant.d/gems/gems/vagrant-libvirt-0.0.36/lib/vagrant-libvirt/action/create_networks.rb:66:in `block (2 levels) in call'
from /home/technoman/.vagrant.d/gems/gems/vagrant-libvirt-0.0.36/lib/vagrant-libvirt/action/create_networks.rb:36:in `each'
from /home/technoman/.vagrant.d/gems/gems/vagrant-libvirt-0.0.36/lib/vagrant-libvirt/action/create_networks.rb:36:in `block in call'
from /home/technoman/.vagrant.d/gems/gems/vagrant-libvirt-0.0.36/lib/vagrant-libvirt/action/create_networks.rb:33:in `synchronize'
from /home/technoman/.vagrant.d/gems/gems/vagrant-libvirt-0.0.36/lib/vagrant-libvirt/action/create_networks.rb:33:in `call'
from /usr/share/vagrant/lib/vagrant/action/warden.rb:34:in `call'
from /home/technoman/.vagrant.d/gems/gems/vagrant-cachier-1.2.1/lib/vagrant-cachier/action/install_buckets.rb:14:in `call'
from /usr/share/vagrant/lib/vagrant/action/warden.rb:34:in `call'
from /usr/share/vagrant/lib/vagrant/action/builtin/provision.rb:80:in `call'
from /usr/share/vagrant/lib/vagrant/action/warden.rb:34:in `call'
from /home/technoman/.vagrant.d/gems/gems/vagrant-cachier-1.2.1/lib/vagrant-cachier/action/configure_bucket_root.rb:20:in `call'
from /usr/share/vagrant/lib/vagrant/action/warden.rb:34:in `call'
from /usr/share/vagrant/lib/vagrant/action/warden.rb:95:in `block in finalize_action'
from /usr/share/vagrant/lib/vagrant/action/warden.rb:34:in `call'
from /usr/share/vagrant/lib/vagrant/action/builder.rb:116:in `call'
from /usr/share/vagrant/lib/vagrant/action/runner.rb:66:in `block in run'
from /usr/share/vagrant/lib/vagrant/util/busy.rb:19:in `busy'
from /usr/share/vagrant/lib/vagrant/action/runner.rb:66:in `run'
from /usr/share/vagrant/lib/vagrant/action/builtin/call.rb:53:in `call'
from /usr/share/vagrant/lib/vagrant/action/warden.rb:34:in `call'
from /usr/share/vagrant/lib/vagrant/action/warden.rb:95:in `block in finalize_action'
from /usr/share/vagrant/lib/vagrant/action/warden.rb:34:in `call'
from /usr/share/vagrant/lib/vagrant/action/builder.rb:116:in `call'
from /usr/share/vagrant/lib/vagrant/action/runner.rb:66:in `block in run'
from /usr/share/vagrant/lib/vagrant/util/busy.rb:19:in `busy'
from /usr/share/vagrant/lib/vagrant/action/runner.rb:66:in `run'
from /usr/share/vagrant/lib/vagrant/action/builtin/call.rb:53:in `call'
from /usr/share/vagrant/lib/vagrant/action/warden.rb:34:in `call'
from /usr/share/vagrant/lib/vagrant/action/builtin/config_validate.rb:25:in `call'
from /usr/share/vagrant/lib/vagrant/action/warden.rb:34:in `call'
from /usr/share/vagrant/lib/vagrant/action/warden.rb:95:in `block in finalize_action'
from /usr/share/vagrant/lib/vagrant/action/warden.rb:34:in `call'
from /usr/share/vagrant/lib/vagrant/action/builder.rb:116:in `call'
from /usr/share/vagrant/lib/vagrant/action/runner.rb:66:in `block in run'
from /usr/share/vagrant/lib/vagrant/util/busy.rb:19:in `busy'
from /usr/share/vagrant/lib/vagrant/action/runner.rb:66:in `run'
from /usr/share/vagrant/lib/vagrant/action/builtin/call.rb:53:in `call'
from /usr/share/vagrant/lib/vagrant/action/warden.rb:34:in `call'
from /usr/share/vagrant/lib/vagrant/action/builtin/config_validate.rb:25:in `call'
from /usr/share/vagrant/lib/vagrant/action/warden.rb:34:in `call'
from /home/technoman/.vagrant.d/gems/gems/vagrant-triggers-0.5.3/lib/vagrant-triggers/action/trigger.rb:17:in `call'
from /usr/share/vagrant/lib/vagrant/action/warden.rb:34:in `call'
from /home/technoman/.vagrant.d/gems/gems/vagrant-triggers-0.5.3/lib/vagrant-triggers/action/trigger.rb:17:in `call'
from /usr/share/vagrant/lib/vagrant/action/warden.rb:34:in `call'
from /home/technoman/.vagrant.d/gems/gems/vagrant-triggers-0.5.3/lib/vagrant-triggers/action/trigger.rb:17:in `call'
from /usr/share/vagrant/lib/vagrant/action/warden.rb:34:in `call'
from /usr/share/vagrant/lib/vagrant/action/builder.rb:116:in `call'
from /usr/share/vagrant/lib/vagrant/action/runner.rb:66:in `block in run'
from /usr/share/vagrant/lib/vagrant/util/busy.rb:19:in `busy'
from /usr/share/vagrant/lib/vagrant/action/runner.rb:66:in `run'
from /usr/share/vagrant/lib/vagrant/machine.rb:224:in `action_raw'
from /usr/share/vagrant/lib/vagrant/machine.rb:199:in `block in action'
from /usr/share/vagrant/lib/vagrant/environment.rb:561:in `lock'
from /usr/share/vagrant/lib/vagrant/machine.rb:185:in `call'
from /usr/share/vagrant/lib/vagrant/machine.rb:185:in `action'
from /usr/share/vagrant/lib/vagrant/batch_action.rb:82:in `block (2 levels) in run'
The issue here is probably that when you source .env from your shell, the values such as SERVER_IP2 are properly interpolated by your shell.
When the .env file is imported via this plugin that doesn't happen, so the literal value of ENV('SERVER_IP2') as far as your Vagrantfile is concerned is $(echo $SERVER_IP1 | cut -d "." -f 1-3).$((($(echo $SERVER_IP | cut -d "." -f 4)+10))) instead of the expected 192.168.14.31.
I have been using vagrant-env to set ip addresses for the VM's but not being able to set in some use cases, and
vagrant up
fails with the following error:My .env file
My Vagrant file
vagrant up
fails but does not fail if i dosource scripts/.env
beforevagrant up
.The text was updated successfully, but these errors were encountered: