mirror of
https://github.com/vdsm/virtual-dsm.git
synced 2025-06-08 17:37:58 +08:00
IP Discovery
This commit is contained in:
parent
17c1ea794f
commit
fd7d66be1e
@ -53,7 +53,7 @@ else
|
|||||||
echo "INFO=\$(curl -s -m 2 -S http://127.0.0.1:2210/read?command=10 2>/dev/null)"
|
echo "INFO=\$(curl -s -m 2 -S http://127.0.0.1:2210/read?command=10 2>/dev/null)"
|
||||||
echo "rest=\${INFO#*http_port}; rest=\${rest#*:}; rest=\${rest%%,*}; PORT=\${rest%%\\\"*}"
|
echo "rest=\${INFO#*http_port}; rest=\${rest#*:}; rest=\${rest%%,*}; PORT=\${rest%%\\\"*}"
|
||||||
echo "rest=\${INFO#*eth0}; rest=\${rest#*ip}; rest=\${rest#*:}; rest=\${rest#*\\\"}; IP=\${rest%%\\\"*}"
|
echo "rest=\${INFO#*eth0}; rest=\${rest#*ip}; rest=\${rest#*:}; rest=\${rest#*\\\"}; IP=\${rest%%\\\"*}"
|
||||||
echo "HTML=\"$HTML\"; [ -z \"\${IP}\" ] && BODY=\"$BODY\" || BODY=\"$WAIT\"; HTML=\${HTML/xxx/\$BODY}"
|
echo "HTML=\"$HTML\"; [ -z \"\${IP}\" ] && BODY=\"$WAIT\" || BODY=\"$BODY\"; HTML=\${HTML/xxx/\$BODY}"
|
||||||
echo "printf '%b' \"HTTP/1.1 200 OK\\nContent-Length: \${#HTML}\\nConnection: close\\n\\n\$HTML\""
|
echo "printf '%b' \"HTTP/1.1 200 OK\\nContent-Length: \${#HTML}\\nConnection: close\\n\\n\$HTML\""
|
||||||
} > "$TMP_FILE"
|
} > "$TMP_FILE"
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user