aboutsummaryrefslogtreecommitdiff
path: root/manifests/subsystem/apt.pp
diff options
context:
space:
mode:
Diffstat (limited to 'manifests/subsystem/apt.pp')
-rw-r--r--manifests/subsystem/apt.pp15
1 files changed, 14 insertions, 1 deletions
diff --git a/manifests/subsystem/apt.pp b/manifests/subsystem/apt.pp
index 28db591..2dcbc26 100644
--- a/manifests/subsystem/apt.pp
+++ b/manifests/subsystem/apt.pp
@@ -14,8 +14,9 @@ class nodo::subsystem::apt(
default => 'enabled',
}
) {
+ # This one is no longer necessary
package { 'apt-transport-https':
- ensure => installed,
+ ensure => absent,
}
# See https://www.cyberciti.biz/faq/howto-use-apt-get-with-ipv6-or-ipv4-transport-on-ubuntu-debian/
@@ -56,6 +57,18 @@ class nodo::subsystem::apt(
},
}
+ file { '/etc/apt/preferences':
+ ensure => present,
+ owner => root,
+ group => root,
+ mode => '0644',
+ require => [ File['/etc/apt/apt.conf.d/1000-force-ipv4-transport'], Package['apt-transport-https'] ],
+ content => $ensure ? {
+ 'present' => template("nodo/apt/${::operatingsystem}.preferences.erb"),
+ default => undef,
+ },
+ }
+
# We have /var/log/dpkg.log, so we do not need to rotate /var/log/upgrade.log
$log = ">> /var/log/upgrade.log 2>&1"
$apt = '/usr/bin/apt-get'