From e4ee042a2aaf880e9863461a7423549be3bb0aa1 Mon Sep 17 00:00:00 2001 From: Emilien Macchi Date: Tue, 4 Dec 2018 14:36:12 -0500 Subject: [PATCH] upgrade: remove tasks that stop and disable services We don't need upgrade_tasks that stop systemd services since all services are now containerized. However, we decided to keep the tasks that remove the rpms in case some of deployments didn't cleanup them in previous releases, they can still do it now. Change-Id: I6abdc9e37966cd818306f7af473958fd4662ccb5 Related-Bug: #1806733 --- deployment/aodh/aodh-api-container.yaml | 32 ---------- deployment/aodh/aodh-evaluator-container.yaml | 19 ------ deployment/aodh/aodh-listener-container.yaml | 19 ------ deployment/aodh/aodh-notifier-container.yaml | 19 ------ docker/services/barbican-api.yaml | 18 ------ docker/services/ceilometer-agent-central.yaml | 19 ------ docker/services/ceilometer-agent-compute.yaml | 33 ---------- docker/services/ceilometer-agent-ipmi.yaml | 19 ------ .../ceilometer-agent-notification.yaml | 19 ------ docker/services/cinder-api.yaml | 44 +------------ docker/services/cinder-backup.yaml | 19 ------ docker/services/cinder-scheduler.yaml | 19 ------ docker/services/cinder-volume.yaml | 19 ------ docker/services/congress.yaml | 19 ------ docker/services/database/mongodb.yaml | 21 +------ docker/services/database/mysql.yaml | 49 +-------------- docker/services/database/redis.yaml | 21 +------ docker/services/ec2-api.yaml | 35 +---------- docker/services/etcd.yaml | 21 +------ docker/services/fluentd.yaml | 17 +---- docker/services/glance-api.yaml | 19 ------ docker/services/gnocchi-api.yaml | 50 +-------------- docker/services/gnocchi-metricd.yaml | 21 +------ docker/services/gnocchi-statsd.yaml | 21 +------ docker/services/haproxy.yaml | 19 ------ docker/services/heat-api-cfn.yaml | 47 +------------- docker/services/heat-api.yaml | 51 +-------------- docker/services/heat-engine.yaml | 21 +------ docker/services/ironic-api.yaml | 50 +-------------- docker/services/ironic-conductor.yaml | 19 ------ docker/services/ironic-inspector.yaml | 22 ------- docker/services/ironic-neutron-agent.yaml | 21 +------ docker/services/iscsid.yaml | 35 +---------- docker/services/keepalived.yaml | 19 ------ docker/services/keystone.yaml | 34 ---------- docker/services/manila-api.yaml | 21 +------ docker/services/manila-scheduler.yaml | 21 +------ docker/services/manila-share.yaml | 21 +------ docker/services/memcached.yaml | 21 +------ .../services/messaging/notify-rabbitmq.yaml | 21 +------ docker/services/messaging/rpc-rabbitmq.yaml | 21 +------ docker/services/metrics/collectd.yaml | 19 ------ docker/services/mistral-api.yaml | 46 -------------- docker/services/mistral-engine.yaml | 19 ------ docker/services/mistral-event-engine.yaml | 19 ------ docker/services/mistral-executor.yaml | 19 ------ docker/services/multipathd.yaml | 21 +------ docker/services/neutron-api.yaml | 19 ------ docker/services/neutron-dhcp.yaml | 21 +------ docker/services/neutron-l3.yaml | 21 +------ docker/services/neutron-metadata.yaml | 21 +------ docker/services/neutron-ovs-agent.yaml | 20 ------ docker/services/neutron-sriov-agent.yaml | 21 +------ docker/services/nova-api.yaml | 51 +-------------- docker/services/nova-compute.yaml | 32 ---------- docker/services/nova-conductor.yaml | 31 ---------- docker/services/nova-consoleauth.yaml | 19 ------ docker/services/nova-ironic.yaml | 22 ------- docker/services/nova-libvirt.yaml | 21 +------ docker/services/nova-placement.yaml | 30 --------- docker/services/nova-scheduler.yaml | 19 ------ docker/services/nova-vnc-proxy.yaml | 19 ------ docker/services/octavia-api.yaml | 48 +------------- docker/services/octavia-health-manager.yaml | 19 ------ docker/services/octavia-housekeeping.yaml | 21 +------ docker/services/octavia-worker.yaml | 21 +------ docker/services/opendaylight-api.yaml | 19 ------ docker/services/ovn-controller.yaml | 21 +------ docker/services/ovn-dbs.yaml | 21 +------ docker/services/ovn-metadata.yaml | 21 +------ docker/services/rabbitmq.yaml | 23 +------ docker/services/sahara-api.yaml | 19 ------ docker/services/sahara-engine.yaml | 19 ------ docker/services/sensu-client.yaml | 23 +------ docker/services/swift-proxy.yaml | 24 ------- docker/services/swift-storage.yaml | 62 ------------------- docker/services/tacker.yaml | 22 +------ docker/services/tripleo-ui.yaml | 28 --------- docker/services/xinetd.yaml | 22 ------- docker/services/zaqar.yaml | 44 ------------- puppet/services/apache.j2.yaml | 22 +------ puppet/services/auditd.yaml | 20 +----- puppet/services/barbican-api.yaml | 21 +------ puppet/services/ceilometer-agent-central.yaml | 18 +----- puppet/services/ceilometer-agent-compute.yaml | 18 +----- puppet/services/ceilometer-agent-ipmi.yaml | 25 +------- .../ceilometer-agent-notification.yaml | 18 +----- puppet/services/cinder-api.yaml | 31 +--------- puppet/services/cinder-scheduler.yaml | 18 +----- puppet/services/cinder-volume.yaml | 18 +----- puppet/services/congress.yaml | 23 +------ puppet/services/database/redis.yaml | 28 +-------- .../disabled/glance-registry-disabled.yaml | 21 +------ .../heat-api-cloudwatch-disabled.yaml | 12 +--- puppet/services/ec2-api.yaml | 25 +------- puppet/services/etcd.yaml | 19 +----- puppet/services/glance-api.yaml | 30 +-------- puppet/services/gnocchi-metricd.yaml | 18 +----- puppet/services/gnocchi-statsd.yaml | 18 +----- puppet/services/haproxy.yaml | 23 +------ puppet/services/heat-api-cfn.yaml | 28 +-------- puppet/services/heat-api.yaml | 28 +-------- puppet/services/heat-engine.yaml | 18 +----- puppet/services/horizon.yaml | 21 +------ puppet/services/ironic-neutron-agent.yaml | 18 +----- puppet/services/logging/fluentd.yaml | 25 +------- puppet/services/metrics/collectd.yaml | 25 +------- puppet/services/mistral-api.yaml | 30 +-------- puppet/services/mistral-engine.yaml | 23 +------ puppet/services/mistral-event-engine.yaml | 23 +------ puppet/services/mistral-executor.yaml | 23 +------ puppet/services/monitoring/sensu-client.yaml | 25 +------- puppet/services/neutron-api.yaml | 18 +----- puppet/services/neutron-dhcp.yaml | 18 +----- puppet/services/neutron-l2gw-agent.yaml | 18 +----- puppet/services/neutron-l3.yaml | 18 +----- puppet/services/neutron-metadata.yaml | 18 +----- puppet/services/neutron-ovs-agent.yaml | 18 +----- puppet/services/neutron-sriov-agent.yaml | 18 +----- puppet/services/opendaylight-api.yaml | 27 +------- puppet/services/ovn-controller.yaml | 18 +----- puppet/services/ovn-dbs.yaml | 18 +----- puppet/services/ovn-metadata.yaml | 20 +----- puppet/services/panko-api.yaml | 26 +------- puppet/services/tacker.yaml | 23 +------ puppet/services/zaqar-api.yaml | 38 +----------- ...pgrade_tasks_cleanup-c913f3f30f4a1db6.yaml | 13 ++++ 127 files changed, 99 insertions(+), 2966 deletions(-) create mode 100644 releasenotes/notes/upgrade_tasks_cleanup-c913f3f30f4a1db6.yaml diff --git a/deployment/aodh/aodh-api-container.yaml b/deployment/aodh/aodh-api-container.yaml index 31e1f7e8b8..e89e332997 100644 --- a/deployment/aodh/aodh-api-container.yaml +++ b/deployment/aodh/aodh-api-container.yaml @@ -229,38 +229,6 @@ outputs: /var/log/containers/aodh and /var/log/containers/httpd/aodh-api. ignore_errors: true upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check for aodh api service running under apache - shell: "httpd -t -D DUMP_VHOSTS | grep -q aodh" - ignore_errors: True - register: aodh_httpd_enabled_result - - name: Set fact aodh_httpd_enabled - set_fact: - aodh_httpd_enabled: "{{ aodh_httpd_enabled_result.rc == 0 }}" - - name: Check if httpd is running - command: systemctl is-active --quiet httpd - ignore_errors: True - register: httpd_running_result - when: httpd_running is undefined - - name: Set fact httpd_running - set_fact: - httpd_running: "{{ httpd_running_result.rc == 0 }}" - when: httpd_running is undefined - - name: "PreUpgrade step0,validation: Check if aodh api is running" - shell: systemctl status 'httpd' | grep -q aodh - tags: validation - when: - - aodh_httpd_enabled|bool - - httpd_running|bool - - when: step|int == 2 - block: - - name: Stop and disable aodh service (running under httpd) - when: - - aodh_httpd_enabled|bool - - httpd_running|bool - service: name=httpd state=stopped enabled=no - when: step|int == 3 block: - name: Set fact for removal of openstack-aodh-api package diff --git a/deployment/aodh/aodh-evaluator-container.yaml b/deployment/aodh/aodh-evaluator-container.yaml index b20a27c320..ac6e74d036 100644 --- a/deployment/aodh/aodh-evaluator-container.yaml +++ b/deployment/aodh/aodh-evaluator-container.yaml @@ -125,25 +125,6 @@ outputs: /var/log/containers/aodh and /var/log/containers/httpd/aodh-api. ignore_errors: true upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if aodh_evaluator is deployed - command: systemctl is-enabled --quiet openstack-aodh-evaluator - ignore_errors: True - register: aodh_evaluator_enabled_result - - name: Set fact aodh_evaluator_enabled - set_fact: - aodh_evaluator_enabled: "{{ aodh_evaluator_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-aodh-evaluator is running" - command: systemctl is-active --quiet openstack-aodh-evaluator - tags: validation - when: aodh_evaluator_enabled|bool - - when: step|int == 2 - block: - - name: Stop and disable openstack-aodh-evaluator service - when: aodh_evaluator_enabled|bool - service: name=openstack-aodh-evaluator.service state=stopped enabled=no - when: step|int == 3 block: - name: Set fact for removal of openstack-aodh-evaluator package diff --git a/deployment/aodh/aodh-listener-container.yaml b/deployment/aodh/aodh-listener-container.yaml index 21ab6eff94..84e681af56 100644 --- a/deployment/aodh/aodh-listener-container.yaml +++ b/deployment/aodh/aodh-listener-container.yaml @@ -133,25 +133,6 @@ outputs: /var/log/containers/aodh and /var/log/containers/httpd/aodh-api. ignore_errors: true upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if aodh_listener is deployed - command: systemctl is-enabled --quiet openstack-aodh-listener - ignore_errors: True - register: aodh_listener_enabled_result - - name: Set fact aodh_listener_enabled - set_fact: - aodh_listener_enabled: "{{ aodh_listener_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-aodh-listener is running" - command: systemctl is-active --quiet openstack-aodh-listener - when: aodh_listener_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable openstack-aodh-listener service - when: aodh_listener_enabled|bool - service: name=openstack-aodh-listener.service state=stopped enabled=no - when: step|int == 3 block: - name: Set fact for removal of openstack-aodh-listener package diff --git a/deployment/aodh/aodh-notifier-container.yaml b/deployment/aodh/aodh-notifier-container.yaml index bbfebaaf93..a7b0fb8303 100644 --- a/deployment/aodh/aodh-notifier-container.yaml +++ b/deployment/aodh/aodh-notifier-container.yaml @@ -133,25 +133,6 @@ outputs: /var/log/containers/aodh and /var/log/containers/httpd/aodh-api. ignore_errors: true upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if aodh_notifier is deployed - command: systemctl is-enabled --quiet openstack-aodh-notifier - ignore_errors: True - register: aodh_notifier_enabled_result - - name: Set fact aodh_notifier_enabled - set_fact: - aodh_notifier_enabled: "{{ aodh_notifier_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-aodh-notifier is running" - command: systemctl is-active --quiet openstack-aodh-notifier - when: aodh_notifier_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable openstack-aodh-notifier service - when: aodh_notifier_enabled|bool - service: name=openstack-aodh-notifier.service state=stopped enabled=no - when: step|int == 3 block: - name: Set fact for removal of openstack-aodh-notifier package diff --git a/docker/services/barbican-api.yaml b/docker/services/barbican-api.yaml index 278684c53c..cc783cefcd 100644 --- a/docker/services/barbican-api.yaml +++ b/docker/services/barbican-api.yaml @@ -243,24 +243,6 @@ outputs: environment: *kolla_env host_prep_tasks: {get_attr: [BarbicanApiLogging, host_prep_tasks]} upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if openstack-barbican-api is deployed - command: systemctl is-enabled --quiet openstack-barbican-api - ignore_errors: True - register: barbican_enabled_result - - name: Set fact barbican_enabled - set_fact: - barbican_enabled: "{{ barbican_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service barbican-api is running" - command: systemctl is-active --quiet openstack-barbican-api - when: barbican_enabled|bool - - when: step|int == 2 - block: - - name: Stop and disable barbican_api service - when: barbican_enabled|bool - service: name=openstack-barbican-api state=stopped enabled=no - when: step|int == 3 block: - name: Set fact for removal of openstack-barbican-api package diff --git a/docker/services/ceilometer-agent-central.yaml b/docker/services/ceilometer-agent-central.yaml index 05894595d5..74b3f0990a 100644 --- a/docker/services/ceilometer-agent-central.yaml +++ b/docker/services/ceilometer-agent-central.yaml @@ -150,25 +150,6 @@ outputs: /var/log/containers/ceilometer. ignore_errors: true upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if ceilometer_agent_central is deployed - command: systemctl is-enabled --quiet openstack-ceilometer-central - ignore_errors: True - register: ceilometer_agent_central_enabled_result - - name: Set fact ceilometer_agent_central_enabled - set_fact: - ceilometer_agent_central_enabled: "{{ ceilometer_agent_central_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-ceilometer-central is running" - command: systemctl is-active --quiet openstack-ceilometer-central - when: ceilometer_agent_central_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable ceilometer agent central service - service: name=openstack-ceilometer-central state=stopped enabled=no - when: ceilometer_agent_central_enabled|bool - when: step|int == 3 block: - name: Set fact for removal of openstack-ceilometer-central package diff --git a/docker/services/ceilometer-agent-compute.yaml b/docker/services/ceilometer-agent-compute.yaml index ea74f2b3cf..c4c5dd784d 100644 --- a/docker/services/ceilometer-agent-compute.yaml +++ b/docker/services/ceilometer-agent-compute.yaml @@ -118,39 +118,6 @@ outputs: /var/log/containers/ceilometer. ignore_errors: true upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if openstack-ceilometer-compute is deployed - command: systemctl is-enabled --quiet openstack-ceilometer-compute - ignore_errors: True - register: openstack_ceilometer_compute_enabled_result - - name: Set fact openstack_ceilometer_compute_enabled - set_fact: - openstack_ceilometer_compute_enabled: "{{ openstack_ceilometer_compute_enabled_result.rc == 0 }}" - - name: Check if openstack-ceilometer-polling is deployed - command: systemctl is-enabled --quiet openstack-ceilometer-polling - ignore_errors: True - register: openstack_ceilometer_polling_enabled_result - - name: Set fact openstack_ceilometer_polling_enabled - set_fact: - openstack_ceilometer_polling_enabled: "{{ openstack_ceilometer_polling_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-ceilometer-compute is running" - command: systemctl is-active --quiet openstack-ceilometer-compute - when: openstack_ceilometer_compute_enabled|bool - tags: validation - - name: "PreUpgrade step0,validation: Check service openstack-ceilometer-polling is running" - command: systemctl is-active --quiet openstack-ceilometer-polling - when: openstack_ceilometer_polling_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable ceilometer compute agent - service: name=openstack-ceilometer-compute state=stopped enabled=no - when: openstack_ceilometer_compute_enabled|bool - - name: Stop and disable ceilometer polling agent - service: name=openstack-ceilometer-polling state=stopped enabled=no - when: openstack_ceilometer_polling_enabled|bool - when: step|int == 3 block: - name: Set fact for removal of openstack-ceilometer-compute and polling package diff --git a/docker/services/ceilometer-agent-ipmi.yaml b/docker/services/ceilometer-agent-ipmi.yaml index c52fd4ff83..39bacb8e46 100644 --- a/docker/services/ceilometer-agent-ipmi.yaml +++ b/docker/services/ceilometer-agent-ipmi.yaml @@ -129,25 +129,6 @@ outputs: /var/log/containers/ceilometer. ignore_errors: true upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if ceilometer-agent-ipmi is deployed - command: systemctl is-enabled --quiet openstack-ceilometer-ipmi - ignore_errors: True - register: ceilometer_ipmi_enabled_result - - name: Set fact ceilometer_ipmi_enabled - set_fact: - ceilometer_ipmi_enabled: "{{ ceilometer_ipmi_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check if openstack-ceilometer-ipmi is running" - command: systemctl is-active --quiet openstack-ceilometer-ipmi - when: ceilometer_ipmi_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable ceilometer agent ipmi service - service: name=openstack-ceilometer-agent-ipmi state=stopped enabled=no - when: ceilometer_ipmi_enabled|bool - when: step|int == 3 block: - name: Set fact for removal of openstack-ceilometer-ipmi package diff --git a/docker/services/ceilometer-agent-notification.yaml b/docker/services/ceilometer-agent-notification.yaml index 1278cc6c13..ffedb3b86f 100644 --- a/docker/services/ceilometer-agent-notification.yaml +++ b/docker/services/ceilometer-agent-notification.yaml @@ -146,25 +146,6 @@ outputs: /var/log/containers/ceilometer. ignore_errors: true upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if ceilometer_agent_notification is deployed - command: systemctl is-enabled --quiet openstack-ceilometer-notification - ignore_errors: True - register: ceilometer_agent_notification_enabled_result - - name: Set fact ceilometer_agent_notification_enabled - set_fact: - ceilometer_agent_notification_enabled: "{{ ceilometer_agent_notification_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-ceilometer-notification is running" - command: systemctl is-active --quiet openstack-ceilometer-notification - when: ceilometer_agent_notification_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable ceilometer agent notification service - service: name=openstack-ceilometer-notification state=stopped enabled=no - when: ceilometer_agent_notification_enabled|bool - when: step|int == 3 block: - name: Set fact for removal of openstack-ceilometer-notification package diff --git a/docker/services/cinder-api.yaml b/docker/services/cinder-api.yaml index cac43649eb..c824d801dc 100644 --- a/docker/services/cinder-api.yaml +++ b/docker/services/cinder-api.yaml @@ -230,33 +230,6 @@ outputs: block: - name: set is_bootstrap_node fact set_fact: is_bootstrap_node={{cinder_api_short_bootstrap_node_name|lower == ansible_hostname|lower}} - - name: Check is cinder_api is deployed - command: systemctl is-enabled openstack-cinder-api - ignore_errors: True - register: cinder_api_enabled_result - - name: Set fact cinder_api_enabled - set_fact: - cinder_api_enabled: "{{ cinder_api_enabled_result.rc == 0 }}" - - name: Check if httpd service is running - command: systemctl is-active --quiet httpd - ignore_errors: True - register: httpd_running_result - when: httpd_running is undefined - - name: Set fact httpd_running - set_fact: - httpd_running: "{{ httpd_running_result.rc == 0 }}" - when: httpd_running is undefined - - name: check for cinder_api running under apache (post upgrade) - shell: "httpd -t -D DUMP_VHOSTS | grep -q cinder" - register: cinder_api_apache - ignore_errors: true - - name: Set fact cinder_api_apache (upgrade) - set_fact: - cinder_api_apache: "{{ cinder_api_apache.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-cinder-api is running" - shell: systemctl is-active --quiet openstack-cinder-api - when: cinder_api_enabled|bool - tags: validation - name: Ensure all online data migrations for Cinder have been applied shell: | if {{ container_cli }} ps | grep cinder_api; then @@ -267,24 +240,9 @@ outputs: docker exec cinder_api cinder-manage db online_data_migrations fi tags: pre-upgrade - when: - - is_bootstrap_node|bool - - not (cinder_api_apache|bool and httpd_running|bool) - - not cinder_api_enabled|bool - - when: step|int == 2 - block: - - name: Stop and disable cinder_api service (pre-upgrade not under httpd) - service: name=openstack-cinder-api state=stopped enabled=no - when: cinder_api_enabled|bool - - name: Stop and disable cinder_api service - service: name=httpd state=stopped enabled=no - when: cinder_api_apache|bool + when: is_bootstrap_node|bool - when: step|int == 3 block: - - name: remove old cinder cron jobs - file: - path: /var/spool/cron/cinder - state: absent - name: Set fact for removal of httpd package set_fact: remove_httpd_package: {get_param: UpgradeRemoveUnusedPackages} diff --git a/docker/services/cinder-backup.yaml b/docker/services/cinder-backup.yaml index 57f9d88a5f..f88202ae73 100644 --- a/docker/services/cinder-backup.yaml +++ b/docker/services/cinder-backup.yaml @@ -189,25 +189,6 @@ outputs: containers_to_rm: - cinder_backup upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if cinder_backup is deployed - command: systemctl is-enabled openstack-cinder-backup - ignore_errors: True - register: cinder_backup_enabled_result - - name: Set fact cinder_backup_enabled - set_fact: - cinder_backup_enabled: "{{ cinder_backup_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-cinder-backup is running" - shell: systemctl is-active --quiet openstack-cinder-backup - when: cinder_backup_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable cinder_backup service - when: cinder_backup_enabled|bool - service: name=openstack-cinder-backup state=stopped enabled=no - when: step|int == 3 block: - name: Set fact for removal of openstack-cinder package diff --git a/docker/services/cinder-scheduler.yaml b/docker/services/cinder-scheduler.yaml index 43c92e4124..6fbd2af162 100644 --- a/docker/services/cinder-scheduler.yaml +++ b/docker/services/cinder-scheduler.yaml @@ -149,25 +149,6 @@ outputs: /var/log/containers/cinder and /var/log/containers/httpd/cinder-api. ignore_errors: true upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if cinder_scheduler is deployed - command: systemctl is-enabled openstack-cinder-scheduler - ignore_errors: True - register: cinder_scheduler_enabled_result - - name: Set fact cinder_scheduler_enabled - set_fact: - cinder_scheduler_enabled: "{{ cinder_scheduler_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-cinder-scheduler is running" - shell: systemctl is-active --quiet openstack-cinder-scheduler - when: cinder_scheduler_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable cinder_scheduler service - when: cinder_scheduler_enabled|bool - service: name=openstack-cinder-scheduler state=stopped enabled=no - when: step|int == 3 block: - name: Set fact for removal of openstack-cinder package diff --git a/docker/services/cinder-volume.yaml b/docker/services/cinder-volume.yaml index acd333821c..4f529d0049 100644 --- a/docker/services/cinder-volume.yaml +++ b/docker/services/cinder-volume.yaml @@ -170,25 +170,6 @@ outputs: environment: {get_attr: [CinderCommon, cinder_volume_environment]} host_prep_tasks: {get_attr: [CinderCommon, cinder_volume_host_prep_tasks]} upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if cinder_volume is deployed - command: systemctl is-enabled openstack-cinder-volume - ignore_errors: True - register: cinder_volume_enabled_result - - name: Set fact cinder_volume_enabled - set_fact: - cinder_volume_enabled: "{{ cinder_volume_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-cinder-volume is running" - shell: systemctl is-active --quiet openstack-cinder-volume - when: cinder_volume_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable cinder_volume service - when: cinder_volume_enabled|bool - service: name=openstack-cinder-volume state=stopped enabled=no - when: step|int == 3 block: - name: Set fact for removal of openstack-cinder package diff --git a/docker/services/congress.yaml b/docker/services/congress.yaml index c3a307decb..5fe3376c59 100644 --- a/docker/services/congress.yaml +++ b/docker/services/congress.yaml @@ -154,25 +154,6 @@ outputs: containers_to_rm: - congress_api upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if congress is deployed - command: systemctl is-enabled --quiet openstack-congress-server - ignore_errors: True - register: congress_enabled_result - - name: Set fact congress_enabled - set_fact: - congress_enabled: "{{ congress_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-congress-server is running" - command: systemctl is-active --quiet openstack-congress-server - when: congress_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable congress_api service - when: congress_enabled|bool - service: name=openstack-congress-server state=stopped enabled=no - when: step|int == 3 block: - name: Set fact for removal of openstack-congress package diff --git a/docker/services/database/mongodb.yaml b/docker/services/database/mongodb.yaml index 8a96d43ffe..22db98a262 100644 --- a/docker/services/database/mongodb.yaml +++ b/docker/services/database/mongodb.yaml @@ -163,26 +163,7 @@ outputs: ignore_errors: true metadata_settings: get_attr: [MongodbPuppetBase, role_data, metadata_settings] - upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check for mongodb service - command: systemctl is-enabled --quiet mongod - ignore_errors: True - register: mongod_enabled_result - - name: Set fact mongod_enabled - set_fact: - mongod_enabled: "{{ mongod_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check if mongod is running" - command: systemctl is-active --quiet mongod - when: mongod_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable mongodb service - when: mongod_enabled|bool - service: name=mongod state=stopped enabled=no + upgrade_tasks: [] fast_forward_upgrade_tasks: - when: - step|int == 0 diff --git a/docker/services/database/mysql.yaml b/docker/services/database/mysql.yaml index d1e902f54f..64f54959d3 100644 --- a/docker/services/database/mysql.yaml +++ b/docker/services/database/mysql.yaml @@ -48,10 +48,6 @@ parameters: type: string description: Specifies the default CA cert to use if TLS is used for services in the internal network. - UndercloudUpgrade: - type: boolean - description: Flag to indicate undercloud upgrade process is being run. - default: false MySQLServerOptions: type: json default: {} @@ -244,50 +240,7 @@ outputs: Log files from mysql containers can be found under /var/log/containers/mysql. ignore_errors: true - upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if mysql service is deployed - command: systemctl is-enabled --quiet mariadb - ignore_errors: True - register: mariadb_enabled_result - - name: Set fact mariadb_enabled - set_fact: - mariadb_enabled: "{{ mariadb_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check if mysql service is running" - command: systemctl is-active --quiet mariadb - when: mariadb_enabled|bool - tags: validation - - when: step|int == 2 - block: - # https://bugs.launchpad.net/tripleo/+bug/1753247 - - name: Rename old neutron database to ovs_neutron - shell: > - if [ -d /var/lib/mysql/neutron ] ; then - mysql -e "CREATE DATABASE IF NOT EXISTS \`ovs_neutron\`;" - for table in `mysql -B -N -e "SHOW TABLES;" neutron` - do - mysql -e "RENAME TABLE \`neutron\`.\`$table\` to \`ovs_neutron\`.\`$table\`" - done - mysql -e "DROP DATABASE \`neutron\`;" - fi - become: true - when: - - {get_param: UndercloudUpgrade} - - mariadb_enabled|bool - # https://bugs.launchpad.net/tripleo/+bug/1776570 - - name: Manage mysql user for healthcheck and revoke grant - shell: | - mysql -e "CREATE USER IF NOT EXISTS \`mysql\`@\`localhost\`;" - mysql -e "REVOKE ALL PRIVILEGES, GRANT OPTION FROM \`mysql\`@\`localhost\`;" - become: true - when: - - {get_param: UndercloudUpgrade} - - mariadb_enabled|bool - - name: Stop and disable mysql service - when: mariadb_enabled|bool - service: name=mariadb state=stopped enabled=no + upgrade_tasks: [] post_upgrade_tasks: - when: step|int == 1 import_role: diff --git a/docker/services/database/redis.yaml b/docker/services/database/redis.yaml index 422c8664df..ca427caffe 100644 --- a/docker/services/database/redis.yaml +++ b/docker/services/database/redis.yaml @@ -165,26 +165,7 @@ outputs: Log files from redis containers can be found under /var/log/containers/redis. ignore_errors: true - upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if redis is deployed - command: systemctl is-enabled --quiet redis - ignore_errors: True - register: redis_enabled_result - - name: Set fact redis_enabled - set_fact: - redis_enabled: "{{ redis_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check if redis is running" - command: systemctl is-active --quiet redis - when: redis_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable redis service - when: redis_enabled|bool - service: name=redis state=stopped enabled=no + upgrade_tasks: [] post_upgrade_tasks: - when: step|int == 1 import_role: diff --git a/docker/services/ec2-api.yaml b/docker/services/ec2-api.yaml index b606f6544c..a29fb4d131 100644 --- a/docker/services/ec2-api.yaml +++ b/docker/services/ec2-api.yaml @@ -215,40 +215,7 @@ outputs: - ec2api - ec2api-metadata ignore_errors: true - upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if EC2-API is deployed - command: systemctl is-enabled --quiet openstack-ec2-api - ignore_errors: True - register: ec2_api_enabled_result - - name: Set fact ec2_api_enabled - set_fact: - ec2_api_enabled: "{{ ec2_api_enabled_result.rc == 0 }}" - - name: Check if EC2-API-METADATA are deployed - command: systemctl is-enabled --quiet openstack-ec2-api-metadata - ignore_errors: True - register: ec2_api_metadata_enabled_result - - name: Set fact ec2_api_metadata_enabled - set_fact: - ec2_api_metadata_enabled: "{{ ec2_api_metadata_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check if openstack-ec2-api is running" - command: systemctl is-active --quiet openstack-ec2-api - when: ec2_api_enabled|bool - tags: validation - - name: "PreUpgrade step0,validation: Check if openstack-ec2-metadata-api is running" - command: systemctl is-active --quiet openstack-ec2-api-metadata - when: ec2_api_metadata_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable EC2-API service - when: ec2_api_enabled|bool - service: name=openstack-ec2-api state=stopped enabled=no - - name: Stop and disable EC2-API-METADATA service - when: ec2_api_metadata_enabled|bool - service: name=openstack-ec2-api-metadata state=stopped enabled=no + upgrade_tasks: [] post_upgrade_tasks: - when: step|int == 1 import_role: diff --git a/docker/services/etcd.yaml b/docker/services/etcd.yaml index d00ed0ab9f..4ff4de5371 100644 --- a/docker/services/etcd.yaml +++ b/docker/services/etcd.yaml @@ -114,26 +114,7 @@ outputs: file: path: /var/lib/etcd state: directory - upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if etcd is deployed - command: systemctl is-enabled --quiet etcd - ignore_errors: True - register: etcd_enabled_result - - name: Set fact etcd_enabled - set_fact: - etcd_enabled: "{{ etcd_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check if etcd is running" - command: systemctl is-active --quiet etcd - when: etcd_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable etcd service - when: etcd_enabled|bool - service: name=etcd state=stopped enabled=no + upgrade_tasks: [] post_upgrade_tasks: - when: step|int == 1 import_role: diff --git a/docker/services/fluentd.yaml b/docker/services/fluentd.yaml index f3e80ce87c..de85758932 100644 --- a/docker/services/fluentd.yaml +++ b/docker/services/fluentd.yaml @@ -124,22 +124,7 @@ outputs: path: /var/cache/containers/fluentd state: directory setype: svirt_sandbox_file_t - upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if fluent.service is deployed - command: systemctl is-enabled --quiet fluentd.service - ignore_errors: True - register: fluentd_enabled_result - - name: Set fact fluentd_enabled - set_fact: - fluentd_enabled: "{{ fluentd_enabled_result.rc == 0 }}" - - when: step|int == 2 - block: - - name: Stop and disable fluentd service - service: name=fluentd.service state=stopped enabled=no - when: fluentd_enabled|bool + upgrade_tasks: [] post_upgrade_tasks: - when: step|int == 1 import_role: diff --git a/docker/services/glance-api.yaml b/docker/services/glance-api.yaml index 8888474a53..0070144961 100644 --- a/docker/services/glance-api.yaml +++ b/docker/services/glance-api.yaml @@ -235,25 +235,6 @@ outputs: state: directory setype: svirt_sandbox_file_t upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if glance_api is deployed - command: systemctl is-enabled --quiet openstack-glance-api - ignore_errors: True - register: glance_api_enabled_result - - name: Set fact glance_api_enabled - set_fact: - glance_api_enabled: "{{ glance_api_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-glance-api is running" - command: systemctl is-active --quiet openstack-glance-api - tags: validation - when: glance_api_enabled|bool - - when: step|int == 2 - block: - - name: Stop and disable glance_api service - when: glance_api_enabled|bool - service: name=openstack-glance-api state=stopped enabled=no - when: step|int == 3 block: - name: Set fact for removal of openstack-glance package diff --git a/docker/services/gnocchi-api.yaml b/docker/services/gnocchi-api.yaml index 3cb4e45b3f..42cb88193b 100644 --- a/docker/services/gnocchi-api.yaml +++ b/docker/services/gnocchi-api.yaml @@ -246,55 +246,7 @@ outputs: file: path: /etc/ceph state: directory - upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if gnocchi_api is deployed - command: systemctl is-enabled --quiet openstack-gnocchi-api - ignore_errors: True - register: gnocchi_api_enabled_result - - name: Set fact gnocchi_api_enabled - set_fact: - gnocchi_api_enabled: "{{ gnocchi_api_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-gnocchi-api is running" - command: systemctl is-active --quiet openstack-gnocchi-api - when: - - gnocchi_api_enabled|bool - tags: validation - - name: Check if httpd service is running - command: systemctl is-active --quiet httpd - ignore_errors: True - register: httpd_running_result - when: httpd_running is undefined - - name: Set fact httpd_running - set_fact: - httpd_running: "{{ httpd_running_result.rc == 0 }}" - when: httpd_running is undefined - - name: Check for gnocchi_api running under apache - shell: "httpd -t -D DUMP_VHOSTS | grep -q gnocchi" - ignore_errors: True - register: gnocchi_httpd_enabled_result - - name: set fact gnocchi_httpd_enabled - set_fact: - gnocchi_httpd_enabled: "{{ gnocchi_httpd_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check if gnocchi_api_wsgi is running" - shell: systemctl status 'httpd' | grep -q gnocchi - tags: validation - when: - - gnocchi_httpd_enabled|bool - - httpd_running|bool - - when: step|int == 2 - block: - - name: Stop and disable gnocchi_api service - service: name=openstack-gnocchi-api state=stopped enabled=no - when: - - gnocchi_api_enabled|bool - - name: Stop and disable httpd service - when: - - gnocchi_httpd_enabled|bool - - httpd_running|bool - service: name=httpd state=stopped enabled=no + upgrade_tasks: [] metadata_settings: get_attr: [GnocchiApiPuppetBase, role_data, metadata_settings] post_upgrade_tasks: diff --git a/docker/services/gnocchi-metricd.yaml b/docker/services/gnocchi-metricd.yaml index a8819d837b..566a468be4 100644 --- a/docker/services/gnocchi-metricd.yaml +++ b/docker/services/gnocchi-metricd.yaml @@ -158,26 +158,7 @@ outputs: file: path: /etc/ceph state: directory - upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if gnocchi_metricd is deployed - command: systemctl is-enabled --quiet openstack-gnocchi-metricd - ignore_errors: True - register: gnocchi_metricd_enabled_result - - name: Set fact gnocchi_metricd_enabled - set_fact: - gnocchi_metricd_enabled: "{{ gnocchi_metricd_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-gnocchi-metricd is running" - command: systemctl is-active --quiet openstack-gnocchi-metricd - when: gnocchi_metricd_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable openstack-gnocchi-metricd service - when: gnocchi_metricd_enabled|bool - service: name=openstack-gnocchi-metricd.service state=stopped enabled=no + upgrade_tasks: [] post_upgrade_tasks: - when: step|int == 1 import_role: diff --git a/docker/services/gnocchi-statsd.yaml b/docker/services/gnocchi-statsd.yaml index cedd6b0f82..b211a6c8d3 100644 --- a/docker/services/gnocchi-statsd.yaml +++ b/docker/services/gnocchi-statsd.yaml @@ -158,26 +158,7 @@ outputs: file: path: /etc/ceph state: directory - upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if gnocchi_statsd is deployed - command: systemctl is-enabled --quiet openstack-gnocchi-statsd - ignore_errors: True - register: gnocchi_statsd_enabled_result - - name: Set fact gnocchi_statsd_enabled - set_fact: - gnocchi_statsd_enabled: "{{ gnocchi_statsd_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-gnocchi-statsd is running" - command: systemctl is-active --quiet openstack-gnocchi-statsd - when: gnocchi_statsd_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable openstack-gnocchi-statsd service - when: gnocchi_statsd_enabled|bool - service: name=openstack-gnocchi-statsd.service state=stopped enabled=no + upgrade_tasks: [] post_upgrade_tasks: - when: step|int == 1 import_role: diff --git a/docker/services/haproxy.yaml b/docker/services/haproxy.yaml index e4718eb8c2..429d5960bf 100644 --- a/docker/services/haproxy.yaml +++ b/docker/services/haproxy.yaml @@ -261,25 +261,6 @@ outputs: environment: - KOLLA_CONFIG_STRATEGY=COPY_ALWAYS upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if HAproxy is deployed - command: systemctl is-enabled --quiet haproxy - ignore_errors: True - register: haproxy_enabled_result - - name: Set fact haproxy_enabled - set_fact: - haproxy_enabled: "{{ haproxy_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service HAproxy is running" - command: systemctl is-active --quiet haproxy - tags: validation - when: haproxy_enabled|bool - - when: step|int == 2 - block: - - name: Stop and disable haproxy service - when: haproxy_enabled|bool - service: name=haproxy state=stopped enabled=no - when: step|int == 3 block: - name: Set fact for removal of HAproxy package diff --git a/docker/services/heat-api-cfn.yaml b/docker/services/heat-api-cfn.yaml index d21e1fad52..9505cf0868 100644 --- a/docker/services/heat-api-cfn.yaml +++ b/docker/services/heat-api-cfn.yaml @@ -139,52 +139,7 @@ outputs: environment: - KOLLA_CONFIG_STRATEGY=COPY_ALWAYS host_prep_tasks: {get_attr: [HeatApiCfnLogging, host_prep_tasks]} - upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if heat_api_cfn is deployed - command: systemctl is-enabled --quiet openstack-heat-api-cfn - ignore_errors: True - register: heat_api_cfn_enabled_result - - set_fact: - heat_api_cfn_enabled: heat_api_cfn_enabled_result|bool - - name: Check for heat_api_cfn running under apache - shell: "httpd -t -D DUMP_VHOSTS | grep -q heat_api_cfn" - ignore_errors: True - register: heat_api_cfn_httpd_enabled_result - - set_fact: - heat_api_cfn_httpd_enabled: "{{ heat_api_cfn_httpd_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-heat-api-cfn is running" - command: systemctl is-active --quiet openstack-heat-api-cfn - when: - - heat_api_cfn_enabled|bool - tags: validation - - name: Check if httpd service is running - command: systemctl is-active --quiet httpd - ignore_errors: True - register: httpd_running_result - when: httpd_running is undefined - - set_fact: - httpd_running: "{{ httpd_running_result.rc == 0 }}" - when: httpd_running is undefined - - name: "PreUpgrade step0,validation: Check if heat_api_cfn_wsgi is running" - tags: validation - shell: systemctl status 'httpd' | grep -q heat_api_cfn - when: - - heat_api_cfn_httpd_enabled|bool - - httpd_running|bool - - when: step|int == 2 - block: - - name: Stop and disable heat_api_cfn service (pre-upgrade not under httpd) - service: name=openstack-heat-api-cfn state=stopped enabled=no - when: - - heat_api_cfn_enabled|bool - - name: Stop heat_api_cfn service (running under httpd) - service: name=httpd state=stopped enabled=no - when: - - heat_api_cfn_httpd_enabled|bool - - httpd_running|bool + upgrade_tasks: [] metadata_settings: get_attr: [HeatBase, role_data, metadata_settings] post_upgrade_tasks: diff --git a/docker/services/heat-api.yaml b/docker/services/heat-api.yaml index a57305df17..dea696c123 100644 --- a/docker/services/heat-api.yaml +++ b/docker/services/heat-api.yaml @@ -177,56 +177,7 @@ outputs: environment: - KOLLA_CONFIG_STRATEGY=COPY_ALWAYS host_prep_tasks: {get_attr: [HeatApiLogging, host_prep_tasks]} - upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if heat_api is deployed - command: systemctl is-enabled --quiet openstack-heat-api - ignore_errors: True - register: heat_api_enabled_result - - set_fact: - heat_api_enabled: "{{ heat_api_enabled_result.rc == 0 }}" - - name: Check for heat_api running under apache - shell: "httpd -t -D DUMP_VHOSTS | grep -q heat_api_wsgi" - ignore_errors: True - register: heat_api_httpd_enabled_result - - set_fact: - heat_api_httpd_enabled: "{{ heat_api_httpd_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-heat-api is running" - command: systemctl is-active --quiet openstack-heat-api - when: - - heat_api_enabled|bool - tags: validation - - name: Check if httpd is running - command: systemctl is-active --quiet httpd - ignore_errors: True - register: httpd_running_result - when: httpd_running is undefined - - set_fact: - httpd_running: "{{ httpd_running_result.rc == 0 }}" - when: httpd_running is undefined - - name: "PreUpgrade step0,validation: Check if heat_api_wsgi is running" - shell: systemctl status 'httpd' | grep -q heat_api_wsgi - tags: validation - when: - - heat_api_httpd_enabled|bool - - httpd_running|bool - - when: step|int == 2 - block: - - name: Stop and disable heat_api service (pre-upgrade not under httpd) - service: name=openstack-heat-api state=stopped enabled=no - when: - - heat_api_enabled|bool - - name: Stop heat_api service (running under httpd) - service: name=httpd state=stopped - when: - - heat_api_httpd_enabled|bool - - httpd_running|bool - - name: remove old heat cron jobs - file: - path: /var/spool/cron/heat - state: absent + upgrade_tasks: [] metadata_settings: get_attr: [HeatBase, role_data, metadata_settings] post_upgrade_tasks: diff --git a/docker/services/heat-engine.yaml b/docker/services/heat-engine.yaml index e5c28a7d39..fcb4c25f2d 100644 --- a/docker/services/heat-engine.yaml +++ b/docker/services/heat-engine.yaml @@ -162,26 +162,7 @@ outputs: - - KOLLA_CONFIG_STRATEGY=COPY_ALWAYS host_prep_tasks: {get_attr: [HeatEngineLogging, host_prep_tasks]} - upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if heat_engine is deployed - command: systemctl is-enabled --quiet openstack-heat-engine - ignore_errors: True - register: heat_engine_enabled_result - - name: Set fact heat_engine_enabled - set_fact: - heat_engine_enabled: "{{ heat_engine_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-heat-engine is running" - command: systemctl is-active --quiet openstack-heat-engine - when: heat_engine_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable heat_engine service - when: heat_engine_enabled|bool - service: name=openstack-heat-engine state=stopped enabled=no + upgrade_tasks: [] post_upgrade_tasks: - when: step|int == 1 import_role: diff --git a/docker/services/ironic-api.yaml b/docker/services/ironic-api.yaml index 7cee5a8d87..9201d16665 100644 --- a/docker/services/ironic-api.yaml +++ b/docker/services/ironic-api.yaml @@ -159,40 +159,6 @@ outputs: block: - name: set is_bootstrap_node fact set_fact: is_bootstrap_node={{ironic_api_short_bootstrap_node_name|lower == ansible_hostname|lower}} - - name: Check if ironic_api is deployed - command: systemctl is-enabled --quiet openstack-ironic-api - ignore_errors: True - register: ironic_api_enabled_result - - name: Set fact ironic_api_enabled - set_fact: - ironic_api_enabled: "{{ ironic_api_enabled_result.rc == 0 }}" - - name: Check for ironic_api running under apache - shell: "httpd -t -D DUMP_VHOSTS | grep -q ironic" - ignore_errors: True - register: ironic_httpd_enabled_result - - name: Set fact ironic_httpd_enabled - set_fact: - ironic_httpd_enabled: "{{ ironic_httpd_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-ironic-api is running" - command: systemctl is-active --quiet openstack-ironic-api - when: - - ironic_api_enabled|bool - tags: validation - - name: Check if httpd service is running - command: systemctl is-active --quiet httpd - ignore_errors: True - register: httpd_running_result - when: httpd_running is undefined - - name: Set fact httpd_running - set_fact: - httpd_running: "{{ httpd_running_result.rc == 0 }}" - when: httpd_running is undefined - - name: "PreUpgrade step0,validation: Check if ironic_api_wsgi is running" - shell: systemctl status 'httpd' | grep -q ironic - tags: validation - when: - - ironic_httpd_enabled|bool - - httpd_running|bool - name: Ensure all online data migrations for Ironic have been applied shell: | if {{ container_cli }} ps | grep ironic_api; then @@ -203,21 +169,7 @@ outputs: docker exec ironic_api ironic-dbsync --config-file /etc/ironic/ironic.conf online_data_migrations fi tags: pre-upgrade - when: - - is_bootstrap_node|bool - - not (ironic_httpd_enabled|bool and httpd_running|bool) - - not ironic_api_enabled|bool - - when: step|int == 2 - block: - - name: Stop and disable ironic_api service - when: - - ironic_api_enabled|bool - service: name=openstack-ironic-api state=stopped enabled=no - - name: Stop ironic_api service (running under httpd) - when: - - ironic_httpd_enabled|bool - - httpd_running|bool - service: name=httpd state=stopped enabled=no + when: is_bootstrap_node|bool - when: step|int == 3 block: - name: Set fact for removal of openstack-ironic-api package diff --git a/docker/services/ironic-conductor.yaml b/docker/services/ironic-conductor.yaml index ae6b243d02..65e87e9c3a 100644 --- a/docker/services/ironic-conductor.yaml +++ b/docker/services/ironic-conductor.yaml @@ -244,25 +244,6 @@ outputs: - httpboot - tftpboot upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if ironic_conductor is deployed - command: systemctl is-enabled --quiet openstack-ironic-conductor - ignore_errors: True - register: ironic_conductor_enabled_result - - name: Set fact ironic_conductor_enabled - set_fact: - ironic_conductor_enabled: "{{ ironic_conductor_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-ironic-conductor is running" - command: systemctl is-active --quiet openstack-ironic-conductor - tags: validation - when: ironic_conductor_enabled|bool - - when: step|int == 2 - block: - - name: Stop and disable ironic_conductor service - when: ironic_conductor_enabled|bool - service: name=openstack-ironic-conductor state=stopped enabled=no - when: step|int == 3 block: - name: Set fact for removal of openstack-ironic-conductor package diff --git a/docker/services/ironic-inspector.yaml b/docker/services/ironic-inspector.yaml index 6a7e8a527d..2fc51c5545 100644 --- a/docker/services/ironic-inspector.yaml +++ b/docker/services/ironic-inspector.yaml @@ -238,28 +238,6 @@ outputs: state: directory setype: svirt_sandbox_file_t upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if ironic_inspector is deployed - command: systemctl is-enabled --quiet openstack-ironic-inspector - ignore_errors: True - register: ironic_inspector_enabled_result - - name: Set fact ironic_inspector_enabled - set_fact: - ironic_inspector_enabled: "{{ ironic_inspector_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-ironic-inspector is running" - command: systemctl is-active --quiet openstack-ironic-inspector - tags: validation - when: ironic_inspector_enabled|bool - - when: step|int == 2 - block: - - name: Stop and disable ironic_inspector service - service: name=openstack-ironic-inspector state=stopped enabled=no - when: ironic_inspector_enabled|bool - - name: Stop and disable ironic_inspector dnsmasq service - service: name=openstack-ironic-inspector-dnsmasq state=stopped enabled=no - when: ironic_inspector_enabled|bool - when: step|int == 3 block: - name: Set fact for removal of openstack-ironic-inspector package diff --git a/docker/services/ironic-neutron-agent.yaml b/docker/services/ironic-neutron-agent.yaml index c49f734ce9..0ef9635836 100644 --- a/docker/services/ironic-neutron-agent.yaml +++ b/docker/services/ironic-neutron-agent.yaml @@ -103,26 +103,7 @@ outputs: environment: - KOLLA_CONFIG_STRATEGY=COPY_ALWAYS host_prep_tasks: {get_attr: [NeutronLogging, host_prep_tasks]} - upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if ironic-neutron-agent is deployed - command: systemctl is-enabled --quiet ironic-neutron-agent - ignore_errors: True - register: ironic_neutron_agent_enabled_result - - name: Set fact ironic_neutron_agent_enabled - set_fact: - ironic_neutron_agent_enabled: "{{ ironic_neutron_agent_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service ironic-neutron-agent is running" - command: systemctl is-active --quiet ironic-neutron-agent - when: ironic_neutron_agent_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable ironic-neutron-agent service - when: ironic_neutron_agent_enabled|bool - service: name=ironic-neutron-agent state=stopped enabled=no + upgrade_tasks: [] post_upgrade_tasks: - when: step|int == 1 import_role: diff --git a/docker/services/iscsid.yaml b/docker/services/iscsid.yaml index 3ffdb0e0be..2920b147b4 100644 --- a/docker/services/iscsid.yaml +++ b/docker/services/iscsid.yaml @@ -114,40 +114,7 @@ outputs: - name: Stop and disable iscsid.socket service service: name=iscsid.socket state=stopped enabled=no when: stat_iscsid_socket.stat.exists - upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if iscsid service is deployed - ignore_errors: True - command: systemctl is-enabled --quiet iscsid - register: iscsid_enabled_result - - name: Set fact iscsid_enabled - set_fact: - iscsid_enabled: "{{ iscsid_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check if iscsid is running" - command: systemctl is-active --quiet iscsid - when: iscsid_enabled|bool - tags: validation - - name: Check if iscsid.socket service is deployed - command: systemctl is-enabled --quiet iscsid.socket - ignore_errors: True - register: iscsid_socket_enabled_result - - name: Set fact iscsid_socket_enabled - set_fact: - iscsid_socket_enabled: "{{ iscsid_socket_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check if iscsid.socket is running" - command: systemctl is-active --quiet iscsid.socket - when: iscsid_socket_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable iscsid service - when: iscsid_enabled|bool - service: name=iscsid state=stopped enabled=no - - name: Stop and disable iscsid.socket service - when: iscsid_socket_enabled|bool - service: name=iscsid.socket state=stopped enabled=no + upgrade_tasks: [] post_upgrade_tasks: - when: step|int == 1 import_role: diff --git a/docker/services/keepalived.yaml b/docker/services/keepalived.yaml index cad6ce0a93..86e760f4e7 100644 --- a/docker/services/keepalived.yaml +++ b/docker/services/keepalived.yaml @@ -123,25 +123,6 @@ outputs: /var/log/containers/keepalived. ignore_errors: true upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if keepalived is deployed - command: systemctl is-enabled --quiet keepalived - ignore_errors: True - register: keepalived_enabled_result - - name: Set fact keepalived_enabled - set_fact: - keepalived_enabled: "{{ keepalived_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service keepalived is running" - command: systemctl is-active --quiet keepalived - when: keepalived_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable keepalived service - service: name=keepalived state=stopped enabled=no - when: keepalived_enabled|bool - when: step|int == 3 block: - name: Set fact for removal of Keepalived package diff --git a/docker/services/keystone.yaml b/docker/services/keystone.yaml index 6a8651cd14..5265ae5e52 100644 --- a/docker/services/keystone.yaml +++ b/docker/services/keystone.yaml @@ -257,40 +257,6 @@ outputs: config_image: *keystone_config_image host_prep_tasks: {get_attr: [KeystoneLogging, host_prep_tasks]} upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check for keystone running under apache - shell: "httpd -t -D DUMP_VHOSTS | grep -q keystone_wsgi" - ignore_errors: True - register: keystone_httpd_enabled_result - - set_fact: - keystone_httpd_enabled: "{{ keystone_httpd_enabled_result.rc == 0 }}" - - name: Check if httpd is running - command: systemctl is-active --quiet httpd - ignore_errors: True - register: httpd_running_result - when: httpd_running is undefined - - set_fact: - httpd_running: "{{ httpd_running_result.rc == 0 }}" - when: httpd_running is undefined - - name: "PreUpgrade step0,validation: Check if keystone_wsgi is running under httpd" - shell: systemctl status 'httpd' | grep -q keystone - tags: validation - when: - - keystone_httpd_enabled|bool - - httpd_running|bool - - when: step|int == 2 - block: - - name: Stop and disable keystone service (running under httpd) - when: - - keystone_httpd_enabled|bool - - httpd_running|bool - service: name=httpd state=stopped enabled=no - - name: remove old keystone cron jobs - file: - path: /var/spool/cron/keystone - state: absent - when: step|int == 3 block: - name: Set fact for removal of openstack-keystone package diff --git a/docker/services/manila-api.yaml b/docker/services/manila-api.yaml index aacde6a69e..617d6efb1c 100644 --- a/docker/services/manila-api.yaml +++ b/docker/services/manila-api.yaml @@ -137,26 +137,7 @@ outputs: Log files from manila containers can be found under /var/log/containers/manila and /var/log/containers/httpd/manila-api. ignore_errors: true - upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if manila_api is deployed - command: systemctl is-enabled --quiet openstack-manila-api - ignore_errors: True - register: manila_api_enabled_result - - name: Set fact manila_api_enabled - set_fact: - manila_api_enabled: "{{ manila_api_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-manila-api is running" - command: systemctl is-active --quiet openstack-manila-api - when: manila_api_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable manila_api service - when: manila_api_enabled|bool - service: name=openstack-manila-api state=stopped enabled=no + upgrade_tasks: [] post_upgrade_tasks: - when: step|int == 1 import_role: diff --git a/docker/services/manila-scheduler.yaml b/docker/services/manila-scheduler.yaml index b34889ff20..9605550b6c 100644 --- a/docker/services/manila-scheduler.yaml +++ b/docker/services/manila-scheduler.yaml @@ -119,26 +119,7 @@ outputs: Log files from manila containers can be found under /var/log/containers/manila and /var/log/containers/httpd/manila-api. ignore_errors: true - upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if manila_scheduler is deployed - command: systemctl is-enabled --quiet openstack-manila-scheduler - ignore_errors: True - register: manila_scheduler_enabled_result - - name: Set fact manila_scheduler_enabled - set_fact: - manila_scheduler_enabled: "{{ manila_scheduler_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-manila-scheduler is running" - command: systemctl is-active --quiet openstack-manila-scheduler - when: manila_scheduler_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable manila_scheduler service - when: manila_scheduler_enabled|bool - service: name=openstack-manila-scheduler state=stopped enabled=no + upgrade_tasks: [] post_upgrade_tasks: - when: step|int == 1 import_role: diff --git a/docker/services/manila-share.yaml b/docker/services/manila-share.yaml index c072dc62c8..ac5d65af59 100644 --- a/docker/services/manila-share.yaml +++ b/docker/services/manila-share.yaml @@ -139,26 +139,7 @@ outputs: file: path: /etc/ceph state: directory - upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if manila_share is deployed - command: systemctl is-enabled --quiet openstack-manila-share - ignore_errors: True - register: manila_share_enabled_result - - name: Set fact manila_share_enabled - set_fact: - manila_share_enabled: "{{ manila_share_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-manila-share is running" - command: systemctl is-active --quiet openstack-manila-share - when: manila_share_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable manila_share service - when: manila_share_enabled|bool - service: name=openstack-manila-share state=stopped enabled=no + upgrade_tasks: [] post_upgrade_tasks: - when: step|int == 1 import_role: diff --git a/docker/services/memcached.yaml b/docker/services/memcached.yaml index 7689b81bc3..e1666de3cc 100644 --- a/docker/services/memcached.yaml +++ b/docker/services/memcached.yaml @@ -93,26 +93,7 @@ outputs: content: | Memcached container logs to stdout/stderr only. ignore_errors: true - upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if memcached is deployed - command: systemctl is-enabled --quiet memcached - ignore_errors: True - register: memcached_enabled_result - - name: Set fact memcached_enabled - set_fact: - memcached_enabled: "{{ memcached_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service memcached is running" - command: systemctl is-active --quiet memcached - when: memcached_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable memcached service - when: memcached_enabled|bool - service: name=memcached state=stopped enabled=no + upgrade_tasks: [] post_upgrade_tasks: - when: step|int == 1 import_role: diff --git a/docker/services/messaging/notify-rabbitmq.yaml b/docker/services/messaging/notify-rabbitmq.yaml index 0ba5b9591a..b16535767e 100644 --- a/docker/services/messaging/notify-rabbitmq.yaml +++ b/docker/services/messaging/notify-rabbitmq.yaml @@ -224,26 +224,7 @@ outputs: Log files from rabbitmq containers can be found under /var/log/containers/rabbitmq. ignore_errors: true - upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if rabbitmq server is deployed - command: systemctl is-enabled --quiet rabbitmq-server - ignore_errors: True - register: rabbitmq_enabled_result - - name: Set fact rabbitmq_enabled - set_fact: - rabbitmq_enabled: "{{ rabbitmq_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service rabbitmq server is running" - command: systemctl is-active --quiet rabbitmq-server - when: rabbitmq_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable rabbitmq service - when: rabbitmq_enabled|bool - service: name=rabbitmq-server state=stopped enabled=no + upgrade_tasks: [] update_tasks: # TODO: Are we sure we want to support this. Rolling update # without pacemaker may fail. Do we test this ? In any case, diff --git a/docker/services/messaging/rpc-rabbitmq.yaml b/docker/services/messaging/rpc-rabbitmq.yaml index a229ee00ca..512dca088c 100644 --- a/docker/services/messaging/rpc-rabbitmq.yaml +++ b/docker/services/messaging/rpc-rabbitmq.yaml @@ -224,26 +224,7 @@ outputs: Log files from rabbitmq containers can be found under /var/log/containers/rabbitmq. ignore_errors: true - upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if rabbitmq server is deployed - command: systemctl is-enabled --quiet rabbitmq-server - ignore_errors: True - register: rabbitmq_enabled_result - - name: Set fact rabbitmq_enabled - set_fact: - rabbitmq_enabled: "{{ rabbitmq_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service rabbitmq server is running" - command: systemctl is-active --quiet rabbitmq-server - when: rabbitmq_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable rabbitmq service - when: rabbitmq_enabled|bool - service: name=rabbitmq-server state=stopped enabled=no + upgrade_tasks: [] update_tasks: # TODO: Are we sure we want to support this. Rolling update # without pacemaker may fail. Do we test this ? In any case, diff --git a/docker/services/metrics/collectd.yaml b/docker/services/metrics/collectd.yaml index b118d9581b..504de8038b 100644 --- a/docker/services/metrics/collectd.yaml +++ b/docker/services/metrics/collectd.yaml @@ -127,25 +127,6 @@ outputs: /var/log/containers/collectd. ignore_errors: true upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if collectd is deployed - command: systemctl is-enabled --quiet collectd - ignore_errors: True - register: collectd_enabled_result - - name: Set fact collectd_enabled - set_fact: - collectd_enabled: "{{ collectd_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service collectd service is running" - command: systemctl is-active --quiet collectd - when: collectd_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable collectd service - when: collectd_enabled|bool - service: name=collectd.service state=stopped enabled=no - when: step|int == 3 block: - name: Set fact for removal of collectd package diff --git a/docker/services/mistral-api.yaml b/docker/services/mistral-api.yaml index eb0b55900b..9b86913c90 100644 --- a/docker/services/mistral-api.yaml +++ b/docker/services/mistral-api.yaml @@ -164,52 +164,6 @@ outputs: /var/log/containers/mistral. ignore_errors: true upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if mistral api is deployed - command: systemctl is-enabled --quiet openstack-mistral-api - ignore_errors: True - register: mistral_api_enabled_result - - set_fact: - mistral_api_enabled: "{{ mistral_api_enabled_result.rc == 0 }}" - - name: Check if httpd service is running - command: systemctl is-active --quiet httpd - ignore_errors: True - register: httpd_running_result - when: httpd_running is undefined - - name: Set fact httpd_running - when: httpd_running is undefined - set_fact: - httpd_running: "{{ httpd_running_result.rc == 0 }}" - - name: Check for mistral_api running under apache - shell: "httpd -t -D DUMP_VHOSTS | grep -q mistral" - ignore_errors: True - register: mistral_httpd_enabled_result - - set_fact: - mistral_httpd_enabled: "{{ mistral_httpd_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check if openstack-mistral-api is running" - command: systemctl is-active --quiet openstack-mistral-api - when: - - mistral_api_enabled|bool - tags: validation - - name: "PreUpgrade step0,validation: Check if mistral_api_wsgi is running" - shell: systemctl status 'httpd' | grep -q mistral - tags: validation - when: - - mistral_httpd_enabled|bool - - httpd_running|bool - - when: step|int == 2 - block: - - name: Stop and disable mistral_api service (pre-upgrade not under httpd) - when: - - mistral_api_enabled|bool - service: name=openstack-mistral-api state=stopped enabled=no - - name: Stop mistral_api service (running under httpd) - service: name=httpd state=stopped enabled=no - when: - - mistral_httpd_enabled|bool - - httpd_running|bool - when: step|int == 3 block: - name: Set fact for removal of openstack-mistral-api package diff --git a/docker/services/mistral-engine.yaml b/docker/services/mistral-engine.yaml index 7e13f8c924..1096c6526f 100644 --- a/docker/services/mistral-engine.yaml +++ b/docker/services/mistral-engine.yaml @@ -134,25 +134,6 @@ outputs: /var/log/containers/mistral. ignore_errors: true upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if mistral engine is deployed - command: systemctl is-enabled --quiet openstack-mistral-engine - ignore_errors: True - register: mistral_engine_enabled_result - - name: Set fact mistral_engine_enabled - set_fact: - mistral_engine_enabled: "{{ mistral_engine_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check if openstack-mistral-engine is running" - command: systemctl is-active --quiet openstack-mistral-engine - when: mistral_engine_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable mistral_engine service - when: mistral_engine_enabled|bool - service: name=openstack-mistral-engine state=stopped enabled=no - when: step|int == 3 block: - name: Set fact for removal of openstack-mistral-engine package diff --git a/docker/services/mistral-event-engine.yaml b/docker/services/mistral-event-engine.yaml index e864ff92c6..fb344e68b7 100644 --- a/docker/services/mistral-event-engine.yaml +++ b/docker/services/mistral-event-engine.yaml @@ -134,25 +134,6 @@ outputs: /var/log/containers/mistral. ignore_errors: true upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if mistral-event-engine is deployed - command: systemctl is-enabled --quiet openstack-mistral-event-engine - ignore_errors: True - register: mistral_event_engine_enabled_result - - name: Set fact mistral_event_engine_enabled - set_fact: - mistral_event_engine_enabled: "{{ mistral_event_engine_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check if openstack-mistral-event-engine is running" - command: systemctl is-active --quiet openstack-mistral-event-engine - when: mistral_event_engine_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable mistral_event_engine service - when: mistral_event_engine_enabled|bool - service: name=openstack-mistral-event-engine state=stopped enabled=no - when: step|int == 3 block: - name: Set fact for removal of openstack-mistral-event-engine package diff --git a/docker/services/mistral-executor.yaml b/docker/services/mistral-executor.yaml index 852b99b8f1..044fb52172 100644 --- a/docker/services/mistral-executor.yaml +++ b/docker/services/mistral-executor.yaml @@ -170,25 +170,6 @@ outputs: state: directory setype: svirt_sandbox_file_t upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if mistral executor is deployed - command: systemctl is-enabled --quiet openstack-mistral-executor - ignore_errors: True - register: mistral_executor_enabled_result - - name: Set fact mistral_executor_enabled - set_fact: - mistral_executor_enabled: "{{ mistral_executor_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check if openstack-mistral-executor is running" - command: systemctl is-active --quiet openstack-mistral-executor - when: mistral_executor_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable mistral_executor service - when: mistral_executor_enabled|bool - service: name=openstack-mistral-executor state=stopped enabled=no - when: step|int == 3 block: - name: Set fact for removal of openstack-mistral-executor package diff --git a/docker/services/multipathd.yaml b/docker/services/multipathd.yaml index 2a76309826..18210b45a5 100644 --- a/docker/services/multipathd.yaml +++ b/docker/services/multipathd.yaml @@ -93,26 +93,7 @@ outputs: vars: modules: - name: dm-multipath - upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if multipathd is deployed - command: systemctl is-enabled --quiet multipathd - ignore_errors: True - register: multipathd_enabled_result - - name: Set fact multipathd_enabled - set_fact: - multipathd_enabled: "{{ multipathd_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service multipathd is running" - command: systemctl is-active --quiet multipathd - when: multipathd_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable multipathd service - when: multipathd_enabled|bool - service: name=multipathd state=stopped enabled=no + upgrade_tasks: [] post_upgrade_tasks: - when: step|int == 1 import_role: diff --git a/docker/services/neutron-api.yaml b/docker/services/neutron-api.yaml index 7e305e017d..1cd22f7415 100644 --- a/docker/services/neutron-api.yaml +++ b/docker/services/neutron-api.yaml @@ -198,25 +198,6 @@ outputs: - {} host_prep_tasks: {get_attr: [NeutronLogging, host_prep_tasks]} upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if neutron_server is deployed - command: systemctl is-enabled --quiet neutron-server - ignore_errors: True - register: neutron_server_enabled_result - - name: Set fact neutron_server_enabled - set_fact: - neutron_server_enabled: "{{ neutron_server_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service neutron-server is running" - command: systemctl is-active --quiet neutron-server - when: neutron_server_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable neutron_api service - when: neutron_server_enabled|bool - service: name=neutron-server state=stopped enabled=no - when: step|int == 3 block: - name: Set fact for removal of openstack-neutron package diff --git a/docker/services/neutron-dhcp.yaml b/docker/services/neutron-dhcp.yaml index 8ce2399377..48e3462fac 100644 --- a/docker/services/neutron-dhcp.yaml +++ b/docker/services/neutron-dhcp.yaml @@ -264,26 +264,7 @@ outputs: path: /var/lib/neutron state: directory setype: svirt_sandbox_file_t - upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if neutron_dhcp_agent is deployed - command: systemctl is-enabled --quiet neutron-dhcp-agent - ignore_errors: True - register: neutron_dhcp_agent_enabled_result - - name: Set fact neutron_dhcp_agent_enabled - set_fact: - neutron_dhcp_agent_enabled: "{{ neutron_dhcp_agent_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service neutron-dhcp-agent is running" - command: systemctl is-active --quiet neutron-dhcp-agent - when: neutron_dhcp_agent_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable neutron_dhcp service - when: neutron_dhcp_agent_enabled|bool - service: name=neutron-dhcp-agent state=stopped enabled=no + upgrade_tasks: [] fast_forward_upgrade_tasks: - when: - step|int == 0 diff --git a/docker/services/neutron-l3.yaml b/docker/services/neutron-l3.yaml index 8ed22a35a4..bf60c95a9f 100644 --- a/docker/services/neutron-l3.yaml +++ b/docker/services/neutron-l3.yaml @@ -261,26 +261,7 @@ outputs: path: /var/lib/neutron state: directory setype: svirt_sandbox_file_t - upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if neutron_l3_agent is deployed - command: systemctl is-enabled --quiet neutron-l3-agent - ignore_errors: True - register: neutron_l3_agent_enabled_result - - name: Set fact neutron_l3_agent_enabled - set_fact: - neutron_l3_agent_enabled: "{{ neutron_l3_agent_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service neutron-l3-agent is running" - command: systemctl is-active --quiet neutron-l3-agent - when: neutron_l3_agent_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable neutron_l3 service - when: neutron_l3_agent_enabled|bool - service: name=neutron-l3-agent state=stopped enabled=no + upgrade_tasks: [] fast_forward_upgrade_tasks: - when: - step|int == 0 diff --git a/docker/services/neutron-metadata.yaml b/docker/services/neutron-metadata.yaml index c6feb3233d..d0ad36675d 100644 --- a/docker/services/neutron-metadata.yaml +++ b/docker/services/neutron-metadata.yaml @@ -143,26 +143,7 @@ outputs: path: /var/lib/neutron state: directory setype: svirt_sandbox_file_t - upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if neutron_metadata_agent is deployed - command: systemctl is-enabled --quiet neutron-metadata-agent - ignore_errors: True - register: neutron_metadata_agent_enabled_result - - name: Set fact neutron_metadata_agent_enabled - set_fact: - neutron_metadata_agent_enabled: "{{ neutron_metadata_agent_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service neutron-metadata-agent is running" - command: systemctl is-active --quiet neutron-metadata-agent - when: neutron_metadata_agent_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable neutron_metadata service - when: neutron_metadata_agent_enabled|bool - service: name=neutron-metadata-agent state=stopped enabled=no + upgrade_tasks: [] post_upgrade_tasks: - when: step|int == 1 import_role: diff --git a/docker/services/neutron-ovs-agent.yaml b/docker/services/neutron-ovs-agent.yaml index 09b55069f9..66b77d6b1f 100644 --- a/docker/services/neutron-ovs-agent.yaml +++ b/docker/services/neutron-ovs-agent.yaml @@ -225,27 +225,7 @@ outputs: service: name: neutron-cleanup enabled: yes - upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if neutron_ovs_agent is deployed - command: systemctl is-enabled --quiet neutron-openvswitch-agent - ignore_errors: True - register: neutron_ovs_agent_enabled_result - - name: Set fact neutron_ovs_agent_enabled - set_fact: - neutron_ovs_agent_enabled: "{{ neutron_ovs_agent_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service neutron-openvswitch-agent is running" - command: systemctl is-active --quiet neutron-openvswitch-agent - when: neutron_ovs_agent_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable neutron_ovs_agent service - when: neutron_ovs_agent_enabled|bool - service: name=neutron-openvswitch-agent state=stopped enabled=no - when: step|int == 3 block: - name: Set fact for removal of openstack-neutron-openvswitch package diff --git a/docker/services/neutron-sriov-agent.yaml b/docker/services/neutron-sriov-agent.yaml index 48aa9832d0..e3d4c3562d 100644 --- a/docker/services/neutron-sriov-agent.yaml +++ b/docker/services/neutron-sriov-agent.yaml @@ -121,26 +121,7 @@ outputs: host_prep_tasks: {get_attr: [NeutronLogging, host_prep_tasks]} metadata_settings: get_attr: [NeutronSriovAgentBase, role_data, metadata_settings] - upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if neutron_sriov_nic_agent is deployed - command: systemctl is-enabled --quiet neutron-sriov-nic-agent - ignore_errors: True - register: neutron_sriov_nic_agent_enabled_result - - name: Set fact neutron_sriov_nic_agent_enabled - set_fact: - neutron_sriov_nic_agent_enabled: "{{ neutron_sriov_nic_agent_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service neutron-sriov-nic-agent is running" - command: systemctl is-active --quiet neutron-sriov-nic-agent - when: neutron_sriov_nic_agent_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable neutron_sriov_agent service - when: neutron_sriov_nic_agent_enabled|bool - service: name=neutron-sriov-nic-agent state=stopped enabled=no + upgrade_tasks: [] post_upgrade_tasks: - when: step|int == 1 import_role: diff --git a/docker/services/nova-api.yaml b/docker/services/nova-api.yaml index 801f972fc7..ac8acb4c87 100644 --- a/docker/services/nova-api.yaml +++ b/docker/services/nova-api.yaml @@ -327,37 +327,6 @@ outputs: block: - name: set is_bootstrap_node fact set_fact: is_bootstrap_node={{nova_api_short_bootstrap_node_name|lower == ansible_hostname|lower}} - - name: Check if nova_api is deployed - command: systemctl is-enabled --quiet openstack-nova-api - ignore_errors: True - register: nova_api_enabled_result - - set_fact: - nova_api_enabled: "{{ nova_api_enabled_result.rc == 0 }}" - - name: Check for nova-api running under apache - shell: httpd -t -D DUMP_VHOSTS | grep -q 'nova' - ignore_errors: True - register: nova_api_httpd_enabled_result - - set_fact: - nova_api_httpd_enabled: "{{ nova_api_httpd_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-nova-api is running" - command: systemctl is-active --quiet openstack-nova-api - tags: validation - when: - - nova_api_enabled|bool - - name: Check if httpd service is running - command: systemctl is-active --quiet httpd - ignore_errors: True - register: httpd_running_result - when: httpd_running is undefined - - set_fact: - httpd_running: "{{ httpd_running_result.rc == 0 }}" - when: httpd_running is undefined - - name: "PreUpgrade step0,validation: Check if nova_wsgi is running" - tags: validation - shell: systemctl status 'httpd' | grep -q 'nova' - when: - - nova_api_httpd_enabled|bool - - httpd_running|bool - name: Ensure all online data migrations for Nova have been applied shell: | if {{ container_cli }} ps | grep nova_api; then @@ -368,21 +337,7 @@ outputs: docker exec nova_api nova-manage db online_data_migrations fi tags: pre-upgrade - when: - - is_bootstrap_node|bool - - not (nova_api_httpd_enabled|bool and httpd_running|bool) - - not nova_api_enabled|bool - - when: step|int == 2 - block: - - name: Stop and disable nova_api service - when: - - nova_api_enabled|bool - service: name=openstack-nova-api state=stopped enabled=no - - name: Stop nova_api service (running under httpd) - when: - - nova_api_httpd_enabled|bool - - httpd_running|bool - service: name=httpd state=stopped + when: is_bootstrap_node|bool - when: step|int == 3 block: - name: Set fact for removal of openstack-nova-api package @@ -393,10 +348,6 @@ outputs: ignore_errors: True when: - remove_nova_api_package|bool - - name: remove old nova cron jobs - file: - path: /var/spool/cron/nova - state: absent external_upgrade_tasks: - when: step|int == 1 block: diff --git a/docker/services/nova-compute.yaml b/docker/services/nova-compute.yaml index 875b709456..7bdcb6bafa 100644 --- a/docker/services/nova-compute.yaml +++ b/docker/services/nova-compute.yaml @@ -50,10 +50,6 @@ parameters: description: Port that dockerized nova migration target sshd service binds to. type: number - UpgradeLevelNovaCompute: - type: string - description: Nova Compute upgrade level - default: '' UpgradeRemoveUnusedPackages: default: false description: Remove package if the service is being disabled during upgrade @@ -290,36 +286,8 @@ outputs: file: path=/var/lib/nova/instanceha/enabled state=touch when: iha_nodes.stdout|lower | search('"'+ansible_hostname|lower+'"') upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if nova_compute is deployed - command: systemctl is-enabled --quiet openstack-nova-compute - ignore_errors: True - register: nova_compute_enabled_result - - name: Set fact nova_compute_enabled - set_fact: - nova_compute_enabled: "{{ nova_compute_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-nova-compute is running" - command: systemctl is-active --quiet openstack-nova-compute - tags: validation - when: nova_compute_enabled|bool - - when: step|int == 1 - block: - - name: Set compute upgrade level to auto - ini_file: - str_replace: - template: "dest=/etc/nova/nova.conf section=upgrade_levels option=compute value=LEVEL" - params: - LEVEL: {get_param: UpgradeLevelNovaCompute} - when: step|int == 2 block: - - name: Stop and disable nova-compute service - when: nova_compute_enabled|bool - service: name=openstack-nova-compute state=stopped enabled=no - - name: Set upgrade marker in nova statedir - when: nova_compute_enabled|bool - file: path=/var/lib/nova/upgrade_marker state=touch owner=nova group=nova - name: Set fact for removal of openstack-nova-compute package set_fact: remove_nova_compute_package: {get_param: UpgradeRemoveUnusedPackages} diff --git a/docker/services/nova-conductor.yaml b/docker/services/nova-conductor.yaml index 9fd49c263e..96f423650c 100644 --- a/docker/services/nova-conductor.yaml +++ b/docker/services/nova-conductor.yaml @@ -41,10 +41,6 @@ parameters: default: {} description: Parameters specific to the role type: json - UpgradeLevelNovaCompute: - type: string - description: Nova Compute upgrade level - default: '' UpgradeRemoveUnusedPackages: default: false description: Remove package if the service is being disabled during upgrade @@ -145,33 +141,6 @@ outputs: - KOLLA_CONFIG_STRATEGY=COPY_ALWAYS host_prep_tasks: {get_attr: [NovaLogging, host_prep_tasks]} upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if nova_conductor is deployed - command: systemctl is-enabled --quiet openstack-nova-conductor - ignore_errors: True - register: nova_conductor_enabled_result - - name: Set fact nova_conductor_enabled - set_fact: - nova_conductor_enabled: "{{ nova_conductor_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-nova-conductor is running" - command: systemctl is-active --quiet openstack-nova-conductor - tags: validation - when: nova_conductor_enabled|bool - - when: step|int == 1 - block: - - name: Set compute upgrade level to auto - ini_file: - str_replace: - template: "dest=/etc/nova/nova.conf section=upgrade_levels option=compute value=LEVEL" - params: - LEVEL: {get_param: UpgradeLevelNovaCompute} - - when: step|int == 2 - block: - - name: Stop and disable nova_conductor service - when: nova_conductor_enabled|bool - service: name=openstack-nova-conductor state=stopped enabled=no - when: step|int == 3 block: - name: Set fact for removal of openstack-nova-conductor package diff --git a/docker/services/nova-consoleauth.yaml b/docker/services/nova-consoleauth.yaml index 143a605591..220f472ad1 100644 --- a/docker/services/nova-consoleauth.yaml +++ b/docker/services/nova-consoleauth.yaml @@ -140,25 +140,6 @@ outputs: - KOLLA_CONFIG_STRATEGY=COPY_ALWAYS host_prep_tasks: {get_attr: [NovaLogging, host_prep_tasks]} upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if nova_consoleauth is deployed - command: systemctl is-enabled --quiet openstack-nova-consoleauth - ignore_errors: True - register: nova_consoleauth_enabled_result - - name: Set fact nova_consoleauth_enabled - set_fact: - nova_consoleauth_enabled: "{{ nova_consoleauth_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-nova-consoleauth is running" - command: systemctl is-active --quiet openstack-nova-consoleauth - tags: validation - when: nova_consoleauth_enabled|bool - - when: step|int == 2 - block: - - name: Stop and disable nova_consoleauth service - when: nova_consoleauth_enabled|bool - service: name=openstack-nova-consoleauth state=stopped enabled=no - when: step|int == 3 block: - name: Set fact for removal of openstack-nova-console package diff --git a/docker/services/nova-ironic.yaml b/docker/services/nova-ironic.yaml index 7e0bf5e81e..4df744d912 100644 --- a/docker/services/nova-ironic.yaml +++ b/docker/services/nova-ironic.yaml @@ -162,28 +162,6 @@ outputs: /var/log/containers/nova and /var/log/containers/httpd/nova-*. ignore_errors: true upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if nova ironic is deployed - command: systemctl is-enabled --quiet openstack-nova-compute - ignore_errors: True - register: nova_ironic_enabled_result - - name: Set fact nova_ironic_enabled - set_fact: - nova_ironic_enabled: "{{ nova_ironic_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-nova-compute is running" - command: systemctl is-active --quiet openstack-nova-compute - tags: validation - when: nova_ironic_enabled|bool - - when: step|int == 2 - block: - - name: Stop and disable nova-compute service - when: nova_ironic_enabled|bool - service: name=openstack-nova-compute state=stopped enabled=no - - name: Set upgrade marker in nova statedir - when: nova_ironic_enabled|bool - file: path=/var/lib/nova/upgrade_marker state=touch owner=nova group=nova - when: step|int == 3 block: - name: Set fact for removal of openstack-nova-compute package diff --git a/docker/services/nova-libvirt.yaml b/docker/services/nova-libvirt.yaml index c92f0a6194..3982908a5a 100644 --- a/docker/services/nova-libvirt.yaml +++ b/docker/services/nova-libvirt.yaml @@ -481,26 +481,7 @@ outputs: d /var/run/libvirt 0755 root root - - metadata_settings: get_attr: [NovaLibvirtBase, role_data, metadata_settings] - upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if nova_libvirt is deployed - command: systemctl is-enabled --quiet libvirtd - ignore_errors: True - register: nova_libvirt_enabled_result - - name: Set fact nova_libvirt_enabled - set_fact: - nova_libvirt_enabled: "{{ nova_libvirt_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service libvirtd is running" - command: systemctl is-active --quiet libvirtd - tags: validation - when: nova_libvirt_enabled|bool - - when: step|int == 2 - block: - - name: Stop and disable libvirtd service - when: nova_libvirt_enabled|bool - service: name=libvirtd state=stopped enabled=no + upgrade_tasks: [] post_upgrade_tasks: - when: step|int == 1 import_role: diff --git a/docker/services/nova-placement.yaml b/docker/services/nova-placement.yaml index 18b85bca98..1d21902a0e 100644 --- a/docker/services/nova-placement.yaml +++ b/docker/services/nova-placement.yaml @@ -156,36 +156,6 @@ outputs: state: directory setype: svirt_sandbox_file_t upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check for nova placement running under apache - shell: "httpd -t -D DUMP_VHOSTS | grep -q placement_wsgi" - ignore_errors: True - register: nova_placement_httpd_enabled - - set_fact: - nova_placement_httpd: "{{ nova_placement_httpd_enabled.rc == 0 }}" - - name: Check if httpd is running - command: systemctl is-active --quiet httpd - ignore_errors: True - register: httpd_running_result - when: httpd_running is undefined - - set_fact: - httpd_running: "{{ httpd_running_result.rc == 0 }}" - when: httpd_running is undefined - - name: "PreUpgrade step0,validation: Check if placement_wsgi is running" - shell: systemctl status 'httpd' | grep -q placement_wsgi - tags: validation - when: - - nova_placement_httpd_enabled|bool - - httpd_running|bool - - when: step|int == 2 - block: - - name: Stop and disable nova_placement service (running under httpd) - when: - - nova_placement_httpd_enabled|bool - - httpd_running|bool - service: name=httpd state=stopped enabled=no - when: step|int == 3 block: - name: Set fact for removal of httpd package diff --git a/docker/services/nova-scheduler.yaml b/docker/services/nova-scheduler.yaml index ee5f85294e..e1e77df0ff 100644 --- a/docker/services/nova-scheduler.yaml +++ b/docker/services/nova-scheduler.yaml @@ -141,25 +141,6 @@ outputs: - KOLLA_CONFIG_STRATEGY=COPY_ALWAYS host_prep_tasks: {get_attr: [NovaLogging, host_prep_tasks]} upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if nova_scheduler is deployed - command: systemctl is-enabled --quiet openstack-nova-scheduler - ignore_errors: True - register: nova_scheduler_enabled_result - - name: Set fact nova_scheduler_enabled - set_fact: - nova_scheduler_enabled: "{{ nova_scheduler_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-nova-scheduler is running" - command: systemctl is-active --quiet openstack-nova-scheduler - tags: validation - when: nova_scheduler_enabled|bool - - when: step|int == 2 - block: - - name: Stop and disable nova_scheduler service - when: nova_scheduler_enabled|bool - service: name=openstack-nova-scheduler state=stopped enabled=no - when: step|int == 3 block: - name: Set fact for removal of openstack-nova-scheduler package diff --git a/docker/services/nova-vnc-proxy.yaml b/docker/services/nova-vnc-proxy.yaml index 47619b9449..e48eed349b 100644 --- a/docker/services/nova-vnc-proxy.yaml +++ b/docker/services/nova-vnc-proxy.yaml @@ -199,25 +199,6 @@ outputs: get_attr: [NovaVncProxyPuppetBase, role_data, metadata_settings] host_prep_tasks: {get_attr: [NovaLogging, host_prep_tasks]} upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if nova vncproxy is deployed - command: systemctl is-enabled --quiet openstack-nova-novncproxy - ignore_errors: True - register: nova_vncproxy_enabled_result - - name: Set fact nova_vncproxy_enabled - set_fact: - nova_vncproxy_enabled: "{{ nova_vncproxy_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-nova-novncproxy is running" - command: systemctl is-active --quiet openstack-nova-novncproxy - tags: validation - when: nova_vncproxy_enabled|bool - - when: step|int == 2 - block: - - name: Stop and disable nova_vnc_proxy service - when: nova_vncproxy_enabled|bool - service: name=openstack-nova-novncproxy state=stopped enabled=no - when: step|int == 3 block: - name: Set fact for removal of openstack-nova-novncproxy package diff --git a/docker/services/octavia-api.yaml b/docker/services/octavia-api.yaml index 18a9e77dfb..10ff7fb2ba 100644 --- a/docker/services/octavia-api.yaml +++ b/docker/services/octavia-api.yaml @@ -222,53 +222,7 @@ outputs: Log files from octavia containers can be found under /var/log/containers/octavia and /var/log/containers/httpd/octavia-api. ignore_errors: true - upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if octavia_api is deployed - command: systemctl is-enabled --quiet openstack-octavia-api - ignore_errors: True - register: octavia_api_enabled_result - - name: Set fact octavia_api_enabled - set_fact: - octavia_api_enabled: "{{ octavia_api_enabled_result.rc == 0 }}" - - name: Check for octavia-api running under apache - shell: httpd -t -D DUMP_VHOSTS | grep -q 'octavia' - ignore_errors: True - register: octavia_api_httpd_enabled_result - - name: Set fact octavia_api_httpd_enabled - set_fact: - octavia_api_httpd_enabled: "{{ octavia_api_httpd_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-octavia-api is running" - command: systemctl is-active --quiet openstack-octavia-api - tags: validation - when: octavia_api_enabled|bool - - name: Check if httpd service is running - command: systemctl is-active --quiet httpd - ignore_errors: True - register: httpd_running_result - when: httpd_running is undefined - - name: Set fact httpd_running - set_fact: - httpd_running: "{{ httpd_running_result.rc == 0 }}" - when: httpd_running is undefined - - name: "PreUpgrade step0,validation: Check if octavia_api_cfn_wsgi is running" - tags: validation - when: - - octavia_api_httpd_enabled|bool - - httpd_running|bool - shell: systemctl status 'httpd' | grep -q 'octavia' - - when: step|int == 2 - block: - - name: Stop and disable octavia_api service - service: name=openstack-octavia-api state=stopped enabled=no - when: octavia_api_enabled|bool - - name: Stop octavia_api service (running under httpd) - when: - - octavia_api_httpd_enabled|bool - - httpd_running|bool - service: name=httpd state=stopped + upgrade_tasks: [] metadata_settings: get_attr: [OctaviaApiPuppetBase, role_data, metadata_settings] post_upgrade_tasks: diff --git a/docker/services/octavia-health-manager.yaml b/docker/services/octavia-health-manager.yaml index 7a86f77903..f29223245f 100644 --- a/docker/services/octavia-health-manager.yaml +++ b/docker/services/octavia-health-manager.yaml @@ -146,25 +146,6 @@ outputs: /var/log/containers/octavia and /var/log/containers/httpd/octavia-api. ignore_errors: true upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if octavia_health_manager is deployed - common: systemctl is-enabled --quiet openstack-octavia-health-manager - ignore_errors: True - register: octavia_health_enabled_result - - name: Set fact octavia_health_enabled - set_fact: - octavia_health_enabled: "{{ octavia_health_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-octavia-health-manager is running" - command: systemctl is-active --quiet openstack-octavia-health-manager - tags: validation - when: octavia_health_enabled|bool - - when: step|int == 2 - block: - - name: Stop and disable octavia_health_manager service - when: octavia_health_enabled|bool - service: name=openstack-octavia-health-manager state=stopped enabled=no - when: step|int == 3 block: - name: Set fact for removal of openstack-octavia-health-manager package diff --git a/docker/services/octavia-housekeeping.yaml b/docker/services/octavia-housekeeping.yaml index 7d25f47562..d555766a49 100644 --- a/docker/services/octavia-housekeeping.yaml +++ b/docker/services/octavia-housekeeping.yaml @@ -141,26 +141,7 @@ outputs: Log files from octavia containers can be found under /var/log/containers/octavia and /var/log/containers/httpd/octavia-api. ignore_errors: true - upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if octavia_housekeeping is deployed - common: systemctl is-enabled --quiet openstack-octavia-housekeeping - ignore_errors: True - register: octavia_housekeeping_enabled_result - - name: Set fact octavia_housekeeping_enabled - set_fact: - octavia_housekeeping_enabled: "{{ octavia_housekeeping_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-octavia-housekeeping is running" - command: systemctl is-active --quiet openstack-octavia-housekeeping - when: octavia_housekeeping_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable octavia_housekeeping service - when: octavia_housekeeping_enabled|bool - service: name=openstack-octavia-housekeeping state=stopped enabled=no + upgrade_tasks: [] post_upgrade_tasks: - when: step|int == 1 import_role: diff --git a/docker/services/octavia-worker.yaml b/docker/services/octavia-worker.yaml index 50bf3f4007..74387e63e5 100644 --- a/docker/services/octavia-worker.yaml +++ b/docker/services/octavia-worker.yaml @@ -160,26 +160,7 @@ outputs: - python2-openstackclient - openssl when: {get_param: EnablePackageInstall} - upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if octavia_worker is deployed - common: systemctl is-enabled --quiet openstack-octavia-worker - ignore_errors: True - register: octavia_worker_enabled_result - - name: Set fact octavia_worker_enabled - set_fact: - octavia_worker_enabled: "{{ octavia_worker_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-octavia-worker is running" - command: systemctl is-active --quiet openstack-octavia-worker - when: octavia_worker_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable octavia_worker service - when: octavia_worker_enabled|bool - service: name=openstack-octavia-worker state=stopped enabled=no + upgrade_tasks: [] post_upgrade_tasks: - when: step|int == 1 import_role: diff --git a/docker/services/opendaylight-api.yaml b/docker/services/opendaylight-api.yaml index f6f9131dc0..3ebdd05a32 100644 --- a/docker/services/opendaylight-api.yaml +++ b/docker/services/opendaylight-api.yaml @@ -165,25 +165,6 @@ outputs: - /var/lib/opendaylight/journal - /var/lib/opendaylight/data upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if opendaylight is deployed - command: systemctl is-enabled --quiet opendaylight - ignore_errors: True - register: opendaylight_enabled_result - - name: Set fact opendaylight_enabled - set_fact: - opendaylight_enabled: "{{ opendaylight_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service opendaylight is running" - command: systemctl is-active --quiet opendaylight - when: opendaylight_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable opendaylight_api service - when: opendaylight_enabled|bool - service: name=opendaylight state=stopped enabled=no # Containerized deployment upgrade steps - name: ODL container L2 update and upgrade tasks block: &odl_container_upgrade_tasks diff --git a/docker/services/ovn-controller.yaml b/docker/services/ovn-controller.yaml index 171b54a9f3..f60c5bece4 100644 --- a/docker/services/ovn-controller.yaml +++ b/docker/services/ovn-controller.yaml @@ -138,26 +138,7 @@ outputs: Log files from openvswitch containers can be found under /var/log/containers/openvswitch. ignore_errors: true - upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if ovn_controller is deployed - command: systemctl is-enabled --quiet ovn-controller - ignore_errors: True - register: ovn_controller_enabled_result - - name: Set fact ovn_controller_enabled - set_fact: - ovn_controller_enabled: "{{ ovn_controller_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service ovn_controller is running" - command: systemctl is-active --quiet ovn-controller - when: ovn_controller_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable ovn-controller service - when: ovn_controller_enabled|bool - service: name=ovn-controller state=stopped enabled=no + upgrade_tasks: [] post_upgrade_tasks: - when: step|int == 1 import_role: diff --git a/docker/services/ovn-dbs.yaml b/docker/services/ovn-dbs.yaml index 933bd34067..80a69f2f81 100644 --- a/docker/services/ovn-dbs.yaml +++ b/docker/services/ovn-dbs.yaml @@ -205,26 +205,7 @@ outputs: Log files from openvswitch containers can be found under /var/log/containers/openvswitch. ignore_errors: true - upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if ovn_northd is deployed - command: systemctl is-enabled --quiet ovn-northd - ignore_errors: True - register: ovn_northd_enabled_result - - name: Set fact ovn_northd_enabled - set_fact: - ovn_northd_enabled: "{{ ovn_northd_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service ovn_northd is running" - command: systemctl is-active --quiet ovn-northd - when: ovn_northd_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable ovn-northd service - when: ovn_northd_enabled|bool - service: name=ovn-northd state=stopped enabled=no + upgrade_tasks: [] post_upgrade_tasks: - when: step|int == 1 import_role: diff --git a/docker/services/ovn-metadata.yaml b/docker/services/ovn-metadata.yaml index df165a1f10..b851d34aac 100644 --- a/docker/services/ovn-metadata.yaml +++ b/docker/services/ovn-metadata.yaml @@ -215,26 +215,7 @@ outputs: path: /var/lib/neutron state: directory setype: svirt_sandbox_file_t - upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if ovn_metadata_agent is deployed - command: systemctl is-enabled --quiet networking-ovn-metadata-agent - ignore_errors: True - register: networking_ovn_metadata_agent_enabled_result - - name: Set fact networking_ovn_metadata_agent_enabled - set_fact: - networking_ovn_metadata_agent_enabled: "{{ networking_ovn_metadata_agent_enabled.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service networking-ovn-metadata-agent is running" - command: systemctl is-active --quiet networking-ovn-metadata-agent - when: networking_ovn_metadata_agent_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable networking_ovn_metadata service - when: networking_ovn_metadata_agent_enabled|bool - service: name=networking-ovn-metadata-agent state=stopped enabled=no + upgrade_tasks: [] post_upgrade_tasks: - when: step|int == 1 import_role: diff --git a/docker/services/rabbitmq.yaml b/docker/services/rabbitmq.yaml index f3d57e863c..38b9513948 100644 --- a/docker/services/rabbitmq.yaml +++ b/docker/services/rabbitmq.yaml @@ -223,27 +223,8 @@ outputs: Log files from rabbitmq containers can be found under /var/log/containers/rabbitmq. ignore_errors: true - upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if rabbitmq server is deployed - command: systemctl is-enabled --quiet rabbitmq-server - ignore_errors: True - register: rabbitmq_enabled_result - - name: Set fact rabbitmq_enabled - set_fact: - rabbitmq_enabled: "{{ rabbitmq_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service rabbitmq server is running" - command: systemctl is-active --quiet rabbitmq-server - when: rabbitmq_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable rabbitmq service - when: rabbitmq_enabled|bool - service: name=rabbitmq-server state=stopped enabled=no - # TODO: Removal of package + # TODO: Removal of package + upgrade_tasks: [] update_tasks: # TODO: Are we sure we want to support this. Rolling update # without pacemaker may fail. Do we test this ? In any case, diff --git a/docker/services/sahara-api.yaml b/docker/services/sahara-api.yaml index 5fd8b2cafc..113e406fc7 100644 --- a/docker/services/sahara-api.yaml +++ b/docker/services/sahara-api.yaml @@ -158,25 +158,6 @@ outputs: /var/log/containers/sahara. ignore_errors: true upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if sahara_api is deployed - command: systemctl is-enabled --quiet openstack-sahara-api - ignore_errors: True - register: sahara_api_enabled_result - - name: Set fact sahara_api_enabled - set_fact: - sahara_api_enabled: "{{ sahara_api_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-sahara-api is running" - command: systemctl is-active --quiet openstack-sahara-api - when: sahara_api_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable sahara_api service - when: sahara_api_enabled|bool - service: name=openstack-sahara-api state=stopped enabled=no - when: step|int == 3 block: - name: Set fact for removal of openstack-sahara-api package diff --git a/docker/services/sahara-engine.yaml b/docker/services/sahara-engine.yaml index 40daeb531e..6fd5e910b9 100644 --- a/docker/services/sahara-engine.yaml +++ b/docker/services/sahara-engine.yaml @@ -147,25 +147,6 @@ outputs: /var/log/containers/sahara. ignore_errors: true upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if sahara_engine is deployed - command: systemctl is-enabled --quiet openstack-sahara-engine - ignore_errors: True - register: sahara_engine_enabled_result - - name: Set fact sahara_engine_enabled - set_fact: - sahara_engine_enabled: "{{ sahara_engine_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-sahara-engine is running" - command: systemctl is-active --quiet openstack-sahara-engine - when: sahara_engine_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable sahara_engine service - when: sahara_engine_enabled|bool - service: name=openstack-sahara-engine state=stopped enabled=no - when: step|int == 3 block: - name: Set fact for removal of openstack-sahara-engine package diff --git a/docker/services/sensu-client.yaml b/docker/services/sensu-client.yaml index 2e7b39ee37..e65fc90a37 100644 --- a/docker/services/sensu-client.yaml +++ b/docker/services/sensu-client.yaml @@ -163,27 +163,8 @@ outputs: Log files from sensu containers can be found under /var/log/containers/sensu. ignore_errors: true - upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if sensu client is deployed - command: systemctl is-enabled --quiet sensu-client - ignore_errors: True - register: sensu_enabled_result - - name: Set fact sensu_enabled - set_fact: - sensu_enabled: "{{ sensu_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check if sensu client is running" - command: systemctl is-active --quiet sensu-client - when: sensu_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable sensu-client service - when: sensu_enabled|bool - service: name=sensu-client state=stopped enabled=no - #TODO: Removal of package + # TODO: Removal of package + upgrade_tasks: [] post_upgrade_tasks: - when: step|int == 1 import_role: diff --git a/docker/services/swift-proxy.yaml b/docker/services/swift-proxy.yaml index 34132864de..afdda44405 100644 --- a/docker/services/swift-proxy.yaml +++ b/docker/services/swift-proxy.yaml @@ -274,30 +274,6 @@ outputs: - logconfig|changed when: rsyslog_config.rc == 0 upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if swift-proxy or swift-object-expirer are deployed - command: systemctl is-enabled --quiet "{{ item }}" - ignore_errors: True - register: swift_proxy_services_enabled_result - with_items: - - openstack-swift-proxy - - openstack-swift-object-expirer - - name: Set fact swift_proxy_services_enabled - set_fact: - swift_proxy_services_enabled: "{{ swift_proxy_services_enabled_result }}" - - name: "PreUpgrade step0,validation: Check service openstack-swift-proxy and openstack-swift-object-expirer are running" - command: systemctl is-active --quiet "{{ item.item }}" - when: item.rc == 0 - tags: validation - with_items: "{{ swift_proxy_services_enabled.results }}" - - when: step|int == 2 - block: - - name: Stop and disable swift-proxy and swift-object-expirer services - when: item.rc == 0 - service: name={{ item.item }} state=stopped enabled=no - with_items: "{{ swift_proxy_services_enabled.results }}" - when: step|int == 3 block: - name: Set fact for removal of openstack-swift-proxy package diff --git a/docker/services/swift-storage.yaml b/docker/services/swift-storage.yaml index 8dc011a252..5df077991f 100644 --- a/docker/services/swift-storage.yaml +++ b/docker/services/swift-storage.yaml @@ -524,62 +524,6 @@ outputs: with_items: "{{ swift_raw_disks }}" when: swift_raw_disks upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if swift storage services are deployed - command: systemctl is-enabled --quiet "{{ item }}" - register: swift_services_enabled_result - ignore_errors: true - with_items: - - openstack-swift-account-auditor - - openstack-swift-account-reaper - - openstack-swift-account-replicator - - openstack-swift-account - - openstack-swift-container-auditor - - openstack-swift-container-replicator - - openstack-swift-container-updater - - openstack-swift-container - - openstack-swift-container-sync - - openstack-swift-object-auditor - - openstack-swift-object-replicator - - openstack-swift-object-updater - - openstack-swift-object - - openstack-swift-object-reconstructor - - name: Set fact swift_services_enabled - set_fact: - swift_services_enabled: "{{ swift_services_enabled_result }}" - - name: "PreUpgrade step0,validation: Check swift storage services are running" - command: systemctl is-active --quiet "{{ item.item }}" - tags: validation - with_items: "{{ swift_services_enabled.results }}" - when: item.rc == 0 - - when: step|int == 2 - block: - - name: Stop and disable swift storage services - service: name={{ item.item }} state=stopped enabled=no - with_items: "{{ swift_services_enabled.results }}" - when: item.rc == 0 - - name: Check if deprecated UC Swift storage directory exists - stat: path=/srv/node/1 - register: swift_dir_1_stat - - name: Move deprecated UC Swift storage directory - command: mv /srv/node/1 /srv/node/d1 - when: swift_dir_1_stat.stat.exists - - name: Update Swift rings to use d1 device instead of 1 - command: swift-ring-builder {{ item }} set_info --device 1 --change-device d1 - with_items: - - /etc/swift/account.builder - - /etc/swift/container.builder - - /etc/swift/object.builder - when: swift_dir_1_stat.stat.exists - - name: Write out updated Swift rings - command: swift-ring-builder {{ item }} write_ring - with_items: - - /etc/swift/account.builder - - /etc/swift/container.builder - - /etc/swift/object.builder - when: swift_dir_1_stat.stat.exists - when: step|int == 3 block: - name: Set fact for removal of openstack-swift-container,object,account package @@ -593,12 +537,6 @@ outputs: - openstack-swift-container - openstack-swift-object - openstack-swift-account - - name: Remove rsync service from xinetd - file: state=absent path=/etc/xinetd.d/rsync - register: rsync_service_removed - - name: Restart xinetd service after rsync removal - service: name=xinetd state=restarted - when: rsync_service_removed|changed update_tasks: - name: Ensure rsyncd pid file is absent file: diff --git a/docker/services/tacker.yaml b/docker/services/tacker.yaml index 9357cda3c5..9291d6ac09 100644 --- a/docker/services/tacker.yaml +++ b/docker/services/tacker.yaml @@ -142,27 +142,7 @@ outputs: Log files from tacker containers can be found under /var/log/containers/tacker. ignore_errors: true - upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if tacker is deployed - command: systemctl is-enabled --quiet openstack-tacker-server - ignore_errors: True - register: tacker_enabled_result - - name: Set fact tacker_enabled - set_fact: - tacker_enabled: "{{ tacker_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check if tacker is running" - command: systemctl is-active --quiet openstack-tacker-server - when: tacker_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable tacker-server service - when: tacker_enabled|bool - service: name=openstack-tacker-server state=stopped enabled=no - #TODO: Removal of package + upgrade_tasks: [] post_upgrade_tasks: - when: step|int == 1 import_role: diff --git a/docker/services/tripleo-ui.yaml b/docker/services/tripleo-ui.yaml index 1a90e34abd..f1d834a114 100644 --- a/docker/services/tripleo-ui.yaml +++ b/docker/services/tripleo-ui.yaml @@ -124,36 +124,8 @@ outputs: with_items: - /var/log/containers/httpd/tripleo-ui upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check for tripleo-ui service running under apache - shell: "httpd -t -D DUMP_VHOSTS | grep -q tripleo-ui" - ignore_errors: True - register: tripleo_ui_httpd_enabled_result - - set_fact: - tripleo_ui_httpd_enabled: "{{ tripleo_ui_httpd_enabled_result.rc == 0 }}" - - name: Check if httpd is running - command: systemctl is-active --quiet httpd - ignore_errors: True - register: httpd_running_result - when: httpd_running is undefined - - set_fact: - httpd_running: "{{ httpd_running_result.rc == 0 }}" - when: httpd_running is undefined - - name: "PreUpgrade step0,validation: Check if tripleo-ui is running" - shell: systemctl status 'httpd' | grep -q tripleo-ui - tags: validation - when: - - tripleo_ui_httpd_enabled|bool - - httpd_running|bool - when: step|int == 2 block: - - name: Stop and disable tripleo-ui service (running under httpd) - when: - - tripleo_ui_httpd_enabled|bool - - httpd_running|bool - service: name=httpd state=stopped enabled=no - name: Remove openstack-tripleo-ui package if operator requests it package: name=openstack-tripleo-ui state=removed ignore_errors: True diff --git a/docker/services/xinetd.yaml b/docker/services/xinetd.yaml index 07aa4040ca..52dea8c919 100644 --- a/docker/services/xinetd.yaml +++ b/docker/services/xinetd.yaml @@ -47,28 +47,6 @@ outputs: config_image: '' config_settings: {} upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check if xinetd service is deployed - ignore_errors: True - command: systemctl is-enabled --quiet xinetd - register: xinetd_enabled_result - - name: Set fact xinetd_enabled - set_fact: - xinetd_enabled: "{{ xinetd_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check if xinetd is running" - command: systemctl is-active --quiet xinetd - when: xinetd_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: stop and deactivate xinetd service - when: xinetd_enabled|bool - service: - name: xinetd - state: stopped - enabled: no - when: step|int == 3 block: - name: set remove_xinetd_pkg fact diff --git a/docker/services/zaqar.yaml b/docker/services/zaqar.yaml index 7f88301cc3..6241ac0594 100644 --- a/docker/services/zaqar.yaml +++ b/docker/services/zaqar.yaml @@ -197,50 +197,6 @@ outputs: /var/log/containers/zaqar and /var/log/containers/httpd/zaqar. ignore_errors: true upgrade_tasks: - - when: step|int == 0 - tags: common - block: - - name: Check for zaqar running under apache - shell: "httpd -t -D DUMP_VHOSTS | grep -q zaqar_wsgi" - ignore_errors: True - register: zaqar_httpd_enabled_result - - set_fact: - zaqar_httpd_enabled: "{{ zaqar_httpd_enabled_result.rc == 0 }}" - - name: Check if httpd is running - command: systemctl is-active --quiet httpd - ignore_errors: True - register: httpd_running_result - when: httpd_running is undefined - - set_fact: - httpd_running: "{{ httpd_running_result.rc == 0 }}" - when: httpd_running is undefined - - name: "PreUpgrade step0,validation: Check if zaqar_wsgi is running" - shell: systemctl status 'httpd' | grep -q zaqar_wsgi - tags: validation - when: - - zaqar_httpd_enabled|bool - - httpd_running|bool - - name: Check if zaqar websocket is deployed - command: systemctl is-enabled --quiet openstack-zaqar@1 - ignore_errors: True - register: zaqar_ws_enabled_result - - name: Set fact zaqar_ws_enabled - set_fact: - zaqar_ws_enabled: "{{ zaqar_ws_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service openstack-zaqar@1 is running" - command: systemctl is-active --quiet openstack-zaqar@1 - when: zaqar_ws_enabled|bool - tags: validation - - when: step|int == 2 - block: - - name: Stop and disable zaqar service - when: - - zaqar_httpd_enabled|bool - - httpd_running|bool - service: name=httpd state=stopped enabled=no - - name: Stop and disable zaqar websocket service - when: zaqar_ws_enabled|bool - service: name=openstack-zaqar@1 state=stopped enabled=no - when: step|int == 3 block: - name: Set fact for removal of openstack-zaqar package diff --git a/puppet/services/apache.j2.yaml b/puppet/services/apache.j2.yaml index 4d8a394803..cec5790b53 100644 --- a/puppet/services/apache.j2.yaml +++ b/puppet/services/apache.j2.yaml @@ -132,24 +132,4 @@ outputs: for_each: $NETWORK: {get_attr: [ApacheNetworks, value]} - null - upgrade_tasks: -{% raw %} - - when: step|int == 0 - tags: common - block: - - name: Check if httpd is deployed - command: systemctl is-enabled httpd - ignore_errors: True - register: httpd_enabled_result - - name: Set fact httpd_enabled - set_fact: - httpd_enabled: "{{ httpd_enabled_result.rc == 0 }}" - - name: "PreUpgrade step0,validation: Check service httpd is running" - shell: /usr/bin/systemctl show 'httpd' --property ActiveState | grep '\bactive\b' - when: httpd_enabled|bool - tags: validation - - when: step|int == 3 - block: - - name: Ensure mod_ssl package is installed - package: name=mod_ssl state=latest -{% endraw %} + upgrade_tasks: [] diff --git a/puppet/services/auditd.yaml b/puppet/services/auditd.yaml index 86cbff96ed..fa3312acc7 100644 --- a/puppet/services/auditd.yaml +++ b/puppet/services/auditd.yaml @@ -44,22 +44,4 @@ outputs: auditd::rules: {get_param: AuditdRules} step_config: | include ::tripleo::profile::base::auditd - upgrade_tasks: - - name: Check if auditd is deployed - command: systemctl is-enabled auditd - tags: common - ignore_errors: True - register: auditd_enabled - - name: "PreUpgrade step0,validation: Check if auditd is running" - shell: > - /usr/bin/systemctl show 'auditd' --property ActiveState | - grep '\bactive\b' - when: - - step|int == 0 - - auditd_enabled.rc == 0 - tags: validation - - name: Stop auditd service - when: - - step|int == 2 - - auditd_enabled.rc == 0 - service: name=auditd state=stopped + upgrade_tasks: [] diff --git a/puppet/services/barbican-api.yaml b/puppet/services/barbican-api.yaml index 97006a9a1f..5549e6b522 100644 --- a/puppet/services/barbican-api.yaml +++ b/puppet/services/barbican-api.yaml @@ -203,23 +203,4 @@ outputs: get_param: [EndpointMap, KeystoneInternal, uri_no_suffix] metadata_settings: get_attr: [ApacheServiceBase, role_data, metadata_settings] - upgrade_tasks: - list_concat: - - get_attr: [ApacheServiceBase, role_data, upgrade_tasks] - - - - name: Check if barbican_api is deployed - command: systemctl is-enabled openstack-barbican-api - tags: common - ignore_errors: True - register: barbican_api_enabled - - name: "PreUpgrade step0,validation: Check service openstack-barbican-api is running" - shell: /usr/bin/systemctl show 'openstack-barbican-api' --property ActiveState | grep '\bactive\b' - when: - - step|int == 0 - - barbican_api_enabled.rc == 0 - tags: validation - - name: Install openstack-barbican-api package if it was disabled - package: name=openstack-barbican-api state=latest - when: - - step|int == 3 - - barbican_api_enabled.rc != 0 + upgrade_tasks: [] diff --git a/puppet/services/ceilometer-agent-central.yaml b/puppet/services/ceilometer-agent-central.yaml index 8c0c4cf22e..d6869dfdea 100644 --- a/puppet/services/ceilometer-agent-central.yaml +++ b/puppet/services/ceilometer-agent-central.yaml @@ -76,20 +76,4 @@ outputs: step_config: | include ::tripleo::profile::base::ceilometer::agent::polling - upgrade_tasks: - - name: Check if ceilometer_agent_central is deployed - command: systemctl is-enabled openstack-ceilometer-central - tags: common - ignore_errors: True - register: ceilometer_agent_central_enabled - - name: "PreUpgrade step0,validation: Check service openstack-ceilometer-central is running" - shell: /usr/bin/systemctl show 'openstack-ceilometer-central' --property ActiveState | grep '\bactive\b' - when: - - step|int == 0 - - ceilometer_agent_central_enabled.rc == 0 - tags: validation - - name: Stop ceilometer_agent_central service - when: - - step|int == 1 - - ceilometer_agent_central_enabled.rc == 0 - service: name=openstack-ceilometer-central state=stopped + upgrade_tasks: [] diff --git a/puppet/services/ceilometer-agent-compute.yaml b/puppet/services/ceilometer-agent-compute.yaml index 617f6f28a6..059e8a7c40 100644 --- a/puppet/services/ceilometer-agent-compute.yaml +++ b/puppet/services/ceilometer-agent-compute.yaml @@ -71,20 +71,4 @@ outputs: get_attr: [CeilometerServiceBase, role_data, service_config_settings] step_config: | include ::tripleo::profile::base::ceilometer::agent::polling - upgrade_tasks: - - name: Check if ceilometer_agent_compute is deployed - command: systemctl is-enabled openstack-ceilometer-compute - tags: common - ignore_errors: True - register: ceilometer_agent_compute_enabled - - name: "PreUpgrade step0,validation: Check service openstack-ceilometer-compute is running" - shell: /usr/bin/systemctl show 'openstack-ceilometer-compute' --property ActiveState | grep '\bactive\b' - when: - - step|int == 0 - - ceilometer_agent_compute_enabled.rc == 0 - tags: validation - - name: Stop ceilometer_agent_compute service - when: - - step|int == 1 - - ceilometer_agent_compute_enabled.rc == 0 - service: name=openstack-ceilometer-compute state=stopped + upgrade_tasks: [] diff --git a/puppet/services/ceilometer-agent-ipmi.yaml b/puppet/services/ceilometer-agent-ipmi.yaml index 9edf9908ea..bdbaad25de 100644 --- a/puppet/services/ceilometer-agent-ipmi.yaml +++ b/puppet/services/ceilometer-agent-ipmi.yaml @@ -73,27 +73,4 @@ outputs: - {get_param: CeilometerAgentIpmiLoggingSource} step_config: | include ::tripleo::profile::base::ceilometer::agent::polling - upgrade_tasks: - - name: Check if ceilometer-agent-ipmi is deployed - command: systemctl is-enabled openstack-ceilometer-ipmi - tags: common - ignore_errors: True - register: ceilometer_ipmi_enabled - - name: "PreUpgrade step0,validation: Check if openstack-ceilometer-ipmi is running" - shell: > - /usr/bin/systemctl show 'openstack-ceilometer-ipmi' --property ActiveState | - grep '\bactive\b' - when: - - step|int == 0 - - ceilometer_ipmi_enabled.rc == 0 - tags: validation - - name: Stop openstack-ceilometer-ipmi service - when: - - step|int == 1 - - ceilometer_ipmi_enabled.rc == 0 - service: name=openstack-ceilometer-ipmi state=stopped - - name: Install openstack-ceilometer-ipmi package if it was disabled - package: name=openstack-ceilometer-ipmi state=latest - when: - - step|int == 3 - - ceilometer_ipmi_enabled.rc != 0 + upgrade_tasks: [] diff --git a/puppet/services/ceilometer-agent-notification.yaml b/puppet/services/ceilometer-agent-notification.yaml index ae75cd7893..4849987daf 100644 --- a/puppet/services/ceilometer-agent-notification.yaml +++ b/puppet/services/ceilometer-agent-notification.yaml @@ -68,20 +68,4 @@ outputs: - {get_param: CeilometerAgentNotificationLoggingSource} step_config: | include ::tripleo::profile::base::ceilometer::agent::notification - upgrade_tasks: - - name: Check if ceilometer_agent_notification is deployed - command: systemctl is-enabled openstack-ceilometer-notification - tags: common - ignore_errors: True - register: ceilometer_agent_notification_enabled - - name: "PreUpgrade step0,validation: Check service openstack-ceilometer-notification is running" - shell: /usr/bin/systemctl show 'openstack-ceilometer-notification' --property ActiveState | grep '\bactive\b' - when: - - step|int == 0 - - ceilometer_agent_notification_enabled.rc == 0 - tags: validation - - name: Stop ceilometer_agent_notification service - when: - - step|int == 1 - - ceilometer_agent_notification_enabled.rc == 0 - service: name=openstack-ceilometer-notification state=stopped + upgrade_tasks: [] diff --git a/puppet/services/cinder-api.yaml b/puppet/services/cinder-api.yaml index 06291e8093..06bbe43c73 100644 --- a/puppet/services/cinder-api.yaml +++ b/puppet/services/cinder-api.yaml @@ -194,33 +194,4 @@ outputs: - "%{hiera('mysql_bind_host')}" metadata_settings: get_attr: [ApacheServiceBase, role_data, metadata_settings] - upgrade_tasks: - list_concat: - - get_attr: [ApacheServiceBase, role_data, upgrade_tasks] - - - - name: Check if cinder_api is deployed - command: systemctl is-enabled openstack-cinder-api - tags: common - ignore_errors: True - register: cinder_api_enabled - - name: "PreUpgrade step0,validation: Check service openstack-cinder-api is running" - shell: /usr/bin/systemctl show 'openstack-cinder-api' --property ActiveState | grep '\bactive\b' - when: - - step|int == 0 - - cinder_api_enabled.rc == 0 - tags: validation - - name: check for cinder running under apache (post upgrade) - when: step|int == 1 - shell: "httpd -t -D DUMP_VHOSTS | grep -q cinder" - register: cinder_apache - ignore_errors: true - - name: Stop cinder_api service (running under httpd) - service: name=httpd state=stopped - when: - - step|int == 1 - - cinder_apache.rc == 0 - - name: Stop and disable cinder_api service (pre-upgrade not under httpd) - when: - - step|int == 1 - - cinder_api_enabled.rc == 0 - service: name=openstack-cinder-api state=stopped enabled=no + upgrade_tasks: [] diff --git a/puppet/services/cinder-scheduler.yaml b/puppet/services/cinder-scheduler.yaml index 127df28dc3..ac51a94986 100644 --- a/puppet/services/cinder-scheduler.yaml +++ b/puppet/services/cinder-scheduler.yaml @@ -69,20 +69,4 @@ outputs: - {get_param: CinderSchedulerLoggingSource} step_config: | include ::tripleo::profile::base::cinder::scheduler - upgrade_tasks: - - name: Check if cinder_scheduler is deployed - command: systemctl is-enabled openstack-cinder-scheduler - tags: common - ignore_errors: True - register: cinder_scheduler_enabled - - name: "PreUpgrade step0,validation: Check service openstack-cinder-scheduler is running" - shell: /usr/bin/systemctl show 'openstack-cinder-scheduler' --property ActiveState | grep '\bactive\b' - when: - - step|int == 0 - - cinder_scheduler_enabled.rc == 0 - tags: validation - - name: Stop cinder_scheduler service - when: - - step|int == 1 - - cinder_scheduler_enabled.rc == 0 - service: name=openstack-cinder-scheduler state=stopped + upgrade_tasks: [] diff --git a/puppet/services/cinder-volume.yaml b/puppet/services/cinder-volume.yaml index b2ae6d9f3a..ba35c7cc17 100644 --- a/puppet/services/cinder-volume.yaml +++ b/puppet/services/cinder-volume.yaml @@ -211,20 +211,4 @@ outputs: - {get_param: CinderVolumeLoggingSource} step_config: | include ::tripleo::profile::base::cinder::volume - upgrade_tasks: - - name: Check if cinder_volume is deployed - command: systemctl is-enabled openstack-cinder-volume - tags: common - ignore_errors: True - register: cinder_volume_enabled - - name: "PreUpgrade step0,validation: Check service openstack-cinder-volume is running" - shell: /usr/bin/systemctl show 'openstack-cinder-volume' --property ActiveState | grep '\bactive\b' - when: - - step|int == 0 - - cinder_volume_enabled.rc == 0 - tags: validation - - name: Stop cinder_volume service - when: - - step|int == 1 - - cinder_volume_enabled.rc == 0 - service: name=openstack-cinder-volume state=stopped + upgrade_tasks: [] diff --git a/puppet/services/congress.yaml b/puppet/services/congress.yaml index 8b111527d3..a86e6cf07f 100644 --- a/puppet/services/congress.yaml +++ b/puppet/services/congress.yaml @@ -149,25 +149,4 @@ outputs: step_config: | include ::tripleo::profile::base::congress - upgrade_tasks: - - name: Check if congress is deployed - command: systemctl is-enabled openstack-congress-server - tags: common - ignore_errors: True - register: congress_enabled - - name: "PreUpgrade step0,validation: Check service openstack-congress-server is running" - shell: /usr/bin/systemctl show 'openstack-congress-server' --property ActiveState | grep '\bactive\b' - when: - - step|int == 0 - - congress_enabled.rc == 0 - tags: validation - - name: Stop congress service - when: - - step|int == 1 - - congress_enabled.rc == 0 - service: name=openstack-congress-server state=stopped - - name: Install openstack-congress package if it was disabled - package: name=openstack-congress state=latest - when: - - step|int == 3 - - congress_enabled.rc != 0 + upgrade_tasks: [] diff --git a/puppet/services/database/redis.yaml b/puppet/services/database/redis.yaml index 76dc81be46..4f8abb01cd 100644 --- a/puppet/services/database/redis.yaml +++ b/puppet/services/database/redis.yaml @@ -102,30 +102,4 @@ outputs: network: {get_param: [ServiceNetMap, RabbitmqNetwork]} type: vip - null - upgrade_tasks: - - name: Check if redis is deployed - command: systemctl is-enabled redis - tags: common - ignore_errors: True - register: redis_enabled - - name: "PreUpgrade step0,validation: Check if redis is running" - shell: > - /usr/bin/systemctl show 'redis' --property ActiveState | - grep '\bactive\b' - when: - - step|int == 0 - - redis_enabled.rc == 0 - tags: validation - - name: Stop redis service - when: - - step|int == 1 - - redis_enabled.rc == 0 - service: name=redis state=stopped - - name: Install redis package if it was disabled - package: name=redis state=latest - when: - - step|int == 3 - - redis_enabled.rc != 0 - - name: Start redis service - when: step|int == 4 - service: name=redis state=started + upgrade_tasks: [] diff --git a/puppet/services/disabled/glance-registry-disabled.yaml b/puppet/services/disabled/glance-registry-disabled.yaml index 71750b20fb..cd2c70f91a 100644 --- a/puppet/services/disabled/glance-registry-disabled.yaml +++ b/puppet/services/disabled/glance-registry-disabled.yaml @@ -36,26 +36,7 @@ outputs: description: Role data for the disabled Glance Registry role. value: service_name: glance_registry_disabled - upgrade_tasks: - - when: step|int == 0 - block: - - name: Check if glance_registry is deployed - command: systemctl is-enabled --quiet openstack-glance-registry - ignore_errors: True - register: glance_registry_enabled_result - - name: Check service openstack-glance-registry is running - shell: systemctl is-active --quiet openstack-glance-registry - register: glance_registry_running_result - ignore_errors: True - - name: Set facts glance_registry_enabled and glance_registry_running - set_fact: - glance_registry_enabled: "{{ glance_registry_enabled_result.rc == 0 }}" - glance_registry_running: "{{ glance_registry_running_result.rc == 0 }}" - - name: Stop and disable glance_registry service on upgrade - service: name=openstack-glance-registry state=stopped enabled=no - when: - - step|int == 1 - - glance_registry_enabled|bool or glance_registry_running|bool + upgrade_tasks: [] fast_forward_upgrade_tasks: - when: - step|int == 0 diff --git a/puppet/services/disabled/heat-api-cloudwatch-disabled.yaml b/puppet/services/disabled/heat-api-cloudwatch-disabled.yaml index f630ffcca3..3da21f5f72 100644 --- a/puppet/services/disabled/heat-api-cloudwatch-disabled.yaml +++ b/puppet/services/disabled/heat-api-cloudwatch-disabled.yaml @@ -36,17 +36,7 @@ outputs: description: Role data for the disabled Heat CloudWatch API value: service_name: heat_api_cloudwatch_disabled - upgrade_tasks: - - name: Check if heat_api_cloudwatch is deployed - command: systemctl is-enabled openstack-heat-api-cloudwatch - when: step|int == 1 - ignore_errors: True - register: heat_api_cloudwatch_enabled - - name: Stop and disable heat_api_cloudwatch service (pre-upgrade not under httpd) - when: - - step|int == 1 - - heat_api_cloudwatch_enabled.rc == 0 - service: name=openstack-heat-api-cloudwatch state=stopped enabled=no + upgrade_tasks: [] fast_forward_upgrade_tasks: - when: - step|int == 0 diff --git a/puppet/services/ec2-api.yaml b/puppet/services/ec2-api.yaml index d1c713ff27..4eb775419f 100644 --- a/puppet/services/ec2-api.yaml +++ b/puppet/services/ec2-api.yaml @@ -205,29 +205,6 @@ outputs: ec2api::db::mysql::allowed_hosts: - '%' - "%{hiera('mysql_bind_host')}" - upgrade_tasks: - - name: Check if ec2-api is deployed - command: systemctl is-enabled openstack-ec2-api - tags: common - ignore_errors: True - register: ec2_api_enabled - - name: "PreUpgrade step0,validation: Check if openstack-ec2-api is running" - shell: > - /usr/bin/systemctl show 'openstack-ec2-api' --property ActiveState | - grep '\bactive\b' - when: - - step|int == 0 - - ec2_api_enabled.rc == 0 - tags: validation - - name: Stop openstack-ec2-api service - when: - - step|int == 1 - - ec2_api_enabled.rc == 0 - service: name=openstack-ec2-api state=stopped - - name: Install openstack-ec2-api package if it was disabled - package: name=openstack-ec2-api state=latest - when: - - step|int == 3 - - ec2_api_enabled.rc != 0 + upgrade_tasks: [] metadata_settings: get_attr: [TLSProxyBase, role_data, metadata_settings] diff --git a/puppet/services/etcd.yaml b/puppet/services/etcd.yaml index 005b34297c..4542a3789b 100644 --- a/puppet/services/etcd.yaml +++ b/puppet/services/etcd.yaml @@ -100,24 +100,7 @@ outputs: - {} step_config: | include ::tripleo::profile::base::etcd - upgrade_tasks: - - name: Check if etcd is deployed - command: systemctl is-enabled etcd - when: step|int == 0 - tags: validation - ignore_errors: True - register: etcd_enabled - - name: "PreUpgrade step0,validation: Check if etcd is running" - shell: > - /usr/bin/systemctl show 'etcd' --property ActiveState | - grep '\bactive\b' - when: - - step|int == 0 - - etcd_enabled.rc == 0 - tags: validation - - name: Stop etcd service - when: step|int == 2 - service: name=etcd state=stopped + upgrade_tasks: [] metadata_settings: if: - internal_tls_enabled diff --git a/puppet/services/glance-api.yaml b/puppet/services/glance-api.yaml index f7883862e0..a05112eccf 100644 --- a/puppet/services/glance-api.yaml +++ b/puppet/services/glance-api.yaml @@ -384,34 +384,6 @@ outputs: # Gleaning mount point by stripping "file://" prefix from staging uri mount: name="{{glance_node_staging_uri[7:]}}" src="{{glance_staging_nfs_share}}" fstype=nfs opts="{{glance_nfs_options}}" state=mounted when: glance_staging_nfs_share != '' - - upgrade_tasks: - - name: Check if glance_api is deployed - command: systemctl is-enabled openstack-glance-api - tags: common - ignore_errors: True - register: glance_api_enabled - #(TODO) Remove all glance-registry bits in Pike. - - name: Check if glance_registry is deployed - command: systemctl is-enabled openstack-glance-registry - tags: common - ignore_errors: True - register: glance_registry_enabled - - name: "PreUpgrade step0,validation: Check service openstack-glance-api is running" - shell: /usr/bin/systemctl show 'openstack-glance-api' --property ActiveState | grep '\bactive\b' - tags: validation - when: - - step|int == 0 - - glance_api_enabled.rc == 0 - - name: Stop glance_api service - when: - - step|int == 1 - - glance_api_enabled.rc == 0 - service: name=openstack-glance-api state=stopped - - name: Stop and disable glance registry (removed for Ocata) - when: - - step|int == 1 - - glance_registry_enabled.rc == 0 - service: name=openstack-glance-registry state=stopped enabled=no + upgrade_tasks: [] metadata_settings: get_attr: [TLSProxyBase, role_data, metadata_settings] diff --git a/puppet/services/gnocchi-metricd.yaml b/puppet/services/gnocchi-metricd.yaml index 4b76459ac5..a073631c30 100644 --- a/puppet/services/gnocchi-metricd.yaml +++ b/puppet/services/gnocchi-metricd.yaml @@ -66,20 +66,4 @@ outputs: gnocchi::metricd::metric_processing_delay: {get_param: MetricProcessingDelay} step_config: | include ::tripleo::profile::base::gnocchi::metricd - upgrade_tasks: - - name: Check if gnocchi_metricd is deployed - command: systemctl is-enabled openstack-gnocchi-metricd - tags: common - ignore_errors: True - register: gnocchi_metricd_enabled - - name: "PreUpgrade step0,validation: Check service openstack-gnocchi-metricd is running" - shell: /usr/bin/systemctl show 'openstack-gnocchi-metricd' --property ActiveState | grep '\bactive\b' - when: - - step|int == 0 - - gnocchi_metricd_enabled.rc == 0 - tags: validation - - name: Stop gnocchi_metricd service - when: - - step|int == 1 - - gnocchi_metricd_enabled.rc == 0 - service: name=openstack-gnocchi-metricd state=stopped + upgrade_tasks: [] diff --git a/puppet/services/gnocchi-statsd.yaml b/puppet/services/gnocchi-statsd.yaml index 13aac91fd4..2fa2635460 100644 --- a/puppet/services/gnocchi-statsd.yaml +++ b/puppet/services/gnocchi-statsd.yaml @@ -60,20 +60,4 @@ outputs: proto: 'udp' step_config: | include ::tripleo::profile::base::gnocchi::statsd - upgrade_tasks: - - name: Check if gnocchi_statsd is deployed - command: systemctl is-enabled openstack-gnocchi-statsd - tags: common - ignore_errors: True - register: gnocchi_statsd_enabled - - name: "PreUpgrade step0,validation: Check service openstack-gnocchi-statsd is running" - shell: /usr/bin/systemctl show 'openstack-gnocchi-statsd' --property ActiveState | grep '\bactive\b' - when: - - step|int == 0 - - gnocchi_statsd_enabled.rc == 0 - tags: validation - - name: Stop gnocchi_statsd service - when: - - step|int == 1 - - gnocchi_statsd_enabled.rc == 0 - service: name=openstack-gnocchi-statsd state=stopped + upgrade_tasks: [] diff --git a/puppet/services/haproxy.yaml b/puppet/services/haproxy.yaml index 92699b61eb..b763c13758 100644 --- a/puppet/services/haproxy.yaml +++ b/puppet/services/haproxy.yaml @@ -162,28 +162,7 @@ outputs: - get_attr: [HAProxyInternalTLS, role_data, config_settings] step_config: | include ::tripleo::profile::base::haproxy - upgrade_tasks: - - name: Check if haproxy is deployed - command: systemctl is-enabled haproxy - tags: common - ignore_errors: True - register: haproxy_enabled - - name: "PreUpgrade step0,validation: Check service haproxy is running" - shell: /usr/bin/systemctl show 'haproxy' --property ActiveState | grep '\bactive\b' - when: - - step|int == 0 - - haproxy_enabled.rc == 0 - tags: validation - - name: Stop haproxy service - when: - - step|int == 2 - - haproxy_enabled.rc == 0 - service: name=haproxy state=stopped - - name: Start haproxy service - when: - - step|int == 4 - - haproxy_enabled.rc == 0 - service: name=haproxy state=started + upgrade_tasks: [] host_prep_tasks: {get_attr: [HAProxyPublicTLS, role_data, host_prep_tasks]} metadata_settings: list_concat: diff --git a/puppet/services/heat-api-cfn.yaml b/puppet/services/heat-api-cfn.yaml index 5e6b111ac0..750446cfbb 100644 --- a/puppet/services/heat-api-cfn.yaml +++ b/puppet/services/heat-api-cfn.yaml @@ -144,30 +144,4 @@ outputs: heat::keystone::auth_cfn::region: {get_param: KeystoneRegion} metadata_settings: get_attr: [ApacheServiceBase, role_data, metadata_settings] - upgrade_tasks: - - name: Check if heat_api_cfn is deployed - command: systemctl is-enabled openstack-heat-api-cfn - tags: common - ignore_errors: True - register: heat_api_cfn_enabled - - name: "PreUpgrade step0,validation: Check service openstack-heat-api-cfn is running" - shell: /usr/bin/systemctl show 'openstack-heat-api-cfn' --property ActiveState | grep '\bactive\b' - when: - - step|int == 0 - - heat_api_cfn_enabled.rc == 0 - tags: validation - - name: check for heat_api_cfn running under apache (post upgrade) - when: step|int == 1 - shell: "httpd -t -D DUMP_VHOSTS | grep -q heat_api_cfn_wsgi" - register: heat_api_cfn_apache - ignore_errors: true - - name: Stop heat_api_cfn service (running under httpd) - service: name=httpd state=stopped - when: - - step|int == 1 - - heat_api_cfn_apache.rc == 0 - - name: Stop and disable heat_api_cfn service (pre-upgrade not under httpd) - when: - - step|int == 1 - - heat_api_cfn_enabled.rc == 0 - service: name=openstack-heat-api-cfn state=stopped enabled=no + upgrade_tasks: [] diff --git a/puppet/services/heat-api.yaml b/puppet/services/heat-api.yaml index 0dfbdcd574..b97e2e5077 100644 --- a/puppet/services/heat-api.yaml +++ b/puppet/services/heat-api.yaml @@ -151,30 +151,4 @@ outputs: heat::keystone::auth::region: {get_param: KeystoneRegion} metadata_settings: get_attr: [ApacheServiceBase, role_data, metadata_settings] - upgrade_tasks: - - name: Check is heat_api is deployed - command: systemctl is-enabled openstack-heat-api - tags: common - ignore_errors: True - register: heat_api_enabled - - name: "PreUpgrade step0,validation: Check service openstack-heat-api is running" - shell: /usr/bin/systemctl show 'openstack-heat-api' --property ActiveState | grep '\bactive\b' - when: - - step|int == 0 - - heat_api_enabled.rc == 0 - tags: validation - - name: check for heat_api running under apache (post upgrade) - when: step|int == 1 - shell: "httpd -t -D DUMP_VHOSTS | grep -q heat_api_wsgi" - register: heat_api_apache - ignore_errors: true - - name: Stop heat_api service (running under httpd) - service: name=httpd state=stopped - when: - - step|int == 1 - - heat_api_apache.rc == 0 - - name: Stop and disable heat_api service (pre-upgrade not under httpd) - when: - - step|int == 1 - - heat_api_enabled.rc == 0 - service: name=openstack-heat-api state=stopped enabled=no + upgrade_tasks: [] diff --git a/puppet/services/heat-engine.yaml b/puppet/services/heat-engine.yaml index 15e176d820..a083fe1210 100644 --- a/puppet/services/heat-engine.yaml +++ b/puppet/services/heat-engine.yaml @@ -174,20 +174,4 @@ outputs: keystone: # This is needed because the keystone profile handles creating the domain tripleo::profile::base::keystone::heat_admin_password: {get_param: HeatStackDomainAdminPassword} - upgrade_tasks: - - name: Check if heat_engine is deployed - command: systemctl is-enabled openstack-heat-engine - tags: common - ignore_errors: True - register: heat_engine_enabled - - name: "PreUpgrade step0,validation: Check service openstack-heat-engine is running" - shell: /usr/bin/systemctl show 'openstack-heat-engine' --property ActiveState | grep '\bactive\b' - when: - - step|int == 0 - - heat_engine_enabled.rc == 0 - tags: validation - - name: Stop heat_engine service - when: - - step|int == 1 - - heat_engine_enabled.rc == 0 - service: name=openstack-heat-engine state=stopped + upgrade_tasks: [] diff --git a/puppet/services/horizon.yaml b/puppet/services/horizon.yaml index b396d2c75e..bc56b45440 100644 --- a/puppet/services/horizon.yaml +++ b/puppet/services/horizon.yaml @@ -149,26 +149,7 @@ outputs: - horizon::django_debug: { get_param: Debug } step_config: | include ::tripleo::profile::base::horizon - # Ansible tasks to handle upgrade - upgrade_tasks: - - name: Check if httpd is deployed - command: systemctl is-enabled httpd - tags: common - ignore_errors: True - register: httpd_enabled - - name: "PreUpgrade step0,validation: Check if httpd is running" - shell: > - /usr/bin/systemctl show 'httpd' --property ActiveState | - grep '\bactive\b' - when: - - step|int == 0 - - httpd_enabled.rc == 0 - tags: validation - - name: Stop Horizon (under httpd) - when: - - step|int == 1 - - httpd_enabled.rc == 0 - service: name=httpd state=stopped + upgrade_tasks: [] service_config_settings: haproxy: tripleo::horizon::firewall_rules: diff --git a/puppet/services/ironic-neutron-agent.yaml b/puppet/services/ironic-neutron-agent.yaml index a9a188932a..a9755a4d9f 100644 --- a/puppet/services/ironic-neutron-agent.yaml +++ b/puppet/services/ironic-neutron-agent.yaml @@ -68,20 +68,4 @@ outputs: - neutron::agents::ml2::networking_baremetal::region_name: {get_param: KeystoneRegion} step_config: | include tripleo::profile::base::neutron::agents::networking_baremetal - upgrade_tasks: - - name: Check if ironic-neutron-agent is deployed - command: systemctl is-enabled ironic-neutron-agent - tags: common - ignore_errors: True - register: ironic_neutron_agent_enabled - - name: "PreUpgrade step0,validation: Check service ironic-neutron-agent is running" - shell: /usr/bin/systemctl show 'ironic-neutron-agent' --property ActiveState | grep '\bactive\b' - when: - - step|int == 0 - - ironic_neutron_agent_enabled.rc == 0 - tags: validation - - name: Stop ironic-neutron-agent service - when: - - step|int == 1 - - ironic_neutron_agent_enabled.rc == 0 - service: name=ironic-neutron-agent state=stopped + upgrade_tasks: [] diff --git a/puppet/services/logging/fluentd.yaml b/puppet/services/logging/fluentd.yaml index d386fe9cd6..617884134e 100644 --- a/puppet/services/logging/fluentd.yaml +++ b/puppet/services/logging/fluentd.yaml @@ -79,27 +79,4 @@ outputs: get_attr: [LoggingConfiguration, LoggingSharedKey] step_config: | include ::tripleo::profile::base::logging::fluentd - upgrade_tasks: - - name: Check if fluentd_client is deployed - command: systemctl is-enabled fluentd - tags: common - ignore_errors: True - register: fluentd_client_enabled - - name: Check status of fluentd service - shell: > - /usr/bin/systemctl show fluentd --property ActiveState | - grep '\bactive\b' - when: - - step|int == 0 - - fluentd_client_enabled.rc == 0 - tags: validation - - name: Stop fluentd service - when: - - step|int == 1 - - fluentd_client_enabled.rc == 0 - service: name=fluentd state=stopped - - name: Install fluentd package if it was disabled - package: name=fluentd state=latest - when: - - step|int == 3 - - fluentd_client_enabled.rc != 0 + upgrade_tasks: [] diff --git a/puppet/services/metrics/collectd.yaml b/puppet/services/metrics/collectd.yaml index 8dd6fc54eb..bfd3ce71e4 100644 --- a/puppet/services/metrics/collectd.yaml +++ b/puppet/services/metrics/collectd.yaml @@ -428,27 +428,4 @@ outputs: - {} step_config: | include ::tripleo::profile::base::metrics::collectd - upgrade_tasks: - - name: Check if collectd is deployed - command: systemctl is-enabled collectd - tags: common - ignore_errors: True - register: collectd_enabled - - name: Check status of collectd service - shell: > - /usr/bin/systemctl show collectd --property ActiveState | - grep '\bactive\b' - when: - - step|int == 0 - - collectd_enabled.rc == 0 - tags: validation - - name: Stop collectd service - when: - - step|int == 1 - - collectd_enabled.rc == 0 - service: name=collectd state=stopped - - name: Install collectd package if it was disabled - package: name=collectd state=latest - when: - - step|int == 3 - - collectd_enabled.rc != 0 + upgrade_tasks: [] diff --git a/puppet/services/mistral-api.yaml b/puppet/services/mistral-api.yaml index 818edcefad..99ca30eff0 100644 --- a/puppet/services/mistral-api.yaml +++ b/puppet/services/mistral-api.yaml @@ -132,32 +132,4 @@ outputs: get_attr: [MistralBase, role_data, service_config_settings] step_config: | include ::tripleo::profile::base::mistral::api - upgrade_tasks: - - name: Check if mistral api is deployed - command: systemctl is-enabled openstack-mistral-api - tags: common - ignore_errors: True - register: mistral_api_enabled - - name: "PreUpgrade step0,validation: Check if openstack-mistral-api is running" - shell: > - /usr/bin/systemctl show 'openstack-mistral-api' --property ActiveState | - grep '\bactive\b' - when: - - step|int == 0 - - mistral_api_enabled.rc == 0 - tags: validation - - name: check for mistral_api running under apache (post upgrade) - when: step|int == 1 - shell: "httpd -t -D DUMP_VHOSTS | grep -q mistral_api_wsgi" - register: mistral_api_apache - ignore_errors: true - - name: Stop mistral_api service (running under httpd) - service: name=httpd state=stopped - when: - - step|int == 1 - - mistral_api_apache.rc == 0 - - name: Stop and disable mistral_api service (pre-upgrade not under httpd) - when: - - step|int == 1 - - mistral_api_enabled.rc == 0 - service: name=openstack-mistral-api state=stopped enabled=no + upgrade_tasks: [] diff --git a/puppet/services/mistral-engine.yaml b/puppet/services/mistral-engine.yaml index 34140a8289..4ed4dcd8e0 100644 --- a/puppet/services/mistral-engine.yaml +++ b/puppet/services/mistral-engine.yaml @@ -76,25 +76,4 @@ outputs: mistral::engine::older_than: {get_param: MistralFinishedExecutionDuration} step_config: | include ::tripleo::profile::base::mistral::engine - upgrade_tasks: - - name: Check if mistral engine is deployed - command: systemctl is-enabled openstack-mistral-engine - tags: common - ignore_errors: True - register: mistral_engine_enabled - - name: "PreUpgrade step0,validation: Check if openstack-mistral-engine is running" - shell: > - /usr/bin/systemctl show 'openstack-mistral-engine' --property ActiveState | - grep '\bactive\b' - when: - - step|int == 0 - - mistral_engine_enabled.rc == 0 - tags: validation - - name: Stop mistral_engine service - when: step|int == 1 - service: name=openstack-mistral-engine state=stopped - - name: Install openstack-mistral-engine package if it was disabled - package: name=openstack-mistral-engine state=latest - when: - - step|int == 3 - - mistral_engine_enabled.rc != 0 + upgrade_tasks: [] diff --git a/puppet/services/mistral-event-engine.yaml b/puppet/services/mistral-event-engine.yaml index ef7ab7d5c8..0272a5c1b4 100644 --- a/puppet/services/mistral-event-engine.yaml +++ b/puppet/services/mistral-event-engine.yaml @@ -51,25 +51,4 @@ outputs: get_attr: [MistralBase, role_data, config_settings] step_config: | include ::tripleo::profile::base::mistral::event_engine - upgrade_tasks: - - name: Check if mistral event engine is deployed - command: systemctl is-enabled openstack-mistral-event-engine - tags: common - ignore_errors: True - register: mistral_event_engine_enabled - - name: "PreUpgrade step0,validation: Check if openstack-mistral-event-engine is running" - shell: > - /usr/bin/systemctl show 'openstack-mistral-event-engine' --property ActiveState | - grep '\bactive\b' - when: - - step|int == 0 - - mistral_event_engine_enabled.rc == 0 - tags: validation - - name: Stop mistral_event_engine service - when: step|int == 1 - service: name=openstack-mistral-event-engine state=stopped - - name: Install openstack-mistral-event-engine package if it was disabled - package: name=openstack-mistral-event-engine state=latest - when: - - step|int == 3 - - mistral_event_engine_enabled.rc != 0 + upgrade_tasks: [] diff --git a/puppet/services/mistral-executor.yaml b/puppet/services/mistral-executor.yaml index a949a8cba2..12e6f7ae81 100644 --- a/puppet/services/mistral-executor.yaml +++ b/puppet/services/mistral-executor.yaml @@ -57,25 +57,4 @@ outputs: - tripleo::profile::base::mistral::executor::docker_group: {get_param: MistralDockerGroup} step_config: | include ::tripleo::profile::base::mistral::executor - upgrade_tasks: - - name: Check if mistral executor is deployed - command: systemctl is-enabled openstack-mistral-executor - tags: common - ignore_errors: True - register: mistral_executor_enabled - - name: "PreUpgrade step0,validation: Check if openstack-mistral-executor is running" - shell: > - /usr/bin/systemctl show 'openstack-mistral-executor' --property ActiveState | - grep '\bactive\b' - when: - - step|int == 0 - - mistral_executor_enabled.rc == 0 - tags: validation - - name: Stop mistral_executor service - when: step|int == 1 - service: name=openstack-mistral-executor state=stopped - - name: Install openstack-mistral-executor package if it was disabled - package: name=openstack-mistral-executor state=latest - when: - - step|int == 3 - - mistral_executor_enabled.rc != 0 + upgrade_tasks: [] diff --git a/puppet/services/monitoring/sensu-client.yaml b/puppet/services/monitoring/sensu-client.yaml index 85ec8d9935..369ec9df62 100644 --- a/puppet/services/monitoring/sensu-client.yaml +++ b/puppet/services/monitoring/sensu-client.yaml @@ -80,27 +80,4 @@ outputs: region: {get_param: KeystoneRegion} step_config: | include ::tripleo::profile::base::monitoring::sensu - upgrade_tasks: - - name: Check if sensu_client is deployed - command: systemctl is-enabled sensu-client - tags: common - ignore_errors: True - register: sensu_client_enabled - - name: Check status of sensu-client service - shell: > - /usr/bin/systemctl show sensu-client --property ActiveState | - grep '\bactive\b' - when: - - step|int == 0 - - sensu_client_enabled.rc == 0 - tags: validation - - name: Stop sensu-client service - when: - - step|int == 1 - - sensu_client_enabled.rc == 0 - service: name=sensu-client state=stopped - - name: Install sensu package if it was disabled - package: name=sensu state=latest - when: - - step|int == 3 - - sensu_client_enabled.rc != 0 + upgrade_tasks: [] diff --git a/puppet/services/neutron-api.yaml b/puppet/services/neutron-api.yaml index dc161a0ff9..f8fe838941 100644 --- a/puppet/services/neutron-api.yaml +++ b/puppet/services/neutron-api.yaml @@ -264,22 +264,6 @@ outputs: neutron::db::mysql::allowed_hosts: - '%' - "%{hiera('mysql_bind_host')}" - upgrade_tasks: - - name: Check if neutron_server is deployed - command: systemctl is-enabled neutron-server - tags: common - ignore_errors: True - register: neutron_server_enabled - - name: "PreUpgrade step0,validation: Check service neutron-server is running" - shell: /usr/bin/systemctl show 'neutron-server' --property ActiveState | grep '\bactive\b' - when: - - step|int == 0 - - neutron_server_enabled.rc == 0 - tags: validation - - name: Stop neutron_api service - when: - - step|int == 1 - - neutron_server_enabled.rc == 0 - service: name=neutron-server state=stopped + upgrade_tasks: [] metadata_settings: get_attr: [TLSProxyBase, role_data, metadata_settings] diff --git a/puppet/services/neutron-dhcp.yaml b/puppet/services/neutron-dhcp.yaml index 35fc5c1db3..6865d8f727 100644 --- a/puppet/services/neutron-dhcp.yaml +++ b/puppet/services/neutron-dhcp.yaml @@ -152,22 +152,6 @@ outputs: - {get_param: NeutronDhcpAgentLoggingSource} step_config: | include tripleo::profile::base::neutron::dhcp - upgrade_tasks: - - name: Check if neutron_dhcp_agent is deployed - command: systemctl is-enabled neutron-dhcp-agent - tags: common - ignore_errors: True - register: neutron_dhcp_agent_enabled - - name: "PreUpgrade step0,validation: Check service neutron-dhcp-agent is running" - shell: /usr/bin/systemctl show 'neutron-dhcp-agent' --property ActiveState | grep '\bactive\b' - when: - - step|int == 0 - - neutron_dhcp_agent_enabled.rc == 0 - tags: validation - - name: Stop neutron_dhcp service - when: - - step|int == 1 - - neutron_dhcp_agent_enabled.rc == 0 - service: name=neutron-dhcp-agent state=stopped + upgrade_tasks: [] metadata_settings: get_attr: [NeutronBase, role_data, metadata_settings] diff --git a/puppet/services/neutron-l2gw-agent.yaml b/puppet/services/neutron-l2gw-agent.yaml index bae886f434..294314ce65 100644 --- a/puppet/services/neutron-l2gw-agent.yaml +++ b/puppet/services/neutron-l2gw-agent.yaml @@ -113,20 +113,4 @@ outputs: - {get_param: NeutronL2gwAgentLoggingSource} step_config: | include tripleo::profile::base::neutron::agents::l2gw - upgrade_tasks: - - name: Check if neutron_l2gw_agent is deployed - command: systemctl is-enabled neutron-l2gw-agent - tags: common - ignore_errors: True - register: neutron_l2gw_agent_enabled - - name: "PreUpgrade step0,validation: Check service neutron-l2gw-agent is running" - shell: /usr/bin/systemctl show 'neutron-l2gw-agent' --property ActiveState | grep '\bactive\b' - when: - - step|int == 0 - - neutron_l2gw_agent_enabled.rc == 0 - tags: validation - - name: Stop neutron_l2gw_agent service - when: - - step|int == 1 - - neutron_l2gw_agent_enabled.rc == 0 - service: name=neutron-l2gw-agent state=stopped + upgrade_tasks: [] diff --git a/puppet/services/neutron-l3.yaml b/puppet/services/neutron-l3.yaml index 2c05641ffb..5aac250bc4 100644 --- a/puppet/services/neutron-l3.yaml +++ b/puppet/services/neutron-l3.yaml @@ -132,22 +132,6 @@ outputs: - {get_param: NeutronL3AgentLoggingSource} step_config: | include tripleo::profile::base::neutron::l3 - upgrade_tasks: - - name: Check if neutron_l3_agent is deployed - command: systemctl is-enabled neutron-l3-agent - tags: common - ignore_errors: True - register: neutron_l3_agent_enabled - - name: "PreUpgrade step0,validation: Check service neutron-l3-agent is running" - shell: /usr/bin/systemctl show 'neutron-l3-agent' --property ActiveState | grep '\bactive\b' - when: - - step|int == 0 - - neutron_l3_agent_enabled.rc == 0 - tags: validation - - name: Stop neutron_l3 service - when: - - step|int == 1 - - neutron_l3_agent_enabled.rc == 0 - service: name=neutron-l3-agent state=stopped + upgrade_tasks: [] metadata_settings: get_attr: [NeutronBase, role_data, metadata_settings] diff --git a/puppet/services/neutron-metadata.yaml b/puppet/services/neutron-metadata.yaml index 145340454f..d95f30e7ae 100644 --- a/puppet/services/neutron-metadata.yaml +++ b/puppet/services/neutron-metadata.yaml @@ -135,22 +135,6 @@ outputs: - {get_param: NeutronMetadataAgentLoggingSource} step_config: | include tripleo::profile::base::neutron::metadata - upgrade_tasks: - - name: Check if neutron_metadata_agent is deployed - command: systemctl is-enabled neutron-metadata-agent - tags: common - ignore_errors: True - register: neutron_metadata_agent_enabled - - name: "PreUpgrade step0,validation: Check service neutron-metadata-agent is running" - shell: /usr/bin/systemctl show 'neutron-metadata-agent' --property ActiveState | grep '\bactive\b' - when: - - step|int == 0 - - neutron_metadata_agent_enabled.rc == 0 - tags: validation - - name: Stop neutron_metadata service - when: - - step|int == 1 - - neutron_metadata_agent_enabled.rc == 0 - service: name=neutron-metadata-agent state=stopped + upgrade_tasks: [] metadata_settings: get_attr: [NeutronBase, role_data, metadata_settings] diff --git a/puppet/services/neutron-ovs-agent.yaml b/puppet/services/neutron-ovs-agent.yaml index 44141e81bf..33a9cee366 100644 --- a/puppet/services/neutron-ovs-agent.yaml +++ b/puppet/services/neutron-ovs-agent.yaml @@ -172,22 +172,6 @@ outputs: - {get_param: NeutronOpenVswitchAgentLoggingSource} step_config: | include ::tripleo::profile::base::neutron::ovs - upgrade_tasks: - - name: Check if neutron_ovs_agent is deployed - command: systemctl is-enabled neutron-openvswitch-agent - tags: common - ignore_errors: True - register: neutron_ovs_agent_enabled - - name: "PreUpgrade step0,validation: Check service neutron-openvswitch-agent is running" - shell: /usr/bin/systemctl show 'neutron-openvswitch-agent' --property ActiveState | grep '\bactive\b' - when: - - step|int == 0 - - neutron_ovs_agent_enabled.rc == 0 - tags: validation - - name: Stop neutron_ovs_agent service - when: - - step|int == 1 - - neutron_ovs_agent_enabled.rc == 0 - service: name=neutron-openvswitch-agent state=stopped + upgrade_tasks: [] metadata_settings: get_attr: [NeutronBase, role_data, metadata_settings] diff --git a/puppet/services/neutron-sriov-agent.yaml b/puppet/services/neutron-sriov-agent.yaml index 5286af2bf1..63b4796841 100644 --- a/puppet/services/neutron-sriov-agent.yaml +++ b/puppet/services/neutron-sriov-agent.yaml @@ -114,22 +114,6 @@ outputs: - get_attr: [RoleParametersValue, value] step_config: | include ::tripleo::profile::base::neutron::sriov - upgrade_tasks: - - name: Check if neutron_sriov_agent is deployed - command: systemctl is-enabled neutron-sriov-nic-agent - tags: common - ignore_errors: True - register: neutron_sriov_nic_agent_enabled - - name: "PreUpgrade step0,validation: Check service neutron-server is running" - shell: /usr/bin/systemctl show 'neutron-sriov-nic-agent' --property ActiveState | grep '\bactive\b' - when: - - step|int == 0 - - neutron_sriov_nic_agent_enabled.rc == 0 - tags: validation - - name: Stop neutron_sriov_nic_agent service - when: - - step|int == 1 - - neutron_sriov_nic_agent_enabled.rc == 0 - service: name=neutron-sriov-nic-agent state=stopped + upgrade_tasks: [] metadata_settings: get_attr: [NeutronBase, role_data, metadata_settings] diff --git a/puppet/services/opendaylight-api.yaml b/puppet/services/opendaylight-api.yaml index 0075e5620d..8e40b14426 100644 --- a/puppet/services/opendaylight-api.yaml +++ b/puppet/services/opendaylight-api.yaml @@ -160,32 +160,7 @@ outputs: - neutron::agents::dhcp::ovsdb_connection: 'tcp:127.0.0.1:6639' step_config: | include tripleo::profile::base::neutron::opendaylight - upgrade_tasks: - - name: Check if opendaylight is deployed - command: systemctl is-enabled opendaylight - tags: common - ignore_errors: True - register: opendaylight_enabled - - name: "PreUpgrade step0,validation: Check service opendaylight is running" - shell: /usr/bin/systemctl show 'opendaylight' --property ActiveState | grep '\bactive\b' - when: - - step|int == 0 - - opendaylight_enabled.rc == 0 - tags: validation - - name: Stop opendaylight service - when: - - step|int == 1 - - opendaylight_enabled.rc == 0 - service: name=opendaylight state=stopped - - name: Removes ODL snapshots, data, journal directories - file: - state: absent - path: /opt/opendaylight/{{item}} - when: step|int == 2 - with_items: - - snapshots - - data - - journal + upgrade_tasks: [] metadata_settings: if: - internal_tls_enabled diff --git a/puppet/services/ovn-controller.yaml b/puppet/services/ovn-controller.yaml index 9e956c13ef..cc521d595e 100644 --- a/puppet/services/ovn-controller.yaml +++ b/puppet/services/ovn-controller.yaml @@ -123,20 +123,4 @@ outputs: dport: 6081 step_config: | include ::tripleo::profile::base::neutron::agents::ovn - upgrade_tasks: - - name: Check if ovn_controller is deployed - command: systemctl is-enabled ovn-controller - tags: common - ignore_errors: True - register: ovn_controller_enabled - - name: "PreUpgrade step0,validation: Check service ovn-controller is running" - shell: /usr/bin/systemctl show 'ovn-controller' --property ActiveState | grep '\bactive\b' - when: - - step|int == 0 - - ovn_controller_enabled.rc == 0 - tags: validation - - name: Stop ovn-controller service - when: - - step|int == 1 - - ovn_controller_enabled.rc == 0 - service: name=ovn-controller state=stopped + upgrade_tasks: [] diff --git a/puppet/services/ovn-dbs.yaml b/puppet/services/ovn-dbs.yaml index e64485d4d7..0c48943006 100644 --- a/puppet/services/ovn-dbs.yaml +++ b/puppet/services/ovn-dbs.yaml @@ -62,20 +62,4 @@ outputs: - {get_param: OVNSouthboundServerPort} step_config: | include ::tripleo::profile::base::neutron::ovn_northd - upgrade_tasks: - - name: Check if ovn_northd is deployed - command: systemctl is-enabled ovn-northd - tags: common - ignore_errors: True - register: ovn_northd_enabled - - name: "PreUpgrade step0,validation: Check service ovn-northd is running" - shell: /usr/bin/systemctl show 'ovn-northd' --property ActiveState | grep '\bactive\b' - when: - - step|int == 0 - - ovn_northd_enabled.rc == 0 - tags: validation - - name: Stop ovn-northd service - when: - - step|int == 1 - - ovn_northd_enabled.rc == 0 - service: name=ovn-northd state=stopped + upgrade_tasks: [] diff --git a/puppet/services/ovn-metadata.yaml b/puppet/services/ovn-metadata.yaml index 2e1adc61c3..268c199120 100644 --- a/puppet/services/ovn-metadata.yaml +++ b/puppet/services/ovn-metadata.yaml @@ -135,22 +135,4 @@ outputs: - neutron::agents::ovn_metadata::metadata_workers: {get_param: NeutronWorkers} step_config: | include tripleo::profile::base::neutron::ovn_metadata - upgrade_tasks: - - name: Check if networking_ovn_metadata_agent is deployed - command: systemctl is-enabled networking-ovn-metadata-agent - tags: common - ignore_errors: True - register: networking_ovn_metadata_agent_enabled - - name: "PreUpgrade step0,validation: Check service networking-ovn-metadata-agent is running" - shell: /usr/bin/systemctl show 'networking-ovn-metadata-agent' --property ActiveState | grep '\bactive\b' - when: - - step|int == 0 - - networking_ovn_metadata_agent_enabled.rc == 0 - tags: validation - - name: Stop networking_ovn_metadata service - when: - - step|int == 1 - - neutron_metadata_agent_enabled.rc == 0 - service: name=networking-ovn-metadata-agent state=stopped - metadata_settings: - get_attr: [NeutronBase, role_data, metadata_settings] + upgrade_tasks: [] diff --git a/puppet/services/panko-api.yaml b/puppet/services/panko-api.yaml index 63f7c3f497..04fb392f19 100644 --- a/puppet/services/panko-api.yaml +++ b/puppet/services/panko-api.yaml @@ -121,28 +121,4 @@ outputs: include tripleo::profile::base::panko::api metadata_settings: get_attr: [ApacheServiceBase, role_data, metadata_settings] - upgrade_tasks: - list_concat: - - get_attr: [ApacheServiceBase, role_data, upgrade_tasks] - - - - name: Check if httpd is deployed - command: systemctl is-enabled httpd - tags: common - ignore_errors: True - register: httpd_enabled - - name: "PreUpgrade step0,validation: Check if httpd is running" - shell: > - /usr/bin/systemctl show 'httpd' --property ActiveState | - grep '\bactive\b' - when: - - step|int == 0 - - httpd_enabled.rc == 0 - tags: validation - - name: Stop panko-api service (running under httpd) - service: name=httpd state=stopped - when: - - step|int == 1 - - httpd_enabled.rc == 0 - - name: Install openstack-panko-api package if it was not installed - when: step|int == 3 - package: name=openstack-panko-api state=latest + upgrade_tasks: [] diff --git a/puppet/services/tacker.yaml b/puppet/services/tacker.yaml index c89bcb70e4..9d585b81f6 100644 --- a/puppet/services/tacker.yaml +++ b/puppet/services/tacker.yaml @@ -148,25 +148,4 @@ outputs: step_config: | include ::tripleo::profile::base::tacker - upgrade_tasks: - - name: Check if tacker is deployed - command: systemctl is-enabled openstack-tacker-server - tags: common - ignore_errors: True - register: tacker_enabled - - name: "PreUpgrade step0,validation: Check service openstack-tacker-server is running" - shell: /usr/bin/systemctl show 'openstack-tacker-server' --property ActiveState | grep '\bactive\b' - when: - - step|int == 0 - - tacker_enabled.rc == 0 - tags: validation - - name: Stop tacker service - when: - - step|int == 1 - - tacker_enabled.rc == 0 - service: name=openstack-tacker-server state=stopped - - name: Install openstack-tacker package if it was disabled - package: name=openstack-tacker state=latest - when: - - step|int == 3 - - tacker_enabled.rc != 0 + upgrade_tasks: [] diff --git a/puppet/services/zaqar-api.yaml b/puppet/services/zaqar-api.yaml index eeed1681a1..190899290f 100644 --- a/puppet/services/zaqar-api.yaml +++ b/puppet/services/zaqar-api.yaml @@ -222,40 +222,4 @@ outputs: include ::tripleo::profile::base::zaqar metadata_settings: get_attr: [ApacheServiceBase, role_data, metadata_settings] - upgrade_tasks: - list_concat: - - get_attr: [ApacheServiceBase, role_data, upgrade_tasks] - - - - name: Check if zaqar is deployed - command: systemctl is-enabled openstack-zaqar - tags: common - ignore_errors: True - register: zaqar_enabled - - name: "PreUpgrade step0,validation: Check if openstack-zaqar is running" - shell: > - /usr/bin/systemctl show 'openstack-zaqar' --property ActiveState | - grep '\bactive\b' - when: - - step|int == 0 - - zaqar_enabled.rc == 0 - tags: validation - - name: Check for zaqar running under apache (post upgrade) - when: step|int == 1 - shell: "httpd -t -D DUMP_VHOSTS | grep -q zaqar_wsgi" - register: zaqar_apache - ignore_errors: true - - name: Stop zaqar service (running under httpd) - service: name=httpd state=stopped - when: - - step|int == 1 - - zaqar_apache.rc == 0 - - name: Stop and disable zaqar service (pre-upgrade not under httpd) - when: - - step|int == 1 - - zaqar_enabled.rc == 0 - service: name=openstack-zaqar state=stopped enabled=no - - name: Install openstack-zaqar package if it was disabled - package: name=openstack-zaqar state=latest - when: - - step|int == 3 - - zaqar_enabled.rc != 0 + upgrade_tasks: [] diff --git a/releasenotes/notes/upgrade_tasks_cleanup-c913f3f30f4a1db6.yaml b/releasenotes/notes/upgrade_tasks_cleanup-c913f3f30f4a1db6.yaml new file mode 100644 index 0000000000..87829a1a6d --- /dev/null +++ b/releasenotes/notes/upgrade_tasks_cleanup-c913f3f30f4a1db6.yaml @@ -0,0 +1,13 @@ +--- +upgrade: + - | + We don't run the upgrade_tasks Ansible tasks that stop systemd services and + since all services are now containerized. + However, we decided to keep the tasks that remove the rpms in case some + of deployments didn't cleanup them in previous releases, they can still + do it now. + These tasks were useful in Rocky when we converted the Undercloud from + baremetal to containers but in Stein this is not useful anymore. + It's actually breaking upgrades for Podman, as containers are now seen + by systemd, and these tasks conflicts with the way containers are managed + in Paunch.