Fakultas Ilmu Komputer UI

Skip to content
Snippets Groups Projects

merge branch Development to branch Main

Compare and
22 files
+ 349
59
Compare changes
  • Side-by-side
  • Inline

Files

+ 18
3
@@ -29,6 +29,15 @@ DEBUG = config('DEBUG')
ALLOWED_HOSTS = ["*"]
CSRF_TRUSTED_ORIGINS = [
'https://evanaurelrius.tech'
]
CORS_ORIGIN_ALLOW_ALL = False
CORS_ALLOWED_ORIGINS = (
'https://evanaurelrius.tech'
)
# Application definition
@@ -39,8 +48,10 @@ INSTALLED_APPS = [
'django.contrib.sessions',
'django.contrib.messages',
'django.contrib.staticfiles',
'whitenoise.runserver_nostatic',
'home',
'notes',
]
MIDDLEWARE = [
@@ -51,6 +62,7 @@ MIDDLEWARE = [
'django.contrib.auth.middleware.AuthenticationMiddleware',
'django.contrib.messages.middleware.MessageMiddleware',
'django.middleware.clickjacking.XFrameOptionsMiddleware',
"whitenoise.middleware.WhiteNoiseMiddleware",
]
ROOT_URLCONF = 'exavarius.urls'
@@ -58,7 +70,7 @@ ROOT_URLCONF = 'exavarius.urls'
TEMPLATES = [
{
'BACKEND': 'django.template.backends.django.DjangoTemplates',
'DIRS': [],
"DIRS": [os.path.join(BASE_DIR,"templates")],
'APP_DIRS': True,
'OPTIONS': {
'context_processors': [
@@ -127,9 +139,12 @@ USE_TZ = True
# Static files (CSS, JavaScript, Images)
# https://docs.djangoproject.com/en/4.1/howto/static-files/
STATICFILES_DIRS = (
os.path.join(BASE_DIR, "static"),
)
STATIC_URL = 'static/'
STATIC_ROOT = os.path.join(BASE_DIR, 'staticfiles')
STATICFILES_STORAGE="whitenoise.storage.CompressedManifestStaticFilesStorage"
# Default primary key field type
# https://docs.djangoproject.com/en/4.1/ref/settings/#default-auto-field
Loading