Add script for restart hooks

This commit is contained in:
bwt committed 2023-01-25 00:13:56 -05:00
1 parent e42f5d2a9a
commit 21ccd036bd
1 file changed
+9
+9
View File
@@ -0,0 +1,9 @@
#!/bin/sh
for UNITFILE in ${1}; do
if /usr/bin/systemctl is-active --quiet "${UNITFILE}"; then
/usr/bin/systemctl restart "${UNITFILE}"
else
echo >&2 " Skipped: ${UNITFILE} not active"
fi
done