mirror of
https://github.com/valitydev/salt.git
synced 2024-11-08 17:33:54 +00:00
17 lines
351 B
Plaintext
17 lines
351 B
Plaintext
|
#!/bin/bash
|
||
|
#
|
||
|
# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany.
|
||
|
|
||
|
markerfile=/var/run/stopped-salt-minion-on-suspend
|
||
|
|
||
|
if [ "$1" = pre ] ; then
|
||
|
if systemctl is-active salt-minion ; then
|
||
|
systemctl stop salt-minion
|
||
|
echo 1 > $markerfile
|
||
|
fi
|
||
|
fi
|
||
|
if [ "$1" = post ] && [ -e $markerfile ] ; then
|
||
|
rm -f $markerfile
|
||
|
systemctl start salt-minion
|
||
|
fi
|