diff options
author | Jenkins <jenkins@review.openstack.org> | 2017-07-26 13:47:21 +0000 |
---|---|---|
committer | Gerrit Code Review <review@openstack.org> | 2017-07-26 13:47:21 +0000 |
commit | 4a441359fba69b754cbae1fb13c82fb7472f29b6 (patch) | |
tree | f3a0f5718ae0f9e2b8562296e5729642970df1a6 | |
parent | c57543bba2626d92d8f868af68df04ef97cc1088 (diff) | |
parent | 223733cccf2ca388431fbf0cd08d9fd39572a3cd (diff) |
Merge "Stop Heat WSGI services on docker upgrade"
-rw-r--r-- | docker/services/heat-api-cfn.yaml | 21 | ||||
-rw-r--r-- | docker/services/heat-api.yaml | 21 | ||||
-rw-r--r-- | puppet/services/heat-api-cfn.yaml | 2 |
3 files changed, 39 insertions, 5 deletions
diff --git a/docker/services/heat-api-cfn.yaml b/docker/services/heat-api-cfn.yaml index aff0f1a1..70612899 100644 --- a/docker/services/heat-api-cfn.yaml +++ b/docker/services/heat-api-cfn.yaml @@ -125,8 +125,25 @@ outputs: path: /var/log/containers/heat state: directory upgrade_tasks: - - name: Stop and disable heat_api_cfn service + - 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: check for heat_api_cfn running under apache (post upgrade) tags: step2 - service: name=httpd state=stopped enabled=no + shell: "httpd -t -D DUMP_VHOSTS | grep -q heat_api_cfn_wsgi" + register: heat_api_cfn_apache + ignore_errors: true + changed_when: false + check_mode: no + - name: Stop heat_api_cfn service (running under httpd) + tags: step2 + service: name=httpd state=stopped + when: heat_api_cfn_apache.rc == 0 + - name: Stop and disable heat_api_cfn service (pre-upgrade not under httpd) + tags: step2 + service: name=openstack-heat-api-cfn state=stopped enabled=no + when: heat_api_cfn_enabled.rc == 0 metadata_settings: get_attr: [HeatBase, role_data, metadata_settings] diff --git a/docker/services/heat-api.yaml b/docker/services/heat-api.yaml index ba8fc75f..0bc331ca 100644 --- a/docker/services/heat-api.yaml +++ b/docker/services/heat-api.yaml @@ -150,8 +150,25 @@ outputs: path: /var/log/containers/heat state: directory upgrade_tasks: - - name: Stop and disable heat_api service + - name: Check is heat_api is deployed + command: systemctl is-enabled openstack-heat-api + tags: common + ignore_errors: True + register: heat_api_enabled + - name: check for heat_api running under apache (post upgrade) tags: step2 - service: name=httpd state=stopped enabled=no + shell: "httpd -t -D DUMP_VHOSTS | grep -q heat_api_wsgi" + register: heat_api_apache + ignore_errors: true + changed_when: false + check_mode: no + - name: Stop heat_api service (running under httpd) + tags: step2 + service: name=httpd state=stopped + when: heat_api_apache.rc == 0 + - name: Stop and disable heat_api service (pre-upgrade not under httpd) + tags: step2 + service: name=openstack-heat-api state=stopped enabled=no + when: heat_api_enabled.rc == 0 metadata_settings: get_attr: [HeatBase, role_data, metadata_settings] diff --git a/puppet/services/heat-api-cfn.yaml b/puppet/services/heat-api-cfn.yaml index 070bd7c7..28bb8658 100644 --- a/puppet/services/heat-api-cfn.yaml +++ b/puppet/services/heat-api-cfn.yaml @@ -153,5 +153,5 @@ outputs: when: heat_api_cfn_apache.rc == 0 - name: Stop and disable heat_api_cfn service (pre-upgrade not under httpd) tags: step1 - when: heat_api_cfn_apache.rc == 0 + when: heat_api_cfn_enabled.rc == 0 service: name=openstack-heat-api-cfn state=stopped enabled=no |