LLI Wiki — My Digital Knowledge Base

certbot : certificat Let's Encrypt pour nginx avec redirection HTTPS et OCSP stapling

Commande certbot unique pour obtenir un certificat, configurer nginx, rediriger vers HTTPS et activer l'agrafage OCSP.

Commande certbot pour obtenir un certificat Let's Encrypt et configurer nginx en une seule fois, avec redirection HTTP vers HTTPS.

sudo certbot --nginx --agree-tos --redirect --staple-ocsp --email user@example.com -d app.example.com
Option Rôle
--nginx utilise le plugin nginx pour obtenir le certificat et modifier la configuration
--agree-tos accepte les conditions d'utilisation de l'autorité de certification
--redirect redirige automatiquement le HTTP vers le HTTPS
--staple-ocsp active l'agrafage OCSP (OCSP stapling)
--email adresse de contact pour les notifications d'expiration
-d nom de domaine à certifier

Remarques

Mastodon LLIMastodon SocialFosstodon