EL8 was shipped with python 3.6, EL9 is being shipped with python 3.9, so let's set python versions accordingly. Change-Id: I5d857a3fbab2143c490016cd6b9cfc78ecb382e5
35 lines
937 B
Puppet
35 lines
937 B
Puppet
# == Class: openstacklib::defaults
|
|
#
|
|
# Default configuration for all openstack-puppet module.
|
|
#
|
|
# This file is loaded in the params.pp of each class.
|
|
#
|
|
class openstacklib::defaults {
|
|
|
|
if ($::os['family'] == 'Debian') {
|
|
$pyvers = '3'
|
|
$pyver3 = '3'
|
|
} elsif ($::os['name'] == 'Fedora') {
|
|
# TODO(tkajinam): This is very outdated and doesn't work with the latest
|
|
# Fedora. We should fix or drop this.
|
|
$pyvers = '3'
|
|
$pyver3 = '3.6'
|
|
} elsif $::os['family'] == 'RedHat' {
|
|
if Integer.new($::os['release']['major']) > 8 {
|
|
$pyvers = '3'
|
|
$pyver3 = '3.9'
|
|
} elsif Integer.new($::os['release']['major']) == 8 {
|
|
$pyvers = '3'
|
|
$pyver3 = '3.6'
|
|
} else {
|
|
$pyvers = ''
|
|
$pyver3 = '2.7'
|
|
}
|
|
} else {
|
|
# TODO(tkajinam) This is left to keep the previous behavior but we should
|
|
# revisit this later.
|
|
$pyvers = ''
|
|
$pyver3 = '2.7'
|
|
}
|
|
}
|