-
Notifications
You must be signed in to change notification settings - Fork 27
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
https support? #16
Comments
It also works with HTTPS. Do you have a log message for me? |
Alright, it seems to be related to certificate verification. Custom enterprise CA. |
Additional information: Ubuntu 16.04 Playbook:
Debug messages:
As I mentioned, i.e. the below playbook works fine, uses the same https://.
|
I just confirmed by setting validate_certs: False, then the playbook ran fine. |
The module uses the requests library as many other Ansible modules. It should respect your local certificate store. Could you please try this in your Python console? import requests
url = "<your checkmk URL>"
r = requests.get(url)
r.status_code
r = requests.get(url, verify=True)
r.status_code
r = requests.get(url, verify=False)
r.status_code |
Python 2.7.12 (default, Nov 12 2018, 14:36:49)
[GCC 5.4.0 20160609] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import requests
url = "https://checkmk-dev01.mgmt.example.com"
>>> url = "https://checkmk-dev01.mgmt.example.com"
>>> r = requests.get(url)
>>> r.status_code
200
>>> r = requests.get(url, verify=True)
>>> r.status_code
200
>>> r = requests.get(url, verify=False)
/var/lib/awx/venv/ansible/local/lib/python2.7/site-packages/urllib3/connectionpool.py:847: InsecureRequestWarning: Unverified HTTPS request is being made. Adding certificate verification is strongly advised. See: https://urllib3.readthedocs.io/en/latest/advanced-usage.html#ssl-warnings
InsecureRequestWarning)
>>> r.status_code
200 |
Strange... Could you please post the debug output from the playbook run (one task should be enough)? e.g. Are you using a custom CA? |
Hello @elnappo,
we just enabled https in front of the check_mk server (LB) and since then, the check_mk.py is not able to work anymore.
Is this module tested against https or is http the only operation mode by design?
thanks in advance.
The text was updated successfully, but these errors were encountered: