"Correct" way to source X11 scripts?

I’m new to Clear Linux and am still trying to wrap my head around the avoidance of /etc. Where, in this paradigm, would be the correct place to add X11 variables for systemd and dbus?

The context is that certain services that are supposed to be auto-loaded aren’t currently working out of the box. A good example is XFCE’s xfce4-notifyd. It installs a dbus service description file, but when a dbus event fires that would otherwise start the service, it fails due to a missing :DISPLAY variable.

Most distro’s include and automatically source an upstream-provided script for this exact purpose: https://github.com/systemd/systemd/blob/98cd752a285c0fba84b8d98f3ba255ed4d11c881/xorg/50-systemd-user.sh

It seems to me like this should “just work” and creation of a config for something so common shouldn’t be required. I’m willing to set up a PR if I can get some more guidance on best practices in this environment.

On the off-hand chance that this does normally work and is expected to, I’ve removed almost all gnome packages and gdm; I’m running solely lightdm and XFCE.

This shouldn’t happen, there is code to avoid this entire problem. Also, you may be running wayland. It may be worth opening a bug on github so it can be tracked (otherwise it’ll be forgotten/overlooked due to holidays.).