From dd0552dce13f123dc05c5600232216f905c70f7b Mon Sep 17 00:00:00 2001 From: Micah Anderson Date: Tue, 7 Dec 2010 23:03:15 -0500 Subject: [PATCH] update apt::preseeded_package template sources to use $lsbdistcodename instead of $debian_release, also expand it to allow for site-apt sources --- README | 8 ++++---- manifests/preseeded_package.pp | 4 +++- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/README b/README index 406266a..7abb1ea 100644 --- a/README +++ b/README @@ -226,10 +226,10 @@ apt::preseeded_package ---------------------- This simplifies installation of packages for which you wish to preseed the -answers to debconf. For example, if you wish to provide a preseed file -for the locales package, you would place the locales.seed file in -'templates/$debian_version/locales.seeds' and then include the following -in your manifest: +answers to debconf. For example, if you wish to provide a preseed file for the +locales package, you would place the locales.seed file in +'site-apt/templates/$lsbdistcodename/locales.seeds' and then include the +following in your manifest: apt::preseeded_package { locales: } diff --git a/manifests/preseeded_package.pp b/manifests/preseeded_package.pp index 8f3bcbd..74aafa5 100644 --- a/manifests/preseeded_package.pp +++ b/manifests/preseeded_package.pp @@ -1,7 +1,9 @@ define apt::preseeded_package ($content = "", $ensure = "installed") { $seedfile = "/var/cache/local/preseeding/$name.seeds" $real_content = $content ? { - "" => template ( "$name.seeds", "$debian_version/$name.seeds" ), + "" => template ( "site-apt/$name.seeds", + "site-apt/$lsbdistcodename/$name.seeds", + "$name.seeds", "$lsbdistcodename/$name.seeds" ), default => $content }