Skip to content

armgit / mwmbl

Public Imported from GitHub
0

An open source, non-profit web search engine

Fix static files location

Daoud Clarke03293384aa6c
diff --git a/mwmbl/settings_common.py b/mwmbl/settings_common.py
index b833f97..a71ac6d 100644
--- a/mwmbl/settings_common.py
+++ b/mwmbl/settings_common.py
@@ -104,7 +104,6 @@ USE_TZ = True
# https://docs.djangoproject.com/en/4.2/howto/static-files/
STATIC_URL = 'static/'
-STATICFILES_DIRS = [str(Path(__file__).parent.parent / "front-end" / "dist")]
# Default primary key field type
# https://docs.djangoproject.com/en/4.2/ref/settings/#default-auto-field
diff --git a/mwmbl/settings_dev.py b/mwmbl/settings_dev.py
index 44257d5..de11849 100644
--- a/mwmbl/settings_dev.py
+++ b/mwmbl/settings_dev.py
@@ -13,6 +13,9 @@ DATABASES = {
}
+STATICFILES_DIRS = [str(Path(__file__).parent.parent / "front-end" / "dist")]
+
+
DEBUG = True
ALLOWED_HOSTS = ["localhost", "127.0.0.1"]
diff --git a/mwmbl/settings_prod.py b/mwmbl/settings_prod.py
index b6adcc2..837dbb0 100644
--- a/mwmbl/settings_prod.py
+++ b/mwmbl/settings_prod.py
@@ -9,6 +9,7 @@ SECRET_KEY = os.environ["DJANGO_SECRET_KEY"]
STATIC_ROOT = "/app/static/"
+STATICFILES_DIRS = ["/front-end-build/"]
DATABASES = {'default': dj_database_url.config(default=os.environ["DATABASE_URL"])}