-
Notifications
You must be signed in to change notification settings - Fork 0
/
Vagrantfile
48 lines (37 loc) · 1.39 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
43
44
45
46
47
48
# -*- mode: ruby -*-
# vi: set ft=ruby :
require 'yaml'
CONF = YAML::load_file("vagrant_config.yml")
Vagrant.configure("2") do |config|
config.ssh.shell = "bash -c 'BASH_ENV=/etc/profile exec bash'"
config.vm.provision "shell", path: "provision.sh"
config.vm.synced_folder ".", "/vagrant", type: "rsync", rsync__exclude: ".git/"
config.vm.provider "virtualbox" do |vb, override|
override.vm.box = "ubuntu/xenial64"
override.vm.hostname = "toolscloud-env"
override.vm.define "localvm"
override.vm.network "private_network", ip: "192.168.33.10"
vb.name = "toolscloud-env"
vb.memory = 3072
vb.cpus = 2
end
config.vm.provider "aws" do |aws, override|
override.vm.box = "ubuntu_aws"
override.vm.box_url = "https://github.com/mitchellh/vagrant-aws/raw/master/dummy.box"
override.ssh.username = "ubuntu"
override.ssh.private_key_path = CONF["ssh_private_key_path"]
aws.access_key_id = CONF["access_key_id"]
aws.secret_access_key = CONF["secret_access_key"]
aws.keypair_name = CONF["aws_keypair_name"]
aws.security_groups = CONF["aws_security_groups"]
aws.ami = "ami-b09da8d0"
aws.instance_type = "m5.large"
aws.region = "us-west-1"
aws.block_device_mapping = [{
'DeviceName' => '/dev/sda1',
'Ebs.VolumeSize' => 20,
'Ebs.VolumeType' => 'gp2',
'Ebs.DeleteOnTermination' => 'true'
}]
end
end