Commit d50e7b78 authored by GuiΩ's avatar GuiΩ
Browse files

fix(config_prod): fix config

parent d8d8adfd
Pipeline #520803 failed with stages
in 1 minute
......@@ -43,9 +43,10 @@ INSTALLED_APPS = [
'django.contrib.sessions',
'django.contrib.messages',
'django.contrib.staticfiles',
'password_reset',
# 'password_reset',
'rest_framework',
'webpack_loader',
# 'webpack_loader',
'django_vite',
'am',
# 'gunicorn',
]
......@@ -129,7 +130,6 @@ DEFAULT_FROM_EMAIL = 'no_reply@ac-grenoble.fr'
EMAIL_USE_TLS = False
EMAIL_USE_SSL = True
SESSION_EXPIRE_AT_BROWSER_CLOSE = True
# Internationalization
# https://docs.djangoproject.com/en/3.1/topics/i18n/
......@@ -144,6 +144,17 @@ USE_L10N = True
USE_TZ = True
### Vite ###
VITE_BASE_DIR = BASE_DIR / 'frontend'
# the absolute path to where the assets are built.
# This must correspond to the build.outDir in ViteJS configuration.
# The DJANGO_VITE_ASSETS_PATH must be included in STATICFILES_DIRS
DJANGO_VITE_ASSETS_PATH = VITE_BASE_DIR / 'dist'
DJANGO_VITE_DEV_MODE = False
# Static files (CSS, JavaScript, Images)
# https://docs.djangoproject.com/en/3.1/howto/static-files/
......@@ -151,10 +162,11 @@ USE_TZ = True
# where they are
STATICFILES_DIRS = [
# os.path.join(BASE_DIR, "dist"),
os.path.join(BASE_DIR, "static/"),
# os.path.join(BASE_DIR, "static/"),
DJANGO_VITE_ASSETS_PATH
]
# where place them
# STATIC_ROOT = os.path.join(BASE_DIR, 'public')
STATIC_ROOT = os.path.join(BASE_DIR, 'static')
# STATICFILES_DIRS = [
# os.path.join(BASE_DIR, "public"),
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment