diff --git a/manifests/config.pp b/manifests/config.pp index 1ad1a0b2..ef6feffc 100644 --- a/manifests/config.pp +++ b/manifests/config.pp @@ -29,17 +29,17 @@ $_config = $config } + ini_setting { "${config_file} register-unsafely-without-email true": + ensure => bool2str($unsafe_registration, 'present', 'absent'), + path => $config_file, + section => '', + setting => 'register-unsafely-without-email', + value => true, + } + unless 'email' in $_config { if $unsafe_registration { warning('No email address specified for the letsencrypt class! Registering unsafely!') - ini_setting { "${config_file} register-unsafely-without-email true": - ensure => present, - path => $config_file, - section => '', - setting => 'register-unsafely-without-email', - value => true, - require => File[$config_dir], - } } else { fail("Please specify an email address to register with Let's Encrypt using the \$email parameter on the letsencrypt class") } diff --git a/metadata.json b/metadata.json index 5e0721f2..7df8af0a 100644 --- a/metadata.json +++ b/metadata.json @@ -80,7 +80,7 @@ }, { "name": "puppetlabs/inifile", - "version_requirement": ">= 2.0.0 < 6.0.0" + "version_requirement": ">= 2.5.0 < 6.0.0" }, { "name": "puppet/epel",