Added support for RHEL and did some syntax cleaning

Assume that "RedHat" also works where "CentOS" does.
This commit is contained in:
Ossi Salmi 2012-09-05 16:42:02 +03:00
parent e9aae1dcf6
commit 24ecb51f6f
63 changed files with 544 additions and 497 deletions

View file

@ -12,9 +12,9 @@ class lynx {
$www_default_url = "http://www.${domain}"
}
if $operatingsystem != "OpenBSD" {
if $::operatingsystem != "OpenBSD" {
package { "lynx":
name => $operatingsystem ? {
name => $::operatingsystem ? {
"ubuntu" => "lynx-cur",
default => "lynx",
},
@ -22,7 +22,7 @@ class lynx {
}
}
if $operatingsystem == "OpenBSD" {
if $::operatingsystem == "OpenBSD" {
exec { "add-local-lynx-config":
command => "echo 'INCLUDE:/etc/lynx-site.cfg' >> /etc/lynx.cfg",
path => "/bin:/usr/bin:/usr/local/bin:/sbin:/usr/sbin:/usr/local/sbin",
@ -32,7 +32,7 @@ class lynx {
}
file { "lynx-site.cfg":
name => $operatingsystem ? {
name => $::operatingsystem ? {
"ubuntu" => "/etc/lynx-cur/local.cfg",
default => "/etc/lynx-site.cfg",
},
@ -40,11 +40,11 @@ class lynx {
content => template("lynx/lynx-site.cfg.erb"),
mode => 0644,
owner => "root",
group => $operatingsystem ? {
group => $::operatingsystem ? {
"openbsd" => "wheel",
default => "root",
},
require => $operatingsystem ? {
require => $::operatingsystem ? {
"openbsd" => undef,
default => Package["lynx"],
},