Merge "Split upgrade_steps_playbook into different plays." into stable/stein

This commit is contained in:
Zuul 2019-09-06 17:55:41 +00:00 committed by Gerrit Code Review
commit b3a6ba0bdf
1 changed files with 47 additions and 33 deletions

View File

@ -693,19 +693,6 @@ outputs:
with_sequence: start=0 end={{pre_upgrade_rolling_steps_max-1}} with_sequence: start=0 end={{pre_upgrade_rolling_steps_max-1}}
loop_control: loop_control:
loop_var: step loop_var: step
{%- endfor %}
upgrade_steps_tasks: |
- name: ensure /var/lib/config-data exists
file:
path: /var/lib/config-data
state: directory
- name: ensure we get the right selinux context
command: chcon -R -t svirt_sandbox_file_t /var/lib/config-data
args:
warn: no
{%- for role in roles %}
- import_tasks: {{role.name}}/upgrade_tasks.yaml
when: tripleo_role_name == '{{role.name}}'
{%- endfor %} {%- endfor %}
upgrade_steps_playbook: upgrade_steps_playbook:
str_replace: str_replace:
@ -718,30 +705,57 @@ outputs:
DEPLOY_IDENTIFIER: {get_param: DeployIdentifier} DEPLOY_IDENTIFIER: {get_param: DeployIdentifier}
BOOTSTRAP_SERVER_ID: {get_attr: [BootstrapServerId, value]} BOOTSTRAP_SERVER_ID: {get_attr: [BootstrapServerId, value]}
ENABLE_DEBUG: {get_param: ConfigDebug} ENABLE_DEBUG: {get_param: ConfigDebug}
ENABLE_PUPPET: {get_param: EnablePuppet}
DOCKER_PUPPET_DEBUG: {get_param: DockerPuppetDebug}
DOCKER_PUPPET_PROCESS_COUNT: {get_param: DockerPuppetProcessCount}
DOCKER_PUPPET_MOUNT_HOST_PUPPET: {get_param: DockerPuppetMountHostPuppet}
template: | template: |
- hosts: DEPLOY_SOURCE_HOST
name: Gather facts from undercloud
gather_facts: yes
become: false
tags:
- facts
- hosts: DEPLOY_TARGET_HOST - hosts: DEPLOY_TARGET_HOST
any_errors_fatal: yes name: Gather facts from overcloud
gather_facts: yes
tags:
- facts
- hosts: all
name: Load global variables
gather_facts: {{ '"{{' }} gather_facts | default(false) {{ '}}"' }}
tasks: tasks:
- include_tasks: upgrade_steps_tasks.yaml - include_vars: global_vars.yaml
with_sequence: start=0 end={{upgrade_steps_max-1}} - name: ensure we get the right selinux context
vars: command: chcon -R -t svirt_sandbox_file_t /var/lib/config-data
bootstrap_server_id: BOOTSTRAP_SERVER_ID args:
deploy_identifier: DEPLOY_IDENTIFIER warn: no
enable_debug: ENABLE_DEBUG tags:
enable_puppet: ENABLE_PUPPET - always
container_cli: CONTAINER_CLI
container_log_stdout_path: CONTAINER_LOG_STDOUT_PATH {%- for step in range(0,upgrade_steps_max) %}
container_healthcheck_disabled: CONTAINER_HEALTHCHECK_DISABLED
docker_puppet_debug: DOCKER_PUPPET_DEBUG - hosts: DEPLOY_TARGET_HOST
docker_puppet_process_count: DOCKER_PUPPET_PROCESS_COUNT name: Upgrade tasks for step {{step}}
docker_puppet_mount_host_puppet: DOCKER_PUPPET_MOUNT_HOST_PUPPET gather_facts: {{ '"{{' }} gather_facts | default(false) {{ '}}"' }}
loop_control: any_errors_fatal: yes
loop_var: step vars:
bootstrap_server_id: BOOTSTRAP_SERVER_ID
step: '{{step}}'
deploy_identifier: DEPLOY_IDENTIFIER
enable_debug: ENABLE_DEBUG
container_cli: CONTAINER_CLI
container_log_stdout_path: CONTAINER_LOG_STDOUT_PATH
container_healthcheck_disabled: CONTAINER_HEALTHCHECK_DISABLED
tasks:
{%- for role in roles %}
- import_tasks: {{role.name}}/upgrade_tasks_step{{step}}.yaml
when: tripleo_role_name == '{{role.name}}'
tags: always tags: always
{%- endfor %}
tags:
- upgrade_steps
- upgrade_step{{step}}
{%- endfor %}
post_upgrade_steps_tasks: | post_upgrade_steps_tasks: |
{%- for role in roles %} {%- for role in roles %}
- import_tasks: {{role.name}}/post_upgrade_tasks.yaml - import_tasks: {{role.name}}/post_upgrade_tasks.yaml