19 lines
668 B
SYSTEMD
19 lines
668 B
SYSTEMD
|
|
[Unit]
|
||
|
|
Description=Refresh the Thermograph IP-geolocation database
|
||
|
|
After=network-online.target
|
||
|
|
Wants=network-online.target
|
||
|
|
|
||
|
|
[Service]
|
||
|
|
Type=oneshot
|
||
|
|
# GEOIP_URL / GEOIP_BASE / THERMOGRAPH_GEOIP_HOST_DIR can be overridden here if
|
||
|
|
# the deployment switches databases. The leading `-` keeps a missing file
|
||
|
|
# non-fatal, matching thermograph.service.
|
||
|
|
EnvironmentFile=-/etc/thermograph.env
|
||
|
|
ExecStart=/opt/thermograph/infra/deploy/geoip-refresh.sh
|
||
|
|
# Downloading ~125 MB and verifying it needs no privilege beyond writing the
|
||
|
|
# destination directory, and nothing else on the box.
|
||
|
|
ProtectSystem=strict
|
||
|
|
ReadWritePaths=/var/lib/thermograph/geoip
|
||
|
|
PrivateTmp=yes
|
||
|
|
NoNewPrivileges=yes
|