From 49a5a42ff917d73f6f06c2c135785955151be87e Mon Sep 17 00:00:00 2001 From: Benjamin Neff Date: Sun, 11 Oct 2020 00:11:38 +0200 Subject: [PATCH] fix(service): don't reload too quick after starting the service --- diaspora/service.sls | 3 +++ 1 file changed, 3 insertions(+) diff --git a/diaspora/service.sls b/diaspora/service.sls index c86136f..7576da5 100644 --- a/diaspora/service.sls +++ b/diaspora/service.sls @@ -77,6 +77,9 @@ diaspora_web_service_restart: service.running: - name: diaspora-web.service - reload: True + - unless: >- + systemctl is-active diaspora-web.service | grep -E 'activ(e|ating)' && + test $(ps -p $(systemctl show --property MainPID diaspora-web.service | cut -d= -f2) -oetimes=) -lt 10 - require: - service: diaspora_service - watch: