diff options
| author | Zuul <zuul@review.opendev.org> | 2023-01-17 10:47:31 +0000 |
|---|---|---|
| committer | Gerrit Code Review <review@openstack.org> | 2023-01-17 10:47:31 +0000 |
| commit | d34ae7edb17eda7e4a2b6c4e0989ce2cebf116a5 (patch) | |
| tree | 2a52ce9c6ddf832d8dbc9f1d0439727cecc96ea5 | |
| parent | a8732d80fb020743fd72a2b68092df1b5c93bc02 (diff) | |
| parent | 2e4ab0287352a623e275fe703ed76305e1fbfd82 (diff) | |
| download | kolla-d34ae7edb17eda7e4a2b6c4e0989ce2cebf116a5.tar.gz kolla-d34ae7edb17eda7e4a2b6c4e0989ce2cebf116a5.zip | |
Merge "relay non-zero exit codes when creating openvswitch bridges" into stable/zed
| -rw-r--r-- | docker/openvswitch/openvswitch-db-server/ovs_ensure_configured.sh | 7 | ||||
| -rw-r--r-- | releasenotes/notes/bug-1999778.yaml | 7 |
2 files changed, 10 insertions, 4 deletions
diff --git a/docker/openvswitch/openvswitch-db-server/ovs_ensure_configured.sh b/docker/openvswitch/openvswitch-db-server/ovs_ensure_configured.sh index c91f87172..6fada1031 100644 --- a/docker/openvswitch/openvswitch-db-server/ovs_ensure_configured.sh +++ b/docker/openvswitch/openvswitch-db-server/ovs_ensure_configured.sh @@ -1,16 +1,15 @@ #!/bin/bash +set -o errexit bridge=$1 port=$2 -ip link show $port -if [[ $? -ne 0 ]]; then +if ! ip link show $port; then # fail when device doesn't exist exit 1 fi -ovs-vsctl br-exists $bridge -if [[ $? -eq 2 ]]; then +ovs-vsctl br-exists $bridge || if [[ $? -eq 2 ]]; then changed=changed ovs-vsctl --no-wait add-br $bridge fi diff --git a/releasenotes/notes/bug-1999778.yaml b/releasenotes/notes/bug-1999778.yaml new file mode 100644 index 000000000..bb45d0082 --- /dev/null +++ b/releasenotes/notes/bug-1999778.yaml @@ -0,0 +1,7 @@ +--- +fixes: + - | + Fixes an issue where the script ``kolla_ensure_openvswitch_configured`` in + the ``openvswitch-db-server`` image would ignore errors encountered while + configuring bridges and ports. + `LP#1999778 <https://launchpad.net/bugs/1999778>`__ |
