diff --git a/Dockerfile b/Dockerfile index c615316..bb0e6f2 100644 --- a/Dockerfile +++ b/Dockerfile @@ -10,4 +10,4 @@ COPY app/ app/ WORKDIR /src/app -CMD ["python", "manage.py", "runserver", "0.0.0.0:8000"] +CMD ["gunicorn", "moneropro.wsgi:application", "--bind", "0.0.0.0:8000"] diff --git a/app/moneropro/urls.py b/app/moneropro/urls.py index 120b17f..9e1f103 100644 --- a/app/moneropro/urls.py +++ b/app/moneropro/urls.py @@ -15,9 +15,13 @@ Including another URLconf """ from django.contrib import admin -from django.urls import path, include +from django.urls import path, include, re_path + +from django.conf import settings +from django.views.static import serve urlpatterns = [ path("admin/", admin.site.urls), - path(r"", include(("charts.urls", "charts"), namespace="charts")), + path("", include(("charts.urls", "charts"), namespace="charts")), + re_path(r"^static/(?P.*)$", serve, {"document_root": settings.STATIC_ROOT}), ]