initialize
This commit is contained in:
19
eg4battery/etc/systemd/system/eg4-battery.service
Normal file
19
eg4battery/etc/systemd/system/eg4-battery.service
Normal file
@@ -0,0 +1,19 @@
|
||||
[Unit]
|
||||
Description=EG4 LifePower4 RS485 -> MQTT bridge
|
||||
After=network-online.target
|
||||
Wants=network-online.target
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
User=noise
|
||||
Group=dialout
|
||||
# Systemd's default PATH does not include ~/.local/bin where `uv` is installed.
|
||||
# The script's `#!/usr/bin/env -S uv run --script` shebang needs to find uv.
|
||||
Environment=PATH=/home/noise/.local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
|
||||
# uv manages the ephemeral venv per the PEP-723 inline deps in the script
|
||||
ExecStart=/usr/local/bin/eg4-battery -C /home/noise/.config/eg4-battery/eg4-battery.yaml
|
||||
Restart=always
|
||||
RestartSec=10
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
Reference in New Issue
Block a user