1 # This adds the necessary components to get backports for ubuntu and debian
6 # The ubuntu/debian release name. Defaults to $lsbdistcodename. Setting this
7 # manually can cause undefined behavior. (Read: universe exploding)
12 # The priority that should be awarded by default to all packages coming from
13 # the Debian Backports project.
17 # include apt::backports
19 # class { 'apt::backports':
25 # Ben Hughes, I think. At least blame him if this goes wrong.
26 # I just added puppet doc.
30 # Copyright 2011 Puppet Labs Inc, unless otherwise noted.
32 $release = $::lsbdistcodename,
33 $location = $::apt::params::backports_location,
35 ) inherits apt::params {
37 if ! is_integer($pin_priority) {
38 fail('$pin_priority must be an integer')
41 if $::lsbdistid == 'LinuxMint' {
42 if $::lsbdistcodename == 'debian' {
44 $release_real = 'wheezy'
47 $release_real = $::lsbdistcodename ? {
56 $distid = $::lsbdistid
57 $release_real = downcase($release)
61 'debian' => 'A1BD8E9D78F7FE5C3E65D8AF8B48AD6246925553',
62 'ubuntu' => '630239CC130E1A7FD81A27B140976EAF437D05B5',
65 'debian' => 'main contrib non-free',
66 'ubuntu' => 'main universe multiverse restricted',
69 apt::pin { 'backports':
70 before => Apt::Source['backports'],
71 release => "${release_real}-backports",
72 priority => $pin_priority,
75 apt::source { 'backports':
76 location => $location,
77 release => "${release_real}-backports",
80 key_server => 'pgp.mit.edu',