Merge "pcs commands on host: rabbitmq" into stable/train

This commit is contained in:
Zuul 2021-02-23 22:21:23 +00:00 committed by Gerrit Code Review
commit 56f6cf5ce1
3 changed files with 78 additions and 57 deletions

View File

@ -192,7 +192,7 @@ outputs:
- {get_param: RabbitCookie}
- {get_param: [DefaultPasswords, rabbit_cookie]}
step_2:
rabbitmq_init_bundle:
rabbitmq_wait_bundle:
start_order: 0
detach: false
net: host
@ -202,8 +202,8 @@ outputs:
list_concat:
- - '/container_puppet_apply.sh'
- '2'
- 'file,file_line,concat,augeas,pacemaker::resource::bundle,pacemaker::property,pacemaker::resource::ocf,pacemaker::constraint::order,pacemaker::constraint::colocation,rabbitmq_policy,rabbitmq_user,rabbitmq_ready'
- 'include ::tripleo::profile::base::pacemaker;include ::tripleo::profile::pacemaker::rabbitmq_bundle'
- 'file,file_line,concat,augeas,rabbitmq_policy,rabbitmq_user,rabbitmq_ready'
- 'include tripleo::profile::pacemaker::rabbitmq_bundle'
- if:
- puppet_debug_enabled
- - '--debug'
@ -224,21 +224,6 @@ outputs:
# NOTE: this should force this container to re-run on each
# update (scale-out, etc.)
TRIPLEO_DEPLOY_IDENTIFIER: {get_param: DeployIdentifier}
rabbitmq_restart_bundle:
start_order: 5
config_volume: rabbitmq
detach: false
net: host
ipc: host
user: root
environment:
TRIPLEO_MINOR_UPDATE: ''
command: /var/lib/container-config-scripts/pacemaker_restart_bundle.sh oslo_messaging_notify rabbitmq rabbitmq-bundle Started
image: {get_param: ContainerRabbitmqImage}
volumes:
list_concat:
- {get_attr: [ContainersCommon, pacemaker_restart_volumes]}
- - /var/lib/config-data/puppet-generated/rabbitmq:/var/lib/kolla/config_files/src:ro
host_prep_tasks:
- name: create persistent directories
file:
@ -264,6 +249,21 @@ outputs:
vars:
container_image: {get_param: ContainerRabbitmqImage}
container_image_latest: *rabbitmq_image_pcmklatest
- name: RabbitMQ Notify HA Wrappers Step
when: step|int == 2
block: &oslo_messaging_notify_puppet_bundle
- name: RabbitMQ notify puppet bundle
import_role:
name: tripleo_ha_wrapper
vars:
tripleo_ha_wrapper_service_name: oslo_messaging_notify
tripleo_ha_wrapper_resource_name: rabbitmq
tripleo_ha_wrapper_bundle_name: rabbitmq-bundle
tripleo_ha_wrapper_resource_state: Started
tripleo_ha_wrapper_puppet_config_volume: rabbitmq
tripleo_ha_wrapper_puppet_execute: '["Rabbitmq_policy", "Rabbitmq_user"].each |String $val| { noop_resource($val) }; include ::tripleo::profile::base::pacemaker; include ::tripleo::profile::pacemaker::rabbitmq_bundle'
tripleo_ha_wrapper_puppet_tags: 'pacemaker::resource::bundle,pacemaker::property,pacemaker::resource::ip,pacemaker::resource::ocf,pacemaker::constraint::order,pacemaker::constraint::colocation'
tripleo_ha_wrapper_puppet_debug: {get_param: ConfigDebug}
update_tasks:
- name: Rabbit fetch and retag container image for pacemaker
@ -295,6 +295,13 @@ outputs:
when:
- old_rabbitmq_image_id.stdout != new_rabbitmq_image_id.stdout
post_update_tasks:
- name: Rabbitmq notify bundle post update
when: step|int == 1
block: *oslo_messaging_notify_puppet_bundle
vars:
tripleo_ha_wrapper_minor_update: true
upgrade_tasks:
- name: Prepare switch of rabbitmq image name
when:
@ -401,7 +408,7 @@ outputs:
name: tripleo-container-rm
vars:
tripleo_containers_to_rm:
- rabbitmq_init_bundle
- rabbitmq_wait_bundle
when:
- oslo_messaging_notify_short_node_names_upgraded | length > 1
- name: add the oslo_messaging_notify short name to hiera data for the upgrade.

