From cd1fadd1752b68b38cee56c9a484ebf85c63c806 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Hugo=20H=C3=B6rnquist?= Date: Wed, 29 Nov 2023 05:19:36 +0100 Subject: Default certificates to certname instead of hostname. Hostname is usually the local component (e.g. gandalf), which you obviously can't get a certificate for. certname is usually the FQDN, which is what we want. --- manifests/certificate.pp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/manifests/certificate.pp b/manifests/certificate.pp index 14e7d2e..b630864 100644 --- a/manifests/certificate.pp +++ b/manifests/certificate.pp @@ -2,13 +2,13 @@ # Should preferably be included before a letsencrypt::domain resource # is declared. class profiles::certificate ( - String $cert_name = $trusted['hostname'], + String $cert_name = $trusted['certname'], Letsencrypt::Authenticator $authenticator = 'nginx', Hash[String,Any] $config = { # more portable than 'systemctl reload nginx' 'post-hook' => 'nginx -s reload', }, - Array[String] $default_domains = [ $trusted['hostname'], ], + Array[String] $default_domains = [ $trusted['certname'], ], ) { include ::letsencrypt -- cgit v1.2.3