Unix::letsencrypt pour un domaine local

De wiki_pcwiki2
Aller à la navigationAller à la recherche

KEYWORDS: LETSENCRYPT, LOCAL DOMAIN, LOCALDOMAIN, LOCALHOST, HTTPS

Le 22/01/2023:
On peut générer des clés SSL pour un domaine local (intranet).
Pour cela, il faut:
- sur la machine locale:
  certbot certonly --manual --prefered-challenges dns
  Ce programme demande un domaine (Exemple: grocy.bois-dery.fr)
  Ce programme propose une clé à introduire en tant que TXT dans _acme-challenge(.domainelocal) (dans poweradmin.pcstreet.org)
  (Exemple:  _acme-challenge.grocy.bois-dery.fr)
  Quand l'entrée DNS répond (Exemple: dig @pc230 _acme-challenge.gocy.bois-dery.fr), 
  on peut alors appuyer sur ENTER pour que le programme puisse créer les clés dans /etc/letsencrypt/live
  Il faudra alors incorporer ces clés dans le fichier apache de la conf du domaine 
 
ATTENTION: Certificates obtained with --manual cannot be renewed automatically with certbot renew 
(unless you've provided a custom authorization script). 
However, certificates obtained with a Certbot DNS plugin can be renewed automatically. 
In order to obtain wildcard certificates that can be renewed without human intervention, 
you'll need to use a Certbot DNS plugin that's compatible with an API supported by your DNS provider, 
or a script that can make appropriate DNS record changes upon demand. 
Even if your regular DNS provider doesn't support a compatible update mechanism, 
you can use a CNAME delegation for the _acme-challenge record in your DNS zone to a different provider that does. You can also point _acme-challenge to an acme-dns instance