Skip to content

Commit

Permalink
Merge pull request voxpupuli#144 from igalic/fix/absolute-facts
Browse files Browse the repository at this point in the history
use $facts when accessing os fact
  • Loading branch information
igalic authored Sep 5, 2019
2 parents d4630a1 + f6e3c9b commit 861a8eb
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions manifests/init.pp
Original file line number Diff line number Diff line change
Expand Up @@ -118,8 +118,8 @@
$os['operatingsystem']
}

unless member($supported_os_names, $::os['name']) {
fail("${::os['name']} not supported")
unless member($supported_os_names, $facts['os']['name']) {
fail("${facts['os']['name']} not supported")
}

$_managed_repos = $manage_os_default_repos ? {
Expand Down
2 changes: 1 addition & 1 deletion manifests/plugin.pp
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
if $pkg_prefix {
$_pkg_prefix = $pkg_prefix
} else {
$_pkg_prefix = $::os['release']['major'] ? {
$_pkg_prefix = $facts['os']['release']['major'] ? {
Variant[Integer[5,5], Enum['5']] => 'yum',
default => 'yum-plugin',
}
Expand Down

0 comments on commit 861a8eb

Please sign in to comment.