Skip to content

Commit bae5907

Browse files
committed
Support RedHat/CentOS 8
1 parent ff8df63 commit bae5907

File tree

3 files changed

+12
-4
lines changed

3 files changed

+12
-4
lines changed

manifests/install.pp

+4
Original file line numberDiff line numberDiff line change
@@ -275,6 +275,10 @@
275275
$pip_category = undef
276276
$pip_package = "${python}-pip"
277277
$pip_provider = $python.regsubst(/^.*python3\.?/,'pip3.').regsubst(/\.$/,'')
278+
} elsif ($facts['os']['family'] == 'RedHat') and (versioncmp($facts['os']['release']['major'], '8') >= 0) {
279+
$pip_category = undef
280+
$pip_package = 'python3-pip'
281+
$pip_provider = pip3
278282
} elsif ($facts['os']['family'] == 'RedHat') and (versioncmp($facts['os']['release']['major'], '7') >= 0) {
279283
$pip_category = undef
280284
$pip_package = 'python2-pip'

manifests/params.pp

+6-3
Original file line numberDiff line numberDiff line change
@@ -46,8 +46,11 @@
4646
default => 'gunicorn',
4747
}
4848

49-
$version = $facts['os']['release']['major'] ? {
50-
'20.04' => '3',
51-
default => 'system',
49+
if $facts['os']['family'] == 'RedHat' and $facts['os']['release']['major'] == '8' {
50+
$version = '3'
51+
} elsif $facts['os']['release']['major'] == '20.04' {
52+
$version = '3'
53+
} else {
54+
$version = 'system'
5255
}
5356
}

metadata.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,8 @@
2525
{
2626
"operatingsystem": "CentOS",
2727
"operatingsystemrelease": [
28-
"7"
28+
"7",
29+
"8"
2930
]
3031
},
3132
{

0 commit comments

Comments
 (0)