Certificate signed by unknown authority error when using google sheets api

Need Help

I am running a go application inside a container which is fetching data from google sheets via a service account which needs ouath. This container is behind a traefik reverse proxy in portainer which provisions a certificate for the subdomain attached to this service. When I try to call the API, oauth2: cannot fetch token: Post "https://oauth2.googleapis.com/token": tls: failed to verify certificate: x509: certificate signed by unknown authority
I am getting this error...

Can you describe your setup again, especially what requests go from where to where?

Share you Traefik static and dynamic config, and docker-compose.yml if used.