summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJesse Luehrs <doy@tozt.net>2017-11-06 01:37:32 -0500
committerJesse Luehrs <doy@tozt.net>2017-11-06 01:37:32 -0500
commitf8cdd73c0639ec66f1090ce946fc32265f63369c (patch)
tree0f63df81b35c842857b483b1653ccad1e25362aa
parent81003b218f43791b1d616590c0e61706bfb230e4 (diff)
downloadpuppet-tozt-f8cdd73c0639ec66f1090ce946fc32265f63369c.tar.gz
puppet-tozt-f8cdd73c0639ec66f1090ce946fc32265f63369c.zip
get a bit of the roundcubemail config in place
still need to add the actual configuration for things like the database
-rw-r--r--modules/roundcubemail/files/roundcubemail.service10
-rw-r--r--modules/roundcubemail/manifests/init.pp24
-rw-r--r--modules/systemd/manifests/init.pp6
-rw-r--r--modules/tozt/manifests/site.pp2
4 files changed, 42 insertions, 0 deletions
diff --git a/modules/roundcubemail/files/roundcubemail.service b/modules/roundcubemail/files/roundcubemail.service
new file mode 100644
index 0000000..94a9bf6
--- /dev/null
+++ b/modules/roundcubemail/files/roundcubemail.service
@@ -0,0 +1,10 @@
+[Unit]
+Description=roundcubemail
+
+[Service]
+User=http
+Group=http
+ExecStart=/usr/bin/spawn-fcgi -a 127.0.0.1 -p 9000 -f /usr/bin/php-cgi -C 2 -n
+
+[Install]
+WantedBy=multi-user.target
diff --git a/modules/roundcubemail/manifests/init.pp b/modules/roundcubemail/manifests/init.pp
new file mode 100644
index 0000000..431d4ea
--- /dev/null
+++ b/modules/roundcubemail/manifests/init.pp
@@ -0,0 +1,24 @@
+class roundcubemail {
+ include systemd
+
+ package { ['roundcubemail', 'spawn-fcgi']:
+ ensure => installed;
+ }
+
+ file { '/etc/systemd/system/roundcubemail.service':
+ source => 'puppet:///modules/roundcubemail/roundcubemail.service',
+ require => [
+ Package['roundcubemail'],
+ Package['spawn-fcgi'],
+ ],
+ notify => Exec['systemctl daemon-reload'];
+ }
+
+ service { 'roundcubemail':
+ ensure => running,
+ require => [
+ File['/etc/systemd/system/roundcubemail.service'],
+ Exec['systemctl daemon-reload'],
+ ];
+ }
+}
diff --git a/modules/systemd/manifests/init.pp b/modules/systemd/manifests/init.pp
new file mode 100644
index 0000000..58835cb
--- /dev/null
+++ b/modules/systemd/manifests/init.pp
@@ -0,0 +1,6 @@
+class systemd {
+ exec { 'systemctl daemon-reload':
+ path => '/usr/bin',
+ refreshonly => true;
+ }
+}
diff --git a/modules/tozt/manifests/site.pp b/modules/tozt/manifests/site.pp
index 3cf1638..b6b43ff 100644
--- a/modules/tozt/manifests/site.pp
+++ b/modules/tozt/manifests/site.pp
@@ -1,4 +1,6 @@
class tozt::site {
+ include roundcubemail
+
nginx::site {
"blog-tls":
source => 'puppet:///modules/tozt/nginx/blog-tls.conf',