Lua-resty-auto-ssl: On-the-fly certs inside nginx (OpenResty)


I’ve been working on a plugin to automatically provision SSL certificates using Let’s Encrypt on-the-fly inside nginx. More specifically, it requires some new functionality in OpenResty, which is nginx+Lua, if you’re not familiar. Now that most of the functionality is in place, I thought I’d share it with the group:

In short, the aim of the plugin is to automatically register and renew SSL certificates for any number of domains dynamically, making SSL much easier to deploy (particularly in environments where you might need to handle SSL for lots of different domains). We’ve been using it across a few production sites for the past few weeks, and it’s been refreshing how simple it’s made SSL.

Any suggestions or feedback are welcome. And thanks to Let’s Encrypt for providing such a great service!


Im about to be testing this within a staging server and then straight to production.

Ill let you know how i go.

Does this autorenew aswell? based on checking the SSL each time a request for a domain happens?