Integrate login and auth server API

This commit is contained in:
2018-11-13 02:45:16 -07:00
parent bd44438277
commit 75d4395964
8 changed files with 319 additions and 238 deletions

View File

@@ -25,9 +25,6 @@ SECRET_KEY = 'h$p_vf^h$h@cebvgeynhda3-@i&+f-(3k9w-qsftn_+!-o_)$0'
# SECURITY WARNING: don't run with debug turned on in production!
DEBUG = True
ALLOWED_HOSTS = []
# Application definition
INSTALLED_APPS = [
@@ -39,6 +36,7 @@ INSTALLED_APPS = [
'django.contrib.staticfiles',
'rest_framework',
'rest_framework.authtoken',
'corsheaders',
'authserver.api',
]
@@ -49,8 +47,14 @@ REST_FRAMEWORK = {
),
}
#CORS_ORIGIN_WHITELIST = (
# 'localhost:8000',
#)
CORS_ORIGIN_ALLOW_ALL = True
MIDDLEWARE = [
'corsheaders.middleware.CorsMiddleware',
'django.middleware.security.SecurityMiddleware',
'django.contrib.sessions.middleware.SessionMiddleware',
'django.middleware.common.CommonMiddleware',

View File

@@ -1,6 +1,7 @@
certifi==2018.8.24
chardet==3.0.4
Django==2.1.1
django-cors-headers==2.4.0
djangorestframework==3.8.2
idna==2.7
Pillow==5.2.0