Puppet Class: jboss::internal::compatibility::initsystem
- Defined in:
- manifests/internal/compatibility/initsystem.pp
Overview
Class: jboss::internal::compatibility::initsystem
INTERNAL CLASS!
4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 |
# File 'manifests/internal/compatibility/initsystem.pp', line 4
class jboss::internal::compatibility::initsystem {
case $::osfamily {
'RedHat': {
case $::operatingsystem {
'RedHat', 'CentOS', 'OracleLinux', 'Scientific', 'OEL': {
if (versioncmp($::operatingsystemrelease, '7.0') >= 0) {
$initsystem = 'SystemD'
} else {
$initsystem = 'SystemV'
}
}
'Fedora': {
if (versioncmp($::operatingsystemrelease, '21') >= 0) {
$initsystem = 'SystemD'
} else {
$initsystem = 'SystemV'
}
}
default: {
fail("Unsupported OS: ${::operatingsystem}")
}
}
}
'Debian': {
case $::operatingsystem {
'Ubuntu': {
if (versioncmp($::operatingsystemrelease, '15.04') >= 0) {
$initsystem = 'SystemD'
} else {
$initsystem = 'SystemV'
}
}
'Debian': {
if (versioncmp($::operatingsystemrelease, '8') >= 0) {
$initsystem = 'SystemD'
} else {
$initsystem = 'SystemV'
}
}
default: {
fail("Unsupported OS: ${::operatingsystem}")
}
}
}
default: {
fail("Unsupported OS family: ${::osfamily}. Supporting only RHEL and Debian systems. Consult README file.")
}
}
}
|