Skip to content

fix: use OnStartupSec instead of OnBootSec for user timers#1268

Merged
RoyalOughtness merged 2 commits intosecureblue:livefrom
HastD:flatpak-setup-fix
Aug 19, 2025
Merged

fix: use OnStartupSec instead of OnBootSec for user timers#1268
RoyalOughtness merged 2 commits intosecureblue:livefrom
HastD:flatpak-setup-fix

Conversation

@HastD
Copy link
Copy Markdown
Collaborator

@HastD HastD commented Aug 18, 2025

Per the systemd documentation (systemd.timer(5)), "the user service manager is generally started on first login only, not already during boot." So, timers for user services should use OnStartupSec instead of OnBootSec, as an activation time relative to boot time could elapse before the user service manager starts, making the timer fail to trigger as expected.

Also did some minor cleanup on timers and services:

  • Adjusted the timing for secureblue-flatpak-setup.timer to simply use OnStartupSec=5s.
  • Removed Persistent=true from timers with no OnCalendar trigger, as it has no effect on such timers.
  • Added --noninteractive to the flatpak install commands in the flatpak setup script to avoid flooding the system journal with download progress messages while it's running.

This should fix #1266.

Per the systemd documentation (systemd.timer(5)), "the user service
manager is generally started on first login only, not already during
boot." So, timers for user services should use OnStartupSec instead of
OnBootSec, as an activation time relative to boot time could elapse
before the user service manager starts, making the timer fail to trigger
as expected.

Also did some minor cleanup on timers and services:
* Adjusted the timing for `secureblue-flatpak-setup.timer` to simply use
  `OnStartupSec=5s`.
* Removed `Persistent=true` from timers with no `OnCalendar` trigger, as
  it has no effect on such timers.
* Added `--noninteractive` to the `flatpak install` commands in the
  flatpak setup script to avoid flooding the system journal with
  download progress messages while it's running.

Signed-off-by: Daniel Hast <[email protected]>
@HastD HastD requested a review from RoyalOughtness as a code owner August 18, 2025 23:32
@RoyalOughtness RoyalOughtness enabled auto-merge (squash) August 19, 2025 18:30
@RoyalOughtness RoyalOughtness merged commit 9b09349 into secureblue:live Aug 19, 2025
10 checks passed
@HastD HastD deleted the flatpak-setup-fix branch August 19, 2025 18:39
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.

[BUG] flatpak provisioning retry logic doesn't function

4 participants