synapse-admin/Dockerfile
Leon Schmidt 7aa0f9f50d
Make PUBLIC_URL and REACT_APP_SERVER configurable (#266)
* Adjust Dockerfile to include args in build process
* Adjust README.md
2022-05-23 14:06:04 +02:00

21 lines
352 B
Docker

# Builder
FROM node:lts as builder
ARG PUBLIC_URL=/
ARG REACT_APP_SERVER
WORKDIR /src
COPY . /src
RUN yarn --network-timeout=100000 install
RUN PUBLIC_URL=$PUBLIC_URL REACT_APP_SERVER=$REACT_APP_SERVER yarn build
# App
FROM nginx:alpine
COPY --from=builder /src/build /app
RUN rm -rf /usr/share/nginx/html \
&& ln -s /app /usr/share/nginx/html