Moved Octavia image upload and CirrOS image identification to Ansible

Change-Id: Ief843310ce57a2d1062d86c54cd7ad6e0f705b68
(cherry picked from commit 85fa2bb2b6)
This commit is contained in:
Jakob Meng
2022-12-06 19:56:55 +01:00
parent 6592363c7c
commit ef5b217411
6 changed files with 55 additions and 49 deletions

View File

@@ -1,4 +1,15 @@
---
- name: List all images
openstack.cloud.image_info:
cloud: "{{ cloud }}"
register: images
- name: Identify CirrOS image name
set_fact:
image_name: "{{ images.openstack_images|community.general.json_query(query)|first }}"
vars:
query: "[?starts_with(name, 'cirros')].name"
- name: Create server with meta as CSV
openstack.cloud.server:
cloud: "{{ cloud }}"