Browse Source

Remove all ignore_errors to avoid confusion when debugging

- deploy-steps-tasks-step-1.yaml: Do not ignore errors when dealing
  with check-mode directories. The file module is resilient enough to
  not fail if the path is already absent.

- deploy-steps-tasks.yaml: Replace ignore_errors by another condition,
  "not ansible_check_mode"; this task is not needed in check mode.

- generate-config-tasks.yaml: Replace ignore_errors by another
  condition, "not ansible_check_mode"; this task is not needed in check mode.

- Neutron wrappers: use fail_key: False instead of ignore_errors: True
  if a key can't be found in /etc/passwd.

- All services with service checks: Replace "ignore_errors: true" by
  "failed_when: false". Since we don't care about whether or not the
  task returns 0, let's just make the task never fail. It will only
  improve UX when scrawling logs; no more failure will be shown for
  these tasks.

- Same as above for cibadmin commands, cluster resources show
  commands and keepalived container restart command; and all other shell
  or command or yum modules uses where we just don't care about their potential
  failures.

- Aodh/Gnocchi: Add pipefail so the task isn't support to fail

- tripleo-packages-baremetal-puppet and undercloud-upgrade: check shell
  rc instead of "succeeded", since the task will always succeed.

Change-Id: I0c44db40e1b9a935e7dde115bb0c9affa15c42bf
(cherry picked from commit 38bad5283f)
changes/76/711576/1
Emilien Macchi 1 year ago
parent
commit
851bbb31e0
64 changed files with 107 additions and 106 deletions
  1. +1
    -1
      ci/environments/disable-unbound.yaml
  2. +0
    -2
      common/deploy-steps-tasks-step-1.yaml
  3. +1
    -1
      common/deploy-steps-tasks.yaml
  4. +3
    -2
      common/generate-config-tasks.yaml
  5. +4
    -3
      deployment/aodh/aodh-api-container-puppet.yaml
  6. +1
    -1
      deployment/aodh/aodh-evaluator-container-puppet.yaml
  7. +1
    -1
      deployment/aodh/aodh-listener-container-puppet.yaml
  8. +1
    -1
      deployment/aodh/aodh-notifier-container-puppet.yaml
  9. +1
    -1
      deployment/ceilometer/ceilometer-agent-central-container-puppet.yaml
  10. +1
    -1
      deployment/ceilometer/ceilometer-agent-compute-container-puppet.yaml
  11. +1
    -1
      deployment/ceilometer/ceilometer-agent-ipmi-container-puppet.yaml
  12. +1
    -1
      deployment/ceilometer/ceilometer-agent-notification-container-puppet.yaml
  13. +1
    -1
      deployment/cinder/cinder-api-container-puppet.yaml
  14. +1
    -1
      deployment/cinder/cinder-scheduler-container-puppet.yaml
  15. +1
    -1
      deployment/cinder/cinder-volume-container-puppet.yaml
  16. +1
    -1
      deployment/cinder/cinder-volume-pacemaker-puppet.yaml
  17. +1
    -1
      deployment/database/mysql-pacemaker-puppet.yaml
  18. +2
    -2
      deployment/database/redis-pacemaker-puppet.yaml
  19. +1
    -1
      deployment/glance/glance-api-container-puppet.yaml
  20. +5
    -4
      deployment/gnocchi/gnocchi-api-container-puppet.yaml
  21. +1
    -1
      deployment/gnocchi/gnocchi-metricd-container-puppet.yaml
  22. +1
    -1
      deployment/gnocchi/gnocchi-statsd-container-puppet.yaml
  23. +3
    -3
      deployment/haproxy/haproxy-pacemaker-puppet.yaml
  24. +1
    -1
      deployment/heat/heat-api-cfn-container-puppet.yaml
  25. +2
    -2
      deployment/heat/heat-api-cloudwatch-disabled-puppet.yaml
  26. +1
    -1
      deployment/heat/heat-api-container-puppet.yaml
  27. +1
    -1
      deployment/heat/heat-engine-container-puppet.yaml
  28. +1
    -1
      deployment/ironic/ironic-api-container-puppet.yaml
  29. +1
    -1
      deployment/ironic/ironic-conductor-container-puppet.yaml
  30. +1
    -1
      deployment/iscsid/iscsid-container-puppet.yaml
  31. +1
    -1
      deployment/keepalived/keepalived-container-puppet.yaml
  32. +2
    -2
      deployment/keystone/keystone-container-puppet.yaml
  33. +1
    -1
      deployment/manila/manila-api-container-puppet.yaml
  34. +1
    -1
      deployment/manila/manila-scheduler-container-puppet.yaml
  35. +1
    -1
      deployment/manila/manila-share-container-puppet.yaml
  36. +1
    -1
      deployment/manila/manila-share-pacemaker-puppet.yaml
  37. +1
    -1
      deployment/memcached/memcached-container-puppet.yaml
  38. +1
    -1
      deployment/metrics/collectd-container-puppet.yaml
  39. +1
    -1
      deployment/multipathd/multipathd-container.yaml
  40. +2
    -2
      deployment/neutron/neutron-api-container-puppet.yaml
  41. +6
    -6
      deployment/neutron/neutron-dhcp-container-puppet.yaml
  42. +5
    -5
      deployment/neutron/neutron-l3-container-puppet.yaml
  43. +3
    -3
      deployment/neutron/neutron-metadata-container-puppet.yaml
  44. +1
    -1
      deployment/neutron/neutron-ovs-agent-container-puppet.yaml
  45. +2
    -2
      deployment/nova/nova-api-container-puppet.yaml
  46. +4
    -4
      deployment/nova/nova-compute-container-puppet.yaml
  47. +2
    -2
      deployment/nova/nova-conductor-container-puppet.yaml
  48. +1
    -1
      deployment/nova/nova-libvirt-container-puppet.yaml
  49. +1
    -1
      deployment/nova/nova-metadata-container-puppet.yaml
  50. +1
    -1
      deployment/nova/nova-migration-target-container-puppet.yaml
  51. +2
    -2
      deployment/nova/nova-scheduler-container-puppet.yaml
  52. +2
    -2
      deployment/nova/nova-vnc-proxy-container-puppet.yaml
  53. +2
    -2
      deployment/ovn/ovn-metadata-container-puppet.yaml
  54. +2
    -2
      deployment/rabbitmq/rabbitmq-messaging-notify-pacemaker-puppet.yaml
  55. +2
    -2
      deployment/rabbitmq/rabbitmq-messaging-pacemaker-puppet.yaml
  56. +2
    -2
      deployment/rabbitmq/rabbitmq-messaging-rpc-pacemaker-puppet.yaml
  57. +1
    -1
      deployment/sahara/sahara-api-container-puppet.yaml
  58. +1
    -1
      deployment/sahara/sahara-engine-container-puppet.yaml
  59. +1
    -1
      deployment/snmp/snmp-baremetal-puppet.yaml
  60. +1
    -1
      deployment/swift/swift-proxy-container-puppet.yaml
  61. +1
    -1
      deployment/swift/swift-storage-container-puppet.yaml
  62. +5
    -5
      deployment/tripleo-packages/tripleo-packages-baremetal-puppet.yaml
  63. +4
    -4
      deployment/undercloud/undercloud-upgrade.yaml
  64. +1
    -1
      deployment/vpp/vpp-baremetal-puppet.yaml

