Add example repo config for installing Li SR4 RPM
[integration/packaging.git] / packer / centos.json
1 {
2   "variables": {
3     "box_version": null,
4     "docker_version": null,
5     "docker_name": null
6   },
7   "builders": [
8     {
9       "type": "qemu",
10       "iso_urls":
11         [
12           "http://mirrors.rit.edu/centos/7.2.1511/isos/x86_64/CentOS-7-x86_64-Minimal-1511.iso",
13           "http://mirrors.usc.edu/pub/linux/distributions/centos/7.2.1511/isos/x86_64/CentOS-7-x86_64-Minimal-1511.iso",
14           "http://centos.eecs.wsu.edu/7.2.1511/isos/x86_64/CentOS-7-x86_64-Minimal-1511.iso",
15           "http://mirror.lug.udel.edu/pub/centos/7.2.1511/isos/x86_64/CentOS-7-x86_64-Minimal-1511.iso",
16           "http://mirror.cc.columbia.edu/pub/linux/centos/7.2.1511/isos/x86_64/CentOS-7-x86_64-Minimal-1511.iso"
17         ],
18       "iso_checksum": "f90e4d28fa377669b2db16cbcb451fcb9a89d2460e3645993e30e137ac37d284",
19       "iso_checksum_type": "sha256",
20       "ssh_username": "vagrant",
21       "ssh_password": "vagrant",
22       "ssh_wait_timeout": "20m",
23       "shutdown_command": "sudo shutdown -P now",
24       "http_directory": ".",
25       "boot_command":
26         [
27         "<tab>text ks=http://{{ .HTTPIP }}:{{ .HTTPPort }}/centos_kickstart.cfg<enter>"
28         ]
29     },
30     {
31       "type": "virtualbox-iso",
32       "guest_os_type": "RedHat_64",
33       "iso_urls":
34         [
35           "http://mirrors.seas.harvard.edu/centos/7/isos/x86_64/CentOS-7-x86_64-Minimal-1503-01.iso",
36           "http://bay.uchicago.edu/centos/7/isos/x86_64/CentOS-7-x86_64-Minimal-1503-01.iso",
37           "http://mirror.vcu.edu/pub/gnu+linux/centos/7/isos/x86_64/CentOS-7-x86_64-Minimal-1503-01.iso",
38           "http://mirror.vtti.vt.edu/centos/7/isos/x86_64/CentOS-7-x86_64-Minimal-1503-01.iso",
39           "http://mirror.clarkson.edu/centos/7/isos/x86_64/CentOS-7-x86_64-Minimal-1503-01.iso"
40         ],
41       "iso_checksum": "7cf1ac8da13f54d6be41e3ccf228dc5bb35792f515642755ff4780d5714d4278",
42       "iso_checksum_type": "sha256",
43       "headless": "false",
44       "ssh_username": "vagrant",
45       "ssh_password": "vagrant",
46       "ssh_wait_timeout": "20m",
47       "shutdown_command": "sudo shutdown -P now",
48       "http_directory": ".",
49       "boot_command": [
50         "<tab>text ks=http://{{ .HTTPIP }}:{{ .HTTPPort }}/centos_kickstart.cfg<enter>"
51       ],
52       "vboxmanage": [
53         [
54           "modifyvm",
55           "{{ .Name }}",
56           "--memory",
57           "1024"
58         ],
59         [
60           "modifyvm",
61           "{{ .Name }}",
62           "--cpus",
63           "2"
64         ]
65       ]
66     },
67     {
68       "type": "docker",
69       "image": "centos:7.1.1503",
70       "pull": false,
71       "commit": true
72     }
73   ],
74   "provisioners": [
75     {
76       "type": "shell",
77       "scripts":
78         [
79           "config_vagrant.sh",
80           "config_ansible.sh"
81         ],
82       "only":
83         [
84           "qemu"
85         ]
86     },
87     {
88       "type": "shell",
89       "scripts":
90         [
91           "config_virtualbox.sh",
92           "config_vagrant.sh",
93           "config_ansible.sh"
94         ],
95       "only":
96         [
97           "virtualbox-iso"
98         ]
99     },
100     {
101       "type": "shell",
102       "scripts":
103         [
104           "config_docker.sh",
105           "config_ansible.sh"
106         ],
107       "only":
108         [
109           "docker"
110         ]
111     },
112     {
113       "type": "ansible-local",
114       "playbook_file": "install_odl.yml"
115     }
116   ],
117   "post-processors": [
118     {
119       "type": "vagrant",
120       "compression_level": "9",
121       "output": "opendaylight-{{ user `box_version` }}-centos-7.2.1511-libvirt.box",
122       "only": ["qemu"]
123     },
124     {
125       "type": "vagrant",
126       "compression_level": "9",
127       "output": "opendaylight-{{ user `box_version` }}-centos-1503-virtualbox.box",
128       "only": ["virtualbox-iso"]
129     },
130     {
131       "type": "docker-tag",
132       "repository": "{{ user `docker_name` }}",
133       "tag": "{{ user `docker_version` }}",
134       "force": true,
135       "only": ["docker"]
136     }
137   ]
138 }