Merge "Resolve upstream breakage from oooq changes"
This commit is contained in:
commit
df910d0cfa
@ -85,17 +85,17 @@ browbeat_workloads:
|
||||
# Guest images for the Overcloud
|
||||
# Note hash key name must match intended name for image upload to
|
||||
# work consistently (Ex. images['cirros'].name == 'cirros')
|
||||
images:
|
||||
centos7:
|
||||
name: centos7
|
||||
url: http://cloud.centos.org/centos/7/images/CentOS-7-x86_64-GenericCloud.qcow2
|
||||
type: qcow2
|
||||
convert_to_raw: false
|
||||
cirros:
|
||||
name: cirros
|
||||
url: http://download.cirros-cloud.net/0.3.5/cirros-0.3.5-x86_64-disk.img
|
||||
type: qcow2
|
||||
convert_to_raw: false
|
||||
browbeat_guest_images:
|
||||
centos7:
|
||||
name: centos7
|
||||
url: http://cloud.centos.org/centos/7/images/CentOS-7-x86_64-GenericCloud.qcow2
|
||||
type: qcow2
|
||||
convert_to_raw: false
|
||||
cirros:
|
||||
name: cirros
|
||||
url: http://download.cirros-cloud.net/0.3.5/cirros-0.3.5-x86_64-disk.img
|
||||
type: qcow2
|
||||
convert_to_raw: false
|
||||
|
||||
# DNS Server to add
|
||||
dns_server: 8.8.8.8
|
||||
|
@ -5,9 +5,16 @@
|
||||
|
||||
- name: Remove Non-EPEL collectd install
|
||||
yum:
|
||||
name: libcollectdclient
|
||||
name: "{{ item }}"
|
||||
state: absent
|
||||
become: true
|
||||
with_items:
|
||||
- libcollectdclient
|
||||
- collectd
|
||||
- collectd-apache
|
||||
- collectd-ceph
|
||||
- collectd-mysql
|
||||
- collectd-turbostat
|
||||
when: collectd_from_epel
|
||||
|
||||
- name: Clean Non-EPEL collectd configuration
|
||||
|
@ -1,42 +1,42 @@
|
||||
---
|
||||
#
|
||||
# Obtain/Upload images to OpenStack Cloud
|
||||
# Obtain/Upload browbeat_guest_images to OpenStack Cloud
|
||||
#
|
||||
|
||||
- name: Fetch image
|
||||
get_url:
|
||||
url: "{{ images[item].url }}"
|
||||
dest: "{{ home_dir }}/{{ images[item].name }}.{{ images[item].type }}"
|
||||
with_items: "{{ images }}"
|
||||
url: "{{ browbeat_guest_images[item].url }}"
|
||||
dest: "{{ home_dir }}/{{ browbeat_guest_images[item].name }}.{{ browbeat_guest_images[item].type }}"
|
||||
with_items: "{{ browbeat_guest_images }}"
|
||||
|
||||
- name: Determine if image exists
|
||||
shell: . {{ browbeat_venv }}/bin/activate; . {{ overcloudrc }}; openstack image list | grep '{{ images[item].name }}'
|
||||
shell: . {{ browbeat_venv }}/bin/activate; . {{ overcloudrc }}; openstack image list | grep '{{ browbeat_guest_images[item].name }}'
|
||||
register: image_exists
|
||||
ignore_errors: true
|
||||
changed_when: false
|
||||
with_items: "{{ images }}"
|
||||
with_items: "{{ browbeat_guest_images }}"
|
||||
|
||||
- name: Remove image from dictionary of images if image exists
|
||||
set_fact:
|
||||
images: "{{ images|dict_remove(item[0]) }}"
|
||||
browbeat_guest_images: "{{ browbeat_guest_images|dict_remove(item[0]) }}"
|
||||
when: "'{{ item[0] }}' in '{{ item[1].stdout }}'"
|
||||
with_nested:
|
||||
- "{{ images }}"
|
||||
- "{{ browbeat_guest_images }}"
|
||||
- "{{ image_exists.results }}"
|
||||
|
||||
- name: Convert images to raw
|
||||
command: qemu-img convert -f {{images[item].type}} -O raw {{ home_dir }}/{{ images[item].name }}.{{ images[item].type }} {{ home_dir }}/{{ images[item].name }}.raw
|
||||
when: "images[item].convert_to_raw == true"
|
||||
with_items: "{{ images }}"
|
||||
command: qemu-img convert -f {{browbeat_guest_images[item].type}} -O raw {{ home_dir }}/{{ browbeat_guest_images[item].name }}.{{ browbeat_guest_images[item].type }} {{ home_dir }}/{{ browbeat_guest_images[item].name }}.raw
|
||||
when: "browbeat_guest_images[item].convert_to_raw == true"
|
||||
with_items: "{{ browbeat_guest_images }}"
|
||||
|
||||
- name: Upload image into cloud (Newton and Ocata versions)
|
||||
shell: . {{ browbeat_venv }}/bin/activate; . {{ overcloudrc }}; openstack image create --public --disk-format={{ images[item].type }} --container-format=bare {{ images[item].name }} < {{ home_dir }}/{{ images[item].name }}.{{ images[item].type }}
|
||||
shell: . {{ browbeat_venv }}/bin/activate; . {{ overcloudrc }}; openstack image create --public --disk-format={{ browbeat_guest_images[item].type }} --container-format=bare {{ browbeat_guest_images[item].name }} < {{ home_dir }}/{{ browbeat_guest_images[item].name }}.{{ browbeat_guest_images[item].type }}
|
||||
ignore_errors: true
|
||||
when: "images[item].convert_to_raw == false"
|
||||
with_items: "{{ images }}"
|
||||
when: "browbeat_guest_images[item].convert_to_raw == false"
|
||||
with_items: "{{ browbeat_guest_images }}"
|
||||
|
||||
- name: Upload raw image into cloud (Newton and Ocata versions)
|
||||
shell: . {{ browbeat_venv }}/bin/activate; . {{ overcloudrc }}; openstack image create --public --disk-format=raw --container-format=bare {{ images[item].name }} < {{ home_dir }}/{{ images[item].name }}.raw
|
||||
shell: . {{ browbeat_venv }}/bin/activate; . {{ overcloudrc }}; openstack image create --public --disk-format=raw --container-format=bare {{ browbeat_guest_images[item].name }} < {{ home_dir }}/{{ browbeat_guest_images[item].name }}.raw
|
||||
ignore_errors: true
|
||||
when: "images[item].convert_to_raw == true"
|
||||
with_items: "{{ images }}"
|
||||
when: "browbeat_guest_images[item].convert_to_raw == true"
|
||||
with_items: "{{ browbeat_guest_images }}"
|
||||
|
@ -2,7 +2,7 @@
|
||||
#Collect and template Metadata about the deployment
|
||||
|
||||
- name: Get Overcloud Image Build date
|
||||
shell: "curl -s -v -X HEAD {{ undercloud_image_url }} 2>&1 | grep '^< Date:'"
|
||||
shell: "curl -s -v -X HEAD {{ overcloud_image_url }} 2>&1 | grep '^< Date:'"
|
||||
register: build
|
||||
ignore_errors: true
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user