Fix django path finding for bin/ scripts
This commit is contained in:
parent
f10c9433c0
commit
c0a65be9d0
|
@ -11,7 +11,8 @@ import django
|
|||
import ipaddress
|
||||
|
||||
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "dnmgmt.settings")
|
||||
sys.path.append("..")
|
||||
BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
|
||||
sys.path.append(BASE_DIR)
|
||||
django.setup()
|
||||
|
||||
|
||||
|
|
|
@ -10,7 +10,8 @@ import logging
|
|||
import select
|
||||
|
||||
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "dnmgmt.settings")
|
||||
sys.path.append("..")
|
||||
BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
|
||||
sys.path.append(BASE_DIR)
|
||||
django.setup()
|
||||
|
||||
from whoisdb.helpers import findInDatabase, getWhoisObjectFields
|
||||
|
|
Loading…
Reference in New Issue