aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
-rwxr-xr-xupdate_apt-panopticon7
1 files changed, 6 insertions, 1 deletions
diff --git a/update_apt-panopticon b/update_apt-panopticon
index ebd5e45..219d86a 100755
--- a/update_apt-panopticon
+++ b/update_apt-panopticon
@@ -14,7 +14,12 @@ fi
14# Check if the lock file still exists. 14# Check if the lock file still exists.
15if [ -f apt-panopticon.lock ] ; then 15if [ -f apt-panopticon.lock ] ; then
16 # Check if it's still running. 16 # Check if it's still running.
17 ps ax -eo pid,args | grep "luajit ./apt-panopticon.lua" | grep -v "grep luajit ./apt-panopticon.lua" | while read line ; do echo "Previous apt-panopticon still running, exiting." exit 1 ; done 17 ps ax -eo pid,args | grep "luajit ./apt-panopticon.lua" | grep -v "grep luajit ./apt-panopticon.lua" | while read line ; do touch apt-panopticon.running ; exit ; done
18 if [ -f apt-panopticon.running ] ; then
19 echo "Previous apt-panopticon still running, exiting."
20 rm apt-panopticon.running
21 exit 1
22 fi
18 echo "Crashed apt-panopticon detected, removing stale lock file." 23 echo "Crashed apt-panopticon detected, removing stale lock file."
19 rm apt-panopticon.lock 24 rm apt-panopticon.lock
20fi 25fi