Open shreyasminocha opened 3 years ago
I have gone down the road of SSL certs using mkcert but I have found issues with certain browsers (ahem Safari), that are a bit finicky.
I personally would love to have automated certificates with an ACME server, but need to find a way to cleanly integrate this. This means that there would be a root Chalet certificate and autogenerated certificates for each subdomain in chalet. Open to ideas and help on this!
I have been using this little snippet for ages now. Never had any issues. I use .box
as my tld. If yours is different just adjust accordingly in 2 places. It uses mkcert
which is installed via Homebrew.
ls ~/.chalet/servers | sed -E 's/\.json/.box/g' | tr '\n' ' ' | xargs mkcert -key-file ~/.chalet/key.pem -cert-file ~/.chalet/cert.pem 'localhost' '127.0.0.1' '0.0.0.0' 'chalet.box'
I actually have it setup as an alias in my system:
alias make_local_ssl="ls ~/.chalet/servers | sed -E 's/\.json/.box/g' | tr '\n' ' ' | xargs mkcert -key-file ~/.chalet/key.pem -cert-file ~/.chalet/cert.pem 'localhost' '127.0.0.1' '0.0.0.0' 'chalet.box'"
Thanks @leeovery
I tried to install mkcert and your snippet (I ran mkcert -install
after).
alias make_local_ssl="ls ~/.chalet/servers | sed -E 's/\.json/.test/g' | tr '\n' ' ' | xargs mkcert -key-file ~/.chalet/key.pem -cert-file ~/.chalet/cert.pem 'localhost' '127.0.0.1' '0.0.0.0' 'chalet.test'"
But I still have issues with the SSL on Brave:
Update: I'm embarrassed to say this was resolved simply by adding my chalet hostnames to /etc/hosts. Didn't realize that was still a thing 😊
typicode#309 and typicode#346. This would be really great.