Spaces:
Runtime error
Runtime error
Update Dockerfile
Browse files- Dockerfile +5 -3
Dockerfile
CHANGED
@@ -2,15 +2,17 @@
|
|
2 |
FROM node:14-bullseye-slim as build-step
|
3 |
WORKDIR /app
|
4 |
ENV PATH /app/node_modules/.bin:$PATH
|
5 |
-
|
6 |
-
# Copy package.json and package-lock.json first to leverage Docker cache
|
7 |
COPY ./frontend/package.json ./frontend/package-lock.json ./frontend/
|
8 |
WORKDIR /app/frontend
|
9 |
RUN npm install -g [email protected]
|
|
|
|
|
10 |
RUN npm install
|
11 |
|
12 |
-
|
13 |
COPY ./frontend ./frontend
|
|
|
14 |
WORKDIR /app/frontend
|
15 |
RUN npm run build
|
16 |
|
|
|
2 |
FROM node:14-bullseye-slim as build-step
|
3 |
WORKDIR /app
|
4 |
ENV PATH /app/node_modules/.bin:$PATH
|
5 |
+
RUN mkdir ./frontend
|
|
|
6 |
COPY ./frontend/package.json ./frontend/package-lock.json ./frontend/
|
7 |
WORKDIR /app/frontend
|
8 |
RUN npm install -g [email protected]
|
9 |
+
# It's OK to have multiple consecutive `RUN` instructions.
|
10 |
+
# hadolint ignore=DL3059
|
11 |
RUN npm install
|
12 |
|
13 |
+
WORKDIR /app
|
14 |
COPY ./frontend ./frontend
|
15 |
+
|
16 |
WORKDIR /app/frontend
|
17 |
RUN npm run build
|
18 |
|