Codegen Graphql can't reach dockerized API

19 Views Asked by At

I am trying to setup codegen graphql on a react app, but it can't reach my local API endpoint. This API is a laravel with lighthouse, that is dockerized.

I can reach my API through Postman & directly on browser, but codegen keep returning the following error :

Failed to load schema from https://local.xxxx.com/graphql:     
      connect ECONNREFUSED 127.0.0.1:443
      Error: connect ECONNREFUSED 127.0.0.1:443

I also tried to set NODE_TLS_REJECT_UNAUTHORIZED=0 but it didn't change anything

Any help would be welcome !

0

There are 0 best solutions below