+ 1
- 1
ci/environments/disable-unbound.yaml View File

@ -51,7 +51,7 @@ outputs:
name: unbound
state: stopped
enabled: false
ignore_errors: true
failed_when: false
- name: Set resolv.conf
copy:
content: "nameserver 1.1.1.1\nnameserver 1.0.0.1"


+ 0
- 2
common/deploy-steps-tasks-step-1.yaml View File

@ -42,7 +42,6 @@
- container_startup_configs
when:
- ansible_check_mode|bool
ignore_errors: true
check_mode: no
- name: Create /var/lib/tripleo-config/check-mode directory for check mode
@ -133,7 +132,6 @@
state: absent
tags:
- container_config
ignore_errors: true
check_mode: no
when:
- ansible_check_mode|bool


+ 1
- 1
common/deploy-steps-tasks.yaml View File

@ -53,13 +53,13 @@
debug:
var: puppet_host_outputs.stdout_lines | default([]) | union(puppet_host_outputs.stderr_lines | default([]))
when:
- not ansible_check_mode|bool
- enable_puppet | bool
- puppet_host_outputs.rc is defined
changed_when: puppet_host_outputs.rc == 2
failed_when: puppet_host_outputs.rc not in [0, 2]
tags:
- host_config
ignore_errors: "{{ ansible_check_mode|bool }}"
#########################################
# Pre-cache facts for container-puppet.py


+ 3
- 2
common/generate-config-tasks.yaml View File

@ -35,9 +35,10 @@
- name: "Debug output for task: Run container-puppet tasks (generate config) during step 1"
debug:
var: generate_config_outputs.stdout_lines | default([]) | union(generate_config_outputs.stderr_lines | default([]))
when: generate_config_outputs.rc is defined
when:
- not (ansible_check_mode | bool)
- generate_config_outputs.rc is defined
failed_when: generate_config_outputs.rc != 0
ignore_errors: "{{ ansible_check_mode|bool }}"
- name: Block for container-puppet tasks (generate config) during step {{ step }} with tripleo-ansible
when:


+ 4
- 3
deployment/aodh/aodh-api-container-puppet.yaml View File

@ -272,14 +272,15 @@ outputs:
block:
- name: Check for aodh running under apache
tags: common
shell: "httpd -t -D DUMP_VHOSTS | grep -q aodh_wsgi"
ignore_errors: true
shell: |-
set -o pipefail
httpd -t -D DUMP_VHOSTS | grep -q aodh_wsgi
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
ignore_errors: True
failed_when: false
command: systemctl is-active --quiet httpd
register: httpd_running_result
when:


+ 1
- 1
deployment/aodh/aodh-evaluator-container-puppet.yaml View File

@ -137,7 +137,7 @@ outputs:
block:
- name: FFU check if openstack-aodh-evaluator is deployed
command: systemctl is-enabled --quiet openstack-aodh-evaluator
ignore_errors: True
failed_when: false
register: aodh_evaluator_enabled_result
- name: Set fact aodh_evaluator_enabled
set_fact:


+ 1
- 1
deployment/aodh/aodh-listener-container-puppet.yaml View File

@ -137,7 +137,7 @@ outputs:
block:
- name: FFU check if openstack-aodh-listener is deployed
command: systemctl is-enabled --quiet openstack-aodh-listener
ignore_errors: True
failed_when: false
register: aodh_listener_enabled_result
- name: Set fact aodh_listener_enabled
set_fact:


+ 1
- 1
deployment/aodh/aodh-notifier-container-puppet.yaml View File

@ -138,7 +138,7 @@ outputs:
block:
- name: FFU check if openstack-aodh-notifier is deployed
command: systemctl is-enabled --quiet openstack-aodh-notifier
ignore_errors: True
failed_when: false
register: aodh_notifier_enabled_result
- name: Set fact aodh_notifier_enabled
set_fact:


+ 1
- 1
deployment/ceilometer/ceilometer-agent-central-container-puppet.yaml View File

