kolla-toolbox: python requests fails to verify certificates with root-ca located at /etc/ssl/certs

Bug #1967132 reported by Uwe Grawert
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
kolla-ansible
New
Undecided
Unassigned

Bug Description

**Bug Report**

What happened:

Deploying an environment with internal TLS is causing issues, if the root-ca certificate is not part of python-certifi.

Example: grafana deployment

FAILED - RETRYING: Wait for grafana application ready (1 retries left).
fatal: [ctl1]: FAILED! => {"action": "uri", "attempts": 30, "changed": false, "elapsed": 0, "msg": "Status code was -1 and not [200]: Request failed: <urlopen error [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1131)>", "redirected": false, "status": -1, "url": "https://api-int.testbed.cloud:3000/login"}

What you expected to happen:

TASK [grafana : Wait for grafana application ready] ***********************************************************************************************************************************************************************************
ok: [ctl1]

How to reproduce it (minimal and precise):

1. set `kolla_enable_tls_internal: "yes"` in globals.yml.
2. Deploy Grafana: kolla-ansible deploy grafana

**Environment**:
* OS (e.g. from /etc/os-release): Ubuntu 20.04.4 LTS
* Kernel (e.g. `uname -a`): Linux ctl1 5.4.0-105-generic #119-Ubuntu SMP Mon Mar 7 18:49:24 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux
* Docker version if applicable (e.g. `docker version`): 20.10.13
* Kolla-Ansible version (e.g. `git head or tag or stable branch` or pip package version if using release): stable/xena
* Docker image Install type (source/binary): source
* Docker image distribution: quay.io/osism/kolla-toolbox:13.0.2.20220321
* Are you using official images from Docker Hub or self built? self-built
* If self built - Kolla version and environment used to build: Xena
* Share your inventory file, globals.yml and other configuration files if relevant

kolla_enable_tls_internal: "yes"
kolla_copy_ca_into_containers: "yes"
openstack_cacert: /etc/ssl/certs/ca-certificates.crt

Notes:
Setting `REQUESTS_CA_BUNDLE=/etc/ssl/certs/ca-certificates.crt` environment variable in the kolla-toobox container is solving the issue. But this is only desirable if cert bundle from python-certifi shall not be used.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.