Prettify subcommand to kill minions

I realize that this is just cosmetic change. And possibly that there is
a compatibility issue, if minionswarm is to be used on platforms that
don't have pkill.
This commit is contained in:
Henrik Holmboe 2013-10-11 10:02:23 +02:00
parent 496730dea5
commit 4a48dc791b

View file

@ -217,8 +217,7 @@ class Swarm(object):
def shutdown(self):
print('Killing any remaining running minions')
subprocess.call(
'kill -KILL $(ps aux | grep python | grep "salt-minion" '
'| awk \'{print $2}\')',
'pkill -KILL -f "python.*salt-minion"',
shell=True
)
if not self.opts['no_clean']: