Perhaps you could also add the mounts as dependencies to the Docker daemon.
Comment on What is easiest solution to automatically resolve missing mounts due to e.g. a power outage?
sylverstream@lemmy.nz 9 months agoThat’s interesting! I’ve converted all my docker run commands to docker compose, as I found that easier to manage. But, I guess you can’t do the dependencies like you have. Also, yours has the advantage it always pulls the latest.
qaz@lemmy.world 9 months ago
key@lemmy.keychat.org 9 months ago
Doesn’t seem mutually exclusive. Replace the docker rm with compose down and the docker run with compose up.
avidamoeba@lemmy.ca 9 months ago
Exactly. In fact I have a few multi-container services with docker-compose that I have to write systems unit files for.