HiPhone_BE/config/settings/local.py

38 lines
757 B
Python
Raw Permalink Normal View History

2023-04-15 22:49:50 +09:00
from .base import *
# SECURITY WARNING: don't run with debug turned on in production!
DEBUG = True
ALLOWED_HOSTS = ["*"]
CORS_ALLOW_ALL_ORIGINS = True
2023-05-16 23:44:33 +09:00
CORS_ALLOW_CREDENTIALS = True
2023-04-15 22:49:50 +09:00
2023-06-23 02:09:19 +09:00
CSRF_TRUSTED_ORIGINS = ["http://localhost:5173"]
2023-04-15 22:49:50 +09:00
# Database
# https://docs.djangoproject.com/en/4.2/ref/settings/#databases
DATABASES = {
"default": {
"ENGINE": "django.db.backends.sqlite3",
"NAME": BASE_DIR / "db.sqlite3",
}
}
2023-05-17 17:13:38 +09:00
# Debug toolbar
INSTALLED_APPS += ["debug_toolbar"]
MIDDLEWARE += ["debug_toolbar.middleware.DebugToolbarMiddleware"]
INTERNAL_IPS = ["127.0.0.1"]
2023-10-18 15:14:50 +09:00
# renderer class
REST_FRAMEWORK["DEFAULT_RENDERER_CLASSES"] = [
"rest_framework.renderers.JSONRenderer",
"rest_framework.renderers.BrowsableAPIRenderer",
]