before: PUB_IP=$( ip route ... after: PUB_IP=$(ip route ...
Signed-off-by: Liu Yinsi liuyinsi@163.com --- lib/bootstrap.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lib/bootstrap.sh b/lib/bootstrap.sh index b04ea3dd4..1127de140 100755 --- a/lib/bootstrap.sh +++ b/lib/bootstrap.sh @@ -287,7 +287,7 @@ export_ip_mac() { if has_cmd ip; then export PUB_NIC=$(ip route get 1.2.3.4 | awk '{print $5; exit}') - export PUB_IP=$( ip route get 1.2.3.4 | awk '{print $7; exit}') + export PUB_IP=$(ip route get 1.2.3.4 | awk '{print $7; exit}') elif has_cmd route; then export PUB_NIC=$(route -n | awk '/[UG][UG]/ {print $8}') export PUB_IP=$(ifconfig $PUB_NIC | awk '/inet / {print $2}')