Skip to content

Commit

Permalink
Merge pull request #543 from puppetlabs/revert-542-fix_apt_params
Browse files Browse the repository at this point in the history
Revert "Fix use of $::apt::params::backports and $::apt::params::xfac…
  • Loading branch information
bmjen committed Jun 22, 2015
2 parents 8f5cb73 + 70c1863 commit 5594aa1
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 10 deletions.
12 changes: 6 additions & 6 deletions manifests/backports.pp
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
$repos = undef,
$key = undef,
$pin = 200,
) inherits apt::params {
){
if $location {
validate_string($location)
$_location = $location
Expand All @@ -29,18 +29,18 @@
}
}

if ($::apt::params::xfacts['lsbdistid'] == 'debian' or $::apt::params::xfacts['lsbdistid'] == 'ubuntu') {
if ($::apt::xfacts['lsbdistid'] == 'debian' or $::apt::xfacts['lsbdistid'] == 'ubuntu') {
unless $location {
$_location = $::apt::params::backports['location']
$_location = $::apt::backports['location']
}
unless $release {
$_release = "${::apt::params::xfacts['lsbdistcodename']}-backports"
$_release = "${::apt::xfacts['lsbdistcodename']}-backports"
}
unless $repos {
$_repos = $::apt::params::backports['repos']
$_repos = $::apt::backports['repos']
}
unless $key {
$_key = $::apt::params::backports['key']
$_key = $::apt::backports['key']
}
} else {
unless $location and $release and $repos and $key {
Expand Down
6 changes: 2 additions & 4 deletions manifests/ppa.pp
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,15 @@
define apt::ppa(
$ensure = 'present',
$options = $::apt::ppa_options,
$release = $::apt::params::xfacts['lsbdistcodename'],
$release = $::apt::xfacts['lsbdistcodename'],
$package_name = $::apt::ppa_package,
$package_manage = false,
) {
include 'apt::params'

unless $release {
fail('lsbdistcodename fact not available: release parameter required')
}

if $::apt::params::xfacts['lsbdistid'] == 'Debian' {
if $::apt::xfacts['lsbdistid'] == 'Debian' {
fail('apt::ppa is not currently supported on Debian.')
}

Expand Down

0 comments on commit 5594aa1

Please sign in to comment.