summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSimon Rettberg2019-03-17 21:43:58 +0100
committerSimon Rettberg2019-03-17 21:43:58 +0100
commitd219a7e45ed18242c42869850eba7981cc0fa440 (patch)
tree80b4ae1a6c9b59b0139b7fd1130d5594b3c8c304
parent[slx-issue] Put Client IP in issue (diff)
downloadmltk-d219a7e45ed18242c42869850eba7981cc0fa440.tar.gz
mltk-d219a7e45ed18242c42869850eba7981cc0fa440.tar.xz
mltk-d219a7e45ed18242c42869850eba7981cc0fa440.zip
[lightdm-greeter-bwlp] Support branding.d, fetch roomplan
-rw-r--r--core/modules/lightdm-greeter-bwlp/data/etc/lightdm/qt-lightdm-greeter.conf5
l---------core/modules/lightdm-greeter-bwlp/data/etc/systemd/system/graphical.target.wants/lightdm-greeter-roomplan.service1
-rw-r--r--core/modules/lightdm-greeter-bwlp/data/etc/systemd/system/lightdm-greeter-roomplan.service9
-rwxr-xr-xcore/modules/lightdm-greeter-bwlp/data/opt/openslx/scripts/systemd-download_roomplan9
4 files changed, 23 insertions, 1 deletions
diff --git a/core/modules/lightdm-greeter-bwlp/data/etc/lightdm/qt-lightdm-greeter.conf b/core/modules/lightdm-greeter-bwlp/data/etc/lightdm/qt-lightdm-greeter.conf
index 8a82bbbe..cea939dc 100644
--- a/core/modules/lightdm-greeter-bwlp/data/etc/lightdm/qt-lightdm-greeter.conf
+++ b/core/modules/lightdm-greeter-bwlp/data/etc/lightdm/qt-lightdm-greeter.conf
@@ -16,7 +16,10 @@
loginform-offset-x=50%
loginform-offset-y=50%
greeter-banner-image=/opt/openslx/lightdm/bwlp-banner.svg
-greeter-bottom-left-logo-path=/etc/branding.svg
+; from legacy config module
+greeter-bottom-left-logo-file=/etc/branding.svg
+; new directory style
+greeter-bottom-left-logo-path=/etc/branding.d
greeter-background-gradient=e8e6e7 ffffff e8e6e7 ffd78b
greeter-message-file=/run/hw-warnings.log
auto-login-check-cmd=/opt/openslx/lightdm/is-autologin-enabled
diff --git a/core/modules/lightdm-greeter-bwlp/data/etc/systemd/system/graphical.target.wants/lightdm-greeter-roomplan.service b/core/modules/lightdm-greeter-bwlp/data/etc/systemd/system/graphical.target.wants/lightdm-greeter-roomplan.service
new file mode 120000
index 00000000..d273ed98
--- /dev/null
+++ b/core/modules/lightdm-greeter-bwlp/data/etc/systemd/system/graphical.target.wants/lightdm-greeter-roomplan.service
@@ -0,0 +1 @@
+../lightdm-greeter-roomplan.service \ No newline at end of file
diff --git a/core/modules/lightdm-greeter-bwlp/data/etc/systemd/system/lightdm-greeter-roomplan.service b/core/modules/lightdm-greeter-bwlp/data/etc/systemd/system/lightdm-greeter-roomplan.service
new file mode 100644
index 00000000..565f72c3
--- /dev/null
+++ b/core/modules/lightdm-greeter-bwlp/data/etc/systemd/system/lightdm-greeter-roomplan.service
@@ -0,0 +1,9 @@
+[Unit]
+Description=Download roomplan pictogram to display in lightdm greeter
+Before=lightdm.service
+After=network.target
+
+[Service]
+Type=oneshot
+Exec=/opt/openslx/scripts/systemd-download_roomplan
+
diff --git a/core/modules/lightdm-greeter-bwlp/data/opt/openslx/scripts/systemd-download_roomplan b/core/modules/lightdm-greeter-bwlp/data/opt/openslx/scripts/systemd-download_roomplan
new file mode 100755
index 00000000..3891ba31
--- /dev/null
+++ b/core/modules/lightdm-greeter-bwlp/data/opt/openslx/scripts/systemd-download_roomplan
@@ -0,0 +1,9 @@
+#!/bin/ash
+
+. /opt/openslx/config
+[ -z "$SLX_PVS_CONFIG_URL" ] && exit 0
+UUID=$( cat /run/system-uuid )
+[ -z "$UUID" ] && exit 0
+
+mkdir -p /etc/branding.d
+exec curl -m 3 -o /etc/branding.d/50-roomplan.svg "${SLX_PVS_CONFIG_URL}&show=svg&machineuuid=${UUID}"