diff --git a/gateway/main/settings.py b/gateway/main/settings.py index c19fd86b8..f580a669a 100644 --- a/gateway/main/settings.py +++ b/gateway/main/settings.py @@ -36,7 +36,7 @@ DEBUG = int(os.environ.get("DEBUG", 1)) # SECURITY WARNING: don't run with debug turned on in production! -LOG_LEVEL = "DEBUG" if int(os.environ.get("DEBUG", 1)) else "WARNING" +LOG_LEVEL = "DEBUG" if int(os.environ.get("DEBUG", 1)) else "INFO" ALLOWED_HOSTS = os.environ.get("ALLOWED_HOSTS", "*").split(",") diff --git a/gateway/main/urls.py b/gateway/main/urls.py index bfe6b7555..5b3c16571 100644 --- a/gateway/main/urls.py +++ b/gateway/main/urls.py @@ -16,6 +16,7 @@ from django.conf import settings from django.conf.urls.static import static +from django.views.static import serve from django.contrib import admin from django.urls import path, include, re_path from rest_framework import routers, permissions @@ -48,8 +49,8 @@ path("", include("django_prometheus.urls")), path("backoffice/", admin.site.urls), re_path(r"^api/v1/", include(("api.v1.urls", "api"), namespace="v1")), + re_path(r"^static/(?P.*)$", serve, {"document_root": settings.STATIC_ROOT}), ] -urlpatterns += static(settings.STATIC_URL, document_root=settings.STATIC_ROOT) if settings.DEBUG: urlpatterns += [