shorten connection timeout for http interactions with containers
This issue came to light in the context of `weave launch`. When the weaver container died after we've completed network configuration, it would take a minute for the script to terminate, due to `curl` being stuck in a connection attempt. Fixes #538.
This commit is contained in:
1 parent
db302a0d3d
commit
0799d9f70b
1 file changed
+1
-1
@@ -429,7 +429,7 @@ http_call_ip() {
|
|||||||
http_verb="$3"
|
http_verb="$3"
|
||||||
url="$4"
|
url="$4"
|
||||||
shift 4
|
shift 4
|
||||||
curl -s -X $http_verb "$@" http://$ip:$port$url
|
curl --connect-timeout 3 -s -X $http_verb "$@" http://$ip:$port$url
|
||||||
}
|
}
|
||||||
|
|
||||||
# Perform operation $1 on container ID $2 to local DNS database at address $3
|
# Perform operation $1 on container ID $2 to local DNS database at address $3
|
||||||
|
|||||||
Reference in new issue
Block a user