Skip to content

Commit

Permalink
fix: Frontend Dockerfile for volume issue in development env
Browse files Browse the repository at this point in the history
  • Loading branch information
nrjadkry committed Jun 28, 2024
1 parent 722b86d commit b9c47bb
Showing 1 changed file with 4 additions and 8 deletions.
12 changes: 4 additions & 8 deletions src/frontend/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -8,17 +8,14 @@ RUN mkdir -p /app
WORKDIR /app
COPY ./src/frontend /app

# Install node packages
FROM base as package_installation
RUN yarn

# Run development environment
FROM package_installation as development
FROM base as development
RUN env | tee .env
ENTRYPOINT [ "yarn", "start", "--host", "0.0.0.0" ]
ENTRYPOINT ["/bin/sh", "-c" , "yarn && yarn start --host 0.0.0.0"]

# Generate frontend build files
FROM package_installation as build
FROM base as build
RUN yarn
RUN yarn build

# Copy static files to minio and generated index.html to backend services
Expand All @@ -28,4 +25,3 @@ RUN apk update && apk add minio-client envsubst
COPY --from=build /app/dist /tmp/dist
COPY ./src/frontend/docker-entrypoint.sh /docker-entrypoint.sh
ENTRYPOINT [ "/docker-entrypoint.sh" ]

0 comments on commit b9c47bb

Please sign in to comment.