How do you make Docker survive a host reboot cleanly?
BeginnerProductionResource Limits, Health & Reliability
Answer
Enable the daemon (systemctl enable docker containerd), set --restart unless-stopped on services (or Compose restart:), keep data in named volumes on durable disks, and ensure dependencies start in order via health-based depends_on or retry logic. Test with an actual reboot, not just systemctl restart docker.
More on Resource Limits, Health & Reliability
How do you set memory and CPU limits, and what happens when they are exceeded?BeginnerWhat is the difference between `--cpus`, `--cpu-shares` and `--cpuset-cpus`?BeginnerWhat does `--memory-reservation` do?AdvancedHow do you diagnose an OOM-killed container?IntermediateWhy do JVM and Node services in containers need explicit memory flags?IntermediateWhat is CPU throttling, and how do you detect it?Advanced