f791f5b3cd
When pipe is added to command, it should still exit with its result code, so save it by setting pipeline option before each command. Close-Bug: #1676156 Change-Id: Ibbe49b4a15a5b7825447a563fe35af85fd48b3ff
28 lines
914 B
YAML
28 lines
914 B
YAML
---
|
|
- name: Upgrade the undercloud
|
|
shell: >
|
|
set -o pipefail &&
|
|
{{ upgrade_working_dir }}/undercloud-upgrade.sh 2>&1 {{ timestamper_cmd }} >
|
|
{{ undercloud_upgrade_log }}
|
|
when: step_upgrade_undercloud
|
|
notify:
|
|
- restart openstack services
|
|
|
|
- name: create vlan if doesn't exist
|
|
ignore_errors: yes
|
|
become: yes
|
|
shell: >
|
|
ifconfig {{ network_isolation_vlan }};
|
|
if [[ $? != 0 ]]; then \
|
|
ovs-vsctl add-port br-ctlplane {{ network_isolation_vlan }} tag={{ network_isolation_vlan_tag }} \
|
|
-- set interface {{ network_isolation_vlan }} type=internal;
|
|
fi
|
|
when: network_isolation|bool and deployment_type == "virtual"
|
|
|
|
- name: set vlan up
|
|
ignore_errors: yes
|
|
become: yes
|
|
shell: >
|
|
ip l set dev {{ network_isolation_vlan }} up; ip addr add {{ network_isolation_ipv4_cidr }} dev {{ network_isolation_vlan }};
|
|
when: network_isolation|bool and deployment_type == "virtual"
|