summaryrefslogtreecommitdiff
path: root/manifests/preferences_snippet.pp
blob: 21dfe86e5ab0ec3e5b62a3f5edce4f86890ba292 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
define apt::preferences_snippet(
  $ensure = 'present',
  $release,
  $priority
){
  include apt::preferences
  file { "${apt::preferences::apt_preferences_dir}/${name}":
    ensure => $ensure,
    content => "Package: ${name}
Pin: release a=${release}
Pin-Priority: ${priority}

",
    notify => Exec["concat_${apt::preferences::apt_preferences_dir}"],
    owner => root, group => 0, mode => 0600;
  }
}