@ -195,7 +195,7 @@ outputs:
block:
- name: FFU check if openstack-ceilometer-central is deployed
command: systemctl is-enabled --quiet openstack-ceilometer-central
ignore_errors: True
failed_when: false
register: ceilometer_agent_central_enabled_result
- name: Set fact ceilometer_agent_central_enabled
set_fact:


+ 1
- 1
deployment/ceilometer/ceilometer-agent-compute-container-puppet.yaml View File

@ -132,7 +132,7 @@ outputs:
block:
- name: FFU check if openstack-ceilometer-compute is deployed
command: systemctl is-enabled openstack-ceilometer-compute
ignore_errors: True
failed_when: false
register: ceilometer_agent_compute_enabled_result
- name: Set fact ceilometer_agent_compute_enabled
set_fact:


+ 1
- 1
deployment/ceilometer/ceilometer-agent-ipmi-container-puppet.yaml View File

@ -145,7 +145,7 @@ outputs:
block:
- name: FFU check if openstack-ceilometer-ipmi is enabled
command: systemctl is-enabled openstack-ceilometer-ipmi
ignore_errors: True
failed_when: false
register: ceilometer_ipmi_enabled_result
- name: Set fact ceilometer_ipmi_enabled
set_fact:


+ 1
- 1
deployment/ceilometer/ceilometer-agent-notification-container-puppet.yaml View File

@ -171,7 +171,7 @@ outputs:
block:
- name: FFU check if openstack-ceilometer-notification is deployed
command: systemctl is-enabled openstack-ceilometer-notification
ignore_errors: True
failed_when: false
register: ceilometer_agent_notification_enabled_result
- name: Set fact ceilometer_agent_notification_enabled
set_fact:


+ 1
- 1
deployment/cinder/cinder-api-container-puppet.yaml View File

@ -407,7 +407,7 @@ outputs:
block:
- name: Check is cinder_api is deployed
command: systemctl is-enabled --quiet openstack-cinder-api
ignore_errors: True
failed_when: false
register: cinder_api_enabled_result
- name: Set fact cinder_api_enabled
set_fact:


+ 1
- 1
deployment/cinder/cinder-scheduler-container-puppet.yaml View File

@ -163,7 +163,7 @@ outputs:
block:
- name: Check if cinder_scheduler is deployed
command: systemctl is-enabled --quiet openstack-cinder-scheduler
ignore_errors: True
failed_when: false
register: cinder_scheduler_enabled_result
- name: Set fact cinder_scheduler_enabled
set_fact:


+ 1
- 1
deployment/cinder/cinder-volume-container-puppet.yaml View File

@ -340,7 +340,7 @@ outputs:
block:
- name: Check if cinder_volume is deployed
command: systemctl is-enabled --quiet openstack-cinder-volume
ignore_errors: True
failed_when: false
register: cinder_volume_enabled_result
- name: Set fact cinder_volume_enabled
set_fact:


+ 1
- 1
deployment/cinder/cinder-volume-pacemaker-puppet.yaml View File

@ -397,7 +397,7 @@ outputs:
resource: openstack-cinder-volume
state: show
check_mode: false
ignore_errors: true
failed_when: false
register: cinder_volume_res_result
- name: Set fact cinder_volume_res
set_fact:


+ 1
- 1
deployment/database/mysql-pacemaker-puppet.yaml View File

@ -444,7 +444,7 @@ outputs:
block:
- name: Check Mysql logging configuration in pacemaker
command: cibadmin --query --xpath "//storage-mapping[@id='mysql-log']"
ignore_errors: true
failed_when: false
register: mysql_logs_moved
- name: Change Mysql logging configuration in pacemaker
# rc == 6 means the configuration doesn't exist in the CIB


+ 2
- 2
deployment/database/redis-pacemaker-puppet.yaml View File

@ -387,7 +387,7 @@ outputs:
block:
- name: Check redis logging configuration in pacemaker
command: cibadmin --query --xpath "//storage-mapping[@id='redis-log' and @source-dir='/var/log/containers/redis']"
ignore_errors: true
failed_when: false
register: redis_logs_moved
- name: Change redis logging configuration in pacemaker
# rc == 6 means the configuration doesn't exist in the CIB
@ -463,7 +463,7 @@ outputs:
resource: {get_attr: [RedisBase, role_data, service_name]}
state: show
check_mode: false
ignore_errors: true
failed_when: false
register: redis_res_result
- name: Set fact redis_res
set_fact:


+ 1
- 1
deployment/glance/glance-api-container-puppet.yaml View File

@ -697,7 +697,7 @@ outputs:
block:
- name: Check if glance_api is deployed
command: systemctl is-enabled --quiet openstack-glance-api
ignore_errors: True
failed_when: false
register: glance_api_enabled_result
- name: Set fact glance_api_enabled
set_fact:


+ 5
- 4
deployment/gnocchi/gnocchi-api-container-puppet.yaml View File

@ -391,7 +391,7 @@ outputs:
- name: Check if httpd service is running
command: systemctl is-active --quiet httpd
tags: common
ignore_errors: True
failed_when: false
register: httpd_running_result
when:
- httpd_running is undefined
@ -403,15 +403,16 @@ outputs:
- name: Check if gnocchi_api is deployed
command: systemctl is-enabled --quiet openstack-gnocchi-api
tags: common
ignore_errors: True
failed_when: false
register: gnocchi_api_enabled_result
- name: Set fact gnocchi_api_enabled
set_fact:
gnocchi_api_enabled: "{{ gnocchi_api_enabled_result.rc == 0 }}"
- name: Check for gnocchi_api running under apache
tags: common
shell: "httpd -t -D DUMP_VHOSTS | grep -q gnocchi"
ignore_errors: True
shell: |-
set -o pipefail
httpd -t -D DUMP_VHOSTS | grep -q gnocchi
register: gnocchi_httpd_enabled_result
- name: Set fact gnocchi_httpd_enabled
set_fact:


