Merged tmakinen/puppet into master
This commit is contained in:
commit
3e958afce1
5 changed files with 33 additions and 6 deletions
|
@ -118,8 +118,16 @@ class abusesa::search {
|
||||||
|
|
||||||
python::setup::install { "/usr/local/src/abusesa-search": }
|
python::setup::install { "/usr/local/src/abusesa-search": }
|
||||||
|
|
||||||
package { [ "python-BeautifulSoup",
|
package { "python-BeautifulSoup":
|
||||||
"python-lxml", ]:
|
ensure => installed,
|
||||||
|
name => $::operatingsystem ? {
|
||||||
|
"debian" => "python-beautifulsoup",
|
||||||
|
"ubuntu" => "python-beautifulsoup",
|
||||||
|
default => "python-BeautifulSoup",
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
package { "python-lxml":
|
||||||
ensure => installed,
|
ensure => installed,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -8,7 +8,7 @@
|
||||||
# Source function library.
|
# Source function library.
|
||||||
. /etc/init.d/functions
|
. /etc/init.d/functions
|
||||||
|
|
||||||
PATH=${PATH}:/usr/local/lib/lmgrd
|
PATH=/bin:/usr/bin:/usr/local/bin:/sbin:/usr/sbin:/usr/local/sbin:/usr/local/lib/lmgrd
|
||||||
|
|
||||||
# Determine license id
|
# Determine license id
|
||||||
licid=`basename $0 | cut -d '.' -f 2-`
|
licid=`basename $0 | cut -d '.' -f 2-`
|
||||||
|
|
|
@ -6,6 +6,11 @@
|
||||||
# Array of NTP servers using [] will disable external servers.
|
# Array of NTP servers using [] will disable external servers.
|
||||||
# Defaults to pool.ntp.org.
|
# Defaults to pool.ntp.org.
|
||||||
#
|
#
|
||||||
|
# $ntp_strict:
|
||||||
|
# When set to "false", permit time synchronization by default. Required
|
||||||
|
# for pool.ntp.org or similar server names which have multiple addresses.
|
||||||
|
# Defaults to "true".
|
||||||
|
#
|
||||||
# $ntp_client_networks:
|
# $ntp_client_networks:
|
||||||
# Array of networks that are allowed to query this server in format
|
# Array of networks that are allowed to query this server in format
|
||||||
# [ "192.168.1.0/255.255.255.0", "192.168.2.0/255.255.255.0", ] or
|
# [ "192.168.1.0/255.255.255.0", "192.168.2.0/255.255.255.0", ] or
|
||||||
|
@ -17,6 +22,10 @@ class ntpd {
|
||||||
$ntp_server = ["pool.ntp.org"]
|
$ntp_server = ["pool.ntp.org"]
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if !$ntp_strict {
|
||||||
|
$ntp_strict = "true"
|
||||||
|
}
|
||||||
|
|
||||||
case $::operatingsystem {
|
case $::operatingsystem {
|
||||||
"fedora": {
|
"fedora": {
|
||||||
case $::operatingsystemrelease {
|
case $::operatingsystemrelease {
|
||||||
|
|
|
@ -3,13 +3,20 @@
|
||||||
tinker panic 0
|
tinker panic 0
|
||||||
|
|
||||||
<% end -%>
|
<% end -%>
|
||||||
|
<% if @ntp_strict == "true" -%>
|
||||||
# By default deny everything.
|
# By default deny everything.
|
||||||
restrict -4 default ignore
|
restrict -4 default ignore
|
||||||
restrict -6 default ignore
|
restrict -6 default ignore
|
||||||
|
<% else -%>
|
||||||
|
# Permit time synchronization with our time source, but do not
|
||||||
|
# permit the source to query or modify the service on this system.
|
||||||
|
restrict -4 default nomodify notrap nopeer noquery
|
||||||
|
restrict -6 default nomodify notrap nopeer noquery
|
||||||
|
<% end -%>
|
||||||
|
|
||||||
# Local users may interrogate the ntp server more closely.
|
# Local users may interrogate the ntp server more closely.
|
||||||
restrict 127.0.0.1
|
restrict 127.0.0.1 nomodify
|
||||||
restrict ::1
|
restrict ::1 nomodify
|
||||||
|
|
||||||
# Drift file.
|
# Drift file.
|
||||||
driftfile /var/lib/ntp/ntp.drift
|
driftfile /var/lib/ntp/ntp.drift
|
||||||
|
@ -17,7 +24,9 @@ driftfile /var/lib/ntp/ntp.drift
|
||||||
# Remote servers.
|
# Remote servers.
|
||||||
<% @ntp_server.each do |server| -%>
|
<% @ntp_server.each do |server| -%>
|
||||||
server <%= server %>
|
server <%= server %>
|
||||||
|
<% if @ntp_strict == "true" -%>
|
||||||
restrict <%= server %> nomodify notrap nopeer noquery
|
restrict <%= server %> nomodify notrap nopeer noquery
|
||||||
|
<% end -%>
|
||||||
<% end -%>
|
<% end -%>
|
||||||
<% if @is_virtual == "false" -%>
|
<% if @is_virtual == "false" -%>
|
||||||
|
|
||||||
|
|
|
@ -63,7 +63,7 @@ class solr {
|
||||||
"/srv/solr/run/solr-webapp",
|
"/srv/solr/run/solr-webapp",
|
||||||
"/srv/solr/spool", ]:
|
"/srv/solr/spool", ]:
|
||||||
ensure => directory,
|
ensure => directory,
|
||||||
mode => "0770",
|
mode => "2770",
|
||||||
owner => "solr",
|
owner => "solr",
|
||||||
group => "solr",
|
group => "solr",
|
||||||
require => File["/srv/solr"],
|
require => File["/srv/solr"],
|
||||||
|
@ -76,6 +76,7 @@ class solr {
|
||||||
group => "solr",
|
group => "solr",
|
||||||
content => template("solr/solr.xml.erb"),
|
content => template("solr/solr.xml.erb"),
|
||||||
require => File["/srv/solr/cores"],
|
require => File["/srv/solr/cores"],
|
||||||
|
notify => Service["solr"],
|
||||||
}
|
}
|
||||||
|
|
||||||
file { "/srv/solr/run/start.jar":
|
file { "/srv/solr/run/start.jar":
|
||||||
|
|
Loading…
Add table
Reference in a new issue