Fallen at the first hurdle: [notice] TLS :client: In state :certify at ssl_handshake.erl:2082 generated CLIENT ALERT: Fatal - Unknown CA

You could just set HEX_UNSAFE_HTTPS=1 when running Mix commands, which disables server certificate verification for Hex server endpoints. When fetching public data from Hex (as opposed to publishing packages or accessing other authenticated endpoints) this should be safe, as package checksums are verified against the signed Hex registry metadata. But I still wouldn’t do this without first understanding why normal HTTPS does not work…

2 Likes

It could very well be that as I’m on my work PC

1 Like

Thanks for all your help everyone - I got it sorted in the end. I’m loving elixir so far - It’s really unlike anything I’ve learned before but at the same time it’s super satisfying to use even as someone learning it

I run into the same issue working with elixir on Windows 10 when invoking mix hex.search. mix hex.config displays all configuration settings for mix. Setting mix hex.config unsafe_https 1 resolves the issue against the background of server certificate not being validated. cacerts_path: nil (default) is what I got from the configuration and a quick googling points to %SystemRoot% \System32\Certlog as the default ca certs path however the folder was no-existent.

This just stated:

c:\Gateway\Server
λ mix deps.update --all
* Updating tds (https://github.com/elixir-ecto/tds.git)
fatal: unable to access 'https://github.com/elixir-ecto/tds.git/': schannel: SEC_E_UNTRUSTED_ROOT (0x80090325) - The certificate chain was issued by an authority that is not trusted.
** (Mix) Command "git --git-dir=.git fetch --force --quiet --progress" failed