make 170-setup-gateway idempotent

Before if we tried to add an address that was already added to the
br-ex device the script would error out. Now, use replace which is
idempotent.

Change-Id: I34bbb361c4fa2f347431629f79753f75b458926f
This commit is contained in:
Dustin Specker 2022-07-22 09:07:35 -05:00
parent c4101e3323
commit 1aadb948aa
1 changed files with 1 additions and 1 deletions

View File

@ -16,7 +16,7 @@ set -xe
# Assign IP address to br-ex
: ${OSH_EXT_SUBNET:="172.24.4.0/24"}
: ${OSH_BR_EX_ADDR:="172.24.4.1/24"}
sudo ip addr add ${OSH_BR_EX_ADDR} dev br-ex
sudo ip addr replace ${OSH_BR_EX_ADDR} dev br-ex
sudo ip link set br-ex up
: ${DNSMASQ_IMAGE:=docker.io/openstackhelm/neutron:xena-ubuntu_focal}