forge
Explore
Log in

Don't you dare go Hollow

iz

Clone
★ 0

0 watching0 forksRustAGPL-3.0567.3 KiB3950aceTahinli27 days ago34 commits

iz.service61 lines, 1.4 KiBHistoryRawDownload
1# systemd unit for iz, the family task board.
2#
3# This file is installed by hand. Nothing enables it automatically: copy it to
4# /etc/systemd/system/iz.service, run `systemctl daemon-reload`, then enable and
5# start it yourself. See README.md, "First run".
6
7[Unit]
8Description=iz family task board
9After=network-online.target
10Wants=network-online.target
11StartLimitIntervalSec=60
12StartLimitBurst=5
13
14[Service]
15Type=simple
16User=iz
17Group=iz
18ExecStart=/usr/local/bin/iz --config /etc/iz/iz.toml serve
19WorkingDirectory=/var/lib/iz
20StateDirectory=iz
21StateDirectoryMode=0700
22Restart=on-failure
23RestartSec=5
24UMask=0077
25
26# Hardening
27NoNewPrivileges=yes
28ProtectSystem=strict
29# Only the data directory is writable: database, iz.key, attachments, backups.
30ReadWritePaths=/var/lib/iz
31ProtectHome=yes
32PrivateTmp=yes
33PrivateDevices=yes
34ProtectKernelTunables=yes
35ProtectKernelModules=yes
36ProtectKernelLogs=yes
37ProtectControlGroups=yes
38ProtectClock=yes
39ProcSubset=pid
40RestrictSUIDSGID=yes
41RestrictRealtime=yes
42RestrictNamespaces=yes
43RestrictAddressFamilies=AF_UNIX AF_INET AF_INET6
44LockPersonality=yes
45MemoryDenyWriteExecute=yes
46SystemCallArchitectures=native
47SystemCallFilter=@system-service
48SystemCallFilter=~@privileged
49ProtectProc=invisible
50ProcSubset=pid
51RemoveIPC=yes
52PrivateMounts=yes
53KeyringMode=private
54MemoryMax=1G
55SystemCallErrorNumber=EPERM
56CapabilityBoundingSet=
57AmbientCapabilities=
58KeyringMode=private
59
60[Install]
61WantedBy=multi-user.target