summaryrefslogtreecommitdiff
path: root/src/grp-journal/grp-remote/systemd-journal-gatewayd
diff options
context:
space:
mode:
authorLuke Shumaker <lukeshu@sbcglobal.net>2016-08-17 01:33:02 -0400
committerLuke Shumaker <lukeshu@sbcglobal.net>2016-08-17 01:33:02 -0400
commit610d801297fe7e46c319e6da4e6571aaded630dd (patch)
treed27f6d077694b84ed9881c99b2894701932ca6e1 /src/grp-journal/grp-remote/systemd-journal-gatewayd
parent7648bff2717c24e9f5c90ec9e4588eda510aba9d (diff)
more
Diffstat (limited to 'src/grp-journal/grp-remote/systemd-journal-gatewayd')
-rw-r--r--src/grp-journal/grp-remote/systemd-journal-gatewayd/Makefile3
-rw-r--r--src/grp-journal/grp-remote/systemd-journal-gatewayd/systemd-journal-gateway.sysusers9
-rw-r--r--src/grp-journal/grp-remote/systemd-journal-gatewayd/systemd-journal-gatewayd.service.in29
-rw-r--r--src/grp-journal/grp-remote/systemd-journal-gatewayd/systemd-journal-gatewayd.socket16
4 files changed, 57 insertions, 0 deletions
diff --git a/src/grp-journal/grp-remote/systemd-journal-gatewayd/Makefile b/src/grp-journal/grp-remote/systemd-journal-gatewayd/Makefile
index 05df34a71d..f6e07621a8 100644
--- a/src/grp-journal/grp-remote/systemd-journal-gatewayd/Makefile
+++ b/src/grp-journal/grp-remote/systemd-journal-gatewayd/Makefile
@@ -60,6 +60,9 @@ nodist_systemunit_DATA += \
dist_gatewayddocumentroot_DATA = \
src/journal-remote/browse.html
+dist_sysusers_DATA += \
+ sysusers.d/systemd-journal-gateway.conf
+
endif # HAVE_MICROHTTPD
EXTRA_DIST += \
diff --git a/src/grp-journal/grp-remote/systemd-journal-gatewayd/systemd-journal-gateway.sysusers b/src/grp-journal/grp-remote/systemd-journal-gatewayd/systemd-journal-gateway.sysusers
new file mode 100644
index 0000000000..a60fcf4d42
--- /dev/null
+++ b/src/grp-journal/grp-remote/systemd-journal-gatewayd/systemd-journal-gateway.sysusers
@@ -0,0 +1,9 @@
+# This file is part of systemd.
+#
+# systemd is free software; you can redistribute it and/or modify it
+# under the terms of the GNU Lesser General Public License as published by
+# the Free Software Foundation; either version 2.1 of the License, or
+# (at your option) any later version.
+
+m4_ifdef(`HAVE_MICROHTTPD',
+u systemd-journal-gateway - "systemd Journal Gateway"
diff --git a/src/grp-journal/grp-remote/systemd-journal-gatewayd/systemd-journal-gatewayd.service.in b/src/grp-journal/grp-remote/systemd-journal-gatewayd/systemd-journal-gatewayd.service.in
new file mode 100644
index 0000000000..f4f845841d
--- /dev/null
+++ b/src/grp-journal/grp-remote/systemd-journal-gatewayd/systemd-journal-gatewayd.service.in
@@ -0,0 +1,29 @@
+# This file is part of systemd.
+#
+# systemd is free software; you can redistribute it and/or modify it
+# under the terms of the GNU Lesser General Public License as published by
+# the Free Software Foundation; either version 2.1 of the License, or
+# (at your option) any later version.
+
+[Unit]
+Description=Journal Gateway Service
+Documentation=man:systemd-journal-gatewayd(8)
+Requires=systemd-journal-gatewayd.socket
+
+[Service]
+ExecStart=@rootlibexecdir@/systemd-journal-gatewayd
+User=systemd-journal-gateway
+Group=systemd-journal-gateway
+SupplementaryGroups=systemd-journal
+PrivateTmp=yes
+PrivateDevices=yes
+PrivateNetwork=yes
+ProtectSystem=full
+ProtectHome=yes
+
+# If there are many split upjournal files we need a lot of fds to
+# access them all and combine
+LimitNOFILE=16384
+
+[Install]
+Also=systemd-journal-gatewayd.socket
diff --git a/src/grp-journal/grp-remote/systemd-journal-gatewayd/systemd-journal-gatewayd.socket b/src/grp-journal/grp-remote/systemd-journal-gatewayd/systemd-journal-gatewayd.socket
new file mode 100644
index 0000000000..79d9b04210
--- /dev/null
+++ b/src/grp-journal/grp-remote/systemd-journal-gatewayd/systemd-journal-gatewayd.socket
@@ -0,0 +1,16 @@
+# This file is part of systemd.
+#
+# systemd is free software; you can redistribute it and/or modify it
+# under the terms of the GNU Lesser General Public License as published by
+# the Free Software Foundation; either version 2.1 of the License, or
+# (at your option) any later version.
+
+[Unit]
+Description=Journal Gateway Service Socket
+Documentation=man:systemd-journal-gatewayd(8)
+
+[Socket]
+ListenStream=19531
+
+[Install]
+WantedBy=sockets.target