-
-
Notifications
You must be signed in to change notification settings - Fork 21
/
Copy pathdocker-baked.json
27 lines (27 loc) · 944 Bytes
/
docker-baked.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
{
"builders": [{
"type": "amazon-ebs",
"region": "ap-northeast-1",
"source_ami": "{{user `source_ami`}}",
"instance_type": "t2.micro",
"ssh_username": "ubuntu",
"ami_name": "packer-ubuntu-xenial-docker-{{timestamp}}"
}],
"provisioners": [{
"type": "shell",
"inline": [
"uname -a",
"sudo apt-get update",
"sudo apt-get --yes upgrade",
"sudo apt-get install apt-transport-https ca-certificates -y",
"sudo apt-key adv --keyserver hkp://p80.pool.sks-keyservers.net:80 --recv-keys 58118E89F3A912897C070ADBF76221572C52609D",
"sudo bash -c 'echo deb https://apt.dockerproject.org/repo ubuntu-xenial main > /etc/apt/sources.list.d/docker.list'",
"sudo apt-get update",
"sudo apt-cache policy docker-engine",
"sudo apt-get install docker-engine -y",
"#sudo service docker start",
"sudo docker info",
"sudo docker run hello-world"
]
}]
}