Skip to content

Commit

Permalink
#77 - Fix Docker CSRF limitation (#79)
Browse files Browse the repository at this point in the history
* fix: Adding ORIGIN env var (no luck yet)

* chore: npm audit

* Revert "fix: Adding ORIGIN env var (no luck yet)"

This reverts commit 9b9aa84.

* fix: adding ORIGIN to docker runtime

* fix: using correct api URL in compose
  • Loading branch information
djavorek authored Aug 21, 2023
1 parent 532a1c6 commit a81f927
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 13 deletions.
9 changes: 8 additions & 1 deletion client/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,8 +1,11 @@
ARG client_url=http://localhost:3000
ARG backend_url=http://veryrezsi_server:8000/api

# Stage BUILD
FROM node:18-alpine as builder

# Build-time variables
ARG backend_url=http://localhost:8000/api
ARG backend_url
ENV REZSI_API_BASE_URL=$backend_url

WORKDIR /app
Expand All @@ -14,6 +17,10 @@ RUN npm run build
# Stage RUN
FROM node:18-alpine

# Run-time variables
ARG client_url
ENV ORIGIN=$client_url

WORKDIR /app

COPY --from=builder /app/package*.json ./
Expand Down
24 changes: 12 additions & 12 deletions client/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit a81f927

Please sign in to comment.