Skip to content

Commit

Permalink
(MODULES-10971) - Ensure apt::keyserver is considered when creating…
Browse files Browse the repository at this point in the history
… a default apt:source

As it stands the source_key_defaults point towards the default `keyserver` value set within the params. This change makes it so that it will instead use the `keyserver` value set in the init, which will in turn default to the params value in none has been given.
  • Loading branch information
david22swan committed Mar 24, 2021
1 parent 18fe46c commit 18522b9
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 7 deletions.
10 changes: 9 additions & 1 deletion manifests/init.pp
Original file line number Diff line number Diff line change
Expand Up @@ -153,8 +153,16 @@
String $preferences_d = $apt::params::preferences_d,
String $apt_conf_d = $apt::params::apt_conf_d,
Hash $config_files = $apt::params::config_files,
Hash $source_key_defaults = $apt::params::source_key_defaults,
# Hash $source_key_defaults = $apt::params::source_key_defaults,
Boolean $sources_list_force = $apt::params::sources_list_force,

Hash $source_key_defaults = {
'server' => $keyserver,
'options' => undef,
'content' => undef,
'source' => undef,
}

) inherits apt::params {

if $facts['os']['family'] != 'Debian' {
Expand Down
12 changes: 6 additions & 6 deletions manifests/params.pp
Original file line number Diff line number Diff line change
Expand Up @@ -71,12 +71,12 @@
'apt.conf.d' => false,
}

$source_key_defaults = {
'server' => $keyserver,
'options' => undef,
'content' => undef,
'source' => undef,
}
# $source_key_defaults = {
# 'server' => $keyserver,
# 'options' => undef,
# 'content' => undef,
# 'source' => undef,
# }

$include_defaults = {
'deb' => true,
Expand Down

0 comments on commit 18522b9

Please sign in to comment.