+ 1
- 1
deployment/gnocchi/gnocchi-metricd-container-puppet.yaml View File

@ -192,7 +192,7 @@ outputs:
block:
- name: FFU check if openstack-gnocchi-metricd is deployed
command: systemctl is-enabled --quiet openstack-gnocchi-metricd
ignore_errors: True
failed_when: false
register: gnocchi_metricd_enabled_result
- name: Set fact gnocchi_metricd_enabled
set_fact:


+ 1
- 1
deployment/gnocchi/gnocchi-statsd-container-puppet.yaml View File

@ -182,7 +182,7 @@ outputs:
fast_forward_upgrade_tasks:
- name: FFU check if openstack-gnocchi-statsd is deployed
command: systemctl is-enabled --quiet openstack-gnocchi-statsd
ignore_errors: True
failed_when: false
register: gnocchi_statsd_enabled_result
when:
- step|int == 0


+ 3
- 3
deployment/haproxy/haproxy-pacemaker-puppet.yaml View File

@ -378,7 +378,7 @@ outputs:
block:
- name: Check haproxy public certificate configuration in pacemaker
command: cibadmin --query --xpath "//storage-mapping[@id='haproxy-cert']"
ignore_errors: true
failed_when: false
register: haproxy_cert_mounted
- name: Disable the haproxy cluster resource
pacemaker_resource:
@ -489,11 +489,11 @@ outputs:
block:
- name: Check haproxy stats socket configuration in pacemaker
command: cibadmin --query --xpath "//storage-mapping[@id='haproxy-var-lib']"
ignore_errors: true
failed_when: false
register: haproxy_stats_exposed
- name: Check haproxy public certificate configuration in pacemaker
command: cibadmin --query --xpath "//storage-mapping[@id='haproxy-cert']"
ignore_errors: true
failed_when: false
register: haproxy_cert_mounted
- name: Add a bind mount for stats socket in the haproxy bundle
command: pcs resource bundle update haproxy-bundle storage-map add id=haproxy-var-lib source-dir=/var/lib/haproxy target-dir=/var/lib/haproxy options=rw


+ 1
- 1
deployment/heat/heat-api-cfn-container-puppet.yaml View File

@ -236,7 +236,7 @@ outputs:
block:
- name: FFU check if openstack-heat-api-cfn service is enabled
command: systemctl is-enabled openstack-heat-api-cfn
ignore_errors: True
failed_when: false
register: heat_api_cfn_enabled_result
- name: Set fact heat_api_cfn_enabled
set_fact:


+ 2
- 2
deployment/heat/heat-api-cloudwatch-disabled-puppet.yaml View File

@ -44,7 +44,7 @@ outputs:
block:
- name: FFU check if heat_api_cloudwatch is deployed
command: systemctl is-enabled openstack-heat-api-cloudwatch
ignore_errors: True
failed_when: false
register: heat_api_cloudwatch_enabled_result
- name: Set fact heat_api_cloudwatch_enabled
set_fact:
@ -57,7 +57,7 @@ outputs:
- heat_api_cloudwatch_enabled|bool
- name: Remove heat_api_cloudwatch package
package: name=openstack-heat-api-cloudwatch state=removed
ignore_errors: True
failed_when: false
when:
- step|int == 2
- release == 'rocky'

+ 1
- 1
deployment/heat/heat-api-container-puppet.yaml View File

@ -298,7 +298,7 @@ outputs:
block:
- name: FFU check openstack-heat-api is enabled
command: systemctl is-enabled openstack-heat-api
ignore_errors: True
failed_when: false
register: heat_api_enabled_result
- name: Set fact heat_api_enabled
set_fact:


+ 1
- 1
deployment/heat/heat-engine-container-puppet.yaml View File

@ -299,7 +299,7 @@ outputs:
block:
- name: FFU check if openstack-heat-engine is enabled
command: systemctl is-enabled --quiet openstack-heat-engine
ignore_errors: True
failed_when: false
register: heat_engine_enabled_result
- name: Set fact heat_engine_enabled
set_fact:


+ 1
- 1
deployment/ironic/ironic-api-container-puppet.yaml View File

@ -298,7 +298,7 @@ outputs:
block:
- name: Check if ironic_api is deployed
command: systemctl is-enabled --quiet openstack-ironic-api
ignore_errors: True
failed_when: false
register: ironic_api_enabled_result
- name: Set fact ironic_api_enabled
set_fact:


+ 1
- 1
deployment/ironic/ironic-conductor-container-puppet.yaml View File

@ -591,7 +591,7 @@ outputs:
block:
- name: Check if ironic_conductor is deployed
command: systemctl is-enabled --quiet openstack-ironic-conductor
ignore_errors: True
failed_when: false
register: ironic_conductor_enabled_result
- name: Set fact ironic_conductor_enabled
set_fact:


+ 1
- 1
deployment/iscsid/iscsid-container-puppet.yaml View File

@ -113,7 +113,7 @@ outputs:
when: stat_iscsid_socket.stat.exists
- name: Check if iscsi.service is enabled
command: systemctl is-enabled --quiet iscsi.service
ignore_errors: True
failed_when: false
register: iscsi_service_enabled_result
- name: Stop iscsi.service
service: name=iscsi.service state=stopped enabled=no


+ 1
- 1
deployment/keepalived/keepalived-container-puppet.yaml View File

