ggiamarchi / vagrant-openstack-provider

Use Vagrant to manage OpenStack Cloud instances.
MIT License
247 stars 101 forks source link

Build host without floating IP #250

Closed rds13 closed 8 years ago

rds13 commented 8 years ago

In some cases where you have a VPN or you're building various server and only one has a floating IP it would be convenient to not force an floating IP step.

ggiamarchi commented 8 years ago

Actually, using a floating IP is not mandatory. both floating_ip_pool and floating_ip are optional.

For instance, the following Vagrantfile is valid.

Vagrant.configure('2') do |config|
  config.ssh.username = ENV['OS_SSH_USERNAME']
  config.vm.provider :openstack do |os|
    os.openstack_auth_url = ENV['OS_AUTH_URL']
    os.tenant_name        = ENV['OS_TENANT_NAME']
    os.username           = ENV['OS_USERNAME']
    os.password           = ENV['OS_PASSWORD']
    os.flavor             = ENV['OS_FLAVOR']
    os.image              = ENV['OS_IMAGE']
    os.networks          << ENV['OS_NETWORK']
  end
end

After the vagrant up, if i run vagrant ssh-config i get

Host default
  HostName 192.168.20.161
  User stack
  Port 22
  ...

That means vagrant will try to SSH into the machine using its private IP address.

Tested with vagrant 1.7.4 and vagrant-openstack-provider 0.7.0.

Did you encounter any problem ?

ggiamarchi commented 8 years ago

Closing for a long inactive time. Feel free to open a new one if there's really an issue.