add git timeout setting for clone_repo.sh
Use GIT_HTTP_LOW_SPEED_TIME as a way to time out the git operations talking to remote servers. Change-Id: I1d828cf629d5370995b2b88eb8e9763438b03aae Signed-off-by: Doug Hellmann <doug@doughellmann.com>
This commit is contained in:
parent
37fa66d282
commit
ca1672c0c4
@ -67,8 +67,10 @@ CACHE_DIR="${ZUUL_CACHE_DIR:-/opt/git}"
|
||||
BRANCH="master"
|
||||
REF=""
|
||||
UPSTREAM="https://git.openstack.org"
|
||||
export GIT_HTTP_LOW_SPEED_TIME=300
|
||||
export GIT_HTTP_LOW_SPEED_LIMIT=1000
|
||||
|
||||
OPTS=`getopt -o h --long branch:,cache-dir:,ref:,upstream:,workspace: -n $0 -- "$@"`
|
||||
OPTS=`getopt -o h --long branch:,cache-dir:,ref:,timeout:,upstream:,workspace: -n $0 -- "$@"`
|
||||
if [ $? != 0 ] ; then
|
||||
echo "Failed parsing options." >&2
|
||||
print_help
|
||||
@ -96,6 +98,11 @@ while true; do
|
||||
shift
|
||||
shift
|
||||
;;
|
||||
--timeout)
|
||||
GIT_HTTP_LOW_SPEED_TIME="$2"
|
||||
shift
|
||||
shift
|
||||
;;
|
||||
--upstream)
|
||||
UPSTREAM="$2"
|
||||
shift
|
||||
|
Loading…
x
Reference in New Issue
Block a user