Code Review
/
apex.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
Merge "Add API network support"
[apex.git]
/
lib
/
common-functions.sh
diff --git
a/lib/common-functions.sh
b/lib/common-functions.sh
index
dfac008
..
6b259ac
100644
(file)
--- a/
lib/common-functions.sh
+++ b/
lib/common-functions.sh
@@
-18,7
+18,7
@@
function find_ip {
return 1
fi
return 1
fi
- python3.4 -B $
CONFIG/lib/python/apex-python-utils.py find_
ip -i $1
+ python3.4 -B $
LIB/python/apex-python-utils.py find-
ip -i $1
}
##attach interface to OVS and set the network config correctly
}
##attach interface to OVS and set the network config correctly
@@
-154,7
+154,7
@@
function detach_interface_from_ovs {
if_dns2=$(sed -n 's/^DNS2=\(.*\)$/\1/p' ${net_path}/ifcfg-${bridge})
if [ -z "$if_mask" ]; then
if_dns2=$(sed -n 's/^DNS2=\(.*\)$/\1/p' ${net_path}/ifcfg-${bridge})
if [ -z "$if_mask" ]; then
- if_prefix=$(sed -n 's/^PREFIX=
\(.*\)
$/\1/p' ${net_path}/ifcfg-${bridge})
+ if_prefix=$(sed -n 's/^PREFIX=
[^0-9]*\([0-9][0-9]*\)[^0-9]*
$/\1/p' ${net_path}/ifcfg-${bridge})
if_mask=$(prefix2mask ${if_prefix})
fi
if_mask=$(prefix2mask ${if_prefix})
fi