mirror of
https://expo.survex.com/repositories/troggle/.git
synced 2024-11-25 08:41:51 +00:00
Add check to avoid running databaseReset as root accidentally
This commit is contained in:
parent
8b74ff4bb6
commit
227120fd57
@ -6,6 +6,10 @@ import timeit
|
||||
import json
|
||||
|
||||
import settings
|
||||
if os.geteuid() == 0:
|
||||
print("This script should be run as expo not root - quitting")
|
||||
exit()
|
||||
|
||||
os.environ['PYTHONPATH'] = settings.PYTHON_PATH
|
||||
os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'settings')
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user