Table of Contents

Installation

Utilisation avec nginx

<pre> server {

  # .well-known doit rester accessible
  location ~ /\.well-known/acme-challenge {
      allow all;
  }
  # On interdit habituellement l'accès au dotfiles
  location ~ /\. { deny all; access_log off; log_not_found off; }

} </pre>

<pre> /srv/letsencrypt/letsencrypt-auto certonly –rsa-key-size 4096 –webroot –webroot-path /var/www/mondomaine.fr -d mondomaine.fr </pre>

Le certificat est généré dans ce répertoire

/etc/letsencrypt/live/

} </pre>

Renouvellement

Pour le renouvellement c'est très simple, la commande suivante renouvellera automatique tous les certificats le nécessitant:

<pre> /srv/letsencrypt/letsencrypt-auto renew </pre>

Avec Certbot

certbot certonly –webroot –webroot-path DOCROOT -d DOMAINE.TLD

Bibliographie

Un grand merci à grafikart.fr pour son tuto clair !

https://www.grafikart.fr/formations/serveur-linux/nginx-ssl-letsencrypt