diff options
Diffstat (limited to 'functions/conf/nginx.pp')
-rw-r--r-- | functions/conf/nginx.pp | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/functions/conf/nginx.pp b/functions/conf/nginx.pp new file mode 100644 index 0000000..aa5f30e --- /dev/null +++ b/functions/conf/nginx.pp @@ -0,0 +1,17 @@ +function letsencrypt::conf::nginx ( + String $cert_name, +) >> Letsencrypt::Ssl_conf::Nginx { + $cert_path = $facts['letsencrypt_directory'][$cert_name] + if $cert_path == undef { + { + ssl => false, + } + } else { + { + ssl => true, + ssl_redirect => true, + ssl_cert => "${cert_path}/fullchain.pem", + ssl_key => "${cert_path}/privkey.pem", + } + } +} |