Don't install rubygem packages on CentOS 6
Because rails is missing from EPEL, some manual installation is needed. See puppet/README.CentOS for instructions.
This commit is contained in:
parent
832fb1f316
commit
3f1bb7a278
2 changed files with 28 additions and 2 deletions
5
puppet/README.CentOS
Normal file
5
puppet/README.CentOS
Normal file
|
@ -0,0 +1,5 @@
|
||||||
|
Installing the required gems on CentOS 6:
|
||||||
|
|
||||||
|
yum install ruby ruby-devel rubygems sqlite sqlite-devel
|
||||||
|
gem install --no-rdoc --no-ri rubygems-update && update_rubygems
|
||||||
|
gem install --no-rdoc --no-ri mongrel rails sqlite3
|
|
@ -203,6 +203,14 @@ class puppet::server::common inherits puppet::client {
|
||||||
|
|
||||||
if $puppet_storeconfigs != "none" {
|
if $puppet_storeconfigs != "none" {
|
||||||
case $operatingsystem {
|
case $operatingsystem {
|
||||||
|
"centos": {
|
||||||
|
if $operatingsystemrelease =~ /^[1-5]/ {
|
||||||
|
package { [ "rubygem-rails",
|
||||||
|
"rubygem-sqlite3-ruby", ]:
|
||||||
|
ensure => installed,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
"debian","ubuntu": {
|
"debian","ubuntu": {
|
||||||
package { [ "rails",
|
package { [ "rails",
|
||||||
regsubst($rubyversion, '^([0-9]+\.[0-9]+)\..*', 'libsqlite3-ruby\1'), ]:
|
regsubst($rubyversion, '^([0-9]+\.[0-9]+)\..*', 'libsqlite3-ruby\1'), ]:
|
||||||
|
@ -226,6 +234,10 @@ class puppet::server::common inherits puppet::client {
|
||||||
|
|
||||||
package { "ruby-rrd":
|
package { "ruby-rrd":
|
||||||
name => $operatingsystem ? {
|
name => $operatingsystem ? {
|
||||||
|
centos => $operatingsystemrelease ? {
|
||||||
|
/^[1-5]/ => "ruby-RRDtool",
|
||||||
|
default => "rrdtool-ruby",
|
||||||
|
},
|
||||||
debian => regsubst($rubyversion, '^([0-9]+\.[0-9]+)\..*', 'librrd-ruby\1'),
|
debian => regsubst($rubyversion, '^([0-9]+\.[0-9]+)\..*', 'librrd-ruby\1'),
|
||||||
ubuntu => regsubst($rubyversion, '^([0-9]+\.[0-9]+)\..*', 'librrd-ruby\1'),
|
ubuntu => regsubst($rubyversion, '^([0-9]+\.[0-9]+)\..*', 'librrd-ruby\1'),
|
||||||
openbsd => "ruby-rrd",
|
openbsd => "ruby-rrd",
|
||||||
|
@ -375,18 +387,27 @@ class puppet::server::mongrel {
|
||||||
$puppet_listenports = [ "18140", "18141", "18142", "18143", ]
|
$puppet_listenports = [ "18140", "18141", "18142", "18143", ]
|
||||||
}
|
}
|
||||||
|
|
||||||
include ::mongrel
|
|
||||||
include ldap::client::ruby
|
include ldap::client::ruby
|
||||||
|
|
||||||
service { "puppetmaster":
|
service { "puppetmaster":
|
||||||
ensure => running,
|
ensure => running,
|
||||||
enable => true,
|
enable => true,
|
||||||
hasstatus => true,
|
hasstatus => true,
|
||||||
require => Package["puppetmaster", "mongrel"],
|
|
||||||
subscribe => File["/etc/puppet/fileserver.conf",
|
subscribe => File["/etc/puppet/fileserver.conf",
|
||||||
"/etc/puppet/puppet.conf"],
|
"/etc/puppet/puppet.conf"],
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if $operatingsystem == "CentOS" and $operatingsystemrelease !~ /^[1-5]/ {
|
||||||
|
Service["puppetmaster"] {
|
||||||
|
require => Package["puppetmaster"]
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
include ::mongrel
|
||||||
|
Service["puppetmaster"] {
|
||||||
|
require => Package["puppetmaster", "mongrel"]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
case $operatingsystem {
|
case $operatingsystem {
|
||||||
debian,ubuntu: {
|
debian,ubuntu: {
|
||||||
file { "/etc/default/puppetmaster":
|
file { "/etc/default/puppetmaster":
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue