Skip to content

Start containers with a restart policy at boot - #48

Merged
ihavespoons merged 1 commit into
mainfrom
podman-restart
Nov 8, 2026
Merged

ihavespoons merged 1 commit into
mainfrom
podman-restart

Conversation

@ihavespoons

Copy link
Copy Markdown
Collaborator

The problem

After the reboot on 2026-11-08, the media stack and heathen-trainer-1 stayed down, although their restart policy is unless-stopped. Podman has no daemon. At boot, only the podman-restart.service user unit starts containers by their restart policy, and that unit was disabled for the sibyl user.

The change

  • os/Containerfile adds podman-restart.service to systemctl --global enable. The unit runs podman start --all --filter should-start-on-boot=true. That starts containers with always or unless-stopped, but not an unless-stopped container that its owner stopped.
  • The six Quadlet containers have restart policy no on the box, so the unit does not start them a second time.
  • The host guide and the design overview say which containers start at boot.

Verification

  • The arm64 image builds. /etc/systemd/user/default.target.wants/podman-restart.service points to /usr/lib/systemd/user/podman-restart.service.
  • bootc container lint passes 14 checks.
  • I did not deploy this to the box, because a training run is in progress there.

🤖 Generated with Claude Code

Podman has no daemon, so restart: unless-stopped did nothing after a
reboot, and the media stack stayed down. Enable the podman-restart.service
user unit for every user. It starts containers whose policy is always or
unless-stopped. The Quadlet containers have no restart policy, so systemd
alone starts them.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@ihavespoons
ihavespoons merged commit 1b56733 into main Nov 8, 2026
13 checks passed
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.

1 participant