aboutsummaryrefslogtreecommitdiffstats
path: root/packer
diff options
context:
space:
mode:
authorJan-Simon Moeller <jsmoeller@linuxfoundation.org>2017-01-25 22:19:29 +0000
committerGerrit Code Review <gerrit@automotivelinux.org>2017-01-25 22:19:29 +0000
commitc7afa2e9eb426b05fe178a3c6935d620830efb6b (patch)
treeb092d12b41e26f86a638bc52c40bbdac7413556c /packer
parent06839a4144754e07bb545c33a9532a30e9150d9a (diff)
parent0c95abf26a191a2980a9e023145c2736451e279c (diff)
Merge "Properly name basebuild images after slave label"
Diffstat (limited to 'packer')
-rw-r--r--packer/templates/basebuild-agl-test-slave.json54
-rw-r--r--packer/templates/basebuild.json9
2 files changed, 55 insertions, 8 deletions
diff --git a/packer/templates/basebuild-agl-test-slave.json b/packer/templates/basebuild-agl-test-slave.json
new file mode 100644
index 00000000..3490fd55
--- /dev/null
+++ b/packer/templates/basebuild-agl-test-slave.json
@@ -0,0 +1,54 @@
+{
+ "variables": {
+ "stack_tenant": null,
+ "stack_user": null,
+ "stack_pass": null,
+ "stack_network": null,
+
+ "base_image": null,
+ "cloud_user": null,
+ "distro": null,
+ "cloud_user_data": null
+ },
+ "builders": [
+ {
+ "type": "openstack",
+ "identity_endpoint": "https://auth.vexxhost.net/v2.0/",
+ "tenant_name": "{{user `stack_tenant`}}",
+ "username": "{{user `stack_user`}}",
+ "password": "{{user `stack_pass`}}",
+ "region": "ca-ymq-1",
+ "ssh_username": "{{user `cloud_user`}}",
+ "image_name": "{{user `distro`}} - basebuild-agl-test-slave - {{isotime \"20060102-1504\"}}",
+ "source_image_name": "{{user `base_image`}}",
+ "flavor": "v1-standard-1",
+ "availability_zone": "ca-ymq-2",
+ "networks": [
+ "{{user `stack_network`}}"
+ ],
+ "user_data_file": "{{user `cloud_user_data`}}"
+ }
+ ],
+ "provisioners": [
+ {
+ "type": "shell",
+ "inline": ["mkdir -p /tmp/packer"]
+ },
+ {
+ "type": "file",
+ "source": "provision/basebuild/",
+ "destination": "/tmp/packer"
+ },
+ {
+ "type": "shell",
+ "scripts": [
+ "provision/baseline.sh",
+ "provision/basebuild.sh",
+ "provision/agl_dependencies.sh",
+ "provision/agl_mirror.sh",
+ "provision/system_reseal.sh"
+ ],
+ "execute_command": "chmod +x {{ .Path }}; if [ \"$UID\" == \"0\" ]; then {{ .Vars }} '{{ .Path }}'; else {{ .Vars }} sudo -E '{{ .Path }}'; fi"
+ }
+ ]
+}
diff --git a/packer/templates/basebuild.json b/packer/templates/basebuild.json
index 8e60b5f9..32fe67a4 100644
--- a/packer/templates/basebuild.json
+++ b/packer/templates/basebuild.json
@@ -41,16 +41,9 @@
},
{
"type": "shell",
- "environment_vars": [
- "LAVAHOST={{user `lavahost`}}",
- "LAVAUSER={{user `lavauser`}}",
- "LAVATOKEN={{user `lavatoken`}}"
- ],
"scripts": [
"provision/baseline.sh",
- "provision/basebuild.sh",
- "provision/agl_dependencies.sh",
- "provision/agl_mirror.sh",
+ "provision/basebuild-no-tmpfs.sh",
"provision/system_reseal.sh"
],
"execute_command": "chmod +x {{ .Path }}; if [ \"$UID\" == \"0\" ]; then {{ .Vars }} '{{ .Path }}'; else {{ .Vars }} sudo -E '{{ .Path }}'; fi"