It had been a while since I tried setting up a new Angular app -- because I've been working on an existing one for several months.
Today, upon trying to install a new Angular app via the terminal in my Mac, it ran really slowly, and then resulted in this err:
npm ERR! code ERR_TLS_CERT_ALTNAME_INVALID
npm ERR! Hostname/IP does not match certificate's altnames: Host: registry.npmjs.org. is not in the cert's altnames: DNS:a.sni.fastly.net, DNS:a.sni.global-ssl.fastly.net
How do I address this issue?
run npm config set strict-ssl false
and re-run ng new appName
if it doesn't work try to run npm config set registry "http://registry.npmjs.org"
Edit
An earlier outage involving a DNS misconfiguration has lead to some ISPs caching npmjs.com as missing, a workaround for this is to use a third party DNS provider such as Cloudflare or Google, the affected caches should clear within the next 24 hours.
https://status.npmjs.org/incidents/v22ffls5cd6h
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With