-
Notifications
You must be signed in to change notification settings - Fork 0
/
Vagrantfile
executable file
·42 lines (34 loc) · 1.15 KB
/
Vagrantfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
# -*- mode: ruby -*-
# vi: set ft=ruby :
# NOTE: Variable overrides are in ./config.rb
require "yaml"
require "fileutils"
CONFIG = File.expand_path("config.rb")
if File.exist?(CONFIG)
require CONFIG
end
Vagrant.configure("2") do |config|
config.vm.define vm_name = "DevOps" do |node|
node.vm.box = $box_name
#node.vm.box_url = [file://somelocationtobox] # local install (optional)
node.vm.hostname = $box_hostname
node.vm.provider "virtualbox" do |vb|
vb.name = $box_hostname
vb.customize ["modifyvm", :id, "--memory", $box_memory]
vb.customize ["modifyvm", :id, "--cpus", $box_vcpus]
end #end vb
end #end node
if Vagrant::Util::Platform.windows?
config.vm.provision :guest_ansible do |ansible|
ansible.limit = $ansible_limit
ansible.playbook = $ansible_playbook
ansible.host_key_checking = false
end #end ansible
else
config.vm.provision :ansible do |ansible|
ansible.limit = $ansible_limit
ansible.playbook = $ansible_playbook
ansible.host_key_checking = false
end #end ansible
end
end