Merge pull request #1 from puppet-community/daenney/remove_unattended_upgrades_remains
[puppet-modules/puppetlabs-apt.git] / manifests / source.pp
index 259d0ebb98993d26eacd83ce9db9cce2ac9012b3..3e9414f11db8121fccae496092455512565a32e0 100644 (file)
@@ -15,12 +15,14 @@ define apt::source(
   $key_content       = undef,
   $key_source        = undef,
   $pin               = false,
-  $architecture      = undef
+  $architecture      = undef,
+  $trusted_source    = false,
 ) {
-
-  include apt::params
   include apt::update
 
+  validate_string($architecture)
+  validate_bool($trusted_source)
+
   $sources_list_d = $apt::params::sources_list_d
   $provider       = $apt::params::provider
 
@@ -40,7 +42,7 @@ define apt::source(
     owner   => root,
     group   => root,
     mode    => '0644',
-    content => template("${module_name}/source.list.erb"),
+    content => template('apt/_header.erb', 'apt/source.list.erb'),
     notify  => Exec['apt_update'],
   }