[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Systemd user environment variables not picked up for me


I'm experimenting with systemd environment variables. I have a file
~/.config/environment.d/50-default.conf where I set a few variables:

> GDK_BACKEND=wayland
> TESTVAR=test123

However, these variables are not set in my environment when I log in. I
have tried logging in in text mode and in the GUI (sddm -> swaywm in my
case). I have tried to systemd daemon-reload and to reboot the machine,
but without much success. The environment variables are not set for me.

When I run /lib/systemd/user-environment-generators/30-systemd-environment-d-generator
from a terminal, then I see the variables being printed on stdout, so I
assume that both the file path and the syntax are correct. Something
seems to prevent the file from being loaded when I log in.

Bug https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=869144 suggests
this was working at some point for someone else. Does someone know how I
can debug this issue?


Reply to: