aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoerg Bornkessel <hd_brummy@gentoo.org>2020-01-08 00:25:31 +0100
committerJoerg Bornkessel <hd_brummy@gentoo.org>2020-01-08 00:25:31 +0100
commitbb884ab5566d9ba05dd2c991b1e973a2e4c43398 (patch)
tree259b627f4795eb08be8eb2f8451c3806716a3a44
parentadded support for the DISPLAY=:0.0 environment variable (diff)
downloadgentoo-vdr-scripts-bb884ab5566d9ba05dd2c991b1e973a2e4c43398.tar.gz
gentoo-vdr-scripts-bb884ab5566d9ba05dd2c991b1e973a2e4c43398.tar.bz2
gentoo-vdr-scripts-bb884ab5566d9ba05dd2c991b1e973a2e4c43398.zip
added TTY configuration for systemd unit, extended README.systemd
Suggested-by: Lucian Muresan <lucianm@users.sourceforge.net> Signed-off-by: Joerg Bornkessel <hd_brummy@gentoo.org>
-rw-r--r--README.systemd24
-rw-r--r--etc/conf.d/vdr10
-rw-r--r--etc/systemd/system/vdr.service.d/00-gentoo-vdr-user.conf25
3 files changed, 48 insertions, 11 deletions
diff --git a/README.systemd b/README.systemd
index 9ad1e52..2683493 100644
--- a/README.systemd
+++ b/README.systemd
@@ -7,17 +7,25 @@ Systemd support has been implemented by re-using all the OpenRC configuration
files of VDR and its plugins located under /etc/conf.d/ even if OpenRC is not installed
at all.
-However, there is one thing which is configured differently, and this is the user under
-which the VDR daemon will run. Just as when running under OpenRC, the gentoo-vdr-scripts
-can be configured to run VDR either as user 'vdr' or as user 'root'. The difference is that
-under systemd, the setting START_VDR_AS_ROOT in /etc/conf.d/vdr is ignored on purpose, to let
-the configuration be done "the systemd way".
- - The default is to run as user 'vdr'. If running as 'root' is desired, uncomment the 'User=root'
+Things which are configured differently:
+
+- Starting the VDR daemon under a user different than 'vdr'. Just as when running under OpenRC, the
+ gentoo-vdr-scripts can be configured to run VDR either as user 'vdr' or as user 'root'.
+ The difference is that under systemd, the setting START_VDR_AS_ROOT in /etc/conf.d/vdr is
+ ignored on purpose, to let the configuration be done "the systemd way".
+
+- The default is to run as user 'vdr'. If running as 'root' is desired, uncomment the 'User=root'
key under the [Service] section in the file
- /etc/systemd/system/vdr.service.d/00-gentoo-vdr-user.conf
- - *If* the plugin 'dbus2vdr' is used, the user who owns the vdr-dbus-service also has to be set to
+ /etc/systemd/system/vdr.service.d/00-gentoo-vdr-user.conf commented "Starting VDR as user 'root'"
+
+- *If* the plugin 'dbus2vdr' is used, the user who owns the vdr-dbus-service also has to be set to
'root' in /etc/dbus-1/system.d/de.tvdr.vdr.conf if running VDR as user 'root';
+- Starting the VDR daemon on a terminal (/dev/tty8 for examle). The settings in /etc/conf.d/vdr are
+ ignored, but this can be achieved by uncommenting the respective entries commented "Starting VDR on
+ terminal" under BOTH sections [Unit] AND [Service] in the file
+ /etc/systemd/system/vdr.service.d/00-gentoo-vdr-user.conf
+ This becomes even necessary if using the plugin vdr-skincurses.
Finally, in order to start the VDR daemon under systemd manually, execute:
diff --git a/etc/conf.d/vdr b/etc/conf.d/vdr
index eae6459..e00ab13 100644
--- a/etc/conf.d/vdr
+++ b/etc/conf.d/vdr
@@ -98,6 +98,10 @@
# viewing of Terminal output of vdr
# allowed values: number of virtual terminal
# default: start vdr completely in the background
+#
+# WILL BE IGNORED IF USING SYSTEMD !!!
+# Please consult media-tv/gentoo-vdr-scripts
+# /usr/share/docs/gentoo-vdr-script-*/README.systemd for further details
#TERMINAL="8"
# Switch to used terminal
@@ -105,6 +109,10 @@
# then switch to this terminal
# allowed values: yes no
# default: no
+#
+# WILL BE IGNORED IF USING SYSTEMD !!!
+# Please consult media-tv/gentoo-vdr-scripts
+# /usr/share/docs/gentoo-vdr-scripts-*/README.systemd for further details
#SWITCH_TO_TERMINAL="yes"
@@ -254,7 +262,7 @@ PLUGIN_CHECK_PATCHLEVEL="yes"
#
# WILL BE IGNORED IF USING SYSTEMD !!!
# Please consult media-tv/gentoo-vdr-scripts
-# README.systemd for further details
+# /usr/share/docs/gentoo-vdr-scripts-*/README.systemd for further details
#
#START_VDR_AS_ROOT="no"
diff --git a/etc/systemd/system/vdr.service.d/00-gentoo-vdr-user.conf b/etc/systemd/system/vdr.service.d/00-gentoo-vdr-user.conf
index b184c24..6d3dc3a 100644
--- a/etc/systemd/system/vdr.service.d/00-gentoo-vdr-user.conf
+++ b/etc/systemd/system/vdr.service.d/00-gentoo-vdr-user.conf
@@ -3,7 +3,28 @@
#
# use this file to override settings from vdr.service
+[Unit]
+#
+# Starting VDR on terminal:
+# Please consult media-tv/gentoo-vdr-scritpts
+# /usr/share/docs/gentoo-vdr-scripts-*/README.systemd for further details
+# Conflicts=getty@tty8.service
+#
+# uncomment the following entries, or add some of your own if you have to tweak service dependencies
+#Requires=mnt-mhddfs-vdr_video.automount
+#After=my_local.service
+
[Service]
# Please consult media-tv/gentoo-vdr-scritpts
-# README.systemd for further details
-#User=root \ No newline at end of file
+# /usr/share/docs/gentoo-vdr-scripts-*/README.systemd for further details
+#User=root
+
+
+# Starting VDR on terminal:
+# Please consult media-tv/gentoo-vdr-scritpts
+# /usr/share/docs/gentoo-vdr-scripts-*/README.systemd for further details
+#
+#StandardInput=tty
+#TTYPath=/dev/tty8
+#ExecStartPre=/usr/bin/chvt 8
+#ExecStartPre=/usr/bin/setterm --clear all --cursor off \ No newline at end of file