-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathVagrantfile
More file actions
38 lines (30 loc) · 1.32 KB
/
Vagrantfile
File metadata and controls
38 lines (30 loc) · 1.32 KB
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
# -*- mode: ruby -*-
# vi: set ft=ruby :
Vagrant.configure(2) do |config|
# Box
config.vm.box = "ubuntu/trusty64"
# Box Configurations - more power!
config.vm.provider :virtualbox do |v|
v.customize ["modifyvm", :id, "--memory", 2048]
v.customize ["modifyvm", :id, "--cpus", 2]
v.customize ["modifyvm", :id, "--natdnshostresolver1", "on"]
v.customize ["modifyvm", :id, "--natdnsproxy1", "on"]
end
# SSH Agent Forwarding
config.ssh.forward_agent = true
# Hostnames
config.vm.hostname = "local.apptimists.com"
config.hostsupdater.aliases = ["production.apptimists.com"]
# Private Network
config.vm.network :private_network, ip: "192.168.50.15"
# Folders
config.vm.synced_folder "build_local", "/var/www/local", :owner => "www-data", :mount_options => [ "dmode=775", "fmode=774" ]
config.vm.synced_folder "build_production", "/var/www/production", :owner => "www-data", :mount_options => [ "dmode=775", "fmode=774" ]
# Provisioning
config.vm.provision "provision", type: "shell", :path => "provision.sh", args: [
"local.apptimists.com", # Local server name
"production.apptimists.com", # Production server alias
"server@apptimists.com" # Server admin
]
config.vm.provision "no-tty-fix", type: "shell", inline: "sed -i '/tty/!s/mesg n/tty -s \\&\\& mesg n/' /root/.profile"
end