in
Clone
https://git.tahinli.com/Tahinli/in.git
0 watching0 forksRustAGPL-3.0528.7 KiB9215377Tahinli27 days ago37 commits
| 1 | [Unit] |
| 2 | Description=in: the family's file drive |
| 3 | After=network-online.target |
| 4 | Wants=network-online.target |
| 5 | StartLimitIntervalSec=60 |
| 6 | StartLimitBurst=5 |
| 7 | |
| 8 | [Service] |
| 9 | Type=simple |
| 10 | User=in |
| 11 | Group=in |
| 12 | Environment=IN_CONFIG=/etc/in/in.toml |
| 13 | ExecStart=/usr/local/bin/in serve |
| 14 | WorkingDirectory=/var/lib/in |
| 15 | StateDirectory=in |
| 16 | StateDirectoryMode=0700 |
| 17 | Restart=on-failure |
| 18 | RestartSec=2 |
| 19 | LimitNOFILE=65536 |
| 20 | |
| 21 | # Hardening. The service writes only to its state directory; see `[backup] dir` in in.toml and add that path |
| 22 | # to ReadWritePaths if backups are on. |
| 23 | NoNewPrivileges=yes |
| 24 | ProtectSystem=strict |
| 25 | ProtectHome=yes |
| 26 | ReadWritePaths=/var/lib/in |
| 27 | PrivateTmp=yes |
| 28 | PrivateDevices=yes |
| 29 | PrivateUsers=yes |
| 30 | ProtectKernelTunables=yes |
| 31 | ProtectKernelModules=yes |
| 32 | ProtectKernelLogs=yes |
| 33 | ProtectControlGroups=yes |
| 34 | ProtectClock=yes |
| 35 | ProtectHostname=yes |
| 36 | RestrictSUIDSGID=yes |
| 37 | RestrictRealtime=yes |
| 38 | RestrictNamespaces=yes |
| 39 | RestrictAddressFamilies=AF_UNIX AF_INET AF_INET6 |
| 40 | LockPersonality=yes |
| 41 | MemoryDenyWriteExecute=yes |
| 42 | SystemCallArchitectures=native |
| 43 | SystemCallFilter=@system-service |
| 44 | SystemCallFilter=~@privileged |
| 45 | ProtectProc=invisible |
| 46 | ProcSubset=pid |
| 47 | RemoveIPC=yes |
| 48 | PrivateMounts=yes |
| 49 | KeyringMode=private |
| 50 | MemoryMax=2G |
| 51 | CapabilityBoundingSet= |
| 52 | AmbientCapabilities= |
| 53 | UMask=0077 |
| 54 | |
| 55 | [Install] |
| 56 | WantedBy=multi-user.target |