tor-router/shutdown.sh

25 lines
372 B
Bash
Raw Normal View History

2015-07-06 14:21:09 +00:00
#!/bin/bash
index="0"
while [ $index -lt $TOR_INSTANCES ]
do
current_instance=$INSTANCE_PREFIX$index
echo "shutting down $current_instance"
docker rm -f $current_instance
index=$[index+1]
done
2015-07-06 18:26:31 +00:00
echo "shutting down haproxy..."
2015-07-06 14:21:09 +00:00
docker rm -f haproxy
2015-07-06 18:26:31 +00:00
echo 'removing files...'
rm -rf /tmp/haproxy.cfg
rm -rf /tmp/tor
2015-07-06 14:21:09 +00:00
#sleep 5
2015-07-06 18:26:31 +00:00
echo 'tor router has shut down'
2015-07-06 14:21:09 +00:00
exit 0