Skip to content

Commit

Permalink
Remove hardcoded dns-ovh.ini file name (replace $config_dir by $confi…
Browse files Browse the repository at this point in the history
…g_file)
  • Loading branch information
aellert committed Aug 8, 2019
1 parent 1175fcc commit 6858d7b
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion manifests/certonly.pp
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@
$plugin_args = [
"--cert-name '${title}' -d",
"'${_domains}'",
"--dns-ovh-credentials ${letsencrypt::plugin::dns_ovh::config_dir}/dns-ovh.ini",
"--dns-ovh-credentials ${letsencrypt::plugin::dns_ovh::config_file}",
"--dns-ovh-propagation-seconds ${letsencrypt::plugin::dns_ovh::propagation_seconds}",
]
}
Expand Down
14 changes: 7 additions & 7 deletions manifests/plugin/dns_ovh.pp
Original file line number Diff line number Diff line change
Expand Up @@ -30,18 +30,18 @@
# Manage the plugin package.
# @param package_name
# The name of the package to install when $manage_package is true.
# @param config_dir
# The path to the configuration directory.
# @param config_file
# The name, with full abolute path, of the configuration file containing OVH credentials.
#
class letsencrypt::plugin::dns_ovh (
Enum['ovh-eu', 'ovh-ca'] $endpoint,
String[1] $application_key,
String[1] $application_secret,
String[1] $consumer_key,
Integer $propagation_seconds = $letsencrypt::dns_ovh_propagation_seconds,
Stdlib::Absolutepath $config_dir = $letsencrypt::config_dir,
Boolean $manage_package = $letsencrypt::dns_ovh_manage_package,
String $package_name = $letsencrypt::dns_ovh_package_name,
Integer $propagation_seconds = $letsencrypt::dns_ovh_propagation_seconds,
Boolean $manage_package = $letsencrypt::dns_ovh_manage_package,
String $package_name = $letsencrypt::dns_ovh_package_name,
Stdlib::Absolutepath $config_file = "${letsencrypt::config_dir}/dns-ovh.ini",
) {

if $manage_package {
Expand All @@ -58,7 +58,7 @@
dns_ovh_propagation_seconds => $propagation_seconds,
}

file { "${config_dir}/dns-ovh.ini":
file { $config_file:
ensure => file,
owner => 'root',
group => 'root',
Expand Down

0 comments on commit 6858d7b

Please sign in to comment.