diff options
author | Ronan Le Martret <ronan.lemartret@iot.bzh> | 2017-04-19 16:16:03 +0200 |
---|---|---|
committer | Jan-Simon Moeller <jsmoeller@linuxfoundation.org> | 2017-05-16 04:51:29 +0000 |
commit | 6ca247d19f2a0d7cc0cb1beb8d26c99e7fac337b (patch) | |
tree | 33f4ff8ea9e3134bede9ff19ea2d596e437d0209 /meta-app-framework/recipes-config/agl-login-manager/agl-login-manager_0.1.bb | |
parent | 7c227f30c8437d2f5a7b95622d97a86149a716c8 (diff) |
Run weston with dedicated 'display' user and group
* Create a user/group display
* Allow weston to start without mandatory root user
* start weston-terminal for each user
Bug-AGL: SPEC-546
Change-Id: Id50acdbf5f7c07d5e0440575d42998b8819b5547
Signed-off-by: Ronan Le Martret <ronan.lemartret@iot.bzh>
Reviewed-on: https://gerrit.automotivelinux.org/gerrit/9135
Tested-by: Jenkins Job builder account <agl-jobbuilder@automotivelinux.org>
ci-image-build: Jenkins Job builder account <agl-jobbuilder@automotivelinux.org>
ci-image-boot-test: Jenkins Job builder account <agl-jobbuilder@automotivelinux.org>
Reviewed-by: Dominig ar Foll <dominig.arfoll@fridu.net>
Reviewed-by: José Bollo <jobol@nonadev.net>
Reviewed-by: Stéphane Desneux <stephane.desneux@iot.bzh>
Reviewed-by: Jan-Simon Moeller <jsmoeller@linuxfoundation.org>
Diffstat (limited to 'meta-app-framework/recipes-config/agl-login-manager/agl-login-manager_0.1.bb')
-rw-r--r-- | meta-app-framework/recipes-config/agl-login-manager/agl-login-manager_0.1.bb | 47 |
1 files changed, 47 insertions, 0 deletions
diff --git a/meta-app-framework/recipes-config/agl-login-manager/agl-login-manager_0.1.bb b/meta-app-framework/recipes-config/agl-login-manager/agl-login-manager_0.1.bb new file mode 100644 index 000000000..c86838268 --- /dev/null +++ b/meta-app-framework/recipes-config/agl-login-manager/agl-login-manager_0.1.bb @@ -0,0 +1,47 @@ +SUMMARY = "AGL Login manager" + +LICENSE = "MIT" +LIC_FILES_CHKSUM = "file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420" + +inherit agl-graphical + +SRC_URI += " \ + file://user-config.service \ + file://user-config.path \ + file://agl-user-session.pamd \ + file://agl-user-session@.service \ +" + +LOGIN_USER ??="agl-driver agl-passenger" + +do_install_append() { + + install -d ${D}${sysconfdir}/pam.d/ + install -m 0644 ${WORKDIR}/agl-user-session.pamd ${D}${sysconfdir}/pam.d/agl-user-session + + install -d ${D}${systemd_user_unitdir} + install -d ${D}${systemd_user_unitdir}/default.target.wants + install -m 0644 ${WORKDIR}/user-config.service ${D}${systemd_user_unitdir} + install -m 0644 ${WORKDIR}/user-config.path ${D}${systemd_user_unitdir} + + sed -e 's,@DISPLAY_XDG_RUNTIME_DIR@,${DISPLAY_XDG_RUNTIME_DIR},g' \ + -i ${D}${systemd_user_unitdir}/user-config.service + sed -e 's,@DISPLAY_XDG_RUNTIME_DIR@,${DISPLAY_XDG_RUNTIME_DIR},g' \ + -i ${D}${systemd_user_unitdir}/user-config.path + + ln -sf ${systemd_user_unitdir}/user-config.path ${D}${systemd_user_unitdir}/default.target.wants + + install -d ${D}${systemd_unitdir}/system/ + install -d ${D}${systemd_unitdir}/system/multi-user.target.wants/ + install -m 0644 ${WORKDIR}/agl-user-session@.service ${D}${systemd_unitdir}/system/ + + for AGL_USER in ${LOGIN_USER};do + ln -sf ${systemd_system_unitdir}/agl-user-session@.service ${D}${systemd_unitdir}/system/multi-user.target.wants/agl-user-session@${AGL_USER}.service; + done +} + +FILES_${PN} += "${sysconfdir}/pam.d/agl-user-session" +FILES_${PN} += "${systemd_user_unitdir}/*" +FILES_${PN} += "${libdir}/systemd/user/default.target.wants/*" +FILES_${PN} += "${systemd_unitdir}/system/agl-user-session@.service" +FILES_${PN} += "${systemd_unitdir}/system/multi-user.target.wants/*" |