-
Notifications
You must be signed in to change notification settings - Fork 12
/
intermediate-centos-7.4.json
32 lines (30 loc) · 1.24 KB
/
intermediate-centos-7.4.json
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
{
"variables": {
"name": "Intermediate Training - CentOS 7.4 - 0.0.15",
"workstation_version": "0.2.43"
},
"builders": [{
"ssh_username": "chef",
"ssh_password": "Cod3Can!",
"type": "amazon-ebs",
"ssh_pty": true,
"region": "us-east-1",
"instance_type": "m3.medium",
"source_ami": "ami-05e6876ba54c79c28",
"ami_name": "{{user `name`}}"
}],
"provisioners": [{
"type": "shell",
"inline": [
"echo 'The base image updated cloud-init. Waiting for cloud-init to finish (~ 5 minutes).'",
"while [ ! -f /var/lib/cloud/instance/boot-finished ]; do echo 'Waiting 15 seconds for cloud-init...'; sleep 15; done",
"curl https://omnitruck.chef.io/install.sh | sudo bash -s -- -v {{user `workstation_version`}} -c stable -P chef-workstation",
"sudo yum install -y git tree wget",
"mkdir /home/chef/.chef",
"git clone https://github.com/chef-training/chef-generator.git /home/chef/.chef/generator",
"echo 'chefdk.generator_cookbook = \"/home/chef/.chef/generator\"' > /home/chef/.chef/config.rb",
"git clone -b extending-cookbooks https://github.com/chef-training/chef-intermediate-repo.git /home/chef/day2-repo",
"/usr/bin/chef gem install kitchen-docker"
]
}]
}