mirror of
https://github.com/telekom-security/tpotce.git
synced 2025-07-02 01:27:27 -04:00
scripts, configs, optimizations, dashboard base
This commit is contained in:
@ -2,11 +2,36 @@
|
||||
|
||||
########################################################
|
||||
# T-Pot #
|
||||
# Only start the container found in /etc/init/t-pot #
|
||||
# Only start the containers found in /etc/init/ #
|
||||
# #
|
||||
# v0.02 by mo, DTAG, 2016-02-08 #
|
||||
# v0.03 by mo, DTAG, 2016-02-12 #
|
||||
########################################################
|
||||
|
||||
# Make sure not to interrupt a check
|
||||
while true
|
||||
do
|
||||
if ! [ -a /var/run/check.lock ];
|
||||
then break
|
||||
fi
|
||||
sleep 0.1
|
||||
if [ "$myCOUNT" = "1" ];
|
||||
then
|
||||
echo -n "Waiting for services "
|
||||
else echo -n .
|
||||
fi
|
||||
if [ "$myCOUNT" = "6000" ];
|
||||
then
|
||||
echo
|
||||
echo "Overriding check.lock"
|
||||
rm /var/run/check.lock
|
||||
break
|
||||
fi
|
||||
myCOUNT=$[$myCOUNT +1]
|
||||
done
|
||||
|
||||
# We do not want to get interrupted by a check
|
||||
touch /var/run/check.lock
|
||||
|
||||
# Delete all T-Pot upstart scripts
|
||||
for i in $(ls /data/upstart/);
|
||||
do
|
||||
@ -20,4 +45,12 @@ for i in $(cat /data/images.conf);
|
||||
cp /data/upstart/"$i".conf /etc/init/;
|
||||
done
|
||||
|
||||
echo Please reboot for the changes to take effect.
|
||||
# Allow checks to resume
|
||||
rm /var/run/check.lock
|
||||
|
||||
# Announce reboot
|
||||
echo "Rebooting in 5 seconds for the changes to take effect."
|
||||
sleep 5
|
||||
|
||||
# Reboot
|
||||
reboot
|
||||
|
Reference in New Issue
Block a user