Do undercloud container prepare in external_deploy_tasks

This change moves docker and docker-distribution installation from
step 1 to host_prep_tasks, then runs container prepare as
external_deploy_tasks.

Container image prepare needs to run before any steps which require
container images, and it always needs to run on the undercloud because
it only ever populates the undercloud registry. Docker needs to be
installed in host_prep_tasks, since it is just before
external_deploy_tasks step 1.

The aim is to move these prepare tasks into their own service file so
they can be run during undercloud install and overcloud deploy, as an
alternative to having a dedicated mistral action for the overcloud
prepare.

Change-Id: I2c82b6829e574424067130d1a369ff30030fb4bc
Blueprint: container-prepare-workflow
This commit is contained in:
Steve Baker 2018-07-12 11:25:06 +12:00
parent 697b1d9438
commit e2148a5167
2 changed files with 6 additions and 6 deletions

@ -60,10 +60,8 @@ outputs:
- 8787 - 8787
- 13787 - 13787
step_config: '' step_config: ''
host_prep_tasks: [] host_prep_tasks:
deploy_steps_tasks:
- name: Install, Configure and Run Docker Distribution - name: Install, Configure and Run Docker Distribution
when: step|int == 1
block: block:
# NOTE(bogdando): w/a https://github.com/ansible/ansible/issues/42621 # NOTE(bogdando): w/a https://github.com/ansible/ansible/issues/42621
- set_fact: - set_fact:
@ -77,6 +75,10 @@ outputs:
- include_role: - include_role:
name: container-registry name: container-registry
tasks_from: docker-distribution tasks_from: docker-distribution
external_deploy_tasks:
- name: Container image prepare
when: step|int == 1
block:
- name: Create temp file for prepare parameter - name: Create temp file for prepare parameter
tempfile: tempfile:
state: file state: file

@ -80,10 +80,8 @@ outputs:
service_name: docker service_name: docker
config_settings: {} config_settings: {}
step_config: '' step_config: ''
host_prep_tasks: [] host_prep_tasks:
deploy_steps_tasks:
- name: Install, Configure and Run Docker - name: Install, Configure and Run Docker
when: step|int == 1
block: block:
# NOTE(bogdando): w/a https://github.com/ansible/ansible/issues/42621 # NOTE(bogdando): w/a https://github.com/ansible/ansible/issues/42621
- set_fact: &docker_vars - set_fact: &docker_vars