From aba6be9a5386e30600e63eec0043276290be360b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Hugo=20H=C3=B6rnquist?= Date: Sun, 15 Jan 2023 15:20:01 +0100 Subject: Documentaion. --- functions/conf/nginx.pp | 5 ++++- functions/conf/nginx/location.pp | 4 ++++ manifests/authenticator/nginx.pp | 5 ----- types/authenticator.pp | 1 + types/renewal_provider.pp | 2 ++ types/ssl_conf/nginx.pp | 3 +++ types/ssl_conf/nginx/location.pp | 1 + 7 files changed, 15 insertions(+), 6 deletions(-) diff --git a/functions/conf/nginx.pp b/functions/conf/nginx.pp index f8e6123..9e7b392 100644 --- a/functions/conf/nginx.pp +++ b/functions/conf/nginx.pp @@ -1,5 +1,8 @@ # Returns a hash to be merged into a nginx::resource::server resources -# parameters. The cert_name parameter should be the name of the domain in question, and NOT the local certificate name. +# parameters. +# @param cert_name +# name of the domain in question, NOT the local certificate name. +# @return hash usable with nginx::resource::server function letsencrypt::conf::nginx ( String $cert_name, ) >> Letsencrypt::Ssl_conf::Nginx { diff --git a/functions/conf/nginx/location.pp b/functions/conf/nginx/location.pp index a787013..19572f3 100644 --- a/functions/conf/nginx/location.pp +++ b/functions/conf/nginx/location.pp @@ -1,4 +1,8 @@ # Returns a hash to be merged into a nginx::resource::location resource. +# @param cert_name +# Domain for which we want the configuration. +# NOT the local certificate name. +# @return hash usable with nginx::resource::location function letsencrypt::conf::nginx::location ( String $cert_name, ) >> Letsencrypt::Ssl_conf::Nginx::Location { diff --git a/manifests/authenticator/nginx.pp b/manifests/authenticator/nginx.pp index 971c4ed..ec5850e 100644 --- a/manifests/authenticator/nginx.pp +++ b/manifests/authenticator/nginx.pp @@ -2,11 +2,6 @@ # variables for enterpolating into nginx configurations # # These use the default cert name -# @example -# nginx::resource::server { 'servername': -# * => $letsescrypt::nginx::server_ssl -# } -# $letsencrypt::nginx::location_ssl # @param certbot_plugin_package # Name of the system package providing this plugin. # Populated through hiera. diff --git a/types/authenticator.pp b/types/authenticator.pp index 8593213..dbd57d5 100644 --- a/types/authenticator.pp +++ b/types/authenticator.pp @@ -1 +1,2 @@ +# @summary Known authenticator types type Letsencrypt::Authenticator = Enum['nginx'] diff --git a/types/renewal_provider.pp b/types/renewal_provider.pp index bfa3077..c63f340 100644 --- a/types/renewal_provider.pp +++ b/types/renewal_provider.pp @@ -1 +1,3 @@ +# Known backends which can keep track of when to issue renewal +# requests. type Letsencrypt::Renewal_provider = Enum['systemd', 'cron'] diff --git a/types/ssl_conf/nginx.pp b/types/ssl_conf/nginx.pp index fb2187d..333093f 100644 --- a/types/ssl_conf/nginx.pp +++ b/types/ssl_conf/nginx.pp @@ -1,3 +1,6 @@ +# @summary SSL configuration hash for nginx +# Will either have ssl set to false, or ssl set to true, along with +# appropriate ssl parameters. type Letsencrypt::Ssl_conf::Nginx = Variant[ Struct[{ ssl => Boolean, diff --git a/types/ssl_conf/nginx/location.pp b/types/ssl_conf/nginx/location.pp index 25941d0..d3bfc32 100644 --- a/types/ssl_conf/nginx/location.pp +++ b/types/ssl_conf/nginx/location.pp @@ -1,3 +1,4 @@ +# SSL configuration for a single nginx location. type Letsencrypt::Ssl_conf::Nginx::Location = Variant[ Struct[{ ssl => Boolean, -- cgit v1.2.3