summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'media-tv/tvheadend')
-rw-r--r--media-tv/tvheadend/files/tvheadend.service15
1 files changed, 9 insertions, 6 deletions
diff --git a/media-tv/tvheadend/files/tvheadend.service b/media-tv/tvheadend/files/tvheadend.service
index 2d0573ca910f..6d1e27445b73 100644
--- a/media-tv/tvheadend/files/tvheadend.service
+++ b/media-tv/tvheadend/files/tvheadend.service
@@ -3,19 +3,22 @@ Description=tvheadend
After=network.target
[Service]
-Type=forking
+Type=simple
User=tvheadend
Group=video
RuntimeDirectory=tvheadend
PIDFile=/run/tvheadend/tvheadend.pid
-ExecStart=/usr/bin/tvheadend -6 -f -p /run/tvheadend.pid -C -c /etc/tvheadend
+EnvironmentFile=/etc/conf.d/tvheadend
+ExecStart=/usr/bin/tvheadend -p /run/tvheadend/tvheadend.pid -c "${TVHEADEND_CONFIG}" ${TVHEADEND_OPTIONS}
+TimeoutStartSec=1m
+TimeoutStopSec=20s
Restart=always
-RestartSec=5
+RestartSec=5s
DevicePolicy=closed
-DeviceAllow=char-DVB rw # DVB devices
-DeviceAllow=char-drm rw # GPUs for transcoding
+DeviceAllow=char-DVB rw
+DeviceAllow=char-drm rw
RestrictAddressFamilies=AF_INET AF_INET6
-ProtectSystem=strict
+ProtectSystem=yes
ProtectHome=yes
NoNewPrivileges=yes