Live data from Hacker News

Using Free SSL/TLS Certificates from Let’s Encrypt for Nginx

nginx.com

11–20 of 50 posts

Re: Using Free SSL/TLS Certificates from Let’s Encrypt for Nginx

#11

I was hoping this was an nginx module where you could specify something like `ssl_letsencrypt on;` and be done with it.

I think its not gona be easy as that - there has to be some croned process and some kind of error handling. (I created https://hub.docker.com/r/analogic/lemanager/ which does both but i am still waiting for some better "native" solution)

Re: Using Free SSL/TLS Certificates from Let’s Encrypt for Nginx

#12

I was hoping this was an nginx module where you could specify something like `ssl_letsencrypt on;` and be done with it.

Caddy has this feature and it's amazing. https://caddyserver.com/docs/automatic-https

this is how it should work. Very nice. I can't wait for other web servers to gain this ability too. Or at least allow us to load certificates from dynamic locations based on some request data.

All other web servers I looked at (nginx, apache, lighttpd) still require at least a reload for an updated certificate and a configuration file change for a new certificate to be used.

I wonder how caddy works with the very low 5 certificates per public suffix and week limit. Does it automatically bundle domains and request a single certificate with SANs?

Re: Using Free SSL/TLS Certificates from Let’s Encrypt for Nginx

#13
post #11

I was hoping this was an nginx module where you could specify something like `ssl_letsencrypt on;` and be done with it.

I think its not gona be easy as that - there has to be some croned process and some kind of error handling. (I created https://hub.docker.com/r/analogic/lemanager/ which does both but i am still waiting for some better "native" solution)

It could hypothetically be that easy, AFAICT. Nginx service runs constantly, so a module could presumably execute scheduled tasks. Those tasks could have error checking, sending errors to the root inbox.

Re: Using Free SSL/TLS Certificates from Let’s Encrypt for Nginx

#14
post #7

Earlier quoted context omitted.

Caddy has this feature and it's amazing. https://caddyserver.com/docs/automatic-https

Wow. I might check try it out then.

It really does do what it says it does.

https://github.com/Xe/dotfiles/tree/master/ansible/roles/cad...

https://xena.greedo.xeserv.us

Re: Using Free SSL/TLS Certificates from Let’s Encrypt for Nginx

#15
post #12

Earlier quoted context omitted.

Caddy has this feature and it's amazing. https://caddyserver.com/docs/automatic-https

this is how it should work. Very nice. I can't wait for other web servers to gain this ability too. Or at least allow us to load certificates from dynamic locations based on some request data. All other web servers I looked at (nginx, apache, lighttpd) still require at least a reload for an updated certificate and a configuration file change for a new certificate to be used. I wonder how caddy works with the very low…

> this is how it should work. Very nice.

Yeah, Caddy is amazing. Matt is doing an awesome job with it.

> I wonder how caddy works with the very low 5 certificates per public suffix and week limit. Does it automatically bundle domains and request a single certificate with SANs?

I directed Matt to this discussion so I hope can answer these questions for you. I unfortunately cannot.

Re: Using Free SSL/TLS Certificates from Let’s Encrypt for Nginx

#16
post #12

Earlier quoted context omitted.

Caddy has this feature and it's amazing. https://caddyserver.com/docs/automatic-https

this is how it should work. Very nice. I can't wait for other web servers to gain this ability too. Or at least allow us to load certificates from dynamic locations based on some request data. All other web servers I looked at (nginx, apache, lighttpd) still require at least a reload for an updated certificate and a configuration file change for a new certificate to be used. I wonder how caddy works with the very low…

> this is how it should work. Very nice.

Thanks for your comments; glad you like the way we integrated it!

> Does it automatically bundle domains and request a single certificate with SANs?

No, as it turns out, SAN makes the auto-management code highly complicated, since names could overlap in different certs, etc. It also complicates renewals and gives more room for error (e.g. 49 of the domains verify but 1 fails, so the cert can't be renewed). So I've opted not to support SAN certificates for the automatic HTTPS feature. But you can of course still issue your own SAN certificates and use those.

Right now, Caddy reloads itself when it renews certificates, but as of Caddy 0.8.2 (slated for release any day now), Caddy will do it all in-process, no reloading.

Re: Using Free SSL/TLS Certificates from Let’s Encrypt for Nginx

#17
post #9

I was hoping this was an nginx module where you could specify something like `ssl_letsencrypt on;` and be done with it.

Or better yet, make "ssl_letsencrypt on;" the default. Make it so that newbies can just apt-get install nginx/apache/lighttpd/etc. and have https up and running, no questions asked. The real reason https adoption isn't up to par has less to do with people not willing to spend money, and more because it's not up by default. Now that https is free, please make it enabled by default.

Check out Caddy, which enables HTTPS by default: https://caddyserver.com/docs/automatic-https

Re: Using Free SSL/TLS Certificates from Let’s Encrypt for Nginx

#19
Here is my Nginx config for let's encrypt on my case, feel free to criticize or copy it: https://gist.github.com/alex-min/158f35f604b24e163ae9. I've managed to get a A+ on the ssllab test so it should not be too bad I believe (but I'm not an expert so if you have some idea for improvements, I would be glad).

Re: Using Free SSL/TLS Certificates from Let’s Encrypt for Nginx

#20
I tried using the official encrypt client on my low spec VPS this weekend (cent os 6). It wouldn't install as when compiling it runs out of memory. Why so heavyweight. Luckily I found a python script which uses the acme tools stuff and that worked fine. Maybe providing binaries would be another option so I don't have to compile everything myself.
Post reply on HN