Getting rid of InsecureRequestWarning messages

I am running HA in a Docker container. I have installed the NextCloud integration to poll data from my NextCloud instance. This is generating InsecureRequestWarning messages every minute.

I have my own CA and the NextCloud server has a certificate signed by that CA. I have installed the “additional_ca” plug-in from HACS and configured it as per instructions with my CA certificate. This made no difference.

I have added the PYTHONWARNINGS=“ignore:Unverified HTTPS request” environment setting to my compose.yaml and this likewise made no difference.

Clearly I am missing something and would welcome any suggestions.

Maybe it is the NextCloud servers that are refusing to use your certificate, because they can not verify it.
This is the case with Google, Alexa and other services.

@WallyR
Thank you for your reply, but I don’t think that’s the case.
I can access the NextCloud instance fine over SSL/TLS from browsers and the Android NextCloud app, with my CA cert added as a trusted cert.

An SSL/TLS cert is linked to a domain name.

If you access a resource internally with an IP address or a .local domain the certificate will not be valid. If your router allows hair pin routing then you may be able to use your external domain name to access.

@KennethLavrsen
The NextCloud server cert is correctly configured with the FQDN of the NextCloud instance, which is correctly resolved by the DNS server on my internal network.
Per my reply to WallyR, there is no issue accessing the NextCloud instance securely from a browser or Android app.
Also, the NextCloud integration is successfully connecting to the NextCloud instance, only with that log message as a side-effect.