Replies: 3 comments
|
Assuming you local Wordpress install is available over SSL, you can add |
0 replies
|
Hi @maxyudin, This looks more like a Node.js TLS issue rather than something related to the Next.js dev server itself. The error: "UNABLE_TO_VERIFY_LEAF_SIGNATURE" usually happens because Node.js does not trust self-signed certificates by default, even if your browser does. So enabling HTTPS for the Next.js dev server ( A few approaches that typically work:
|
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
I am on the localhost with *.test domains for each project. Following the guide by Cecile Muller I've created self-issued certificates for testing purposes. Now I'm experimenting with Next.js and facing the problem when I can't fetch the GraphQL output from my localhost-based WordPress because of "FetchError: request to XXXXX failed, reason: unable to verify the first certificate". Errno and error code are "UNABLE_TO_VERIFY_LEAF_SIGNATURE". All my browsers eats this certificate like their own food, but not node-fetch and others from NodeJS.
How can I ignore certificate verification when fetching the data? I can't see any CLI option or config string to do this like, e. g., curl can do. Should I write (copy/paste) a script to include it somewhere?
ssl-root-cas looks like a solution, but I can't figure out how to nail it to the brand-new starter project.
All reactions