@ -136,7 +136,7 @@ outputs:
- name: Restart Keepalived container
shell: "{{container_cli}} restart keepalived"
when: restart_keepalived|bool
ignore_errors: True
failed_when: false
- name: load ip_vs module
import_role:
name: tripleo-module-load


+ 2
- 2
deployment/keystone/keystone-container-puppet.yaml View File

@ -758,13 +758,13 @@ outputs:
- name: Check for keystone running under apache
tags: common
shell: "httpd -t -D DUMP_VHOSTS | grep -q keystone_wsgi"
ignore_errors: true
failed_when: false
register: keystone_httpd_enabled_result
- name: Set fact keystone_httpd_enabled
set_fact:
keystone_httpd_enabled: "{{ keystone_httpd_enabled_result.rc == 0 }}"
- name: Check if httpd is running
ignore_errors: True
failed_when: false
command: systemctl is-active --quiet httpd
register: httpd_running_result
when:


+ 1
- 1
deployment/manila/manila-api-container-puppet.yaml View File

@ -256,7 +256,7 @@ outputs:
fast_forward_upgrade_tasks:
- name: Check if manila_api is deployed
command: systemctl is-enabled --quiet openstack-manila-api
ignore_errors: True
failed_when: false
register: manila_api_enabled_result
when:
- step|int == 0


+ 1
- 1
deployment/manila/manila-scheduler-container-puppet.yaml View File

@ -119,7 +119,7 @@ outputs:
fast_forward_upgrade_tasks:
- name: Check if manila_scheduler is deployed
command: systemctl is-enabled --quiet openstack-manila-scheduler
ignore_errors: True
failed_when: false
register: manila_scheduler_enabled_result
when:
- step|int == 0


+ 1
- 1
deployment/manila/manila-share-container-puppet.yaml View File

@ -174,7 +174,7 @@ outputs:
fast_forward_upgrade_tasks:
- name: Check if manila_share is deployed
command: systemctl is-enabled --quiet openstack-manila-share
ignore_errors: True
failed_when: false
register: manila_share_enabled_result
when:
- step|int == 0


+ 1
- 1
deployment/manila/manila-share-pacemaker-puppet.yaml View File

@ -379,7 +379,7 @@ outputs:
resource: openstack-manila-share
state: show
check_mode: false
ignore_errors: true
failed_when: false
register: manila_share_res_result
when:
- step|int == 0


+ 1
- 1
deployment/memcached/memcached-container-puppet.yaml View File

@ -194,7 +194,7 @@ outputs:
- name: Check if memcached is deployed
command: systemctl is-enabled --quiet memcached
tags: common
ignore_errors: True
failed_when: false
register: memcached_enabled_result
- name: memcached_enabled
set_fact:


+ 1
- 1
deployment/metrics/collectd-container-puppet.yaml View File

@ -662,7 +662,7 @@ outputs:
block:
- name: Check if collectd.service is deployed
command: systemctl is-enabled --quiet collectd.service
ignore_errors: True
failed_when: false
register: collectd_enabled_result
- name: Set fact collectd_enabled
set_fact:


+ 1
- 1
deployment/multipathd/multipathd-container.yaml View File

@ -136,7 +136,7 @@ outputs:
host_prep_tasks:
- name: Check if multipathd is deployed on the host
command: systemctl is-enabled --quiet multipathd
ignore_errors: True
failed_when: false
register: multipathd_enabled_result
- name: Set fact multipathd_enabled
set_fact:


+ 2
- 2
deployment/neutron/neutron-api-container-puppet.yaml View File

@ -542,7 +542,7 @@ outputs:
block:
- name: Check if neutron_server is deployed
command: systemctl is-enabled --quiet neutron-server
ignore_errors: True
failed_when: false
register: neutron_server_enabled_result
- name: Set fact neutron_server_enabled
set_fact:
@ -565,7 +565,7 @@ outputs:
package: name=python-networking-odl state=latest
# package python-networking-cisco may or may not be present
- name: Networking cisco db sync workaround
ignore_errors: true
failed_when: false
package: name=python-networking-cisco state=latest
- name: Neutron db sync
command: neutron-db-manage upgrade head


+ 6
- 6
deployment/neutron/neutron-dhcp-container-puppet.yaml View File

@ -405,10 +405,10 @@ outputs:
- - name: create /run/netns with temp namespace
command: ip netns add ns_temp
register: ipnetns_add_result
ignore_errors: True
failed_when: false
- - name: remove temp namespace
command: ip netns delete ns_temp
ignore_errors: True
failed_when: false
when: ipnetns_add_result.rc == 0
- - name: create /var/lib/neutron
file:
@ -428,7 +428,7 @@ outputs:
block:
- name: Check if neutron_dhcp_agent is deployed
command: systemctl is-enabled --quiet neutron-dhcp-agent
ignore_errors: True
failed_when: false
register: neutron_dhcp_agent_enabled_result
- name: Set fact neutron_dhcp_agent_enabled
set_fact:
@ -444,7 +444,7 @@ outputs:
getent:
database: passwd
key: neutron
ignore_errors: True
fail_key: false
- name: Set neutron_user_avail
set_fact:
neutron_user_avail: "{{ getent_passwd is defined }}"
@ -460,7 +460,7 @@ outputs:
setfacl -R -m u:neutron:rw /var/lib/neutron
find /var/lib/neutron -type d -exec setfacl -m u:neutron:rwx '{}' \;
- name: Provide access for domain sockets
ignore_errors: True
failed_when: false
become: true
shell: |
umask 0002
@ -469,4 +469,4 @@ outputs:
- /var/lib/neutron/metadata_proxy
- /var/lib/neutron
# These files are not necessarily present
ignore_errors: True
failed_when: false

