diff --git a/manifests/plugin/dns_cloudflare.pp b/manifests/plugin/dns_cloudflare.pp index f5f7d694..a35d982c 100644 --- a/manifests/plugin/dns_cloudflare.pp +++ b/manifests/plugin/dns_cloudflare.pp @@ -23,7 +23,7 @@ Boolean $manage_package = true, Integer $propagation_seconds = 10, ) { - require letsencrypt + include letsencrypt if ! $api_key and ! $api_token { fail('No authentication method provided, please specify either api_token or api_key and api_email.') @@ -34,8 +34,15 @@ fail('No package name provided for certbot dns cloudflare plugin.') } + $requirement = if $letsencrypt::configure_epel { + Class['epel'] + } else { + undef + } + package { $package_name: - ensure => $letsencrypt::package_ensure, + ensure => $letsencrypt::package_ensure, + require => $requirement, } } diff --git a/manifests/plugin/dns_rfc2136.pp b/manifests/plugin/dns_rfc2136.pp index 5c358945..094c8f5b 100644 --- a/manifests/plugin/dns_rfc2136.pp +++ b/manifests/plugin/dns_rfc2136.pp @@ -24,7 +24,7 @@ Stdlib::Absolutepath $config_dir = $letsencrypt::config_dir, Boolean $manage_package = true, ) { - require letsencrypt + include letsencrypt if $manage_package { package { $package_name: diff --git a/manifests/plugin/dns_route53.pp b/manifests/plugin/dns_route53.pp index 09a59337..27a1ac9b 100644 --- a/manifests/plugin/dns_route53.pp +++ b/manifests/plugin/dns_route53.pp @@ -12,7 +12,7 @@ Integer $propagation_seconds = 10, Boolean $manage_package = true, ) { - require letsencrypt + include letsencrypt if $manage_package { package { $package_name: diff --git a/manifests/plugin/nginx.pp b/manifests/plugin/nginx.pp index d63be1cc..a49f070d 100644 --- a/manifests/plugin/nginx.pp +++ b/manifests/plugin/nginx.pp @@ -6,7 +6,7 @@ Boolean $manage_package = true, String[1] $package_name = 'python3-certbot-nginx', ) { - require letsencrypt + include letsencrypt if $manage_package { package { $package_name: