Skip to content
Branch: master
Find file Copy path
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
28 lines (22 sloc) 1.02 KB
# -*- mode: ruby -*-
# vi: set ft=ruby :
Vagrant.configure("2") do |config|
# Ask Vagrant not to randomly generate keys as we will supply our own keys
config.ssh.insert_key = false
# Tell Vagrant which private keys to use. We still need to keep the default Vagrant key
# as the next command would otherwise already try to use the Ansible key which is not yet
# in the authorized_keys file at this point in time
config.ssh.private_key_path = ['~/.vagrant.d/insecure_private_key', '~/vagrant/vagrant_key']
# Add our own key to authorized_keys file
config.vm.provision "file", source: "~/vagrant/", destination: "~/.ssh/authorized_keys"
# We set up two boxes, connected to the same private network
# with static IP addresses
config.vm.define "boxA" do |boxA| = "ubuntu/bionic64" "private_network", ip: ""
config.vm.define "boxB" do |boxB| = "ubuntu/bionic64" "private_network", ip: ""
You can’t perform that action at this time.