Skip to contentSkip to conversation

seatd: add seatd recipe

PATCH New Randy Li 1 participant 1 message Apr 29, 2021

lore
Share & tools
lore

Randy Li

author
#0 lore raw

PATCH v4 1/1 seatd: add seatd recipe

Seat management takes care of mediating access to shared devices (graphics, input), without requiring the applications needing access to be root.

---
 meta/recipes-core/seatd/libseat/init     | 50 ++++++++++++++++++++++++
 meta/recipes-core/seatd/libseat_0.5.0.bb | 42 ++++++++++++++++++++
 2 files changed, 92 insertions(+)
 create mode 100644 meta/recipes-core/seatd/libseat/init
 create mode 100644 meta/recipes-core/seatd/libseat_0.5.0.bb
meta/recipes-core/seatd/libseat/init new file +50 -0
new file mode 100644
index 0000000000..8c9d77255d
@@ -0,0 +1,50 @@
+#!/bin/sh
+#
+### BEGIN INIT INFO
+# Provides:          seatd
+# Short-Description: Start seat management daemon
+# Required-Start:    $local_fs $remote_fs
+# Required-Stop:     $local_fs $remote_fs
+# Default-Start:     2 3 4 5
+# Default-Stop:      0 1 6
+### END INIT INFO
+
+PATH=/bin:/usr/bin:/sbin:/usr/sbin
+
+test -x /usr/bin/seatd || exit 0
+
+# For configuration of the init script use the file
+# /etc/default/seatd, do not edit this init script.
+
+seatd_group="seatd"
+
+[ -e /etc/default/seatd ] && . /etc/default/seatd
+
+NAME=seatd
+DAEMON=/usr/bin/seatd
+STOP_RETRY_SCHEDULE='TERM/10/forever/KILL/1'
+
+. /etc/init.d/functions
+
+case "$1" in
+  start)
+    start-stop-daemon --start --backgroud --quiet --pidfile /var/run/$NAME.pid \
+	    --exec $DAEMON -- -g $seatd_group
+    ;;
+
+  stop)
+    killproc $NAME
+    ;;
+
+  restart)
+    $0 stop
+    sleep 1
+    $0 start
+    ;;
+  *)
+    echo "Usage: $0 {start|stop|restart}"
+    exit 1
+
+esac
+
+exit 0
meta/recipes-core/seatd/libseat_0.5.0.bb new file +42 -0

42 lines not on this page · raw message

Signature · 1 line
2.30.2