From 3959e296ae30d41bca11a2ed5fa7a478a166cb69 Mon Sep 17 00:00:00 2001 From: Tobias Florek Date: Thu, 9 Jul 2015 10:16:08 +0200 Subject: [PATCH] BindTo docker in example systemd service BindTo=docker.service ensures, that the service is stopped or restarted whenever docker is. This is more sane behavior if no docker restart policy is given (i.e. --restart=always). --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index cc412fc..0f8aa0b 100644 --- a/README.md +++ b/README.md @@ -126,6 +126,7 @@ cat root/etc/systemd/system/httpd_template.service [Unit] Description=The Apache HTTP Server for TEMPLATE After=docker.service +BindTo=docker.service [Service] ExecStart=/usr/bin/docker start TEMPLATE