+ 5
- 5
deployment/neutron/neutron-l3-container-puppet.yaml View File

@ -361,10 +361,10 @@ outputs:
- - name: create /run/netns with temp namespace
command: ip netns add ns_temp
register: ipnetns_add_result
ignore_errors: True
failed_when: false
- - name: remove temp namespace
command: ip netns delete ns_temp
ignore_errors: True
failed_when: false
when: ipnetns_add_result.rc == 0
- - name: create /var/lib/neutron
file:
@ -384,7 +384,7 @@ outputs:
block:
- name: Check if neutron_l3_agent is deployed
command: systemctl is-enabled --quiet neutron-l3-agent
ignore_errors: True
failed_when: false
register: neutron_l3_agent_enabled_result
- name: Set fact neutron_l3_agent_enabled
set_fact:
@ -400,7 +400,7 @@ outputs:
getent:
database: passwd
key: neutron
ignore_errors: True
fail_key: false
- name: Set neutron_user_avail
set_fact:
neutron_user_avail: "{{ getent_passwd is defined }}"
@ -425,4 +425,4 @@ outputs:
- /var/lib/neutron/keepalived-state-change
- /var/lib/neutron
# These files are not necessarily present
ignore_errors: True
failed_when: false

+ 3
- 3
deployment/neutron/neutron-metadata-container-puppet.yaml View File

@ -217,7 +217,7 @@ outputs:
block:
- name: Check if neutron_metadata_agent is deployed
command: systemctl is-enabled --quiet neutron-metadata-agent
ignore_errors: True
failed_when: false
register: neutron_metadata_agent_enabled_result
- name: Set fact neutron_metadata_agent_enabled
set_fact:
@ -233,7 +233,7 @@ outputs:
getent:
database: passwd
key: neutron
ignore_errors: True
fail_key: false
- name: Set neutron_user_avail
set_fact:
neutron_user_avail: "{{ getent_passwd is defined }}"
@ -258,4 +258,4 @@ outputs:
- /var/lib/neutron/keepalived-state-change
- /var/lib/neutron
# These files are not necessarily present
ignore_errors: True
failed_when: false

+ 1
- 1
deployment/neutron/neutron-ovs-agent-container-puppet.yaml View File

@ -396,7 +396,7 @@ outputs:
block:
- name: Check if neutron_ovs_agent is deployed
command: systemctl is-enabled --quiet neutron-openvswitch-agent
ignore_errors: True
failed_when: false
register: neutron_ovs_agent_enabled_result
- name: Set fact neutron_ovs_agent_enabled
set_fact:


+ 2
- 2
deployment/nova/nova-api-container-puppet.yaml View File

@ -486,7 +486,7 @@ outputs:
delay: 30
until: nova_api_healthcheck_state.status.ExecMainPID != '0' and
nova_api_healthcheck_state.status.ActiveState in ['inactive', 'failed']
ignore_errors: yes
failed_when: false
- name: Fail if nova-api healthcheck report failed status
fail:
msg: nova-api isn't working (healthcheck failed)
@ -524,7 +524,7 @@ outputs:
block:
- name: Check if nova-api is deployed
command: systemctl is-enabled --quiet openstack-nova-api
ignore_errors: True
failed_when: false
register: nova_api_enabled_result
- name: Set fact nova_api_enabled
set_fact:


+ 4
- 4
deployment/nova/nova-compute-container-puppet.yaml View File

@ -1049,7 +1049,7 @@ outputs:
delay: 30
until: nova_compute_healthcheck_state.status.ExecMainPID != '0' and
nova_compute_healthcheck_state.status.ActiveState in ['inactive', 'failed']
ignore_errors: yes
failed_when: false
- name: Fail if nova-compute healthcheck report failed status
fail:
msg: nova-compute isn't working (healthcheck failed)
@ -1062,7 +1062,7 @@ outputs:
- openstack-nova-compute
- python-nova
state: removed
ignore_errors: True
failed_when: false
when: step|int == 2
update_tasks:
- name: Remove openstack-nova-compute and python-nova package during upgrade
@ -1071,7 +1071,7 @@ outputs:
- openstack-nova-compute
- python-nova
state: removed
ignore_errors: True
failed_when: false
when: step|int == 2
scale_tasks:
- when: step|int == 1
@ -1146,7 +1146,7 @@ outputs:
block:
- name: Check if nova-compute is deployed
command: systemctl is-enabled --quiet openstack-nova-compute
ignore_errors: True
failed_when: false
register: nova_compute_enabled_result
- name: Set fact nova_compute_enabled
set_fact:


+ 2
- 2
deployment/nova/nova-conductor-container-puppet.yaml View File

@ -214,7 +214,7 @@ outputs:
delay: 30
until: nova_conductor_healthcheck_state.status.ExecMainPID != '0' and
nova_conductor_healthcheck_state.status.ActiveState in ['inactive', 'failed']
ignore_errors: yes
failed_when: false
- name: Fail if nova-conductor healthcheck report failed status
fail:
msg: nova-conductor isn't working (healthcheck failed)
@ -249,7 +249,7 @@ outputs:
block:
- name: Check if nova_conductor is deployed
command: systemctl is-enabled --quiet openstack-nova-conductor
ignore_errors: True
failed_when: false
register: nova_conductor_enabled_result
- name: Set fact nova_conductor_enabled
set_fact:


+ 1
- 1
deployment/nova/nova-libvirt-container-puppet.yaml View File

@ -813,7 +813,7 @@ outputs:
delay: 30
until: nova_libvirt_healthcheck_state.status.ExecMainPID != '0' and
nova_libvirt_healthcheck_state.status.ActiveState in ['inactive', 'failed']
ignore_errors: yes
failed_when: false
- name: Fail if nova-libvirt healthcheck report failed status
fail:
msg: nova-libvirt isn't working (healtcheck failed)


