summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMateusz Moscicki <m.moscicki2@partner.samsung.com>2019-04-19 13:44:18 +0200
committerMateusz Moscicki <m.moscicki2@partner.samsung.com>2019-04-19 13:44:18 +0200
commitac9ed8c65311123504d84f5f88affbec94a0718d (patch)
treedbd244f53495bfdadd6961d04e7a26216517a32b
parentd4ac8b912f446463e85ade9ece5d6b07295f79a7 (diff)
downloadisf-config-ac9ed8c65311123504d84f5f88affbec94a0718d.tar.gz
isf-config-ac9ed8c65311123504d84f5f88affbec94a0718d.tar.bz2
isf-config-ac9ed8c65311123504d84f5f88affbec94a0718d.zip
tizen: Add additional unit for "unified" user session
The unified user session is about moving user session units, managed by systemd --user, to main systemd, where it's managed as part of newly created user@.target. user@.target will contain same units as previously available in user/, with same UID and environment setup. systemd instance is used for unit to be able to specify UID (inherited from user@.target). The rationale behind this work is following: * VD requirement to remove user session support * boot time optimization requirements, due to: + 'systemd --user' taking 1s its own startup that could be used for unit startup + ability to better rearrange units if these managed by one systemd instance Unit installed by this commit will not be used till user login mechanism will be changed in systemd package (via changing pam_systemd to start user@.target, rather than user@.service). Change-Id: I901f029753a7d470b42254c272f941a8d7fdf6d0
-rw-r--r--packaging/isf-config-mobile.spec7
-rw-r--r--scim@.service20
2 files changed, 27 insertions, 0 deletions
diff --git a/packaging/isf-config-mobile.spec b/packaging/isf-config-mobile.spec
index 81b1db1..2fae12d 100644
--- a/packaging/isf-config-mobile.spec
+++ b/packaging/isf-config-mobile.spec
@@ -21,14 +21,19 @@ rm -rf %{buildroot}
%__mkdir_p %{buildroot}%{_sysconfdir}/scim/conf
%__mkdir_p %{buildroot}%{_prefix}/lib/systemd/user
%__mkdir_p %{buildroot}%{_prefix}/lib/systemd/user/basic.target.wants
+%__mkdir_p %{buildroot}%{_prefix}/lib/systemd/system
+%__mkdir_p %{buildroot}%{_prefix}/lib/systemd/system/user-basic@.target.wants
%__cp etc/scim/conf/* %{buildroot}%{_sysconfdir}/scim/conf
%__cp scim.service %{buildroot}%{_prefix}/lib/systemd/user
ln -sf ../scim.service %{buildroot}%{_prefix}/lib/systemd/user/basic.target.wants/scim.service
+%__cp scim@.service %{buildroot}%{_prefix}/lib/systemd/system
+ln -sf ../scim@.service %{buildroot}%{_prefix}/lib/systemd/system/user-basic@.target.wants/scim@.service
%post
mkdir -p %{_sysconfdir}/systemd/default-extra-dependencies/ignore-units.d/
ln -sf %{_prefix}/lib/systemd/user/scim.service %{_sysconfdir}/systemd/default-extra-dependencies/ignore-units.d/
+ln -sf %{_prefix}/lib/systemd/system/scim@.service %{_sysconfdir}/systemd/default-extra-dependencies/ignore-units.d/
%files
%manifest %{name}.manifest
@@ -36,4 +41,6 @@ ln -sf %{_prefix}/lib/systemd/user/scim.service %{_sysconfdir}/systemd/default-e
/etc/scim/conf/*
%{_prefix}/lib/systemd/user/scim.service
%{_prefix}/lib/systemd/user/basic.target.wants/scim.service
+%{_prefix}/lib/systemd/system/scim@.service
+%{_prefix}/lib/systemd/system/user-basic@.target.wants/scim@.service
%license LICENSE.APLv2
diff --git a/scim@.service b/scim@.service
new file mode 100644
index 0000000..207794d
--- /dev/null
+++ b/scim@.service
@@ -0,0 +1,20 @@
+[Unit]
+PartOf=userlogin@%i.target
+Description=Start the input service framework panel
+After=enlightenment-user@%i.service
+DefaultDependencies=no
+ConditionPathExists=!/run/user/%i/.container
+
+[Service]
+User=%i
+Environment=DBUS_SESSION_BUS_ADDRESS=kernel:path=/sys/fs/kdbus/%i-user/bus;unix:path=/run/user/%i/bus
+Environment=XDG_RUNTIME_DIR=/run/user/%i
+SmackProcessLabel=User
+ExecStart=/usr/bin/isf-panel-efl
+Environment="DISPLAY=:0.0" "HOME=%h" USE_OZONE_WAYLAND_VKB=1 OZONE_WAYLAND_USE_XDG_SHELL='defined'
+EnvironmentFile=/run/tizen-system-env
+Restart=on-failure
+RestartSec=2
+
+[Install]
+WantedBy=user-default@.target