jenkins-community-slave: verify HTTPS certificate in head() request

Fixes a warning:

/usr/local/lib/python3.7/dist-packages/urllib3/connectionpool.py:1004: InsecureRequestWarning: Unverified HTTPS request is being made to host 'build.ffh.zone'. Adding certificate verification is strongly advised. See: https://urllib3.readthedocs.io/en/latest/advanced-usage.html#ssl-warnings
This commit is contained in:
Matthias Schiffer 2020-05-30 02:24:16 +02:00 committed by Martin Weinelt
parent 7fdffcaa1c
commit 5232428b19

View File

@ -70,7 +70,7 @@ if os.environ.get('SLAVE_SECRET') is None:
def master_ready(url):
try:
r = requests.head(url, verify=False, timeout=None)
r = requests.head(url, timeout=None)
return r.status_code == requests.codes.ok
except:
return False