summaryrefslogtreecommitdiff
path: root/services
diff options
context:
space:
mode:
authorJulien Dessaux2017-08-25 22:58:10 +0200
committerJulien Dessaux2017-08-25 22:58:10 +0200
commit46cd3abd238a4d9211d9a31677cf518724b504b2 (patch)
treeb2744788cbc74bccc7262fda852dace5c0d75cf0 /services
parentFixed sshd policy mistake (diff)
downloadmasterfiles-46cd3abd238a4d9211d9a31677cf518724b504b2.tar.gz
masterfiles-46cd3abd238a4d9211d9a31677cf518724b504b2.tar.bz2
masterfiles-46cd3abd238a4d9211d9a31677cf518724b504b2.zip
Added nagios server policy
Diffstat (limited to 'services')
-rw-r--r--services/applications.cf2
-rw-r--r--services/applications/fcgiwrap.cf15
-rw-r--r--services/applications/nagios.cf13
-rw-r--r--services/main.cf5
4 files changed, 28 insertions, 7 deletions
diff --git a/services/applications.cf b/services/applications.cf
index 07ac9e0..6a5af1d 100644
--- a/services/applications.cf
+++ b/services/applications.cf
@@ -3,6 +3,8 @@ body file control
inputs => {
"services/applications/bareos_fd.cf",
"services/applications/check_mk.cf",
+ "services/applications/fcgiwrap.cf",
+ "services/applications/nagios.cf",
"services/applications/sshd.cf",
};
}
diff --git a/services/applications/fcgiwrap.cf b/services/applications/fcgiwrap.cf
index af2e8f8..7c491c0 100644
--- a/services/applications/fcgiwrap.cf
+++ b/services/applications/fcgiwrap.cf
@@ -1,8 +1,11 @@
-bundle common fcgiwrap
+bundle agent fcgiwrap(user, group, mode)
{
- vars:
- use_fcgiwrap::
- "packages" slist => {
- "fcgiwrap",
- };
+ methods:
+ freebsd::
+ "any" usebundle => install_package("fcgiwrap");
+ "any" usebundle => add_rc_conf_line("fcgiwrap_enable=\"YES\"");
+ "any" usebundle => add_rc_conf_line("fcgiwrap_user=\"$(user)\"");
+ "any" usebundle => add_rc_conf_line("fcgiwrap_mode=\"$(mode)\"");
+ "any" usebundle => add_rc_conf_line("fcgiwrap_owner=\"$(user)\"");
+ "any" usebundle => add_rc_conf_line("fcgiwrap_group=\"$(group)\"");
}
diff --git a/services/applications/nagios.cf b/services/applications/nagios.cf
new file mode 100644
index 0000000..156fdfb
--- /dev/null
+++ b/services/applications/nagios.cf
@@ -0,0 +1,13 @@
+bundle agent nagios
+{
+ vars:
+ nagios::
+ "packages" slist => {
+ "nagios4",
+ "nginx",
+ "php56",
+ };
+ methods:
+ nagios::
+ "any" usebundle => fcgiwrap("nagios", "www", "770");
+}
diff --git a/services/main.cf b/services/main.cf
index e6d7642..e861bf4 100644
--- a/services/main.cf
+++ b/services/main.cf
@@ -1,4 +1,4 @@
-bundle common classify
+bundle agent classify
{
vars:
any::
@@ -33,4 +33,7 @@ bundle common classify
"legend",
};
"mail_servers" or => { "legend" };
+ methods:
+ nagios::
+ "any" usebundle => nagios;
}