--- a/tools/rc.thermferm Thu Apr 11 15:58:49 2024 +0200 +++ b/tools/rc.thermferm Sat Apr 13 16:50:26 2024 +0200 @@ -10,6 +10,7 @@ fi PIDFILE=/run/thermferm.pid +STOPTIME=45 case "$1" in start) @@ -26,6 +27,14 @@ echo -n "Stopping Fermentation Controller: " if [ -f ${PIDFILE} ]; then kill $(cat ${PIDFILE}) + tim=0 + while [ true ]; do + [ ! -f "${PIDFILE}" ] && break; + [ $tim -gt $STOPTIME ] && break; + echo -n "." + sleep 1 + tim=$(($tim+1)) + done echo "done." else echo "wasn't running."