diff options
author | Silvio Rhatto <rhatto@riseup.net> | 2013-01-26 15:20:30 -0200 |
---|---|---|
committer | Micah Anderson <micah@riseup.net> | 2013-06-25 15:35:11 -0400 |
commit | 50b4bef76180181a34d04958b320295c7b6e9cf0 (patch) | |
tree | 4699217074e4e8460834c32e392dec5a5aa30f47 | |
parent | c38be6cb7c2cbd53a133291b2750d053877ebe4f (diff) | |
download | puppet-apt-50b4bef76180181a34d04958b320295c7b6e9cf0.tar.gz puppet-apt-50b4bef76180181a34d04958b320295c7b6e9cf0.tar.bz2 |
Make custom_key_dir a class parameter and not a global variable
Conflicts:
manifests/init.pp
-rw-r--r-- | README | 22 | ||||
-rw-r--r-- | manifests/init.pp | 7 | ||||
-rw-r--r-- | manifests/params.pp | 1 |
3 files changed, 15 insertions, 15 deletions
@@ -129,18 +129,6 @@ pull in the templates/site_apt/sources.list file: $custom_sources_list = template('site_apt/sources.list') -$custom_key_dir ---------------- - -If you have different apt-key files that you want to get added to your -apt keyring, you can set this variable to a path in your fileserver -where individual key files can be placed. If this is set and keys -exist there, this module will 'apt-key add' each key. - -The debian-archive-keyring package is installed and kept current up to the -latest revision (this includes the backports archive keyring). - - Classes ======= @@ -235,6 +223,16 @@ Class parameters: include apt::dist_upgrade class { 'apt': codename => 'wheezy', notify => Exec['apt_dist-upgrade'] } +* custom_key_dir + + If you have different apt-key files that you want to get added to your + apt keyring, you can set this variable to a path in your fileserver + where individual key files can be placed. If this is set and keys + exist there, this module will 'apt-key add' each key. + + The debian-archive-keyring package is installed and kept current up to the + latest revision (this includes the backports archive keyring). + apt::apticron ------------- diff --git a/manifests/init.pp b/manifests/init.pp index 3f8e1c8..de28c23 100644 --- a/manifests/init.pp +++ b/manifests/init.pp @@ -15,7 +15,8 @@ class apt( $ubuntu_url = $apt::params::ubuntu_url, $repos = $apt::params::repos, $custom_preferences = $apt::params::custom_preferences, - $disable_update = $apt::params::disable_update + $disable_update = $apt::params::disable_update, + $custom_key_dir = $apt::params::custom_key_dir ) inherits apt::params { case $::operatingsystem { 'debian': { @@ -113,9 +114,9 @@ class apt( $apt_base_dir = "${common::moduledir::module_dir_path}/apt" modules_dir { 'apt': } - if $::custom_key_dir { + if $custom_key_dir { file { "${apt_base_dir}/keys.d": - source => $::custom_key_dir, + source => $custom_key_dir, recurse => true, owner => root, group => root, diff --git a/manifests/params.pp b/manifests/params.pp index b210ff6..12273ac 100644 --- a/manifests/params.pp +++ b/manifests/params.pp @@ -14,4 +14,5 @@ class apt::params () { $repos = 'auto' $custom_preferences = '' $disable_update = false + $custom_key_dir = false } |