From: Peter Palfrader Date: Sun, 29 Apr 2012 18:57:52 +0000 (+0200) Subject: *sigh* X-Git-Url: https://git.adam-barratt.org.uk/?a=commitdiff_plain;h=ff616a9a63dc5a16092d30649deb84ca45b0e37c;p=mirror%2Fdsa-puppet.git *sigh* --- diff --git a/modules/buildd/manifests/init.pp b/modules/buildd/manifests/init.pp index bdb29eb85..7dded5ea7 100644 --- a/modules/buildd/manifests/init.pp +++ b/modules/buildd/manifests/init.pp @@ -40,11 +40,12 @@ class buildd { require => Package['apt-transport-https'], } - file { '/etc/apt/preferences.d/buildd': + # "bad" extension + file { '/etc/apt/preferences.d/buildd.debian.org': ensure => absent, } file { '/etc/apt/preferences.d/buildd.debian.org': - content => template('buildd/etc/apt/preferences.d/buildd.debian.org'), + content => template('buildd/etc/apt/preferences.d/buildd'), before => File["/etc/apt/sources.list.d/buildd.debian.org.list"], ; } diff --git a/modules/buildd/templates/etc/apt/preferences.d/buildd b/modules/buildd/templates/etc/apt/preferences.d/buildd new file mode 100644 index 000000000..4be1d8ea8 --- /dev/null +++ b/modules/buildd/templates/etc/apt/preferences.d/buildd @@ -0,0 +1,17 @@ +<% if scope.lookupvar('site::nodeinfo')['ldap'].has_key?('architecture') and scope.lookupvar('site::nodeinfo')['ldap']['architecture'][0] == 'armhf' -%> +Package: schroot +Pin: release o=buildd.debian.org +Pin-Priority: 700 + +Package: schroot-common +Pin: release o=buildd.debian.org +Pin-Priority: 700 +<% else -%> +Package: schroot +Pin: release o=buildd.debian.org +Pin-Priority: 500 + +Package: schroot-common +Pin: release o=buildd.debian.org +Pin-Priority: 500 +<% end %> diff --git a/modules/buildd/templates/etc/apt/preferences.d/buildd.debian.org b/modules/buildd/templates/etc/apt/preferences.d/buildd.debian.org deleted file mode 100644 index 4be1d8ea8..000000000 --- a/modules/buildd/templates/etc/apt/preferences.d/buildd.debian.org +++ /dev/null @@ -1,17 +0,0 @@ -<% if scope.lookupvar('site::nodeinfo')['ldap'].has_key?('architecture') and scope.lookupvar('site::nodeinfo')['ldap']['architecture'][0] == 'armhf' -%> -Package: schroot -Pin: release o=buildd.debian.org -Pin-Priority: 700 - -Package: schroot-common -Pin: release o=buildd.debian.org -Pin-Priority: 700 -<% else -%> -Package: schroot -Pin: release o=buildd.debian.org -Pin-Priority: 500 - -Package: schroot-common -Pin: release o=buildd.debian.org -Pin-Priority: 500 -<% end %>