View File

@ -192,7 +192,7 @@ outputs:
- {get_param: RabbitCookie}
- {get_param: [DefaultPasswords, rabbit_cookie]}
step_2:
rabbitmq_init_bundle:
rabbitmq_wait_bundle:
start_order: 0
detach: false
net: host
@ -202,8 +202,8 @@ outputs:
list_concat:
- - '/container_puppet_apply.sh'
- '2'
- 'file,file_line,concat,augeas,pacemaker::resource::bundle,pacemaker::property,pacemaker::resource::ocf,pacemaker::constraint::order,pacemaker::constraint::colocation,rabbitmq_policy,rabbitmq_user,rabbitmq_ready'
- 'include ::tripleo::profile::base::pacemaker;include ::tripleo::profile::pacemaker::rabbitmq_bundle'
- 'file,file_line,concat,augeas,rabbitmq_policy,rabbitmq_user,rabbitmq_ready'
- 'include tripleo::profile::pacemaker::rabbitmq_bundle'
- if:
- puppet_debug_enabled
- - '--debug'
@ -224,21 +224,6 @@ outputs:
# NOTE: this should force this container to re-run on each
# update (scale-out, etc.)
TRIPLEO_DEPLOY_IDENTIFIER: {get_param: DeployIdentifier}
rabbitmq_restart_bundle:
start_order: 6
config_volume: rabbitmq
detach: false
net: host
ipc: host
user: root
environment:
TRIPLEO_MINOR_UPDATE: ''
command: /var/lib/container-config-scripts/pacemaker_restart_bundle.sh rabbitmq rabbitmq rabbitmq-bundle Started
image: {get_param: ContainerRabbitmqImage}
volumes:
list_concat:
- {get_attr: [ContainersCommon, pacemaker_restart_volumes]}
- - /var/lib/config-data/puppet-generated/rabbitmq:/var/lib/kolla/config_files/src:ro
host_prep_tasks:
- name: create persistent directories
file:
@ -264,6 +249,21 @@ outputs:
vars:
container_image: {get_param: ContainerRabbitmqImage}
container_image_latest: *rabbitmq_image_pcmklatest
- name: RabbitMQ HA Wrappers Step
when: step|int == 2
block: &rabbitmq_puppet_bundle
- name: Rabbitmq puppet bundle
import_role:
name: tripleo_ha_wrapper
vars:
tripleo_ha_wrapper_service_name: rabbitmq
tripleo_ha_wrapper_resource_name: rabbitmq
tripleo_ha_wrapper_bundle_name: rabbitmq-bundle
tripleo_ha_wrapper_resource_state: Started
tripleo_ha_wrapper_puppet_config_volume: rabbitmq
tripleo_ha_wrapper_puppet_execute: '["Rabbitmq_policy", "Rabbitmq_user"].each |String $val| { noop_resource($val) }; include ::tripleo::profile::base::pacemaker; include ::tripleo::profile::pacemaker::rabbitmq_bundle'
tripleo_ha_wrapper_puppet_tags: 'pacemaker::resource::bundle,pacemaker::property,pacemaker::resource::ip,pacemaker::resource::ocf,pacemaker::constraint::order,pacemaker::constraint::colocation'
tripleo_ha_wrapper_puppet_debug: {get_param: ConfigDebug}
update_tasks:
- name: Rabbit fetch and retag container image for pacemaker
@ -295,6 +295,13 @@ outputs:
when:
- old_rabbitmq_image_id.stdout != new_rabbitmq_image_id.stdout
post_update_tasks:
- name: Rabbitmq bundle post update
when: step|int == 1
block: *rabbitmq_puppet_bundle
vars:
tripleo_ha_wrapper_minor_update: true
upgrade_tasks:
- name: Prepare switch of rabbitmq image name
when:
@ -398,7 +405,7 @@ outputs:
name: tripleo-container-rm
vars:
tripleo_containers_to_rm:
- rabbitmq_init_bundle
- rabbitmq_wait_bundle
when:
- rabbitmq_short_node_names_upgraded | length > 1
- name: add the rabbitmq short name to hiera data for the upgrade.