+ 1
- 1
deployment/nova/nova-metadata-container-puppet.yaml View File

@ -255,7 +255,7 @@ outputs:
delay: 30
until: nova_metadata_healthcheck_state.status.ExecMainPID != '0' and
nova_metadata_healthcheck_state.status.ActiveState in ['inactive', 'failed']
ignore_errors: yes
failed_when: false
- name: Fail if nova-metadata healthcheck report failed status
fail:
msg: nova-metadata isn't working (healthcheck failed)


+ 1
- 1
deployment/nova/nova-migration-target-container-puppet.yaml View File

@ -189,7 +189,7 @@ outputs:
delay: 30
until: nova_migration_target_healthcheck_state.status.ExecMainPID != '0' and
nova_migration_target_healthcheck_state.status.ActiveState in ['inactive', 'failed']
ignore_errors: yes
failed_when: false
- name: Fail if nova-migration-target healthcheck report failed status
fail:
msg: nova-migration-target isn't working (healtcheck failed)


+ 2
- 2
deployment/nova/nova-scheduler-container-puppet.yaml View File

@ -204,7 +204,7 @@ outputs:
delay: 30
until: nova_scheduler_healthcheck_state.status.ExecMainPID != '0' and
nova_scheduler_healthcheck_state.status.ActiveState in ['inactive', 'failed']
ignore_errors: yes
failed_when: false
- name: Fail if nova-scheduler healthcheck report failed status
fail:
msg: nova-scheduler isn't working (healthcheck failed)
@ -224,7 +224,7 @@ outputs:
block:
- name: Check if nova_scheduler is deployed
command: systemctl is-enabled --quiet openstack-nova-scheduler
ignore_errors: True
failed_when: false
register: nova_scheduler_enabled_result
- name: Set fact nova_scheduler_enabled
set_fact:


+ 2
- 2
deployment/nova/nova-vnc-proxy-container-puppet.yaml View File

@ -300,7 +300,7 @@ outputs:
delay: 30
until: nova_vnc_proxy_healthcheck_state.status.ExecMainPID != '0' and
nova_vnc_proxy_healthcheck_state.status.ActiveState in ['inactive', 'failed']
ignore_errors: yes
failed_when: false
- name: Fail if nova-vnc-proxy healtcheck report failed status
fail:
msg: nova-vnc-proxy isn't working (healthcheck failed)
@ -328,7 +328,7 @@ outputs:
block:
- name: Check if nova vncproxy is deployed
command: systemctl is-enabled --quiet openstack-nova-novncproxy
ignore_errors: True
failed_when: false
register: nova_vncproxy_enabled_result
- name: Set fact nova_vncproxy_enabled
set_fact:


+ 2
- 2
deployment/ovn/ovn-metadata-container-puppet.yaml View File

@ -348,10 +348,10 @@ outputs:
- - name: create /run/netns with temp namespace
command: ip netns add ns_temp
register: ipnetns_add_result
ignore_errors: True
failed_when: false
- - name: remove temp namespace
command: ip netns delete ns_temp
ignore_errors: True
failed_when: false
when: ipnetns_add_result.rc == 0
- - name: create /var/lib/neutron
file:


+ 2
- 2
deployment/rabbitmq/rabbitmq-messaging-notify-pacemaker-puppet.yaml View File

@ -342,7 +342,7 @@ outputs:
block:
- name: Check rabbitmq logging configuration in pacemaker
command: cibadmin --query --xpath "//storage-mapping[@id='rabbitmq-log']"
ignore_errors: true
failed_when: false
register: rabbitmq_logs_moved
- name: Add a bind mount for logging in the rabbitmq bundle
# rc == 6 means the configuration doesn't exist in the CIB
@ -437,7 +437,7 @@ outputs:
resource: {get_attr: [RabbitmqBase, role_data, service_name]}
state: show
check_mode: false
ignore_errors: true
failed_when: false
register: rabbitmq_res_result
- name: Set fact rabbitmq_res
set_fact:


+ 2
- 2
deployment/rabbitmq/rabbitmq-messaging-pacemaker-puppet.yaml View File

@ -343,7 +343,7 @@ outputs:
block:
- name: Check rabbitmq logging configuration in pacemaker
command: cibadmin --query --xpath "//storage-mapping[@id='rabbitmq-log']"
ignore_errors: true
failed_when: false
register: rabbitmq_logs_moved
- name: Add a bind mount for logging in the rabbitmq bundle
# rc == 6 means the configuration doesn't exist in the CIB
@ -424,7 +424,7 @@ outputs:
resource: {get_attr: [RabbitmqBase, role_data, service_name]}
state: show
check_mode: false
ignore_errors: true
failed_when: false
register: rabbitmq_res_result
- name: Set fact rabbitmq_res
set_fact:


+ 2
- 2
deployment/rabbitmq/rabbitmq-messaging-rpc-pacemaker-puppet.yaml View File

@ -348,7 +348,7 @@ outputs:
block:
- name: Check rabbitmq logging configuration in pacemaker
command: cibadmin --query --xpath "//storage-mapping[@id='rabbitmq-log']"
ignore_errors: true
failed_when: false
register: rabbitmq_logs_moved
- name: Add a bind mount for logging in the rabbitmq bundle
# rc == 6 means the configuration doesn't exist in the CIB
@ -443,7 +443,7 @@ outputs:
resource: {get_attr: [RabbitmqBase, role_data, service_name]}
state: show
check_mode: false
ignore_errors: true
failed_when: false
register: rabbitmq_res_result
- name: Set fact rabbitmq_res
set_fact:


