Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save janikvonrotz/2a50f908e34502972ecf0f0067fff6fb to your computer and use it in GitHub Desktop.
Save janikvonrotz/2a50f908e34502972ecf0f0067fff6fb to your computer and use it in GitHub Desktop.
Manually renew letsencrypt certificate

Clone the letsencrypt cli.

git clone https://github.com/letsencrypt/letsencrypt
cd letsencrypt

Request a new certificate for your domain manually.

./letsencrypt-auto certonly -a manual -d janikvonrotz.ch

This install dependencies, prompt a few things and finally output something like this:

Create a file containing just this data:

Ye_NZDAneJxd6qAZ-rYA69PaC5zX7MvPoL2RCAylRjI.vrz1sjWRICB9gRaBBY4j9RorDIZ-3MMinwKOrnzFyak

And make it available on your web server at this URL:

http://janikvonrotz.ch/.well-known/acme-challenge/Ye_NZDAneJxd6qAZ-rYA69PaC5zX7MvPoL2RCAylRjI

Do exactly as told.

If you are using hugo as CMS, simply create the file and folder strucuture inside the static folder.

Check with curl before moving on with the challenge.

curl http://janikvonrotz.ch/.well-known/acme-challenge/Ye_NZDAneJxd6qAZ-rYA69PaC5zX7MvPoL2RCAylRjI

Finish the challenge and you should find the certs and key here: /etc/letsencrypt/live/janikvonrotz.ch

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment