def get_jwt_details(): active_config = get_global_config() r = requests.post('http://127.0.0.1:8000/api/token', json={ 'username': active_config['superuser']['username'], 'password': active_config['superuser']['password'] }).json() return (r)
https://docs.djangoproject.com/en/2.2/topics/settings/ For the full list of settings and their values, see https://docs.djangoproject.com/en/2.2/ref/settings/ """ import os # Build paths inside the project like this: os.path.join(BASE_DIR, ...) BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) TEMPLATE_DIR = os.path.join(BASE_DIR, 'templates') from global_config import get_global_config active_config = get_global_config() # Quick-start development settings - unsuitable for production # See https://docs.djangoproject.com/en/2.2/howto/deployment/checklist/ # SECURITY WARNING: keep the secret key used in production secret! SECRET_KEY = '=9f+j$o6&rci+8&$!3hc$_pp@@l+=mwa9#++=iqv68x(3u16c3' # SECURITY WARNING: don't run with debug turned on in production! DEBUG = True # Application definition INSTALLED_APPS = [ 'django.contrib.admin', 'django.contrib.auth', 'django.contrib.contenttypes', 'django.contrib.sessions',