Skip to content

Commit e0ada8d

Browse files
author
Marc Fournier
committed
apt: remove sources.list/preferences not managed by puppet.
1 parent e3c5b69 commit e0ada8d

File tree

3 files changed

+11
-0
lines changed

3 files changed

+11
-0
lines changed

Diff for: files/empty/.placeholder

Whitespace-only changes.

Diff for: manifests/classes/apt.pp

+10
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,16 @@
33
require => Exec["apt-get_update"]
44
}
55

6+
# ensure only files managed by puppet be present in this directory.
7+
file { "/etc/apt/sources.list.d":
8+
ensure => directory,
9+
source => "puppet:///apt/empty/",
10+
recurse => true,
11+
purge => true,
12+
force => true,
13+
ignore => ".placeholder",
14+
}
15+
616
apt::conf {"10periodic":
717
ensure => present,
818
source => "puppet:///apt/10periodic",

Diff for: manifests/definitions/preferences.pp

+1
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77

88
common::concatfilepart { $name:
99
ensure => $ensure,
10+
manage => true,
1011
file => "/etc/apt/preferences",
1112
content => template("apt/preferences.erb"),
1213
before => Exec["apt-get_update"],

0 commit comments

Comments
 (0)