From 7a8ddc2d094aca8ea32b4d6edf65dfa276a251dd Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Valenta?= <git@imaniti.org>
Date: Wed, 4 Jan 2023 23:13:47 +0100
Subject: [PATCH] placeholder values for collectstatic

---
 Dockerfile | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/Dockerfile b/Dockerfile
index 4136651..177b8c0 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -11,7 +11,12 @@ COPY . .
 RUN pip install -r requirements/base.txt -r requirements/prod.txt
 RUN npm install
 RUN npm run build
-RUN python manage.py collectstatic --noinput --settings=rybicka.settings.prod
+
+# Placeholder values so the static files collect
+RUN DATABASE_URL=postgres://x/x \
+    SECRET_KEY=x \
+    ALLOWED_HOSTS=x \
+    python manage.py collectstatic --noinput --settings=rybicka.settings.prod
 
 RUN bash -c "adduser --disabled-login --quiet --gecos app app &&  \
              chmod -R o+r /app/ && \
-- 
GitLab