OPINIONATED OMARCHY
TROUBLESHOOTING CORPUS
790
RECORDS
790
AUDITED
0
UNCHECKED
2388
SOURCES
LIVE
apps-services high common DISPUTE

Make Omarchy's Docker containers come back after a reboot

omarchyarchdockersystemd
AUDITED Audited against its sources and confirmed accurate.
AUDIT NOTE

Fully verified against Omarchy 4.0.1: install/config/enable-services.sh enables docker.socket and never docker.service, bin/omarchy-upgrade-to-quattro explicitly disables docker.service and ships /etc/systemd/system/docker.service.d/no-block-boot.conf (the exact path the record cites), and issue basecamp/omarchy#8541 confirms the mechanism verbatim: socket activation only fires on /run/docker.sock, published ports are served by docker-proxy (a child of dockerd), and --restart unless-stopped is a daemon-side policy that never runs while the daemon is down. Fix, restart-policy inspection and the ss -ltnp verify are all correct. Only nit: on stock Omarchy 4 the docker commands in the symptom/fix need sudo (or omarchy-sudo-docker), since Quattro does not put you in the docker group.

Symptom

I installed Postgres/MySQL/Redis from Omarchy's Install > Development > Docker DB menu. It works, but after every reboot my app cannot connect, with connection refused on 127.0.0.1:5432, until I run docker ps once, after which everything springs to life.

Cause

Omarchy deliberately enables only docker.socket and leaves docker.service disabled to keep boot fast. Socket activation only fires when something actually touches /run/docker.sock. Published container ports are served by docker-proxy, a child of the daemon, which does not exist while the daemon is inactive, so the containers' --restart unless-stopped policy is never evaluated at boot.

Fix

Enable the service alongside the socket:


sudo systemctl enable --now docker.service

Omarchy already ships a drop-in at /etc/systemd/system/docker.service.d/no-block-boot.conf that takes Docker off the critical boot path, so this does not slow down boot. Confirm both are enabled:


systemctl is-enabled docker.service docker.socket

And confirm the containers themselves have a restart policy:


docker inspect -f '{{.Name}} {{.HostConfig.RestartPolicy.Name}}' $(docker ps -aq)
docker update --restart unless-stopped <container>

Verify

Reboot, and without running any docker command, ss -ltnp | grep 5432 shows the port listening and your app connects.

Sources

omarchy-docker-containers-dead-after-reboot