summaryrefslogtreecommitdiffstats
path: root/satellit_installer/static_files/taskmanager/etc
diff options
context:
space:
mode:
authorSimon Rettberg2020-12-17 15:08:14 +0100
committerSimon Rettberg2020-12-17 15:08:14 +0100
commitb5c3eb9e01b09367935f558a57633b68a65a1a21 (patch)
treeb6c322f3089192124779b9d7a29c8365eb39533f /satellit_installer/static_files/taskmanager/etc
parent[SSPS] slx-cert: Put hostname in SAN too, chromium requires this (diff)
downloadsetup-scripts-b5c3eb9e01b09367935f558a57633b68a65a1a21.tar.gz
setup-scripts-b5c3eb9e01b09367935f558a57633b68a65a1a21.tar.xz
setup-scripts-b5c3eb9e01b09367935f558a57633b68a65a1a21.zip
[SSPS] Refactor static_files: Submodules with tree
Add submodules (aka directories) to static_files, named according to what component they are for. Add function "install_files" to copy the contents of one of those modules to the root directory. This should make the resulting setup more obvious and require less manual copying of files everywhere.
Diffstat (limited to 'satellit_installer/static_files/taskmanager/etc')
-rw-r--r--satellit_installer/static_files/taskmanager/etc/sudoers.d/taskmanager12
l---------satellit_installer/static_files/taskmanager/etc/systemd/system/multi-user.target.wants/taskmanager.service1
-rw-r--r--satellit_installer/static_files/taskmanager/etc/systemd/system/taskmanager.service17
3 files changed, 30 insertions, 0 deletions
diff --git a/satellit_installer/static_files/taskmanager/etc/sudoers.d/taskmanager b/satellit_installer/static_files/taskmanager/etc/sudoers.d/taskmanager
new file mode 100644
index 0000000..b34bf9f
--- /dev/null
+++ b/satellit_installer/static_files/taskmanager/etc/sudoers.d/taskmanager
@@ -0,0 +1,12 @@
+# Sudoers configuration for user 'taskmanager'
+taskmanager ALL=(root) NOPASSWD: /opt/taskmanager/scripts/ldadp-launcher
+taskmanager ALL=(root) NOPASSWD: /sbin/reboot
+taskmanager ALL=(root) NOPASSWD: /bin/netstat
+taskmanager ALL=(root) NOPASSWD: /opt/taskmanager/scripts/systemctl
+taskmanager ALL=(root) NOPASSWD: /opt/taskmanager/scripts/mount-store
+taskmanager ALL=(root) NOPASSWD: /opt/taskmanager/scripts/system-backup
+taskmanager ALL=(root) NOPASSWD: /opt/taskmanager/scripts/system-restore
+taskmanager ALL=(root) NOPASSWD: /opt/taskmanager/scripts/install-https
+taskmanager ALL=(root) NOPASSWD: /opt/taskmanager/scripts/ldadp-setperms
+ALL ALL=(www-data) NOPASSWD: /usr/local/bin/slxlog
+Defaults env_keep += "TM_*"
diff --git a/satellit_installer/static_files/taskmanager/etc/systemd/system/multi-user.target.wants/taskmanager.service b/satellit_installer/static_files/taskmanager/etc/systemd/system/multi-user.target.wants/taskmanager.service
new file mode 120000
index 0000000..141a3f2
--- /dev/null
+++ b/satellit_installer/static_files/taskmanager/etc/systemd/system/multi-user.target.wants/taskmanager.service
@@ -0,0 +1 @@
+../taskmanager.service \ No newline at end of file
diff --git a/satellit_installer/static_files/taskmanager/etc/systemd/system/taskmanager.service b/satellit_installer/static_files/taskmanager/etc/systemd/system/taskmanager.service
new file mode 100644
index 0000000..97662cb
--- /dev/null
+++ b/satellit_installer/static_files/taskmanager/etc/systemd/system/taskmanager.service
@@ -0,0 +1,17 @@
+[Unit]
+Description=bwLehrpool Taskmanager
+
+[Service]
+User=taskmanager
+Group=taskmanager
+WorkingDirectory=/opt/taskmanager/
+ExecStart=/opt/taskmanager/taskmanager.sh
+Restart=always
+RestartSec=5
+SyslogIdentifier=taskmanager
+StandardOutput=syslog
+StandardError=syslog
+
+[Install]
+WantedBy=multi-user.target
+