Merge "Add network_config_hook interface to run-os-net-config.sh"
This commit is contained in:
commit
3de4f828b4
|
@ -113,11 +113,17 @@ if [ -n '$network_config' ]; then
|
|||
mkdir -p /etc/os-net-config
|
||||
# Note these variables come from the calling heat SoftwareConfig
|
||||
echo '$network_config' > /etc/os-net-config/config.json
|
||||
|
||||
if [ "$(type -t network_config_hook)" = "function" ]; then
|
||||
network_config_hook
|
||||
fi
|
||||
|
||||
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
|
||||
|
||||
os-net-config -c /etc/os-net-config/config.json -v --detailed-exit-codes
|
||||
RETVAL=$?
|
||||
|
||||
if [[ $RETVAL == 2 ]]; then
|
||||
ping_metadata_ip
|
||||
|
||||
|
|
Loading…
Reference in New Issue