View File

@ -192,7 +192,7 @@ outputs:
- {get_param: RabbitCookie}
- {get_param: [DefaultPasswords, rabbit_cookie]}
step_2:
rabbitmq_init_bundle:
rabbitmq_wait_bundle:
start_order: 0
detach: false
net: host
@ -202,8 +202,8 @@ outputs:
list_concat:
- - '/container_puppet_apply.sh'
- '2'
- 'file,file_line,concat,augeas,pacemaker::resource::bundle,pacemaker::property,pacemaker::resource::ocf,pacemaker::constraint::order,pacemaker::constraint::colocation,rabbitmq_policy,rabbitmq_user,rabbitmq_ready'
- 'include ::tripleo::profile::base::pacemaker;include ::tripleo::profile::pacemaker::rabbitmq_bundle'
- 'file,file_line,concat,augeas,rabbitmq_policy,rabbitmq_user,rabbitmq_ready'
- 'include tripleo::profile::pacemaker::rabbitmq_bundle'
- if:
- puppet_debug_enabled
- - '--debug'
@ -230,21 +230,6 @@ outputs:
passwords:
- {get_param: RabbitCookie}
- {get_param: [DefaultPasswords, rabbit_cookie]}
rabbitmq_restart_bundle:
start_order: 4
config_volume: rabbitmq
detach: false
net: host
ipc: host
user: root
environment:
TRIPLEO_MINOR_UPDATE: ''
command: /var/lib/container-config-scripts/pacemaker_restart_bundle.sh oslo_messaging_rpc rabbitmq rabbitmq-bundle Started
image: {get_param: ContainerRabbitmqImage}
volumes:
list_concat:
- {get_attr: [ContainersCommon, pacemaker_restart_volumes]}
- - /var/lib/config-data/puppet-generated/rabbitmq:/var/lib/kolla/config_files/src:ro
metadata_settings:
get_attr: [RabbitmqBase, role_data, metadata_settings]
host_prep_tasks:
@ -270,6 +255,21 @@ outputs:
vars:
container_image: {get_param: ContainerRabbitmqImage}
container_image_latest: *rabbitmq_image_pcmklatest
- name: RabbitMQ RPC HA Wrappers Step
when: step|int == 2
block: &oslo_messaging_rpc_puppet_bundle
- name: Rabbitmq rpc puppet bundle
import_role:
name: tripleo_ha_wrapper
vars:
tripleo_ha_wrapper_service_name: oslo_messaging_rpc
tripleo_ha_wrapper_resource_name: rabbitmq
tripleo_ha_wrapper_bundle_name: rabbitmq-bundle
tripleo_ha_wrapper_resource_state: Started
tripleo_ha_wrapper_puppet_config_volume: rabbitmq
tripleo_ha_wrapper_puppet_execute: '["Rabbitmq_policy", "Rabbitmq_user"].each |String $val| { noop_resource($val) }; include ::tripleo::profile::base::pacemaker; include ::tripleo::profile::pacemaker::rabbitmq_bundle'
tripleo_ha_wrapper_puppet_tags: 'pacemaker::resource::bundle,pacemaker::property,pacemaker::resource::ip,pacemaker::resource::ocf,pacemaker::constraint::order,pacemaker::constraint::colocation'
tripleo_ha_wrapper_puppet_debug: {get_param: ConfigDebug}
update_tasks:
- name: Rabbit fetch and retag container image for pacemaker
@ -301,6 +301,13 @@ outputs:
when:
- old_rabbitmq_image_id.stdout != new_rabbitmq_image_id.stdout
post_update_tasks:
- name: Rabbitmq rpc bundle post update
when: step|int == 1
block: *oslo_messaging_rpc_puppet_bundle
vars:
tripleo_ha_wrapper_minor_update: true
upgrade_tasks:
- name: Prepare switch of rabbitmq image name
when:
@ -407,7 +414,7 @@ outputs:
name: tripleo-container-rm
vars:
tripleo_containers_to_rm:
- rabbitmq_init_bundle
- rabbitmq_wait_bundle
when:
- oslo_messaging_rpc_short_node_names_upgraded | length > 1
- name: add the oslo_messaging_rpc short name to hiera data for the upgrade.