chore: run the server unit as root from /opt/lpra

The panel's ufw integration needs root; the database now lives next to
the binary in /opt/lpra.
This commit is contained in:
redtea committed 2026-10-13 14:55:37 +03:00
1 parent bcfe909aaa
commit 5e6e0b8a3a
1 file changed
+3 -6
+3 -6
View File
@@ -33,17 +33,14 @@ After=network-online.target
Wants=network-online.target Wants=network-online.target
[Service] [Service]
Type=simple
User=lpra
Group=lpra
WorkingDirectory=/opt/lpra WorkingDirectory=/opt/lpra
# Optional environment overrides; "-" means the file is not required. # Optional environment overrides; "-" means the file is not required.
EnvironmentFile=-/etc/lpra-server.env
ExecStart=/opt/lpra/lpra-server \ ExecStart=/opt/lpra/lpra-server \
-addr 127.0.0.1:8091 \ -addr 127.0.0.1:8091 \
-db /var/lib/lpra/lpra.db \ -db /opt/lpra/lpra.db \
-dist /opt/lpra/dist -dist /opt/lpra/dist
Restart=always Restart=always
@@ -59,7 +56,7 @@ ProtectKernelTunables=true
ProtectControlGroups=true ProtectControlGroups=true
RestrictSUIDSGID=true RestrictSUIDSGID=true
# The server only needs to write its SQLite database here. # The server only needs to write its SQLite database here.
ReadWritePaths=/var/lib/lpra ReadWritePaths=/opt/lpra
[Install] [Install]
WantedBy=multi-user.target WantedBy=multi-user.target