forked from wiedehopf/mlat-server
-
Notifications
You must be signed in to change notification settings - Fork 2
/
systemd-service.example
30 lines (27 loc) · 843 Bytes
/
systemd-service.example
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
[Unit]
Wants=network.target
After=network.target
[Service]
User=mlat-server
SyslogIdentifier=mlat-server
RuntimeDirectory=mlat-server
RuntimeDirectoryMode=0755
Type=simple
Restart=always
RestartSec=20
# this cuts down on load, multithreading beyond the one extra num thread is detrimental:
Environment=MKL_NUM_THREADS=1
Environment=NUMEXPR_NUM_THREADS=1
Environment=OMP_NUM_THREADS=1
# not really required but doesn't hurt:
Environment=PYTHONOPTIMIZE=2
# display python version on startup:
ExecStartPre=/opt/mlat-python-venv/bin/python3 --version
ExecStart=/opt/mlat-python-venv/bin/python3 /opt/mlat-server/mlat-server \
--client-listen 31090 \
--filtered-basestation-listen 31003 \
--basestation-listen 31004 \
--write-csv /run/mlat-server/positions.csv \
--work-dir /run/mlat-server
[Install]
WantedBy=default.target