X-Git-Url: https://review.fuel-infra.org/gitweb?a=blobdiff_plain;f=manifests%2Fparams.pp;h=3ce8f4864007f151262e64f0fab3208bfa1ed5a3;hb=refs%2Fheads%2Frelease-prep;hp=6167ea505d75adc7bc52d3442d1d0c6b546e4076;hpb=18fe46c4b19729099bfea98f0a353bbdc087f717;p=puppet-modules%2Fpuppetlabs-apt.git diff --git a/manifests/params.pp b/manifests/params.pp index 6167ea5..3ce8f48 100644 --- a/manifests/params.pp +++ b/manifests/params.pp @@ -3,7 +3,6 @@ # @api private # class apt::params { - if $facts['os']['family'] != 'Debian' { fail('This module only works on Debian or derivatives like Ubuntu') } @@ -44,7 +43,7 @@ class apt::params { 'list' => { 'path' => $sources_list_d, 'ext' => '.list', - } + }, } $update_defaults = { @@ -71,31 +70,20 @@ class apt::params { 'apt.conf.d' => false, } - $source_key_defaults = { - 'server' => $keyserver, - 'options' => undef, - 'content' => undef, - 'source' => undef, - } - $include_defaults = { 'deb' => true, 'src' => false, } - case $facts['os']['name']{ + case $facts['os']['name'] { 'Debian': { - $backports = { - 'location' => 'http://deb.debian.org/debian', - 'repos' => 'main contrib non-free', - } + $backports = { + 'location' => 'http://deb.debian.org/debian', + 'repos' => 'main contrib non-free', + } $ppa_options = undef $ppa_package = undef - if versioncmp($facts['os']['release']['major'], '9') >= 0 { - $auth_conf_owner = '_apt' - } else { - $auth_conf_owner = 'root' - } + $auth_conf_owner = '_apt' } 'Ubuntu': { $backports = { @@ -103,13 +91,9 @@ class apt::params { 'key' => '630239CC130E1A7FD81A27B140976EAF437D05B5', 'repos' => 'main universe multiverse restricted', } - $ppa_options = '-y' + $ppa_options = ['-y'] $ppa_package = 'software-properties-common' - if versioncmp($facts['os']['release']['full'], '16.04') >= 0 { - $auth_conf_owner = '_apt' - } else { - $auth_conf_owner = 'root' - } + $auth_conf_owner = '_apt' } undef: { fail('Unable to determine value for fact os[\"name\"]')