enable allow-insecure for apt::source defined types, includes new tests, documentatio...
[puppet-modules/puppetlabs-apt.git] / manifests / source.pp
index be5b1c475253758aa1bd9799dd53df7b3e8fabf2..54cfadfe14fa422694001acbbdfd524bc2829230 100644 (file)
@@ -70,6 +70,7 @@ define apt::source(
   Optional[Variant[Hash, Numeric, String]] $pin = undef,
   Optional[String] $architecture                = undef,
   Boolean $allow_unsigned                       = false,
+  Boolean $allow_insecure                       = false,
   Boolean $notify_update                        = true,
 ) {
 
@@ -135,9 +136,10 @@ define apt::source(
     'comment'          => $comment,
     'includes'         => $includes,
     'options'          => delete_undef_values({
-      'arch'      => $_architecture,
-      'trusted'   => $allow_unsigned ? {true => "yes", false => undef},
-      'signed-by' => $keyring,
+      'arch'           => $architecture,
+      'trusted'        => $allow_unsigned ? {true => "yes", false => undef},
+      'allow-insecure' => $allow_insecure ? {true => "yes", false => undef},
+      'signed-by'      => $keyring,
     }),
     'location'         => $_location,
     'release'          => $_release,