[systemd-devel] $PWD=/ in systemd --user

Kok, Auke-jan H auke-jan.h.kok at intel.com
Tue Jul 3 14:26:31 PDT 2012


On Tue, Jul 3, 2012 at 11:10 AM, Léo Gillot-Lamure
<leo.gillot at navaati.net> wrote:
> I'm running a user session using systemd --user and my PWD in the
> session (visible, for example, when launching a xterm) is / instead of
> $HOME as one would expect. That's a bit annoying.
> I tried to wrap systemd --user in a script doing "cd $HOME" before
> exec'ing it, but it doesn't change anything.
>
> Have you guys using the user session noticed the same thing ?

yes.

Basically systemd --user doesn't do the "sane default" stuff that you
would expect. I've been thinking of a way to solve the issue, but it's
not clear to me what the right solution is:

- write a wrapper that wraps around systemd --user. This could handle
login management as well and talk to logind.

- write or use pam modules to do these bits for us, and just let
/etc/pam.d/login(?) catch it.

- ???

Auke


More information about the systemd-devel mailing list