From 92736be58fb16426d5a3f5363ae73d34dc82f84a Mon Sep 17 00:00:00 2001 From: theoleuthardt Date: Tue, 4 Mar 2025 15:35:57 +0100 Subject: [PATCH] fix: use root user for creating tmp directory in backend docker container --- backend/Dockerfile | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/backend/Dockerfile b/backend/Dockerfile index fa2258d..c60b62e 100644 --- a/backend/Dockerfile +++ b/backend/Dockerfile @@ -58,10 +58,11 @@ COPY --from=builder --chown=fastify:nodejs /app/dist ./dist COPY --from=deps --chown=fastify:nodejs /app/node_modules ./node_modules COPY --from=builder --chown=fastify:nodejs /app/package.json ./package.json -USER fastify - +USER root RUN mkdir -p /app/tmp && chown -R fastify:fastify /app/tmp +USER fastify + EXPOSE 4000 ARG CORS_ALLOWED_ORIGIN