From f9c3b4ca12d4cf2227c4131945784daafad579f8 Mon Sep 17 00:00:00 2001 From: Henit Chobisa Date: Sat, 2 Sep 2023 07:57:00 +0000 Subject: [PATCH] chore: Updated dockerfiles for web and space --- apps/app/Dockerfile.web | 6 +++++- apps/space/Dockerfile.space | 1 + 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/apps/app/Dockerfile.web b/apps/app/Dockerfile.web index 2b28e1fd1..cb3cbff2f 100644 --- a/apps/app/Dockerfile.web +++ b/apps/app/Dockerfile.web @@ -15,6 +15,7 @@ FROM node:18-alpine AS installer RUN apk add --no-cache libc6-compat WORKDIR /app ARG NEXT_PUBLIC_API_BASE_URL=http://localhost:8000 +ARG NEXT_PUBLIC_DEPLOY_URL=http://localhost/spaces # First install the dependencies (as they change less often) COPY .gitignore .gitignore @@ -54,8 +55,11 @@ COPY --from=installer --chown=captain:plane /app/apps/app/.next/standalone ./ COPY --from=installer --chown=captain:plane /app/apps/app/.next ./apps/app/.next ARG NEXT_PUBLIC_API_BASE_URL=http://localhost:8000 +ARG NEXT_PUBLIC_DEPLOY_URL=http://localhost/spaces + ENV NEXT_PUBLIC_API_BASE_URL=$NEXT_PUBLIC_API_BASE_URL \ - BUILT_NEXT_PUBLIC_API_BASE_URL=$NEXT_PUBLIC_API_BASE_URL + BUILT_NEXT_PUBLIC_API_BASE_URL=$NEXT_PUBLIC_API_BASE_URL \ + NEXT_PUBLIC_DEPLOY_URL=$NEXT_PUBLIC_DEPLOY_URL USER root COPY replace-env-vars.sh /usr/local/bin/ diff --git a/apps/space/Dockerfile.space b/apps/space/Dockerfile.space index 0240ddbf7..4d9a2fd8e 100644 --- a/apps/space/Dockerfile.space +++ b/apps/space/Dockerfile.space @@ -52,6 +52,7 @@ COPY --from=installer /app/apps/space/package.json . COPY --from=installer --chown=captain:plane /app/apps/space/.next/standalone ./ COPY --from=installer --chown=captain:plane /app/apps/space/.next ./apps/space/.next +COPY --from=installer --chown=captain:plane /app/apps/space/public ./apps/space/public ARG NEXT_PUBLIC_API_BASE_URL=http://localhost:8000 ENV NEXT_PUBLIC_API_BASE_URL=$NEXT_PUBLIC_API_BASE_URL \