diff options
-rw-r--r-- | manifests/cert.pp | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/manifests/cert.pp b/manifests/cert.pp index 81a5f4b..28906f0 100644 --- a/manifests/cert.pp +++ b/manifests/cert.pp @@ -1,20 +1,18 @@ -define nginx::cert( - $address -) +define nginx::cert() { - ssl::cert { "$address": + ssl::cert { "$name": main => true, notify => Service['nginx'], } - ssl::check { "$address": + ssl::check { "$name": file => true, } Service["nginx"] { require => [ Package["nginx"], - File["/etc/nginx/sites-enabled/${address}"], - File["/etc/ssl/private/${address}.pem"], - File["/etc/ssl/certs/${address}.crt"] ], + File["/etc/nginx/sites-enabled/${name}"], + File["/etc/ssl/private/${name}.pem"], + File["/etc/ssl/certs/${name}.crt"] ], } } |