diff options
| author | Guilhem Moulin <guilhem@fripost.org> | 2026-03-06 13:50:24 +0100 |
|---|---|---|
| committer | Guilhem Moulin <guilhem@fripost.org> | 2026-03-06 16:08:40 +0100 |
| commit | 1af347391f9f54b370dfc7395464b8ed637a79ca (patch) | |
| tree | f73b1ff30c968763260c0aa0443de572c665350e /files/etc/systemd/system/geodata-download@.service | |
| parent | 8ee835b7fc9a3e3eac93a74f877b0b040d8dcb03 (diff) | |
Rename "webmap" to the less generic "geodata".
The database has uses beyond the webmap.
Cf. ca91a579770c89d25aefae220079bf336fa88dc9 in tools.
Diffstat (limited to 'files/etc/systemd/system/geodata-download@.service')
| -rw-r--r-- | files/etc/systemd/system/geodata-download@.service | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/files/etc/systemd/system/geodata-download@.service b/files/etc/systemd/system/geodata-download@.service new file mode 100644 index 0000000..2a8c940 --- /dev/null +++ b/files/etc/systemd/system/geodata-download@.service @@ -0,0 +1,37 @@ +[Unit] +Description=Geodata updater service (download ā%Iā) +# Chaining logic from https://serverfault.com/questions/1079993/why-does-my-systemd-timer-only-trigger-once-when-the-unit-is-a-target#answer-1128671 +# XXX Looks like Upholds= prevents running a single unit, as it causes +# geodata-update@%i.target to start upon `systemctl start geodata-download@foo.service` +After=network-online.target geodata-update@%i.target +Upholds=geodata-update@%i.target + +[Service] +User=_geodata-download +Group=_geodata + +Nice=15 +IOSchedulingClass=idle + +Type=oneshot +ExecStart=/usr/local/bin/geodata-download \ + --cachedir=%C/geodata \ + --lockdir=%t/lock/geodata/cache \ + --no-exit-code \ + --quiet \ + -- %I + +# Hardening +NoNewPrivileges=yes +ProtectHome=yes +ProtectSystem=strict +PrivateDevices=yes +ProtectControlGroups=yes +ProtectKernelModules=yes +ProtectKernelTunables=yes +RestrictAddressFamilies=AF_UNIX AF_INET AF_INET6 +ReadWritePaths=%C/geodata +ReadWritePaths=%t/lock/geodata/cache + +[Install] +WantedBy=geodata-update@%i.target |
