mirror of
https://github.com/Xevion/HATray.git
synced 2025-12-05 23:15:09 -06:00
feat!: add linux cross-platform support with systemd unit file
This commit is contained in:
44
build/unix/HATray.service
Normal file
44
build/unix/HATray.service
Normal file
@@ -0,0 +1,44 @@
|
||||
[Unit]
|
||||
Description=HATray - Home Assistant Tray Utility
|
||||
Documentation=https://github.com/Xevion/HATray
|
||||
After=network-online.target
|
||||
Wants=network-online.target
|
||||
|
||||
[Service]
|
||||
Type=notify
|
||||
NotifyAccess=main
|
||||
ExecStart=$BINARY_PATH
|
||||
ExecReload=/bin/kill -HUP $MAINPID
|
||||
|
||||
Restart=on-failure
|
||||
RestartSec=5
|
||||
|
||||
# CPUAccounting=yes
|
||||
# MemoryAccounting=yes
|
||||
# StandardOutput=journal
|
||||
# StandardError=journal
|
||||
# SyslogIdentifier=HATray
|
||||
|
||||
# Environment variables
|
||||
# Environment=HOME=/home/%i
|
||||
|
||||
# Security settings
|
||||
# NoNewPrivileges=true
|
||||
# PrivateTmp=true
|
||||
# ProtectSystem=strict
|
||||
# ProtectHome=true
|
||||
# ReadWritePaths=/home/%i/.config/HATray
|
||||
|
||||
# Resource limits (cgroups v2)
|
||||
# MemoryMax=128M
|
||||
# MemoryHigh=96M
|
||||
# MemorySwapMax=0
|
||||
# CPUQuota=10%
|
||||
# CPUWeight=100
|
||||
# IOWeight=100
|
||||
# TasksMax=100
|
||||
# LimitNOFILE=1024
|
||||
# LimitCORE=0
|
||||
|
||||
[Install]
|
||||
WantedBy=default.target
|
||||
Reference in New Issue
Block a user