Add UCL Certs to linux / python environment
Note: Make sure you select the
idp-dev.cs.ucl.ac.uk
host in the Certificate Hierarchy andExport
as Base64 certificate chain
This will create ~/Downloads/idp-dev.cs.ucl.ac.uk.cer, there should be 3 certificates in that file.
grep 'END CERT' ~/Downloads/idp-dev.cs.ucl.ac.uk.cer
-----END CERTIFICATE-----
-----END CERTIFICATE-----
-----END CERTIFICATE-----
See
add-ucl-to-ca-certs.sh
For example:
docker build -t ucl-certs . --progress=plain
docker run -it ucl-certs bash
root@54fe5912c222:/# curl -s https://idp-dev.cs.ucl.ac.uk > /dev/null && echo curl works!
curl works!
root@54fe5912c222:/# python3 -c 'import requests ; requests.get("https://idp-dev.cs.ucl.ac.uk"); print("python works!")'
python works!
- The
python
solution relies on setting REQUESTS_CA_BUNDLE. The attached docker file sets this via docker's ENV. Similar steps should be taken in k8s/helm.