From 86f003951f685e6bf2b0b57315f3d83993cca0eb Mon Sep 17 00:00:00 2001 From: Kinn Date: Tue, 13 Oct 2026 23:57:55 -0700 Subject: [PATCH] add: copy of systemd unit files --- systemd/loading-program.service | 15 +++++++++++++++ systemd/loading-program.timer | 10 ++++++++++ 2 files changed, 25 insertions(+) create mode 100644 systemd/loading-program.service create mode 100644 systemd/loading-program.timer diff --git a/systemd/loading-program.service b/systemd/loading-program.service new file mode 100644 index 0000000..96c320e --- /dev/null +++ b/systemd/loading-program.service @@ -0,0 +1,15 @@ +# /etc/systemd/system/provision-homes.service +[Unit] +Description=Create home directories for lab-committee members +RequiresMountsFor=/mnt/stockroom +Wants=network-online.target +After=network-online.target + +[Service] +Type=oneshot +ExecStart=/usr/local/sbin/loading-program +CapabilityBoundingSet=CAP_CHOWN CAP_DAC_OVERRIDE CAP_FOWNER +NoNewPrivileges=yes +ProtectSystem=strict +ReadWritePaths=/mnt/stockroom/homes +PrivateTmp=yes diff --git a/systemd/loading-program.timer b/systemd/loading-program.timer new file mode 100644 index 0000000..1d4874f --- /dev/null +++ b/systemd/loading-program.timer @@ -0,0 +1,10 @@ +# /etc/systemd/system/loading-program.timer +[Unit] +Description=Periodically provision lab-committee home directories + +[Timer] +OnBootSec=2min +OnUnitActiveSec=5min + +[Install] +WantedBy=timers.target