+ 1
- 1
deployment/sahara/sahara-api-container-puppet.yaml View File

@ -219,7 +219,7 @@ outputs:
block:
- name: FFU check openstack-sahara-api is enabled
command: systemctl is-enabled openstack-sahara-api
ignore_errors: True
failed_when: false
register: sahara_api_enabled_result
- name: Set fact sahara_api_enabled
set_fact:


+ 1
- 1
deployment/sahara/sahara-engine-container-puppet.yaml View File

@ -141,7 +141,7 @@ outputs:
block:
- name: FFU check if openstack-sahara-engine is enabled
command: systemctl is-enabled --quiet openstack-sahara-engine
ignore_errors: True
failed_when: false
register: sahara_engine_enabled_result
- name: Set fact sahara_engine_enabled
set_fact:


+ 1
- 1
deployment/snmp/snmp-baremetal-puppet.yaml View File

@ -93,7 +93,7 @@ outputs:
block:
- name: Check if snmpd is enabled
command: systemctl is-enabled --quiet snmpd
ignore_errors: True
failed_when: false
register: snmpd_enabled_result
- name: Set fact snmpd_enabled
set_fact:


+ 1
- 1
deployment/swift/swift-proxy-container-puppet.yaml View File

@ -479,7 +479,7 @@ outputs:
block:
- name: Check if swift-proxy or swift-object-expirer are deployed
command: systemctl is-enabled --quiet "{{ item }}"
ignore_errors: True
failed_when: false
register: swift_proxy_services_enabled_result
with_items:
- openstack-swift-proxy


+ 1
- 1
deployment/swift/swift-storage-container-puppet.yaml View File

@ -688,7 +688,7 @@ outputs:
- openstack-swift-object-updater
- openstack-swift-object
- openstack-swift-object-reconstructor
ignore_errors: True
failed_when: false
register: swift_services_enabled_result
- name: Set fact swift_services_enabled
set_fact:


+ 5
- 5
deployment/tripleo-packages/tripleo-packages-baremetal-puppet.yaml View File

@ -241,7 +241,7 @@ outputs:
set -o pipefail
yum info -q rhosp-openvswitch | awk '/^Version/{print $NF}'
register: rhosp_package_result
ignore_errors: true
failed_when: false
- name: Set fact for triggering OpenvSwitch layered product package handling
set_fact:
ovs_lp_packaging: "{{ rhosp_package_result.rc == 0 }}"
@ -295,13 +295,13 @@ outputs:
block:
- name: check if an upgrade is required
register: ovs_need_upgrade
ignore_errors: true
failed_when: false
shell: |
yum check-upgrade openvswitch | awk '/openvswitch/{print}'
- name: Check openvswitch packaging.
shell: rpm -q --scripts openvswitch | awk '/postuninstall/,/*/' | grep -q "systemctl.*try-restart"
register: ovs_packaging_issue
ignore_errors: true
failed_when: false
- name: Upgrade openvswitch
block:
- name: "Ensure empty directory: emptying."
@ -332,7 +332,7 @@ outputs:
when:
- step|int == 2
- run_ovs_update|bool
- ovs_packaging_issue|default(false)|succeeded
- ovs_packaging_issue.rc == 0 | default(false)
- ovs_need_upgrade.stdout|default('')
- name: Install libibverbs (https://bugs.launchpad.net/tripleo/+bug/1817743)
when: step|int == 2
@ -356,7 +356,7 @@ outputs:
- name: Check that os-net-config has configuration
shell: test -s /etc/os-net-config/config.json
register: os_net_config_has_config
ignore_errors: True
failed_when: false
when: step|int == 3
- block:
- name: Upgrade os-net-config


+ 4
- 4
deployment/undercloud/undercloud-upgrade.yaml View File

@ -89,7 +89,7 @@ outputs:
set -o pipefail
yum info -q rhosp-openvswitch | awk '/^Version/{print $NF}'
register: rhosp_package_result
ignore_errors: true
failed_when: false
- name: Set fact for triggering OpenvSwitch layered product package handling
set_fact:
ovs_lp_packaging: "{{ rhosp_package_result.rc == 0 }}"
@ -143,13 +143,13 @@ outputs:
block:
- name: check if an upgrade is required
register: ovs_need_upgrade
ignore_errors: true
failed_when: false
shell: |
yum check-upgrade openvswitch | awk '/openvswitch/{print}'
- name: Check openvswitch packaging.
shell: rpm -q --scripts openvswitch | awk '/postuninstall/,/*/' | grep -q "systemctl.*try-restart"
register: ovs_packaging_issue
ignore_errors: true
failed_when: false
- name: Upgrade openvswitch
block:
- name: "Ensure empty directory: emptying."
@ -180,7 +180,7 @@ outputs:
when:
- step|int == 2
- run_ovs_update|bool
- ovs_packaging_issue|default(false)|succeeded
- ovs_packaging_issue.rc == 0 | default(false)
- ovs_need_upgrade.stdout|default('')
# The openvswitch package disables the systemd service on install. When installing
# the layered product we prevent the service from being killed, but it doesn't


+ 1
- 1
deployment/vpp/vpp-baremetal-puppet.yaml View File

@ -57,7 +57,7 @@ outputs:
- name: Check if vpp is deployed
command: systemctl is-enabled vpp
tags: common
ignore_errors: True
failed_when: false
register: vpp_enabled
- name: "PreUpgrade step0,validation: Check service vpp is running"
shell: /usr/bin/systemctl show 'vpp' --property ActiveState | grep '\bactive\b'


Loading…
Cancel
Save