6bf7a6ab5d
This reverts commit 7e8113b3fc
.
see https://leap.se/code/issues/1990 for the miserious details.
20 lines
588 B
Puppet
20 lines
588 B
Puppet
class apt::preferences {
|
|
|
|
$pref_contents = $apt::custom_preferences ? {
|
|
'' => $::operatingsystem ? {
|
|
'debian' => template("apt/${::operatingsystem}/preferences_${apt::codename}.erb"),
|
|
'ubuntu' => template("apt/${::operatingsystem}/preferences_${apt::codename}.erb"),
|
|
},
|
|
default => $apt::custom_preferences
|
|
}
|
|
|
|
file { '/etc/apt/preferences':
|
|
ensure => present,
|
|
alias => 'apt_config',
|
|
# only update together
|
|
content => $pref_contents,
|
|
require => File['/etc/apt/sources.list'],
|
|
owner => root, group => 0, mode => '0644';
|
|
}
|
|
|
|
}
|