Skip to content

Commit

Permalink
update dockerfile
Browse files Browse the repository at this point in the history
  • Loading branch information
taulant.disha authored and taulant.disha committed May 20, 2024
1 parent 57735d6 commit 8ba85c3
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,20 @@ ENV PATH /app/node_modules/.bin:$PATH
ENV GENERATE_SOURCEMAP=false
ENV NODE_OPTIONS=--openssl-legacy-provider

COPY .npmrc ./
ARG ENV_FILE
ENV ENV_FILE=${ENV_FILE}

# COPY .npmrc ./
COPY package.json ./
COPY package-lock.json ./
RUN npm install --legacy-peer-dep

RUN npm install --legacy-peer-deps

COPY . ./
COPY ${ENV_FILE} .env

RUN npm run build

# production environment
FROM nginx:stable-alpine
COPY --from=build /app/build /usr/share/nginx/html
COPY nginx/nginx.conf /etc/nginx/conf.d/default.conf
Expand Down

0 comments on commit 8ba85c3

Please sign in to comment.