Properly place undercloud hosts record upgrade task
Undercloud record for hosts has to be in all the nodes that fetch
images from it. Proper location for this code is where we set up
podman. If it's only in ContainerImagesPrepare it runs on the
Controller role only.
Closes-Bug: #1871243
Change-Id: Id081f049bca6c961ad2ff649ac357cea8d552739
(cherry picked from commit fff8cf73c6
)
This commit is contained in:
parent
5323f2033e
commit
0d783d38e2
|
@ -132,12 +132,3 @@ outputs:
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
when:
|
when:
|
||||||
- (step | int) == 1
|
- (step | int) == 1
|
||||||
upgrade_tasks:
|
|
||||||
- name: Make sure the Undercloud hostname is included in /etc/hosts
|
|
||||||
when:
|
|
||||||
- step|int == 1
|
|
||||||
- undercloud_hosts_entries is defined
|
|
||||||
lineinfile:
|
|
||||||
dest: /etc/hosts
|
|
||||||
line: "{{ '{{ ' }} undercloud_hosts_entries | join('') {{ ' }}' }}"
|
|
||||||
state: present
|
|
||||||
|
|
|
@ -160,6 +160,13 @@ outputs:
|
||||||
when:
|
when:
|
||||||
- step|int == 1
|
- step|int == 1
|
||||||
block:
|
block:
|
||||||
|
- name: Make sure the Undercloud hostname is included in /etc/hosts
|
||||||
|
when:
|
||||||
|
- undercloud_hosts_entries is defined
|
||||||
|
lineinfile:
|
||||||
|
dest: /etc/hosts
|
||||||
|
line: "{{ undercloud_hosts_entries | join('') }}"
|
||||||
|
state: present
|
||||||
- name: Set container_registry_insecure_registries fact.
|
- name: Set container_registry_insecure_registries fact.
|
||||||
set_fact:
|
set_fact:
|
||||||
container_registry_insecure_registries:
|
container_registry_insecure_registries:
|
||||||
|
|
Loading…
Reference in New Issue