|
|
@ -40,6 +40,8 @@ else: |
|
|
|
DJANGO_PROJECT_PATH = os.path.dirname(sys.argv[0]) + '/..' |
|
|
|
DJANGO_PROJECT_PATH = os.path.dirname(sys.argv[0]) + '/..' |
|
|
|
sys.path.insert(1, DJANGO_PROJECT_PATH) |
|
|
|
sys.path.insert(1, DJANGO_PROJECT_PATH) |
|
|
|
os.environ['DJANGO_SETTINGS_MODULE'] = DJANGO_SETTINGS_MODULE |
|
|
|
os.environ['DJANGO_SETTINGS_MODULE'] = DJANGO_SETTINGS_MODULE |
|
|
|
|
|
|
|
import django |
|
|
|
|
|
|
|
django.setup() |
|
|
|
from pyi2phosts.postkey.models import i2phost |
|
|
|
from pyi2phosts.postkey.models import i2phost |
|
|
|
from pyi2phosts.lib.validation import validate_hostname |
|
|
|
from pyi2phosts.lib.validation import validate_hostname |
|
|
|
from pyi2phosts.lib.validation import validate_b64hash |
|
|
|
from pyi2phosts.lib.validation import validate_b64hash |
|
|
|