Fix python 2.6 usage on CentOS 5
This commit is contained in:
parent
16644e0ad6
commit
b0f01e7318
4 changed files with 45 additions and 48 deletions
|
@ -10,22 +10,6 @@
|
|||
#
|
||||
class abusesa {
|
||||
|
||||
case $::operatingsystem {
|
||||
"centos","redhat": {
|
||||
case $::operatingsystemrelease {
|
||||
/^5/: {
|
||||
package { "python26":
|
||||
ensure => installed,
|
||||
}
|
||||
Python::Setup::Install["/usr/local/src/abusesa"] {
|
||||
python => "python2.6",
|
||||
require => Package["python26"],
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if !$abusesa_package {
|
||||
if $abusesa_package_latest {
|
||||
$abusesa_package = $abusesa_package_latest
|
||||
|
@ -86,7 +70,16 @@ class abusesa {
|
|||
require => File["/usr/local/src/abusesa.tar.gz"],
|
||||
before => Python::Setup::Install["/usr/local/src/abusesa"],
|
||||
}
|
||||
python::setup::install { "/usr/local/src/abusesa": }
|
||||
|
||||
if $::operatingsystem in ["CentOS","RedHat"] and versioncmp($::operatingsystemrelease, "6") < 0 {
|
||||
include python::python26
|
||||
python::setup::install { "/usr/local/src/abusesa":
|
||||
python => "python2.6",
|
||||
require => Package["python26"],
|
||||
}
|
||||
} else {
|
||||
python::setup::install { "/usr/local/src/abusesa": }
|
||||
}
|
||||
|
||||
if $abusesa_botnets {
|
||||
class { "abusehelper::init":
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue