make image downloading modular
diff --git a/roles/xos-vm-install/files/xos-setup-cord-pod-playbook.yml b/roles/xos-vm-install/files/xos-setup-cord-pod-playbook.yml
index 549ddc9..79b25d2 100644
--- a/roles/xos-vm-install/files/xos-setup-cord-pod-playbook.yml
+++ b/roles/xos-vm-install/files/xos-setup-cord-pod-playbook.yml
@@ -44,9 +44,10 @@
- name: download software image
get_url:
- url=http://www.vicci.org/opencloud/trusty-server-cloudimg-amd64-disk1.img
- checksum=sha256:5fb160ea09649f9cebe5cfd7aaf3d1a341e8e0f9eca6e52e46eb6271155c48b0
- dest={{ xos_repo_dest }}/xos/configurations/{{ xos_configuration }}/images/trusty-server-multi-nic.img
+ url={{ item.url }}
+ checksum={{ item.checksum }}
+ dest={{ xos_repo_dest }}/xos/configurations/{{ xos_configuration }}/images/{{ item.name }}.img
+ with_items: "{{ xos_images }}"
- name: Pull docker images for XOS
shell: "cd {{ xos_repo_dest }}/xos/configurations/{{ xos_configuration }}; sudo docker-compose pull"
diff --git a/roles/xos-vm-install/templates/xos-setup-vars.yml.j2 b/roles/xos-vm-install/templates/xos-setup-vars.yml.j2
index 415a079..2d5ab15 100644
--- a/roles/xos-vm-install/templates/xos-setup-vars.yml.j2
+++ b/roles/xos-vm-install/templates/xos-setup-vars.yml.j2
@@ -6,3 +6,5 @@
xos_configuration: "{{ xos_configuration }}"
+xos_images:
+{{ xos_images | to_nice_yaml }}
diff --git a/vars/cord.yml b/vars/cord.yml
index e8e5081..c8a7c87 100644
--- a/vars/cord.yml
+++ b/vars/cord.yml
@@ -34,3 +34,14 @@
unbound_listen_on_default: True
+xos_images:
+ - name: "trusty-server-multi-nic"
+ url: "http://www.vicci.org/opencloud/trusty-server-cloudimg-amd64-disk1.img"
+ checksum: "sha256:5fb160ea09649f9cebe5cfd7aaf3d1a341e8e0f9eca6e52e46eb6271155c48b0"
+ - name: "vsg-1.0"
+ url: "http://www.vicci.org/cord/vsg-1.0.img"
+ checksum: "sha256:ba1f1dfd9099a21ed6512f9e08ceddafbc8302dcc0da66eda3a0318281219abc"
+# - name: ceilometer-trusty-server-multi-nic
+# image_url: "http://www.vicci.org/cord/ceilometer-trusty-server-multi-nic.compressed.qcow2"
+# checksum: "sha256:afde3f0448483902693be4d52ae76bb683fd74b1c7728019094bf81b37d86105"
+