metrics-for-apps: updated playbook to target bootstrap vm

Signed-off-by: David Kirwan <dkirwan@redhat.com>
This commit is contained in:
David Kirwan 2021-07-22 10:19:49 +01:00
parent 47953f5677
commit 50ffa8a458

View file

@ -16,7 +16,7 @@
# - 192.168.2.2 # - 192.168.2.2
# gateway # gateway
# deploy_host: # http server serving ignition files # deploy_host: # http server serving ignition files
- hosts: os_control_stg:ocp_controlplane_stg:ocp_workers_stg - hosts: os_control_stg:ocp_controlplane_stg:ocp_workers_stg:ocp_bootstrap_stg
user: root user: root
gather_facts: false gather_facts: false
@ -82,16 +82,16 @@
register: vm_exists register: vm_exists
tags: tags:
- kvm_deploy - kvm_deploy
when: inventory_hostname in groups['ocp_controlplane_stg'] when: inventory_hostname in groups['ocp_controlplane_stg','ocp_boostrap_stg']
- block: - block:
- name: ensure the lv for the guest is made - name: ensure the lv for the guest is made
lvol: lv={{ inventory_hostname }} vg={{ volgroup }} size={{ lvm_size }} state=present lvol: lv={{ inventory_hostname }} vg={{ volgroup }} size={{ lvm_size }} state=present
delegate_to: "{{ vmhost }}" delegate_to: "{{ vmhost }}"
when: inventory_hostname in groups['ocp_controlplane_stg'] when: inventory_hostname in groups['ocp_controlplane_stg','ocp_boostrap_stg']
- name: == OCP KVM provisioning == Deploying the OCP Virtual Guest[s] - name: == OCP KVM provisioning == Deploying the OCP Virtual Guest[s]
command: "{{ virt_install_command }}" command: "{{ virt_install_command }}"
delegate_to: "{{ vmhost }}" delegate_to: "{{ vmhost }}"
tags: tags:
- kvm_deploy - kvm_deploy
when: inventory_hostname in groups['ocp_controlplane_stg'] when: inventory_hostname in groups['ocp_controlplane_stg','ocp_boostrap_stg']
when: vm_exists is failed when: vm_exists is failed