Skip to content
Snippets Groups Projects
Verified Commit 98b6713a authored by Varac's avatar Varac
Browse files

Install python-treq from strech on jessie nodes

New soledad-common depends on `python-treq`, which
is only available in debian stretch.
We pin all stretch packages to 1 (same as for sid), which
means (from `man apt_preferences`):

    "causes a version to be installed only if there is no
    installed version of the package"

- Resolves: #8836
parent 772f0757
Branches
Tags
No related merge requests found
...@@ -20,11 +20,14 @@ class site_apt { ...@@ -20,11 +20,14 @@ class site_apt {
$apt_platform_codename = $platform_sources['apt']['codename'] $apt_platform_codename = $platform_sources['apt']['codename']
} }
# needed on jessie hosts for getting pnp4nagios from testing # needed on jessie hosts for getting python-treq from stretch
# see https://0xacab.org/leap/platform/issues/8836
if ( $::operatingsystemmajrelease == '8' ) { if ( $::operatingsystemmajrelease == '8' ) {
$use_next_release = true $use_next_release = true
$custom_preferences = template("site_apt/${::operatingsystem}/preferences_jessie.erb")
} else { } else {
$use_next_release = false $use_next_release = false
$custom_preferences = ''
} }
class { 'apt': class { 'apt':
...@@ -33,6 +36,7 @@ class site_apt { ...@@ -33,6 +36,7 @@ class site_apt {
security_url => $apt_url_security, security_url => $apt_url_security,
backports_url => $apt_url_backports, backports_url => $apt_url_backports,
use_next_release => $use_next_release, use_next_release => $use_next_release,
custom_preferences => $custom_preferences,
repos => 'main' repos => 'main'
} }
......
Explanation: Debian jessie
Package: *
Pin: release o=Debian,n=jessie
Pin-Priority: 990
Explanation: Debian stretch
Package: *
Pin: release o=Debian,n=stretch
Pin-Priority: 1
Explanation: Debian sid
Package: *
Pin: release o=Debian,n=sid
Pin-Priority: 1
Explanation: Debian fallback
Package: *
Pin: release o=Debian
Pin-Priority: -10
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment