updated cache

This commit is contained in:
nvrl committed 2026-02-16 17:56:05 +01:00
1 parent d9ab80e096
commit cec7410249
2 files changed
+19 -6

No files matched your search

+12
View File
@@ -94,6 +94,18 @@ DATABASES = {
}
}
# Cache configuration for Ratelimiting
CACHES = {
'default': {
'BACKEND': 'django.core.cache.backends.filebased.FileBasedCache',
'LOCATION': os.path.join(BASE_DIR, 'django_cache'),
}
}
# Silence the ratelimit error for locmem if it appears,
# though we just switched to file-based which is supported.
SILENCED_SYSTEM_CHECKS = ['django_ratelimit.E003']
# Password validation
# https://docs.djangoproject.com/en/6.0/ref/settings/#auth-password-validators
+7 -6
View File
@@ -1,3 +1,5 @@
version: '3.8'
services:
# --- Backend Service (Gunicorn + WhiteNoise) ---
backend:
@@ -9,7 +11,7 @@ services:
- narl
- internal
env_file:
- .env
- .env.narl.io
volumes:
- ./backend:/app
- ./legacy:/app/legacy
@@ -23,7 +25,6 @@ services:
labels:
- "traefik.enable=true"
- "traefik.docker.network=narl"
# Using a unique project-specific router name to avoid network conflicts
- "traefik.http.routers.holy-energy-backend.priority=100"
- "traefik.http.routers.holy-energy-backend.rule=Host(`holy.narl.io`) && (PathPrefix(`/api`) || PathPrefix(`/admin`) || PathPrefix(`/static`) || PathPrefix(`/media`))"
- "traefik.http.routers.holy-energy-backend.entrypoints=websecure"
@@ -41,15 +42,16 @@ services:
networks:
- narl
env_file:
- .env
- .env.narl.io
depends_on:
- backend
labels:
- "traefik.enable=true"
- "traefik.docker.network=narl"
# Lower priority fallback
# Higher priority for backend paths is set on the backend router,
# but we use an explicit exclusion here to be 100% safe.
- "traefik.http.routers.holy-energy-frontend.priority=10"
- "traefik.http.routers.holy-energy-frontend.rule=Host(`holy.narl.io`)"
- "traefik.http.routers.holy-energy-frontend.rule=Host(`holy.narl.io`) && !(PathPrefix(`/api`) || PathPrefix(`/admin`) || PathPrefix(`/static`) || PathPrefix(`/media`))"
- "traefik.http.routers.holy-energy-frontend.entrypoints=websecure"
- "traefik.http.routers.holy-energy-frontend.tls.certresolver=https_resolver"
- "traefik.http.services.holy-energy-frontend.loadbalancer.server.port=80"
@@ -62,4 +64,3 @@ networks:
volumes:
db_data: