pixielabs / letsencrypt-rails-heroku

Automatic LetsEncrypt SSL certificates in your Rails app on Heroku.
MIT License
220 stars 33 forks source link

ACME v2 & saving registration #62

Closed jalada closed 5 years ago

jalada commented 5 years ago

Context: #59, #60

This PR splits up the great work from @mashedkeyboard in #60, which also includes a stab at DNS-based validations.

Specifically, this PR:

  1. Adds an ACME_TERMS_AGREED environment variable which must be set.
  2. Removes the ACME_ENDPOINT environment variable. We never tested this works with anything other than LetsEncrypt, and LetsEncrypt diverges from ACME v2. Also, the clue is in the name of the gem.
  3. Moves to V2 of the ACME API, which paves the way for DNS-based validations.
  4. Saves the private key & key ID when registering, for re-use on subsequent runs.

Pretty much ready to go.