projects
/
mirror
/
dsa-puppet.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
8ce239a
)
Handle ConnectTimeout the same as ReadTimeout for mirror-health
author
Tollef Fog Heen
<tfheen@err.no>
Tue, 12 Dec 2017 21:25:14 +0000
(22:25 +0100)
committer
Tollef Fog Heen
<tfheen@err.no>
Tue, 12 Dec 2017 21:25:14 +0000
(22:25 +0100)
modules/roles/files/mirror_health/mirror-health
patch
|
blob
|
history
diff --git
a/modules/roles/files/mirror_health/mirror-health
b/modules/roles/files/mirror_health/mirror-health
index
a4df165
..
5770366
100755
(executable)
--- a/
modules/roles/files/mirror_health/mirror-health
+++ b/
modules/roles/files/mirror_health/mirror-health
@@
-43,11
+43,11
@@
def check_uptodate():
lm = last_modified(retrieve_from_host(host, URL))
logging.debug("lm for host %s: %s", host, lm)
latest_ts = max(latest_ts, lm)
lm = last_modified(retrieve_from_host(host, URL))
logging.debug("lm for host %s: %s", host, lm)
latest_ts = max(latest_ts, lm)
- except (requests.exceptions.ProxyError, requests.exceptions.ReadTimeout):
+ except (requests.exceptions.ProxyError, requests.exceptions.ReadTimeout
, requests.exceptions.ConnectTimeout
):
pass
try:
local_lm = last_modified(retrieve_from_host('localhost', URL))
pass
try:
local_lm = last_modified(retrieve_from_host('localhost', URL))
- except (requests.exceptions.ProxyError, requests.exceptions.ReadTimeout):
+ except (requests.exceptions.ProxyError, requests.exceptions.ReadTimeout
, requests.exceptions.ConnectTimeout
):
return False
logging.debug("lm for localhost: %s", local_lm)
if local_lm < latest_ts:
return False
logging.debug("lm for localhost: %s", local_lm)
if local_lm < latest_ts: