Skip to content

Commit

Permalink
TMP: use lock file to prevent multiple launches
Browse files Browse the repository at this point in the history
  • Loading branch information
astrofrog committed Feb 28, 2024
1 parent 627d0a6 commit 4e8ae38
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions start_glue.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,12 @@

if __name__ == "__main__":

if os.path.exists('/tmp/gluelock'):
raise Exception("glue lock already exists")

with open('/tmp/gluelock', 'w') as f:
f.write('Denied!')

if '--debug' in sys.argv or '--test' in sys.argv:
logger.setLevel("INFO")

Expand Down

0 comments on commit 4e8ae38

Please sign in to comment.