summarylogtreecommitdiffstats
path: root/rserve-sandbox-docker.service
diff options
context:
space:
mode:
authorfrnmst/Franco Masotti2016-10-19 14:37:24 +0200
committerfrnmst/Franco Masotti2016-10-19 14:37:24 +0200
commit343add4746671ace27c6cd1f6637ed37c03d75c7 (patch)
treeea30af53202018bb15e4099bfaeef61602479505 /rserve-sandbox-docker.service
downloadaur-343add4746671ace27c6cd1f6637ed37c03d75c7.tar.gz
Initial commit.
Diffstat (limited to 'rserve-sandbox-docker.service')
-rw-r--r--rserve-sandbox-docker.service45
1 files changed, 45 insertions, 0 deletions
diff --git a/rserve-sandbox-docker.service b/rserve-sandbox-docker.service
new file mode 100644
index 000000000000..9e5173a756ab
--- /dev/null
+++ b/rserve-sandbox-docker.service
@@ -0,0 +1,45 @@
+#
+# rserve-sandbox-docker.service
+#
+# Copyright (C) 2016 frnmst (Franco Masotti) <franco.masotti@student.unife.it>
+#
+# This file is part of cplint-installer.
+#
+# cplint-installer is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# cplint-installer is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with cplint-installer. If not, see <http://www.gnu.org/licenses/>.
+#
+#
+
+# To be placed in /usr/lib/systemd/system/rserve-sandbox-docker.service
+
+[Unit]
+Description=Docker spec for running Rserve in a sandbox
+Documentation=https://github.com/JanWielemaker/rserve-sandbox https://github.com/JanWielemaker/rserve_client
+Requires=docker.service
+After=docker.service
+
+[Service]
+# Run ExecStartPre with root permissions.
+PermissionsStartOnly=true
+ExecStartPre=/usr/bin/systemd-tmpfiles --create rserve-sandbox-docker.conf
+ExecStart=/usr/bin/rserve-sandbox-docker -s
+ExecStop=/usr/bin/rserve-sandbox-docker -k
+Type=forking
+PIDFile=/run/rserve-sandbox-docker.pid
+User=rsd
+Group=rsd
+
+[Install]
+Also=docker.service
+WantedBy=default.target
+