Merge "Remove ffwd-upgrade leftovers from THT."
This commit is contained in:
commit
2f607aafee
@ -21,8 +21,6 @@
|
||||
{% set upgrade_steps_max = 6 -%}
|
||||
{% set external_upgrade_steps_max = 3 -%}
|
||||
{% set post_upgrade_steps_max = 4 -%}
|
||||
{% set fast_forward_upgrade_steps_max = 9 -%}
|
||||
{% set fast_forward_upgrade_prep_steps_max = 3 -%}
|
||||
{% set post_update_steps_max = 4 -%}
|
||||
{% set scale_steps_max = 1 -%}
|
||||
|
||||
@ -97,10 +95,6 @@ parameters:
|
||||
type: boolean
|
||||
default: true
|
||||
description: Whether containerized puppet executions use modules from the baremetal host. Defaults to true. Can be set to false to consume puppet modules from containers directly.
|
||||
FastForwardUpgradeReleases:
|
||||
type: comma_delimited_list
|
||||
default: ['rocky', 'stein', 'train']
|
||||
description: List of releases to fast forward through during upgrade. Last release in list is used for post steps.
|
||||
ContainerLogStdoutPath:
|
||||
type: string
|
||||
description: Absolute path for container stdout output (Podman only)
|
||||
@ -166,7 +160,7 @@ parameters:
|
||||
Type of update, to differentiate between UPGRADE and UPDATE cases
|
||||
when StackAction is UPDATE (both are the same stack action).
|
||||
constraints:
|
||||
- allowed_values: ['', 'UPGRADE', 'FASTFORWARDUPGRADE']
|
||||
- allowed_values: ['', 'UPGRADE']
|
||||
default: ''
|
||||
ContainerCli:
|
||||
type: string
|
||||
@ -1198,88 +1192,6 @@ outputs:
|
||||
when: ansible_hostname is not defined
|
||||
tags:
|
||||
- scale
|
||||
fast_forward_upgrade_playbook:
|
||||
{{ self.deploy_steps_str_replace_params() }}
|
||||
template: |
|
||||
- hosts: DEPLOY_TARGET_HOST
|
||||
any_errors_fatal: yes
|
||||
tasks:
|
||||
- set_fact:
|
||||
releases: {get_param: [FastForwardUpgradeReleases]}
|
||||
{% raw %}
|
||||
- set_fact:
|
||||
ffu_releases: "{{ releases | difference( releases | last )}}"
|
||||
- include_tasks: fast_forward_upgrade_release_tasks.yaml
|
||||
loop_control:
|
||||
loop_var: release
|
||||
with_items: '{{ ffu_releases }}'
|
||||
- set_fact:
|
||||
release: "{{ releases | last }}"
|
||||
ffu_packages_apply: True
|
||||
{% endraw %}
|
||||
- include_tasks: fast_forward_upgrade_post_role_tasks.yaml
|
||||
fast_forward_upgrade_release_tasks: |
|
||||
- include_tasks: fast_forward_upgrade_prep_tasks.yaml
|
||||
- include_tasks: fast_forward_upgrade_bootstrap_tasks.yaml
|
||||
fast_forward_upgrade_prep_tasks: |
|
||||
{%- for role in roles %}
|
||||
- shell: |
|
||||
#!/bin/bash
|
||||
if [ ! -f /root/.ffu_workaround ]; then
|
||||
touch /root/.ffu_workaround
|
||||
os-apply-config -m /var/lib/os-collect-config/{{role.deprecated_server_resource_name|default(role.name)}}Deployment.json
|
||||
systemctl stop os-collect-config
|
||||
rm -r /var/lib/os-collect-config/*
|
||||
rm -f /usr/libexec/os-refresh-config/configure.d/40-hiera-datafiles
|
||||
rm -f /usr/libexec/os-apply-config/templates/etc/puppet/hiera.yaml
|
||||
rm -f /usr/libexec/os-refresh-config/configure.d/10-hiera-disable
|
||||
fi
|
||||
when: tripleo_role_name == '{{role.name}}'
|
||||
name: Run Fast Forward Upgrade Prep Workarounds for {{role.name}}
|
||||
{%- endfor %}
|
||||
- name: Create /var/lib/container-puppet
|
||||
file: path=/var/lib/container-puppet state=directory setype=container_file_t selevel=s0 recurse=true
|
||||
- name: Write container-puppet.sh
|
||||
no_log: True
|
||||
copy: src=container_puppet_script.yaml dest=/var/lib/container-puppet/container-puppet.sh force=yes mode=0755 setype=container_file_t
|
||||
- include_tasks: fast_forward_upgrade_prep_role_tasks.yaml
|
||||
with_sequence: start=0 end={{fast_forward_upgrade_prep_steps_max}}
|
||||
loop_control:
|
||||
loop_var: step
|
||||
fast_forward_upgrade_post_role_tasks: |
|
||||
{%- for role in roles %}
|
||||
- include_tasks: {{role.name}}/fast_forward_post_upgrade_tasks.yaml
|
||||
when: tripleo_role_name == '{{role.name}}'
|
||||
tags:
|
||||
- always
|
||||
{%- endfor %}
|
||||
- name: Openstack Heat Agents package update
|
||||
package: name=openstack-heat-agents state=latest
|
||||
- name: Update os-collect-config
|
||||
package: name=os-collect-config state=latest
|
||||
- name: Start os-collect-config back up
|
||||
service: name=os-collect-config state=started enabled=yes
|
||||
fast_forward_upgrade_prep_role_tasks: |
|
||||
{%- for role in roles %}
|
||||
- include_tasks: {{role.name}}/fast_forward_upgrade_tasks.yaml
|
||||
when: tripleo_role_name == '{{role.name}}'
|
||||
tags:
|
||||
- always
|
||||
{%- endfor %}
|
||||
fast_forward_upgrade_bootstrap_tasks: |
|
||||
- include_tasks: fast_forward_upgrade_bootstrap_role_tasks.yaml
|
||||
with_sequence: start={{fast_forward_upgrade_prep_steps_max+1}} end={{fast_forward_upgrade_steps_max}}
|
||||
loop_control:
|
||||
loop_var: step
|
||||
fast_forward_upgrade_bootstrap_role_tasks: |
|
||||
{%- for role in roles %}
|
||||
- include_tasks: {{role.name}}/fast_forward_upgrade_tasks.yaml
|
||||
when:
|
||||
- tripleo_role_name == '{{role.name}}'
|
||||
- is_bootstrap_node|bool
|
||||
tags:
|
||||
- always
|
||||
{%- endfor %}
|
||||
post_update_steps_tasks: |
|
||||
{%- for role in roles %}
|
||||
- include_tasks: {{role.name}}/post_update_tasks.yaml
|
||||
|
@ -212,24 +212,6 @@ resources:
|
||||
expression: coalesce($.data, []).where($ != null).select($.get('external_upgrade_tasks')).where($ != null).flatten().distinct()
|
||||
data: {get_attr: [ServiceChain, role_data]}
|
||||
|
||||
FastForwardUpgradeTasks:
|
||||
type: OS::Heat::Value
|
||||
properties:
|
||||
type: comma_delimited_list
|
||||
value:
|
||||
yaql:
|
||||
expression: coalesce($.data, []).where($ != null).select($.get('fast_forward_upgrade_tasks')).where($ != null).flatten().distinct()
|
||||
data: {get_attr: [ServiceChain, role_data]}
|
||||
|
||||
FastForwardPostUpgradeTasks:
|
||||
type: OS::Heat::Value
|
||||
properties:
|
||||
type: comma_delimited_list
|
||||
value:
|
||||
yaql:
|
||||
expression: coalesce($.data, []).where($ != null).select($.get('fast_forward_post_upgrade_tasks')).where($ != null).flatten().distinct()
|
||||
data: {get_attr: [ServiceChain, role_data]}
|
||||
|
||||
PreUpgradeRollingTasks:
|
||||
type: OS::Heat::Value
|
||||
properties:
|
||||
@ -381,8 +363,6 @@ outputs:
|
||||
external_update_tasks: {get_attr: [ExternalUpdateTasks, value]}
|
||||
external_upgrade_tasks: {get_attr: [ExternalUpgradeTasks, value]}
|
||||
scale_tasks: {get_attr: [ScaleTasks, value]}
|
||||
fast_forward_upgrade_tasks: {get_attr: [FastForwardUpgradeTasks, value]}
|
||||
fast_forward_post_upgrade_tasks: {get_attr: [FastForwardPostUpgradeTasks, value]}
|
||||
pre_upgrade_rolling_tasks: {get_attr: [PreUpgradeRollingTasks, value]}
|
||||
upgrade_tasks: {get_attr: [UpgradeTasks, value]}
|
||||
post_upgrade_tasks: {get_attr: [PostUpgradeTasks, value]}
|
||||
|
@ -176,36 +176,6 @@ all containerized services and the updated configuration if any.
|
||||
Note: as pacemaker is not containerized, the points 1 and 4 happen in
|
||||
deployment/pacemaker/pacemaker-baremetal-puppet.yaml.
|
||||
|
||||
Fast-forward Upgrade Steps
|
||||
--------------------------
|
||||
|
||||
Each service template may optionally define a `fast_forward_upgrade_tasks` key,
|
||||
which is a list of Ansible tasks to be performed during the fast-forward
|
||||
upgrade process. As with Upgrade steps each task is associated to a particular
|
||||
step provided as a variable and used along with a release variable by a basic
|
||||
conditional that determines when the task should run.
|
||||
|
||||
Steps are broken down into two categories, prep tasks executed across all hosts
|
||||
and bootstrap tasks executed on a single host for a given role.
|
||||
|
||||
The individual steps then correspond to the following tasks during the upgrade:
|
||||
|
||||
Prep steps:
|
||||
|
||||
- Step=0: Check running services
|
||||
- Step=1: Stop the service
|
||||
- Step=2: Stop the cluster
|
||||
- Step=3: Update repos
|
||||
|
||||
Bootstrap steps:
|
||||
|
||||
- Step=4: DB backups
|
||||
- Step=5: Pre package update commands
|
||||
- Step=6: Package updates
|
||||
- Step=7: Post package update commands
|
||||
- Step=8: DB syncs
|
||||
- Step=9: Verification
|
||||
|
||||
Input Parameters
|
||||
----------------
|
||||
|
||||
|
@ -273,49 +273,3 @@ outputs:
|
||||
tripleo_containers_to_stop:
|
||||
- aodh_api
|
||||
tripleo_delegate_to: "{{ groups['aodh_api'] | default([]) }}"
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: Check for aodh running under apache
|
||||
tags: common
|
||||
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
|
||||
failed_when: false
|
||||
command: systemctl is-active --quiet httpd
|
||||
register: httpd_running_result
|
||||
when:
|
||||
- httpd_running is undefined
|
||||
- name: Set fact httpd_running if undefined
|
||||
set_fact:
|
||||
httpd_running: "{{ httpd_running_result.rc == 0 }}"
|
||||
when:
|
||||
- httpd_running is undefined
|
||||
- name: Stop and disable aodh (under httpd)
|
||||
service: name=httpd state=stopped enabled=no
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- aodh_httpd_enabled|bool
|
||||
- httpd_running|bool
|
||||
- name: Aodh package update
|
||||
package:
|
||||
name: 'openstack-aodh*'
|
||||
state: latest
|
||||
when:
|
||||
- step|int == 6
|
||||
- is_bootstrap_node|bool
|
||||
- aodh_httpd_enabled|bool
|
||||
- name: aodh db sync
|
||||
command: aodh-dbsync
|
||||
when:
|
||||
- step|int == 8
|
||||
- is_bootstrap_node|bool
|
||||
- aodh_httpd_enabled|bool
|
||||
|
@ -131,21 +131,3 @@ outputs:
|
||||
tripleo_containers_to_stop:
|
||||
- aodh_evaluator
|
||||
tripleo_delegate_to: "{{ groups['aodh_evaluator'] | default([]) }}"
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: FFU check if openstack-aodh-evaluator is deployed
|
||||
command: systemctl is-enabled --quiet openstack-aodh-evaluator
|
||||
failed_when: false
|
||||
register: aodh_evaluator_enabled_result
|
||||
- name: Set fact aodh_evaluator_enabled
|
||||
set_fact:
|
||||
aodh_evaluator_enabled: "{{ aodh_evaluator_enabled_result.rc == 0 }}"
|
||||
- name: FFU stop and disable openstack-aodh-evaluator service
|
||||
service: name=openstack-aodh-evaluator state=stopped enabled=no
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- aodh_evaluator_enabled|bool
|
||||
|
@ -131,21 +131,3 @@ outputs:
|
||||
tripleo_containers_to_stop:
|
||||
- aodh_listener
|
||||
tripleo_delegate_to: "{{ groups['aodh_listener'] | default([]) }}"
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: FFU check if openstack-aodh-listener is deployed
|
||||
command: systemctl is-enabled --quiet openstack-aodh-listener
|
||||
failed_when: false
|
||||
register: aodh_listener_enabled_result
|
||||
- name: Set fact aodh_listener_enabled
|
||||
set_fact:
|
||||
aodh_listener_enabled: "{{ aodh_listener_enabled_result.rc == 0 }}"
|
||||
- name: FFU stop and disable openstack-aodh-listener service
|
||||
service: name=openstack-aodh-listener state=stopped enabled=no
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- aodh_listener_enabled|bool
|
||||
|
@ -132,21 +132,3 @@ outputs:
|
||||
tripleo_containers_to_stop:
|
||||
- aodh_notifier
|
||||
tripleo_delegate_to: "{{ groups['aodh_notifier'] | default([]) }}"
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: FFU check if openstack-aodh-notifier is deployed
|
||||
command: systemctl is-enabled --quiet openstack-aodh-notifier
|
||||
failed_when: false
|
||||
register: aodh_notifier_enabled_result
|
||||
- name: Set fact aodh_notifier_enabled
|
||||
set_fact:
|
||||
aodh_notifier_enabled: "{{ aodh_notifier_enabled_result.rc == 0 }}"
|
||||
- name: FFU stop and disable openstack-aodh-notifier service
|
||||
service: name=openstack-aodh-notifier state=stopped enabled=no
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- aodh_notifier_enabled|bool
|
||||
|
@ -187,21 +187,3 @@ outputs:
|
||||
tripleo_containers_to_stop:
|
||||
- ceilometer_agent_central
|
||||
tripleo_delegate_to: "{{ groups['ceilometer_agent_central'] | default([]) }}"
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: FFU check if openstack-ceilometer-central is deployed
|
||||
command: systemctl is-enabled --quiet openstack-ceilometer-central
|
||||
failed_when: false
|
||||
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: FFU stop and disable openstack-ceilometer-central service
|
||||
service: name=openstack-ceilometer-central state=stopped enabled=no
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- ceilometer_agent_central_enabled|bool
|
||||
|
@ -126,21 +126,3 @@ outputs:
|
||||
name: virt_sandbox_use_netlink
|
||||
persistent: yes
|
||||
state: yes
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: FFU check if openstack-ceilometer-compute is deployed
|
||||
command: systemctl is-enabled openstack-ceilometer-compute
|
||||
failed_when: false
|
||||
register: ceilometer_agent_compute_enabled_result
|
||||
- name: Set fact ceilometer_agent_compute_enabled
|
||||
set_fact:
|
||||
ceilometer_agent_compute_enabled: "{{ ceilometer_agent_compute_enabled_result.rc == 0 }}"
|
||||
- name: FFU stop and disable openstack-ceilometer-compute service
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- ceilometer_agent_compute_enabled|bool
|
||||
service: name=openstack-ceilometer-compute state=stopped enabled=no
|
||||
|
@ -139,21 +139,3 @@ outputs:
|
||||
mode: "{{ item.mode }}"
|
||||
with_items:
|
||||
- { 'path': /var/log/containers/ceilometer, 'setype': container_file_t, 'mode': '0750' }
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: FFU check if openstack-ceilometer-ipmi is enabled
|
||||
command: systemctl is-enabled openstack-ceilometer-ipmi
|
||||
failed_when: false
|
||||
register: ceilometer_ipmi_enabled_result
|
||||
- name: Set fact ceilometer_ipmi_enabled
|
||||
set_fact:
|
||||
ceilometer_ipmi_enabled: "{{ ceilometer_ipmi_enabled_result.rc == 0 }}"
|
||||
- name: FFU stop and disable openstack-ceilometer-ipmi service
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- ceilometer_ipmi_enabled|bool
|
||||
service: name=openstack-ceilometer-ipmi state=stopped enabled=no
|
||||
|
@ -225,21 +225,3 @@ outputs:
|
||||
tripleo_containers_to_stop:
|
||||
- ceilometer_agent_notification
|
||||
tripleo_delegate_to: "{{ groups['ceilometer_agent_notification'] | default([]) }}"
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: FFU check if openstack-ceilometer-notification is deployed
|
||||
command: systemctl is-enabled openstack-ceilometer-notification
|
||||
failed_when: false
|
||||
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: FFU stop and diable openstack-ceilometer-notification service
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- ceilometer_agent_notification_enabled|bool
|
||||
service: name=openstack-ceilometer-notification state=stopped enabled=no
|
||||
|
@ -44,7 +44,7 @@ parameters:
|
||||
Type of update, to differentiate between UPGRADE and UPDATE cases
|
||||
when StackAction is UPDATE (both are the same stack action).
|
||||
constraints:
|
||||
- allowed_values: ['', 'UPGRADE', 'FASTFORWARDUPGRADE']
|
||||
- allowed_values: ['', 'UPGRADE']
|
||||
default: ''
|
||||
NodeDataLookup:
|
||||
type: json
|
||||
|
@ -401,52 +401,6 @@ outputs:
|
||||
- cinder_api
|
||||
- cinder_api_cron
|
||||
tripleo_delegate_to: "{{ groups['cinder_api'] | default([]) }}"
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: Check is cinder_api is deployed
|
||||
command: systemctl is-enabled --quiet openstack-cinder-api
|
||||
failed_when: false
|
||||
register: cinder_api_enabled_result
|
||||
- name: Set fact cinder_api_enabled
|
||||
set_fact:
|
||||
cinder_api_enabled: "{{ cinder_api_enabled_result.rc == 0 }}"
|
||||
- name: Stop openstack-cinder-api
|
||||
service: name=openstack-cinder-api state=stopped
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- cinder_api_enabled|bool
|
||||
- name: Extra removal of services for cinder
|
||||
shell: |
|
||||
cinder-manage service list |\
|
||||
grep -v Binary | tr '@' ' ' |\
|
||||
awk '{print $1 " " $2}' |\
|
||||
while read i ; do cinder-manage service remove $i ; done
|
||||
when:
|
||||
- step|int == 5
|
||||
- release == 'stein'
|
||||
- is_bootstrap_node|bool
|
||||
- name: Extra migration for cinder
|
||||
command: cinder-manage db online_data_migrations
|
||||
when:
|
||||
- step|int == 5
|
||||
- release == 'stein'
|
||||
- is_bootstrap_node|bool
|
||||
- name: Cinder package update
|
||||
package:
|
||||
name: 'openstack-cinder*'
|
||||
state: latest
|
||||
when:
|
||||
- step|int == 6
|
||||
- is_bootstrap_node|bool
|
||||
- name: Cinder db sync
|
||||
command: cinder-manage db sync
|
||||
when:
|
||||
- step|int == 8
|
||||
- is_bootstrap_node|bool
|
||||
external_deploy_tasks:
|
||||
- name: Manage Cinder Volume Type
|
||||
become: true
|
||||
|
@ -408,33 +408,3 @@ outputs:
|
||||
when:
|
||||
- step|int == 3
|
||||
block: *cinder_backup_fetch_retag_container_tasks
|
||||
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
- is_bootstrap_node|bool
|
||||
block:
|
||||
- name: Check cluster resource status
|
||||
pacemaker_resource:
|
||||
resource: openstack-cinder-backup
|
||||
state: show
|
||||
check_mode: false
|
||||
failed_when: false
|
||||
register: cinder_backup_res_result
|
||||
- name: Set fact cinder_backup_res
|
||||
set_fact:
|
||||
cinder_backup_res: "{{ cinder_backup_res_result.rc == 0 }}"
|
||||
- name: Disable the openstack-cinder-backup cluster resource
|
||||
pacemaker_resource:
|
||||
resource: openstack-cinder-backup
|
||||
state: disable
|
||||
wait_for_resource: true
|
||||
register: cinder_backup_output
|
||||
retries: 5
|
||||
until: cinder_backup_output.rc == 0
|
||||
when:
|
||||
- step|int == 2
|
||||
- release == 'rocky'
|
||||
- is_bootstrap_node|bool
|
||||
- cinder_backup_res|bool
|
||||
|
@ -158,21 +158,3 @@ outputs:
|
||||
tripleo_containers_to_stop:
|
||||
- cinder_scheduler
|
||||
tripleo_delegate_to: "{{ groups['cinder_scheduler'] | default([]) }}"
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: Check if cinder_scheduler is deployed
|
||||
command: systemctl is-enabled --quiet openstack-cinder-scheduler
|
||||
failed_when: false
|
||||
register: cinder_scheduler_enabled_result
|
||||
- name: Set fact cinder_scheduler_enabled
|
||||
set_fact:
|
||||
cinder_scheduler_enabled: "{{ cinder_scheduler_enabled_result.rc == 0 }}"
|
||||
- name: Stop openstack-cinder-scheduler
|
||||
service: name=openstack-cinder-scheduler state=stopped enabled=no
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- cinder_scheduler_enabled|bool
|
||||
|
@ -362,21 +362,3 @@ outputs:
|
||||
when:
|
||||
- cvol_active_active_tls_enabled|bool
|
||||
- step|int == 3
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: Check if cinder_volume is deployed
|
||||
command: systemctl is-enabled --quiet openstack-cinder-volume
|
||||
failed_when: false
|
||||
register: cinder_volume_enabled_result
|
||||
- name: Set fact cinder_volume_enabled
|
||||
set_fact:
|
||||
cinder_volume_enabled: "{{ cinder_volume_enabled_result.rc == 0 }}"
|
||||
- name: Stop openstack-cinder-volume
|
||||
service: name=openstack-cinder-volume state=stopped enabled=no
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- cinder_volume_enabled|bool
|
||||
|
@ -402,33 +402,3 @@ outputs:
|
||||
pacemaker_resource:
|
||||
resource: openstack-cinder-volume
|
||||
state: enable
|
||||
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
- is_bootstrap_node|bool
|
||||
block:
|
||||
- name: Check cluster resource status
|
||||
pacemaker_resource:
|
||||
resource: openstack-cinder-volume
|
||||
state: show
|
||||
check_mode: false
|
||||
failed_when: false
|
||||
register: cinder_volume_res_result
|
||||
- name: Set fact cinder_volume_res
|
||||
set_fact:
|
||||
cinder_volume_res: "{{ cinder_volume_res_result.rc == 0 }}"
|
||||
- name: Disable the openstack-cinder-volume cluster resource
|
||||
pacemaker_resource:
|
||||
resource: openstack-cinder-volume
|
||||
state: disable
|
||||
wait_for_resource: true
|
||||
register: cinder_volume_output
|
||||
retries: 5
|
||||
until: cinder_volume_output.rc == 0
|
||||
when:
|
||||
- step|int == 2
|
||||
- release == 'rocky'
|
||||
- is_bootstrap_node|bool
|
||||
- cinder_volume_res|bool
|
||||
|
@ -307,26 +307,3 @@ outputs:
|
||||
- name: Check and upgrade Mysql database after major version upgrade
|
||||
command: "{{ container_cli }} exec -u root mysql mysql_upgrade"
|
||||
when: step|int == 2
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 6
|
||||
- release == 'rocky'
|
||||
- is_bootstrap_node|bool
|
||||
block:
|
||||
- name: Remove whitespaces in .my.cnf
|
||||
replace:
|
||||
path: /root/.my.cnf
|
||||
regexp: '^ +'
|
||||
replace: ''
|
||||
- name: Create cell0 db
|
||||
mysql_db:
|
||||
name: nova_cell0
|
||||
state: present
|
||||
login_unix_socket: '/var/lib/mysql/mysql.sock'
|
||||
- name: Grant access to cell0 db
|
||||
mysql_user:
|
||||
name: nova
|
||||
host_all: yes
|
||||
state: present
|
||||
priv: '*.*:ALL'
|
||||
login_unix_socket: '/var/lib/mysql/mysql.sock'
|
||||
|
@ -643,27 +643,3 @@ outputs:
|
||||
tripleo_transfer_dest_dir: /var/lib/mysql
|
||||
tripleo_transfer_dest_host: "{{hostvars[groups['overcloud'][0]]['mysql_short_bootstrap_node_name']}}"
|
||||
tripleo_transfer_flag_file: /var/lib/tripleo/transfer-flags/var-lib-mysql
|
||||
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 6
|
||||
- release == 'rocky'
|
||||
- is_bootstrap_node|bool
|
||||
block:
|
||||
- name: Remove whitespaces in .my.cnf
|
||||
replace:
|
||||
path: /root/.my.cnf
|
||||
regexp: '^ +'
|
||||
replace: ''
|
||||
- name: Create cell0 db
|
||||
mysql_db:
|
||||
name: nova_cell0
|
||||
state: present
|
||||
login_unix_socket: '/var/lib/mysql/mysql.sock'
|
||||
- name: Grant access to cell0 db
|
||||
mysql_user:
|
||||
name: nova
|
||||
host_all: yes
|
||||
state: present
|
||||
priv: '*.*:ALL'
|
||||
login_unix_socket: '/var/lib/mysql/mysql.sock'
|
||||
|
@ -490,33 +490,3 @@ outputs:
|
||||
when:
|
||||
- step|int == 3
|
||||
block: *redis_fetch_retag_container_tasks
|
||||
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
- is_bootstrap_node|bool
|
||||
block:
|
||||
- name: Check cluster resource status of redis
|
||||
pacemaker_resource:
|
||||
resource: {get_attr: [RedisBase, role_data, service_name]}
|
||||
state: show
|
||||
check_mode: false
|
||||
failed_when: false
|
||||
register: redis_res_result
|
||||
- name: Set fact redis_res
|
||||
set_fact:
|
||||
redis_res: "{{ redis_res_result.rc == 0 }}"
|
||||
- name: Disable the redis cluster resource
|
||||
pacemaker_resource:
|
||||
resource: {get_attr: [RedisBase, role_data, service_name]}
|
||||
state: disable
|
||||
wait_for_resource: true
|
||||
register: redis_output
|
||||
retries: 5
|
||||
until: redis_output.rc == 0
|
||||
when:
|
||||
- step|int == 2
|
||||
- release == 'rocky'
|
||||
- is_bootstrap_node|bool
|
||||
- redis_res|bool
|
||||
|
@ -213,33 +213,3 @@ outputs:
|
||||
with_items:
|
||||
- { 'path': /var/log/containers/sahara, 'setype': container_file_t, 'mode': '0750' }
|
||||
- { 'path': /var/lib/sahara, 'setype': container_file_t }
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: FFU check openstack-sahara-api is enabled
|
||||
command: systemctl is-enabled openstack-sahara-api
|
||||
failed_when: false
|
||||
register: sahara_api_enabled_result
|
||||
- name: Set fact sahara_api_enabled
|
||||
set_fact:
|
||||
sahara_api_enabled: "{{ sahara_api_enabled_result.rc == 0 }}"
|
||||
- name: FFU stop and disable openstack-sahara-api
|
||||
service: name=openstack-sahara-api state=stopped enabled=no
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- sahara_api_enabled|bool
|
||||
- name: FFU Sahara package update
|
||||
package:
|
||||
name: 'openstack-sahara*'
|
||||
state: latest
|
||||
when:
|
||||
- step|int == 6
|
||||
- is_bootstrap_node|bool
|
||||
- name: FFU Sahara db upgrade
|
||||
command: sahara-db-manage --config-file /etc/sahara/sahara.conf upgrade head
|
||||
when:
|
||||
- step|int == 8
|
||||
- is_bootstrap_node|bool
|
||||
|
@ -135,21 +135,3 @@ outputs:
|
||||
name: virt_sandbox_use_netlink
|
||||
persistent: yes
|
||||
state: yes
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: FFU check if openstack-sahara-engine is enabled
|
||||
command: systemctl is-enabled --quiet openstack-sahara-engine
|
||||
failed_when: false
|
||||
register: sahara_engine_enabled_result
|
||||
- name: Set fact sahara_engine_enabled
|
||||
set_fact:
|
||||
sahara_engine_enabled: "{{ sahara_engine_enabled_result.rc == 0 }}"
|
||||
- name: FFU stop and disable openstack-sahara-engine service
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- sahara_engine_enabled|bool
|
||||
service: name=openstack-sahara-engine state=stopped enabled=no
|
||||
|
@ -733,31 +733,3 @@ outputs:
|
||||
tripleo_containers_to_stop:
|
||||
- glance_api
|
||||
tripleo_delegate_to: "{{ groups['glance_api'] | default([]) }}"
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: Check if glance_api is deployed
|
||||
command: systemctl is-enabled --quiet openstack-glance-api
|
||||
failed_when: false
|
||||
register: glance_api_enabled_result
|
||||
- name: Set fact glance_api_enabled
|
||||
set_fact:
|
||||
glance_api_enabled: "{{ glance_api_enabled_result.rc == 0 }}"
|
||||
- name: Stop openstack-glance-api
|
||||
service: name=openstack-glance-api state=stopped enabled=no
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- glance_api_enabled|bool
|
||||
- name: glance package update
|
||||
package: name=openstack-glance state=latest
|
||||
when:
|
||||
- step|int == 6
|
||||
- is_bootstrap_node|bool
|
||||
- name: glance db sync
|
||||
command: glance-manage db_sync
|
||||
when:
|
||||
- step|int == 8
|
||||
- is_bootstrap_node|bool
|
||||
|
@ -397,67 +397,3 @@ outputs:
|
||||
tripleo_containers_to_stop:
|
||||
- gnocchi_api
|
||||
tripleo_delegate_to: "{{ groups['gnocchi_api'] | default([]) }}"
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: Check if httpd service is running
|
||||
command: systemctl is-active --quiet httpd
|
||||
tags: common
|
||||
failed_when: false
|
||||
register: httpd_running_result
|
||||
when:
|
||||
- httpd_running is undefined
|
||||
- name: Set fact httpd_running if unset
|
||||
set_fact:
|
||||
httpd_running: "{{ httpd_running_result.rc == 0 }}"
|
||||
when:
|
||||
- httpd_running is undefined
|
||||
- name: Check if gnocchi_api is deployed
|
||||
command: systemctl is-enabled --quiet openstack-gnocchi-api
|
||||
tags: common
|
||||
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: |-
|
||||
set -o pipefail
|
||||
httpd -t -D DUMP_VHOSTS | grep -q gnocchi
|
||||
register: gnocchi_httpd_enabled_result
|
||||
- name: Set fact gnocchi_httpd_enabled
|
||||
set_fact:
|
||||
gnocchi_httpd_enabled: "{{ gnocchi_httpd_enabled_result.rc == 0 }}"
|
||||
- name: Stop and disable gnocchi_api service
|
||||
service: name=openstack-gnocchi-api state=stopped enabled=no
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- gnocchi_api_enabled|bool
|
||||
- name: Stop and disable httpd service
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- gnocchi_httpd_enabled|bool
|
||||
- httpd_running|bool
|
||||
service: name=httpd state=stopped enabled=no
|
||||
- name: Update gnocchi packages
|
||||
package:
|
||||
name:
|
||||
- openstack-gnocchi*
|
||||
- numpy
|
||||
state: latest
|
||||
# (pradk): We have to explicitly update numpy as its obsoleted
|
||||
# by python2-numpy.
|
||||
when:
|
||||
- step|int == 6
|
||||
- is_bootstrap_node|bool
|
||||
- name: Sync gnocchi DB
|
||||
command: gnocchi-upgrade --skip-storage
|
||||
when:
|
||||
- step|int == 8
|
||||
- is_bootstrap_node|bool
|
||||
- gnocchi_api_enabled|bool
|
||||
|
@ -186,21 +186,3 @@ outputs:
|
||||
tripleo_containers_to_stop:
|
||||
- gnocchi_metricd
|
||||
tripleo_delegate_to: "{{ groups['gnocchi_metricd'] | default([]) }}"
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: FFU check if openstack-gnocchi-metricd is deployed
|
||||
command: systemctl is-enabled --quiet openstack-gnocchi-metricd
|
||||
failed_when: false
|
||||
register: gnocchi_metricd_enabled_result
|
||||
- name: Set fact gnocchi_metricd_enabled
|
||||
set_fact:
|
||||
gnocchi_metricd_enabled: "{{ gnocchi_metricd_enabled_result.rc == 0 }}"
|
||||
- name: FFU stop and disable openstack-gnocchi-metricd service
|
||||
service: name=openstack-gnocchi-metricd state=stopped enabled=no
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- gnocchi_metricd_enabled|bool
|
||||
|
@ -178,23 +178,3 @@ outputs:
|
||||
tripleo_containers_to_stop:
|
||||
- gnocchi_statsd
|
||||
tripleo_delegate_to: "{{ groups['gnocchi_statsd'] | default([]) }}"
|
||||
fast_forward_upgrade_tasks:
|
||||
- name: FFU check if openstack-gnocchi-statsd is deployed
|
||||
command: systemctl is-enabled --quiet openstack-gnocchi-statsd
|
||||
failed_when: false
|
||||
register: gnocchi_statsd_enabled_result
|
||||
when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
- name: Set fact gnocchi_statsd_enabled
|
||||
set_fact:
|
||||
gnocchi_statsd_enabled: "{{ gnocchi_statsd_enabled_result.rc == 0 }}"
|
||||
when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
- name: FFU stop and disable openstack-gnocchi-statsd service
|
||||
service: name=openstack-gnocchi-statsd state=stopped enabled=no
|
||||
when:
|
||||
- step|int == 2
|
||||
- release == 'rocky'
|
||||
- gnocchi_statsd_enabled|bool
|
||||
|
@ -236,21 +236,3 @@ outputs:
|
||||
tripleo_containers_to_stop:
|
||||
- heat_api_cfn
|
||||
tripleo_delegate_to: "{{ groups['heat_api_cfn'] | default([]) }}"
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: FFU check if openstack-heat-api-cfn service is enabled
|
||||
command: systemctl is-enabled openstack-heat-api-cfn
|
||||
failed_when: false
|
||||
register: heat_api_cfn_enabled_result
|
||||
- name: Set fact heat_api_cfn_enabled
|
||||
set_fact:
|
||||
heat_api_cfn_enabled: "{{ heat_api_cfn_enabled_result.rc == 0 }}"
|
||||
- name: FFU stop and disable openstack-heat-api-cfn service
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- heat_api_cfn_enabled|bool
|
||||
service: name=openstack-heat-api-cfn state=stopped enabled=no
|
||||
|
@ -37,27 +37,3 @@ outputs:
|
||||
value:
|
||||
service_name: heat_api_cloudwatch_disabled
|
||||
upgrade_tasks: []
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: FFU check if heat_api_cloudwatch is deployed
|
||||
command: systemctl is-enabled openstack-heat-api-cloudwatch
|
||||
failed_when: false
|
||||
register: heat_api_cloudwatch_enabled_result
|
||||
- name: Set fact heat_api_cloudwatch_enabled
|
||||
set_fact:
|
||||
heat_api_cloudwatch_enabled: "{{ heat_api_cloudwatch_enabled_result.rc == 0 }}"
|
||||
- name: FFU stop and disable the heat-api-cloudwatch service.
|
||||
service: name=openstack-heat-api-cloudwatch state=stopped enabled=no
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- heat_api_cloudwatch_enabled|bool
|
||||
- name: Remove heat_api_cloudwatch package
|
||||
package: name=openstack-heat-api-cloudwatch state=removed
|
||||
failed_when: false
|
||||
when:
|
||||
- step|int == 2
|
||||
- release == 'rocky'
|
||||
|
@ -298,33 +298,3 @@ outputs:
|
||||
- heat_api
|
||||
- heat_api_cron
|
||||
tripleo_delegate_to: "{{ groups['heat_api'] | default([]) }}"
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: FFU check openstack-heat-api is enabled
|
||||
command: systemctl is-enabled openstack-heat-api
|
||||
failed_when: false
|
||||
register: heat_api_enabled_result
|
||||
- name: Set fact heat_api_enabled
|
||||
set_fact:
|
||||
heat_api_enabled: "{{ heat_api_enabled_result.rc == 0 }}"
|
||||
- name: FFU stop and disable openstack-heat-api
|
||||
service: name=openstack-heat-api state=stopped enabled=no
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- heat_api_enabled|bool
|
||||
- name: FFU Heat package update
|
||||
package:
|
||||
name: 'openstack-heat*'
|
||||
state: latest
|
||||
when:
|
||||
- step|int == 6
|
||||
- is_bootstrap_node|bool
|
||||
- name: FFU Heat db-sync
|
||||
command: heat-manage db_sync
|
||||
when:
|
||||
- step|int == 8
|
||||
- is_bootstrap_node|bool
|
||||
|
@ -313,21 +313,3 @@ outputs:
|
||||
tripleo_containers_to_stop:
|
||||
- heat_engine
|
||||
tripleo_delegate_to: "{{ groups['heat_engine'] | default([]) }}"
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: FFU check if openstack-heat-engine is enabled
|
||||
command: systemctl is-enabled --quiet openstack-heat-engine
|
||||
failed_when: false
|
||||
register: heat_engine_enabled_result
|
||||
- name: Set fact heat_engine_enabled
|
||||
set_fact:
|
||||
heat_engine_enabled: "{{ heat_engine_enabled_result.rc == 0 }}"
|
||||
- name: FFU stop and disable openstack-heat-engine service
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- heat_engine_enabled|bool
|
||||
service: name=openstack-heat-engine state=stopped enabled=no
|
||||
|
@ -299,39 +299,3 @@ outputs:
|
||||
tags:
|
||||
- online_upgrade
|
||||
- online_upgrade_ironic
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: Check if ironic_api is deployed
|
||||
command: systemctl is-enabled --quiet openstack-ironic-api
|
||||
failed_when: false
|
||||
register: ironic_api_enabled_result
|
||||
- name: Set fact ironic_api_enabled
|
||||
set_fact:
|
||||
ironic_api_enabled: "{{ ironic_api_enabled_result.rc == 0 }}"
|
||||
- name: Stop openstack-ironic-api
|
||||
service: name=openstack-ironic-api state=stopped enabled=no
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- ironic_api_enabled|bool
|
||||
- name: Ironic package update
|
||||
package:
|
||||
name: 'openstack-ironic*'
|
||||
state: latest
|
||||
when:
|
||||
- step|int == 6
|
||||
- is_bootstrap_node|bool
|
||||
- name: Synchronize the database
|
||||
command: ironic-dbsync --config-file /etc/ironic/ironic.conf upgrade
|
||||
when:
|
||||
- step|int == 8
|
||||
- is_bootstrap_node|bool
|
||||
- name: Do online data migration
|
||||
command: ironic-dbsync --config-file /etc/ironic/ironic.conf online_data_migrations
|
||||
when:
|
||||
- step|int == 8
|
||||
- is_bootstrap_node|bool
|
||||
- release == 'stein'
|
||||
|
@ -636,28 +636,3 @@ outputs:
|
||||
- step|int == 0
|
||||
tags: common
|
||||
block: *ironic_config_data_cleanup
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: Check if ironic_conductor is deployed
|
||||
command: systemctl is-enabled --quiet openstack-ironic-conductor
|
||||
failed_when: false
|
||||
register: ironic_conductor_enabled_result
|
||||
- name: Set fact ironic_conductor_enabled
|
||||
set_fact:
|
||||
ironic_conductor_enabled: "{{ ironic_conductor_enabled_result.rc == 0 }}"
|
||||
- name: Stop openstack-ironic-conductor
|
||||
service: name=openstack-ironic-conductor state=stopped enabled=no
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- ironic_conductor_enabled|bool
|
||||
- name: Ironic packages update
|
||||
package:
|
||||
name: 'openstack-ironic*'
|
||||
state: latest
|
||||
when:
|
||||
- step|int == 6
|
||||
- is_bootstrap_node|bool
|
||||
|
@ -843,46 +843,3 @@ outputs:
|
||||
- keystone
|
||||
- keystone_cron
|
||||
tripleo_delegate_to: "{{ groups['keystone'] | default([]) }}"
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: Check for keystone running under apache
|
||||
tags: common
|
||||
shell: "httpd -t -D DUMP_VHOSTS | grep -q keystone_wsgi"
|
||||
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
|
||||
failed_when: false
|
||||
command: systemctl is-active --quiet httpd
|
||||
register: httpd_running_result
|
||||
when:
|
||||
- httpd_running is undefined
|
||||
- name: Set fact httpd_running if undefined
|
||||
set_fact:
|
||||
httpd_running: "{{ httpd_running_result.rc == 0 }}"
|
||||
when:
|
||||
- httpd_running is undefined
|
||||
- name: Stop and disable keystone (under httpd)
|
||||
service: name=httpd state=stopped enabled=no
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- keystone_httpd_enabled|bool
|
||||
- httpd_running|bool
|
||||
- name: Keystone package update
|
||||
package:
|
||||
name: 'openstack-keystone*'
|
||||
state: latest
|
||||
when:
|
||||
- step|int == 6
|
||||
- is_bootstrap_node|bool
|
||||
- name: keystone db sync
|
||||
command: keystone-manage db_sync
|
||||
when:
|
||||
- step|int == 8
|
||||
- is_bootstrap_node|bool
|
||||
|
@ -262,35 +262,3 @@ outputs:
|
||||
- { 'path': /var/log/containers/manila, 'setype': container_file_t, 'mode': '0750' }
|
||||
- { 'path': /var/log/containers/httpd/manila-api, 'setype': container_file_t, 'mode': '0750' }
|
||||
upgrade_tasks: []
|
||||
fast_forward_upgrade_tasks:
|
||||
- name: Check if manila_api is deployed
|
||||
command: systemctl is-enabled --quiet openstack-manila-api
|
||||
failed_when: false
|
||||
register: manila_api_enabled_result
|
||||
when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
- name: Set fact manila_api_enabled
|
||||
set_fact:
|
||||
manila_api_enabled: "{{ manila_api_enabled_result.rc == 0 }}"
|
||||
when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
- name: Stop openstack-manila-api
|
||||
service: name=openstack-manila-api state=stopped
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- manila_api_enabled|bool
|
||||
- name: manila package update
|
||||
package:
|
||||
name: 'openstack-manila*'
|
||||
state: latest
|
||||
when:
|
||||
- step|int == 6
|
||||
- is_bootstrap_node|bool
|
||||
- name: Manila db sync
|
||||
command: manila-manage db sync
|
||||
when:
|
||||
- step|int == 8
|
||||
- is_bootstrap_node|bool
|
||||
|
@ -117,23 +117,3 @@ outputs:
|
||||
persistent: yes
|
||||
state: yes
|
||||
upgrade_tasks: []
|
||||
fast_forward_upgrade_tasks:
|
||||
- name: Check if manila_scheduler is deployed
|
||||
command: systemctl is-enabled --quiet openstack-manila-scheduler
|
||||
failed_when: false
|
||||
register: manila_scheduler_enabled_result
|
||||
when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
- name: Set fact manila_scheduler_enabled
|
||||
set_fact:
|
||||
manila_scheduler_enabled: "{{ manila_scheduler_enabled_result.rc == 0 }}"
|
||||
when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
- name: Stop openstack-manila-scheduler
|
||||
service: name=openstack-manila-scheduler state=stopped enabled=no
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- manila_scheduler_enabled|bool
|
||||
|
@ -190,23 +190,3 @@ outputs:
|
||||
path: /etc/ceph
|
||||
state: directory
|
||||
upgrade_tasks: []
|
||||
fast_forward_upgrade_tasks:
|
||||
- name: Check if manila_share is deployed
|
||||
command: systemctl is-enabled --quiet openstack-manila-share
|
||||
failed_when: false
|
||||
register: manila_share_enabled_result
|
||||
when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
- name: Set fact manila_share_enabled
|
||||
set_fact:
|
||||
manila_share_enabled: "{{ manila_share_enabled_result.rc == 0 }}"
|
||||
when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
- name: Stop openstack-manila-share
|
||||
service: name=openstack-manila-share state=stopped enabled=no
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- manila_share_enabled|bool
|
||||
|
@ -374,36 +374,3 @@ outputs:
|
||||
when:
|
||||
- step|int == 3
|
||||
block: *manila_share_fetch_retag_container_tasks
|
||||
|
||||
fast_forward_upgrade_tasks:
|
||||
- name: Check cluster resource status
|
||||
pacemaker_resource:
|
||||
resource: openstack-manila-share
|
||||
state: show
|
||||
check_mode: false
|
||||
failed_when: false
|
||||
register: manila_share_res_result
|
||||
when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
- is_bootstrap_node|bool
|
||||
- name: Set fact manila_share_res
|
||||
set_fact:
|
||||
manila_share_res: "{{ manila_share_res_result.rc == 0 }}"
|
||||
when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
- is_bootstrap_node|bool
|
||||
- name: Disable the openstack-manila-share cluster resource
|
||||
pacemaker_resource:
|
||||
resource: openstack-manila-share
|
||||
state: disable
|
||||
wait_for_resource: true
|
||||
register: manila_share_output
|
||||
retries: 5
|
||||
until: manila_share_output.rc == 0
|
||||
when:
|
||||
- step|int == 2
|
||||
- release == 'rocky'
|
||||
- is_bootstrap_node|bool
|
||||
- manila_share_res|bool
|
||||
|
@ -210,22 +210,3 @@ outputs:
|
||||
tripleo_containers_to_stop:
|
||||
- memcached
|
||||
tripleo_delegate_to: "{{ groups['memcached'] | default([]) }}"
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: Check if memcached is deployed
|
||||
command: systemctl is-enabled --quiet memcached
|
||||
tags: common
|
||||
failed_when: false
|
||||
register: memcached_enabled_result
|
||||
- name: memcached_enabled
|
||||
set_fact:
|
||||
memcached_enabled: "{{ memcached_enabled_result.rc == 0 }}"
|
||||
- name: Stop and disable memcached service
|
||||
when:
|
||||
- step|int == 2
|
||||
- release == 'rocky'
|
||||
- memcached_enabled|bool
|
||||
service: name=memcached state=stopped enabled=no
|
||||
|
@ -740,21 +740,3 @@ outputs:
|
||||
import_role:
|
||||
name: tripleo_provision_mcelog
|
||||
when: {get_param: CollectdEnableMcelog}
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: Check if collectd.service is deployed
|
||||
command: systemctl is-enabled --quiet collectd.service
|
||||
failed_when: false
|
||||
register: collectd_enabled_result
|
||||
- name: Set fact collectd_enabled
|
||||
set_fact:
|
||||
collectd_enabled: "{{ collectd_enabled_result.rc == 0 }}"
|
||||
- name: Stop collectd service
|
||||
service: name=collectd.service state=stopped enabled=no
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- collectd_enabled|bool
|
||||
|
@ -569,40 +569,3 @@ outputs:
|
||||
tripleo_containers_to_stop:
|
||||
- neutron_api
|
||||
tripleo_delegate_to: "{{ groups['neutron_api'] | default([]) }}"
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: Check if neutron_server is deployed
|
||||
command: systemctl is-enabled --quiet neutron-server
|
||||
failed_when: false
|
||||
register: neutron_server_enabled_result
|
||||
- name: Set fact neutron_server_enabled
|
||||
set_fact:
|
||||
neutron_server_enabled: "{{ neutron_server_enabled_result.rc == 0 }}"
|
||||
- name: Stop neutron_server
|
||||
service: name=neutron-server state=stopped enabled=no
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- neutron_server_enabled|bool
|
||||
- when:
|
||||
- step|int == 6
|
||||
- is_bootstrap_node|bool
|
||||
block:
|
||||
- name: Neutron package update
|
||||
package:
|
||||
name: 'openstack-neutron*'
|
||||
state: latest
|
||||
- name: Neutron package update workaround
|
||||
package: name=python-networking-odl state=latest
|
||||
# package python-networking-cisco may or may not be present
|
||||
- name: Networking cisco db sync workaround
|
||||
failed_when: false
|
||||
package: name=python-networking-cisco state=latest
|
||||
- name: Neutron db sync
|
||||
command: neutron-db-manage upgrade head
|
||||
when:
|
||||
- step|int == 8
|
||||
- is_bootstrap_node|bool
|
||||
|
@ -439,24 +439,6 @@ outputs:
|
||||
mode: 0755
|
||||
content: {get_file: ./kill-script}
|
||||
upgrade_tasks: []
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: Check if neutron_dhcp_agent is deployed
|
||||
command: systemctl is-enabled --quiet neutron-dhcp-agent
|
||||
failed_when: false
|
||||
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: Stop neutron_dhcp_agent
|
||||
service: name=neutron-dhcp-agent state=stopped enabled=no
|
||||
when:
|
||||
- step|int == 2
|
||||
- release == 'rocky'
|
||||
- neutron_dhcp_agent_enabled|bool
|
||||
post_upgrade_tasks:
|
||||
- name: Check for neutron user
|
||||
getent:
|
||||
|
@ -394,24 +394,6 @@ outputs:
|
||||
mode: 0755
|
||||
content: {get_file: ./kill-script}
|
||||
upgrade_tasks: []
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: Check if neutron_l3_agent is deployed
|
||||
command: systemctl is-enabled --quiet neutron-l3-agent
|
||||
failed_when: false
|
||||
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: Stop neutron_l3_agent
|
||||
service: name=neutron-l3-agent state=stopped enabled=no
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- neutron_l3_agent_enabled|bool
|
||||
post_upgrade_tasks:
|
||||
- name: Check for neutron user
|
||||
getent:
|
||||
|
@ -210,24 +210,6 @@ outputs:
|
||||
persistent: yes
|
||||
state: yes
|
||||
upgrade_tasks: []
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: Check if neutron_metadata_agent is deployed
|
||||
command: systemctl is-enabled --quiet neutron-metadata-agent
|
||||
failed_when: false
|
||||
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: Stop neutron_metadata_agent
|
||||
service: name=neutron-metadata-agent state=stopped enabled=no
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- neutron_metadata_agent_enabled|bool
|
||||
post_upgrade_tasks:
|
||||
- name: Check for neutron user
|
||||
getent:
|
||||
|
@ -417,21 +417,3 @@ outputs:
|
||||
regexp=".*neutron-"
|
||||
state=absent
|
||||
when: step|int == 5
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: Check if neutron_ovs_agent is deployed
|
||||
command: systemctl is-enabled --quiet neutron-openvswitch-agent
|
||||
failed_when: false
|
||||
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: Stop neutron_openvswitch_agent
|
||||
service: name=neutron-openvswitch-agent state=stopped enabled=no
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- neutron_ovs_agent_enabled|bool
|
||||
|
@ -158,5 +158,3 @@ outputs:
|
||||
get_attr: [NeutronOvsAgent, role_data, upgrade_tasks]
|
||||
update_tasks:
|
||||
get_attr: [NeutronOvsAgent, role_data, update_tasks]
|
||||
fast_forward_upgrade_tasks:
|
||||
get_attr: [NeutronOvsAgent, role_data, fast_forward_upgrade_tasks]
|
||||
|
@ -507,152 +507,3 @@ outputs:
|
||||
- nova_api
|
||||
- nova_api_cron
|
||||
tripleo_delegate_to: "{{ groups['nova_api'] | default([]) }}"
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: Check if nova-api is deployed
|
||||
command: systemctl is-enabled --quiet openstack-nova-api
|
||||
failed_when: false
|
||||
register: nova_api_enabled_result
|
||||
- name: Set fact nova_api_enabled
|
||||
set_fact:
|
||||
nova_api_enabled: "{{ nova_api_enabled_result.rc == 0 }}"
|
||||
- name: Stop openstack-nova-api service
|
||||
service: name=openstack-nova-api state=stopped
|
||||
when:
|
||||
- step|int == 1
|
||||
- nova_api_enabled|bool
|
||||
- release == 'rocky'
|
||||
- name: Extra migration for nova tripleo/+bug/1656791
|
||||
command: nova-manage db online_data_migrations
|
||||
when:
|
||||
- step|int == 5
|
||||
- release == 'rocky'
|
||||
- is_bootstrap_node|bool
|
||||
- name: Update nova packages
|
||||
package:
|
||||
name: '*nova*'
|
||||
state: latest
|
||||
when:
|
||||
- step|int == 6
|
||||
- is_bootstrap_node|bool
|
||||
#FIXME(lyarwood): Use puppet to do this?
|
||||
- when:
|
||||
- step|int == 7
|
||||
- release == 'rocky'
|
||||
- is_bootstrap_node|bool
|
||||
block:
|
||||
- name: Create puppet manifest to set transport_url in nova.conf
|
||||
copy:
|
||||
dest: /root/nova-api_upgrade_manifest.pp
|
||||
mode: 0600
|
||||
content: >
|
||||
$transport_url = os_transport_url({
|
||||
'transport' => hiera('messaging_service_name', 'rabbit'),
|
||||
'hosts' => any2array(hiera('rabbitmq_node_names', undef)),
|
||||
'port' => sprintf('%s',hiera('nova::rabbit_port', '5672') ),
|
||||
'username' => hiera('nova::rabbit_userid', 'guest'),
|
||||
'password' => hiera('nova::rabbit_password'),
|
||||
'ssl' => sprintf('%s', bool2num(str2bool(hiera('nova::rabbit_use_ssl', '0'))))
|
||||
})
|
||||
oslo::messaging::default { 'nova_config':
|
||||
transport_url => $transport_url
|
||||
}
|
||||
|
||||
- name: Run puppet apply to set tranport_url in nova.conf
|
||||
command: puppet apply --modulepath /etc/puppet/modules:/opt/stack/puppet-modules:/usr/share/openstack-puppet/modules --detailed-exitcodes /root/nova-api_upgrade_manifest.pp
|
||||
register: puppet_apply_nova_api_upgrade
|
||||
failed_when: puppet_apply_nova_api_upgrade.rc not in [0,2]
|
||||
changed_when: puppet_apply_nova_api_upgrade.rc == 2
|
||||
- name: Setup cell_v2 (map cell0)
|
||||
shell:
|
||||
str_replace:
|
||||
template: nova-manage cell_v2 map_cell0 --database_connection='CELL0DB' --transport-url="'TRANSPORTURL'"
|
||||
params:
|
||||
CELL0DB:
|
||||
list_join:
|
||||
- ''
|
||||
- - '{scheme}'
|
||||
- '://'
|
||||
- '{username}'
|
||||
- ':'
|
||||
- '{password}'
|
||||
- '@'
|
||||
-
|
||||
if:
|
||||
- mysql_ipv6_use_ip_address
|
||||
- '[{hostname}]'
|
||||
- '{hostname}'
|
||||
- '/'
|
||||
- 'nova_cell0'
|
||||
- '?'
|
||||
- '{query}'
|
||||
TRANSPORTURL:
|
||||
list_join:
|
||||
- ''
|
||||
- - '{scheme}'
|
||||
- '://'
|
||||
- '{username}'
|
||||
- ':'
|
||||
- '{password}'
|
||||
- '@'
|
||||
- '{hostname}'
|
||||
- ':'
|
||||
- '{port}'
|
||||
- '/'
|
||||
- '?'
|
||||
- '{query}'
|
||||
- name: Setup cell_v2 (create default cell)
|
||||
# (owalsh) puppet-nova expects the cell name 'default'
|
||||
shell:
|
||||
str_replace:
|
||||
template: nova-manage cell_v2 create_cell --name='default' --database_connection='CELLDB'
|
||||
params:
|
||||
CELLDB:
|
||||
list_join:
|
||||
- ''
|
||||
- - '{scheme}'
|
||||
- '://'
|
||||
- '{username}'
|
||||
- ':'
|
||||
- '{password}'
|
||||
- '@'
|
||||
-
|
||||
if:
|
||||
- mysql_ipv6_use_ip_address
|
||||
- '[{hostname}]'
|
||||
- '{hostname}'
|
||||
- '/'
|
||||
- 'nova'
|
||||
- '?'
|
||||
- '{query}'
|
||||
register: nova_api_create_cell
|
||||
failed_when: nova_api_create_cell.rc not in [0,2]
|
||||
changed_when: nova_api_create_cell.rc == 0
|
||||
- name: Setup cell_v2 (sync nova/cell DB)
|
||||
command: nova-manage db sync
|
||||
async: {get_param: NovaDbSyncTimeout}
|
||||
poll: 10
|
||||
- name: Setup cell_v2 (get cell uuid)
|
||||
shell: nova-manage cell_v2 list_cells | sed -e '1,3d' -e '$d' | awk -F ' *| *' '$2 == "default" {print $4}'
|
||||
register: nova_api_cell_uuid
|
||||
- name: Setup cell_v2 (migrate hosts)
|
||||
command: nova-manage cell_v2 discover_hosts --cell_uuid {{nova_api_cell_uuid.stdout}} --verbose
|
||||
- name: Setup cell_v2 (migrate instances)
|
||||
command: nova-manage cell_v2 map_instances --cell_uuid {{nova_api_cell_uuid.stdout}}
|
||||
- when:
|
||||
- step|int == 8
|
||||
- is_bootstrap_node|bool
|
||||
block:
|
||||
- name: Sync nova/cell DB
|
||||
command: nova-manage db sync
|
||||
async: {get_param: NovaDbSyncTimeout}
|
||||
poll: 10
|
||||
when:
|
||||
- release == 'stein'
|
||||
- name: Sync nova_api DB
|
||||
command: nova-manage api_db sync
|
||||
- name: Online data migration for nova
|
||||
command: nova-manage db online_data_migrations
|
||||
|
@ -1193,27 +1193,3 @@ outputs:
|
||||
command: openstack compute service delete {{ nova_compute_service[0].ID }}
|
||||
delegate_to: localhost
|
||||
check_mode: no
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: Check if nova-compute is deployed
|
||||
command: systemctl is-enabled --quiet openstack-nova-compute
|
||||
failed_when: false
|
||||
register: nova_compute_enabled_result
|
||||
- name: Set fact nova_compute_enabled
|
||||
set_fact:
|
||||
nova_compute_enabled: "{{ nova_compute_enabled_result.rc == 0 }}"
|
||||
- when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: Stop and disable nova-compute service
|
||||
service: name=openstack-nova-compute state=stopped
|
||||
when:
|
||||
- nova_compute_enabled|bool
|
||||
- name: Set upgrade marker in nova statedir
|
||||
file: path=/var/lib/nova/upgrade_marker state=touch owner=nova group=nova
|
||||
when:
|
||||
- nova_compute_enabled|bool
|
||||
|
@ -226,21 +226,3 @@ outputs:
|
||||
tripleo_containers_to_stop:
|
||||
- nova_conductor
|
||||
tripleo_delegate_to: "{{ groups['nova_conductor'] | default([]) }}"
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: Check if nova_conductor is deployed
|
||||
command: systemctl is-enabled --quiet openstack-nova-conductor
|
||||
failed_when: false
|
||||
register: nova_conductor_enabled_result
|
||||
- name: Set fact nova_conductor_enabled
|
||||
set_fact:
|
||||
nova_conductor_enabled: "{{ nova_conductor_enabled_result.rc == 0 }}"
|
||||
- name: Stop and disable nova_conductor service
|
||||
service: name=openstack-nova-conductor state=stopped
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- nova_conductor_enabled|bool
|
||||
|
@ -223,27 +223,3 @@ outputs:
|
||||
persistent: yes
|
||||
state: yes
|
||||
external_post_deploy_tasks: {get_attr: [NovaComputeCommon, nova_compute_common_deploy_steps_tasks]}
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: Check if nova ironic is deployed
|
||||
command: systemctl is-enabled --quiet openstack-nova-compute
|
||||
tags: common
|
||||
register: nova_ironic_enabled_result
|
||||
- name: Set fact nova_ironic_enabled
|
||||
set_fact:
|
||||
nova_ironic_enabled: "{{ nova_ironic_enabled_result.rc == 0 }}"
|
||||
- name: Stop and disable nova-compute service
|
||||
service: name=openstack-nova-compute state=stopped
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- nova_ironic_enabled|bool
|
||||
- name: Set upgrade marker in nova statedir
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- nova_ironic_enabled|bool
|
||||
file: path=/var/lib/nova/upgrade_marker state=touch owner=nova group=nova
|
||||
|
@ -239,24 +239,6 @@ outputs:
|
||||
name: virt_sandbox_use_netlink
|
||||
persistent: yes
|
||||
state: yes
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: Check if nova_scheduler is deployed
|
||||
command: systemctl is-enabled --quiet openstack-nova-scheduler
|
||||
failed_when: false
|
||||
register: nova_scheduler_enabled_result
|
||||
- name: Set fact nova_scheduler_enabled
|
||||
set_fact:
|
||||
nova_scheduler_enabled: "{{ nova_scheduler_enabled_result.rc == 0 }}"
|
||||
- name: Stop and disable nova-scheduler service
|
||||
service: name=openstack-nova-scheduler state=stopped
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- nova_scheduler_enabled|bool
|
||||
external_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 1
|
||||
|
@ -85,7 +85,7 @@ parameters:
|
||||
Type of update, to differentiate between UPGRADE and UPDATE cases
|
||||
when StackAction is UPDATE (both are the same stack action).
|
||||
constraints:
|
||||
- allowed_values: ['', 'UPGRADE', 'FASTFORWARDUPGRADE']
|
||||
- allowed_values: ['', 'UPGRADE']
|
||||
default: ''
|
||||
|
||||
|
||||
@ -332,24 +332,6 @@ outputs:
|
||||
state: present
|
||||
shell: /sbin/nologin
|
||||
comment: qemu user
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: Check if nova vncproxy is deployed
|
||||
command: systemctl is-enabled --quiet openstack-nova-novncproxy
|
||||
failed_when: false
|
||||
register: nova_vncproxy_enabled_result
|
||||
- name: Set fact nova_vncproxy_enabled
|
||||
set_fact:
|
||||
nova_vncproxy_enabled: "{{ nova_vncproxy_enabled_result.rc == 0 }}"
|
||||
- name: Stop and disable nova-novncproxy service
|
||||
service: name=openstack-nova-novncproxy state=stopped
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- nova_vncproxy_enabled|bool
|
||||
external_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 1
|
||||
|
@ -443,33 +443,3 @@ outputs:
|
||||
when:
|
||||
- step|int == 3
|
||||
block: *rabbitmq_fetch_retag_container_tasks
|
||||
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
- is_bootstrap_node|bool
|
||||
block:
|
||||
- name: Check cluster resource status of rabbitmq
|
||||
pacemaker_resource:
|
||||
resource: {get_attr: [RabbitmqBase, role_data, service_name]}
|
||||
state: show
|
||||
check_mode: false
|
||||
failed_when: false
|
||||
register: rabbitmq_res_result
|
||||
- name: Set fact rabbitmq_res
|
||||
set_fact:
|
||||
rabbitmq_res: "{{ rabbitmq_res_result.rc == 0 }}"
|
||||
- name: Disable the rabbitmq cluster resource
|
||||
pacemaker_resource:
|
||||
resource: {get_attr: [RabbitmqBase, role_data, service_name]}
|
||||
state: disable
|
||||
wait_for_resource: true
|
||||
register: rabbitmq_output
|
||||
retries: 5
|
||||
until: rabbitmq_output.rc == 0
|
||||
when:
|
||||
- step|int == 2
|
||||
- release == 'rocky'
|
||||
- is_bootstrap_node|bool
|
||||
- rabbitmq_res|bool
|
||||
|
@ -430,33 +430,3 @@ outputs:
|
||||
when:
|
||||
- step|int == 3
|
||||
block: *rabbitmq_fetch_retag_container_tasks
|
||||
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
- is_bootstrap_node|bool
|
||||
block:
|
||||
- name: Check cluster resource status of rabbitmq
|
||||
pacemaker_resource:
|
||||
resource: {get_attr: [RabbitmqBase, role_data, service_name]}
|
||||
state: show
|
||||
check_mode: false
|
||||
failed_when: false
|
||||
register: rabbitmq_res_result
|
||||
- name: Set fact rabbitmq_res
|
||||
set_fact:
|
||||
rabbitmq_res: "{{ rabbitmq_res_result.rc == 0 }}"
|
||||
- name: Disable the rabbitmq cluster resource
|
||||
pacemaker_resource:
|
||||
resource: {get_attr: [RabbitmqBase, role_data, service_name]}
|
||||
state: disable
|
||||
wait_for_resource: true
|
||||
register: rabbitmq_output
|
||||
retries: 5
|
||||
until: rabbitmq_output.rc == 0
|
||||
when:
|
||||
- step|int == 2
|
||||
- release == 'rocky'
|
||||
- is_bootstrap_node|bool
|
||||
- rabbitmq_res|bool
|
||||
|
@ -449,33 +449,3 @@ outputs:
|
||||
when:
|
||||
- step|int == 3
|
||||
block: *rabbitmq_fetch_retag_container_tasks
|
||||
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
- is_bootstrap_node|bool
|
||||
block:
|
||||
- name: Check cluster resource status of rabbitmq
|
||||
pacemaker_resource:
|
||||
resource: {get_attr: [RabbitmqBase, role_data, service_name]}
|
||||
state: show
|
||||
check_mode: false
|
||||
failed_when: false
|
||||
register: rabbitmq_res_result
|
||||
- name: Set fact rabbitmq_res
|
||||
set_fact:
|
||||
rabbitmq_res: "{{ rabbitmq_res_result.rc == 0 }}"
|
||||
- name: Disable the rabbitmq cluster resource
|
||||
pacemaker_resource:
|
||||
resource: {get_attr: [RabbitmqBase, role_data, service_name]}
|
||||
state: disable
|
||||
wait_for_resource: true
|
||||
register: rabbitmq_output
|
||||
retries: 5
|
||||
until: rabbitmq_output.rc == 0
|
||||
when:
|
||||
- step|int == 2
|
||||
- release == 'rocky'
|
||||
- is_bootstrap_node|bool
|
||||
- rabbitmq_res|bool
|
||||
|
@ -481,25 +481,3 @@ outputs:
|
||||
when: swift_log_link.stat.islnk is defined and swift_log_link.stat.islnk
|
||||
metadata_settings:
|
||||
get_attr: [TLSProxyBase, role_data, metadata_settings]
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: Check if swift-proxy or swift-object-expirer are deployed
|
||||
command: systemctl is-enabled --quiet "{{ item }}"
|
||||
failed_when: false
|
||||
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: Stop swift-proxy and swift-object-expirer services
|
||||
service: name={{ item.item }} state=stopped enabled=no
|
||||
with_items: "{{ swift_proxy_services_enabled.results }}"
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- item.rc == 0
|
||||
|
@ -667,37 +667,3 @@ outputs:
|
||||
path: /var/log/containers/swift
|
||||
state: absent
|
||||
when: swift_log_link.stat.islnk is defined and swift_log_link.stat.islnk
|
||||
fast_forward_upgrade_tasks:
|
||||
- when:
|
||||
- step|int == 0
|
||||
- release == 'rocky'
|
||||
block:
|
||||
- name: Check if swift storage services are deployed
|
||||
command: systemctl is-enabled --quiet "{{ item }}"
|
||||
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
|
||||
failed_when: false
|
||||
register: swift_services_enabled_result
|
||||
- name: Set fact swift_services_enabled
|
||||
set_fact:
|
||||
swift_services_enabled: "{{ swift_services_enabled_result }}"
|
||||
- name: Stop swift storage services
|
||||
service: name={{ item.item }} state=stopped enabled=no
|
||||
with_items: "{{ swift_services_enabled.results }}"
|
||||
when:
|
||||
- step|int == 1
|
||||
- release == 'rocky'
|
||||
- item.rc == 0
|
||||
|
@ -34,23 +34,6 @@ parameters:
|
||||
default: 'false'
|
||||
description: Set to true to enable package installation at deploy time
|
||||
type: boolean
|
||||
FastForwardRepoType:
|
||||
default: 'tripleo-repos'
|
||||
type: string
|
||||
constraints:
|
||||
- allowed_values: ['tripleo-repos', 'custom-script']
|
||||
FastForwardRepoArgs:
|
||||
default: {'tripleo_repos': {'rocky': '-b rocky current', 'stein': '-b stein current', 'train': '-b train current'}}
|
||||
type: json
|
||||
FastForwardCustomRepoScriptContent:
|
||||
default: |
|
||||
#!/bin/bash
|
||||
set -e
|
||||
echo "If you use FastForwardRepoType 'custom-script' you have to provide the upgrade repo script content."
|
||||
echo "It will be installed as /root/ffu_upgrade_repo.sh on the node"
|
||||
echo "and passed the upstream name (rocky, stein, train) of the release as first argument"
|
||||
exit 1
|
||||
type: string
|
||||
UpgradeLeappEnabled:
|
||||
description: Use Leapp for operating system upgrade
|
||||
type: boolean
|
||||
@ -484,79 +467,3 @@ outputs:
|
||||
name: openvswitch
|
||||
enabled: yes
|
||||
state: started
|
||||
fast_forward_upgrade_tasks:
|
||||
- block:
|
||||
- name: set is_bootstrap_node fact
|
||||
set_fact: is_bootstrap_node={{tripleo_packages_short_bootstrap_node_name|lower == ansible_hostname|lower}}
|
||||
- name: Register repo type and args
|
||||
set_fact:
|
||||
fast_forward_repo_type: {get_param: FastForwardRepoType}
|
||||
fast_forward_repo_args: {get_param: FastForwardRepoArgs}
|
||||
- debug:
|
||||
msg: "fast_forward_repo_type: {{ fast_forward_repo_type }} fast_forward_repo_args: {{ fast_forward_repo_args }}"
|
||||
when:
|
||||
- step|int == 3
|
||||
- block:
|
||||
- name: clone tripleo-repos
|
||||
git:
|
||||
repo: https://github.com/openstack/tripleo-repos.git
|
||||
dest: /home/stack/tripleo-repos/
|
||||
- name: install tripleo-repos
|
||||
command: python setup.py install
|
||||
args:
|
||||
chdir: /home/stack/tripleo-repos/
|
||||
- name: Enable tripleo-repos
|
||||
command: "tripleo-repos {{ fast_forward_repo_args.tripleo_repos[release] }}"
|
||||
when:
|
||||
- step|int == 3
|
||||
- is_bootstrap_node|bool
|
||||
- fast_forward_repo_type == 'tripleo-repos'
|
||||
- block:
|
||||
- name: Create custom Script for upgrading repo.
|
||||
copy:
|
||||
dest: /root/ffu_update_repo.sh
|
||||
content: {get_param: FastForwardCustomRepoScriptContent}
|
||||
mode: 0700
|
||||
- name: Execute custom script for upgrading repo.
|
||||
shell: "/root/ffu_update_repo.sh {{release}}"
|
||||
when:
|
||||
- step|int == 3
|
||||
- is_bootstrap_node|bool
|
||||
- fast_forward_repo_type == 'custom-script'
|
||||
fast_forward_post_upgrade_tasks:
|
||||
- block:
|
||||
- name: Register repo type and args
|
||||
set_fact:
|
||||
fast_forward_repo_type: {get_param: FastForwardRepoType}
|
||||
fast_forward_repo_args: {get_param: FastForwardRepoArgs}
|
||||
- debug:
|
||||
msg: "fast_forward_repo_type: {{ fast_forward_repo_type }} fast_forward_repo_args: {{ fast_forward_repo_args }}"
|
||||
when:
|
||||
- step|int == 3
|
||||
- block:
|
||||
- name: clone tripleo-repos
|
||||
git:
|
||||
repo: https://github.com/openstack/tripleo-repos.git
|
||||
dest: /home/stack/tripleo-repos/
|
||||
- name: install tripleo-repos
|
||||
command: python setup.py install
|
||||
args:
|
||||
chdir: /home/stack/tripleo-repos/
|
||||
- name: Enable tripleo-repos
|
||||
command: "tripleo-repos {{ fast_forward_repo_args.tripleo_repos[release] }}"
|
||||
when:
|
||||
- step|int == 3
|
||||
- is_bootstrap_node|bool
|
||||
- fast_forward_repo_type == 'tripleo-repos'
|
||||
- block:
|
||||
- name: Create custom Script for upgrading repo.
|
||||
copy:
|
||||
dest: /root/ffu_update_repo.sh
|
||||
content: {get_param: FastForwardCustomRepoScriptContent}
|
||||
mode: 0700
|
||||
- name: Execute custom script for upgrading repo.
|
||||
shell: "/root/ffu_update_repo.sh {{release}}"
|
||||
when:
|
||||
- step|int == 3
|
||||
- is_bootstrap_node|bool
|
||||
- fast_forward_repo_type == 'custom-script'
|
||||
|
@ -7,5 +7,4 @@ resource_registry:
|
||||
OS::TripleO::Services::MongoDb: OS::Heat::None
|
||||
|
||||
parameter_defaults:
|
||||
StackUpdateType: FASTFORWARDUPGRADE
|
||||
NetworkDeploymentActions: ['CREATE','UPDATE']
|
||||
|
@ -0,0 +1,6 @@
|
||||
---
|
||||
deprecations:
|
||||
- |
|
||||
As the fast forward upgrade workflow to skip multiple releases now
|
||||
relies on the very same upgrade_tasks, there is no need to mantain
|
||||
the fast_forward_upgrade_tasks, as well as any of its references.
|
@ -57,8 +57,6 @@ REQUIRED_DOCKER_SECTIONS = ['service_name', 'docker_config', 'puppet_config',
|
||||
OPTIONAL_DOCKER_SECTIONS = ['container_puppet_tasks', 'upgrade_tasks',
|
||||
'deploy_steps_tasks',
|
||||
'pre_upgrade_rolling_tasks',
|
||||
'fast_forward_upgrade_tasks',
|
||||
'fast_forward_post_upgrade_tasks',
|
||||
'post_upgrade_tasks', 'update_tasks',
|
||||
'post_update_tasks', 'service_config_settings',
|
||||
'host_prep_tasks', 'metadata_settings',
|
||||
@ -102,8 +100,6 @@ REQUIRED_DOCKER_SECTIONS_OVERRIDES = {
|
||||
}
|
||||
# ansible tasks cannot be an empty dict or ansible is unhappy
|
||||
ANSIBLE_TASKS_SECTIONS = ['upgrade_tasks', 'pre_upgrade_rolling_tasks',
|
||||
'fast_forward_upgrade_tasks',
|
||||
'fast_forward_post_upgrade_tasks',
|
||||
'post_upgrade_tasks', 'update_tasks',
|
||||
'post_update_tasks', 'host_prep_tasks',
|
||||
'external_deploy_tasks',
|
||||
@ -803,16 +799,6 @@ def validate_docker_service(filename, tpl):
|
||||
print('ERROR: upgrade_tasks validation failed')
|
||||
return 1
|
||||
|
||||
if 'fast_forward_upgrade_tasks' in role_data and role_data['fast_forward_upgrade_tasks']:
|
||||
if validate_upgrade_tasks(role_data['fast_forward_upgrade_tasks']):
|
||||
print('ERROR: fast_forward_upgrade_tasks validation failed')
|
||||
return 1
|
||||
|
||||
if 'fast_forward_post_upgrade_tasks' in role_data and role_data['fast_forward_post_upgrade_tasks']:
|
||||
if validate_upgrade_tasks(role_data['fast_forward_post_upgrade_tasks']):
|
||||
print('ERROR: fast_forward_post_upgrade_tasks validation failed')
|
||||
return 1
|
||||
|
||||
if 'parameters' in tpl:
|
||||
for param in required_params:
|
||||
if param not in tpl['parameters']:
|
||||
@ -870,16 +856,6 @@ def validate_service(filename, tpl):
|
||||
print('ERROR: upgrade_tasks validation failed')
|
||||
return 1
|
||||
|
||||
if 'fast_forward_upgrade_tasks' in role_data and role_data['fast_forward_upgrade_tasks']:
|
||||
if validate_upgrade_tasks(role_data['fast_forward_upgrade_tasks']):
|
||||
print('ERROR: fast_forward_upgrade_tasks validation failed')
|
||||
return 1
|
||||
|
||||
if 'fast_forward_post_upgrade_tasks' in role_data and role_data['fast_forward_post_upgrade_tasks']:
|
||||
if validate_upgrade_tasks(role_data['fast_forward_post_upgrade_tasks']):
|
||||
print('ERROR: fast_forward_post_upgrade_tasks validation failed')
|
||||
return 1
|
||||
|
||||
if 'parameters' in tpl:
|
||||
for param in required_params:
|
||||
if param not in tpl['parameters']:
|
||||
|
@ -33,8 +33,6 @@
|
||||
upgrade_tasks
|
||||
post_upgrade_tasks
|
||||
external_upgrade_tasks
|
||||
fast_forward_upgrade_tasks
|
||||
fast_forward_post_upgrade_tasks
|
||||
# In the future this list shoud be extended to support
|
||||
# automatically any role definition in t-h-t/roles/*
|
||||
# Currently we have a --all option check allservices
|
||||
|
Loading…
Reference in New Issue
Block a user