Vagrant.require_version ">= 1.7.0"
Vagrant.configure(2) do |config|
config.vm.box = "ubuntu/trusty64"
config.vm.define "example_server" # This is the fixed name in the host file and is referenced by playbooks
config.vm.provider "virtualbox" do |v|
v.memory = 8192
v.cpus = 4
end
config.ssh.forward_agent = true
# Setup the Deployment user
config.vm.provision "deployuser", type: "ansible" do |ansible|
ansible.verbose = "v"
ansible.playbook = "add_deployment_user.yml"
ansible.inventory_path = "inventories/example.hosts"
ansible.extra_vars = {
ansible_ssh_host: "127.0.0.1",
ansible_ssh_port: config.ssh.port
}
end
end