summaryrefslogtreecommitdiff
path: root/sitemodules/profiles
diff options
context:
space:
mode:
Diffstat (limited to 'sitemodules/profiles')
-rw-r--r--sitemodules/profiles/manifests/cacert_selfservice_api.pp50
1 files changed, 50 insertions, 0 deletions
diff --git a/sitemodules/profiles/manifests/cacert_selfservice_api.pp b/sitemodules/profiles/manifests/cacert_selfservice_api.pp
new file mode 100644
index 0000000..a1e9f0d
--- /dev/null
+++ b/sitemodules/profiles/manifests/cacert_selfservice_api.pp
@@ -0,0 +1,50 @@
+# Class: profiles::cacert_selfservice_api
+# =======================================
+#
+# This class defines the cacert_selfservice_api profile that installs the
+# CAcert community self service system API backend
+#
+# Examples
+# --------
+#
+# @example
+# class roles::myhost {
+# include profiles::cacert_selfservice_api
+# }
+#
+# Authors
+# -------
+#
+# Jan Dittberner <jandd@cacert.org>
+#
+# Copyright
+# ---------
+#
+# Copyright 2019 Jan Dittberner
+#
+class profiles::cacert_selfservice_api (
+) {
+ include profiles::cacert_debrepo
+
+ $service_name = 'cacert-selfservice'
+ $log_directory = "/var/log/${service_name}"
+
+ package { $service_name:
+ ensure => latest,
+ require => Apt::Source['cacert'],
+ }
+
+ file { $log_directory:
+ ensure => directory,
+ owner => $service_name,
+ group => 'root',
+ mode => '0750',
+ require => Package[$service_name],
+ }
+
+ service { $service_name:
+ ensure => running,
+ enable => true,
+ require => Package[$service_name],
+ }
+}