summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Poessinger <christian@poessinger.com>2021-06-24 19:22:31 +0200
committerChristian Poessinger <christian@poessinger.com>2021-06-24 19:23:49 +0200
commitf8f867adeb9893756e8ce89f9c8bf9a70b7a1c67 (patch)
tree313a84ab4dd0c55d09ae54f7987cd7085187b08b
parentc5fcc109e78bddea0e27bf4a5ea57f8e35c26be3 (diff)
downloadvyos-1x-f8f867adeb9893756e8ce89f9c8bf9a70b7a1c67.tar.gz
vyos-1x-f8f867adeb9893756e8ce89f9c8bf9a70b7a1c67.zip
systemd: lcdproc: T3641: override upstream files
Debian Bullseye ships an upstream version of lcdproc.service which infact will start LCDd instead of the lcdproc client. Divert the Debian Upstream service file and use the ones provided by vyos-1x.
-rw-r--r--debian/vyos-1x.preinst1
-rw-r--r--src/etc/systemd/system/LCDd.service.d/override.conf8
-rw-r--r--src/systemd/LCDd.service14
3 files changed, 15 insertions, 8 deletions
diff --git a/debian/vyos-1x.preinst b/debian/vyos-1x.preinst
new file mode 100644
index 000000000..009fd22a2
--- /dev/null
+++ b/debian/vyos-1x.preinst
@@ -0,0 +1 @@
+dpkg-divert --package vyos-1x --add --rename /lib/systemd/system/lcdproc.service
diff --git a/src/etc/systemd/system/LCDd.service.d/override.conf b/src/etc/systemd/system/LCDd.service.d/override.conf
deleted file mode 100644
index 5f3f0dc95..000000000
--- a/src/etc/systemd/system/LCDd.service.d/override.conf
+++ /dev/null
@@ -1,8 +0,0 @@
-[Unit]
-After=
-After=vyos-router.service
-
-[Service]
-ExecStart=
-ExecStart=/usr/sbin/LCDd -c /run/LCDd/LCDd.conf
-
diff --git a/src/systemd/LCDd.service b/src/systemd/LCDd.service
new file mode 100644
index 000000000..233c1e2ca
--- /dev/null
+++ b/src/systemd/LCDd.service
@@ -0,0 +1,14 @@
+[Unit]
+Description=LCD display daemon
+Documentation=man:LCDd(8) http://www.lcdproc.org/
+RequiresMountsFor=/run
+ConditionPathExists=/run/LCDd/LCDd.conf
+After=vyos-router.service
+
+
+[Service]
+User=root
+ExecStart=/usr/sbin/LCDd -s 1 -f -c /run/LCDd/LCDd.conf
+
+[Install]
+WantedBy=multi-user.target