I have XM Cloud running locally in a docker container. This means with self-signed certificates.
When I use JSS to create and deploy the JSS Style guide application, I keep getting the following error when starting my JSS application on http://localhost:3000: FetchError: request to https://xmcloudcm.localhost/sitecore/api/graph/edge failed, reason: unable to verify the first certificate
With the built-in GraphiQL explorer on URL https://xmcloudcm.localhost/sitecore/api/graph/edge/ui I can execute GraphQL queries on the endpoint https://xmcloudcm.localhost/sitecore/api/graph/edge.
This does not work with Insomnia offline GraphQL API client, I get the following error
When I disable validate certificates in the settings of Insomnia it works:
I tried to set the environment variable ENV NODE_TLS_REJECT_UNAUTHORIZED "0"
in the Dockerfile
for the CM server, but that did not help.
Any ideas to get this working in an docker containers based environment with self-signed certificates?