aboutsummaryrefslogtreecommitdiffstats
path: root/network
diff options
context:
space:
mode:
authorJenkins <jenkins@review.openstack.org>2017-01-19 10:53:00 +0000
committerGerrit Code Review <review@openstack.org>2017-01-19 10:53:00 +0000
commitab66969ad181ac2c1451ceec21e83fa02a35d6a1 (patch)
treef7e27c88389973c15adcc2cf6a851290860cdfe6 /network
parentecb482f85c737374031934230dfe9a610860fb6d (diff)
parent22ffadd3258c258069b9f4b9df140a6d4b1a5f8d (diff)
Merge "set -e in run-os-net-config.sh"
Diffstat (limited to 'network')
-rwxr-xr-xnetwork/scripts/run-os-net-config.sh6
1 files changed, 5 insertions, 1 deletions
diff --git a/network/scripts/run-os-net-config.sh b/network/scripts/run-os-net-config.sh
index a7dbedc7..8fe2d270 100755
--- a/network/scripts/run-os-net-config.sh
+++ b/network/scripts/run-os-net-config.sh
@@ -10,7 +10,7 @@
# a deployment input via input_values
# $network_config : the json serialized os-net-config config to apply
#
-set -ux
+set -eux
function get_metadata_ip() {
@@ -98,8 +98,10 @@ EOF_CAT
fi
fi
done
+ set +e
os-net-config -c /etc/os-net-config/dhcp_all_interfaces.yaml -v --detailed-exit-codes --cleanup
RETVAL=$?
+ set -e
if [[ $RETVAL == 2 ]]; then
ping_metadata_ip
elif [[ $RETVAL != 0 ]]; then
@@ -123,8 +125,10 @@ if [ -n '$network_config' ]; then
sed -i "s/bridge_name/${bridge_name:-''}/" /etc/os-net-config/config.json
sed -i "s/interface_name/${interface_name:-''}/" /etc/os-net-config/config.json
+ set +e
os-net-config -c /etc/os-net-config/config.json -v --detailed-exit-codes
RETVAL=$?
+ set -e
if [[ $RETVAL == 2 ]]; then
ping_metadata_ip