Skip to content

Add support for D-Bus session management in wait_for_session hook#69

Merged
jikortus merged 1 commit into
mainfrom
kiosk_wait
Jun 10, 2026
Merged

Add support for D-Bus session management in wait_for_session hook#69
jikortus merged 1 commit into
mainfrom
kiosk_wait

Conversation

@jstodola

@jstodola jstodola commented Jun 9, 2026

Copy link
Copy Markdown
Collaborator

This update introduces environment variable exports for XDG_RUNTIME_DIR and DBUS_SESSION_BUS_ADDRESS. It also adds a function to check if specific D-Bus names are owned and implements a waiting mechanism for gnome-kiosk and Mutter APIs before starting the gnome-ponytail-daemon, enhancing session readiness checks.

@jikortus jikortus left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for this improvement, waiting for gnome-kiosk/Mutter becoming available on D-Bus seems to be useful. However, the environment variables exports seem to be unnecessary, as those are already defined in the systemd unit files (https://github.com/rhinstaller/anabot/blob/main/etc/systemd/system/anabot-direct.service#L16 and https://github.com/rhinstaller/anabot/blob/main/etc/systemd/system/anabot.service#L23).

I also wonder if we could perhaps get rid of the sleep in the unit files (https://github.com/rhinstaller/anabot/blob/main/etc/systemd/system/anabot.service#L15) after we deploy this change (dbus_name_owned()). However, we should make sure that removing it would bring back the crashes due to which we introduced it earlier on, it's just a momentary idea without any deeper research - just in case you'd want to experiment with it.

This update adds a function to check if specific D-Bus names are owned
and implements a waiting mechanism for gnome-kiosk and Mutter APIs
before starting the gnome-ponytail-daemon, enhancing session readiness
checks.

Generated-by: Cursor
@jstodola

jstodola commented Jun 10, 2026

Copy link
Copy Markdown
Collaborator Author

Thank you for this improvement, waiting for gnome-kiosk/Mutter becoming available on D-Bus seems to be useful. However, the environment variables exports seem to be unnecessary, as those are already defined in the systemd unit files (https://github.com/rhinstaller/anabot/blob/main/etc/systemd/system/anabot-direct.service#L16 and https://github.com/rhinstaller/anabot/blob/main/etc/systemd/system/anabot.service#L23).

Good point, removed and confirmed it works fine.

I also wonder if we could perhaps get rid of the sleep in the unit files (https://github.com/rhinstaller/anabot/blob/main/etc/systemd/system/anabot.service#L15) after we deploy this change (dbus_name_owned()). However, we should make sure that removing it would bring back the crashes due to which we introduced it earlier on, it's just a momentary idea without any deeper research - just in case you'd want to experiment with it.

The sleep is for Xorg installations, this change affects just Wayland installations, so it's unrelated.

The PR is ready for a final review.

@jstodola jstodola requested a review from jikortus June 10, 2026 11:16

@jikortus jikortus left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The changes look good to me, hopefully improving stability. Thank you!

@jikortus jikortus merged commit 88e025c into main Jun 10, 2026
3 checks passed
@jikortus jikortus deleted the kiosk_wait branch June 10, 2026 17:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants