Skip to content

Commit d002206

Browse files
committed
Make getting started guide faster
Signed-off-by: Stefan Scherer <[email protected]>
1 parent e04817f commit d002206

File tree

1 file changed

+9
-5
lines changed

1 file changed

+9
-5
lines changed

Dockerfile

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,20 +5,24 @@ WORKDIR /app
55
COPY requirements.txt .
66
RUN pip install -r requirements.txt
77

8-
# Run tests to validate app
98
FROM node:12-alpine AS app-base
10-
RUN apk add --no-cache python g++ make
119
WORKDIR /app
1210
COPY app/package.json app/yarn.lock ./
13-
RUN yarn install
1411
COPY app/spec ./spec
1512
COPY app/src ./src
13+
14+
# Run tests to validate app
15+
FROM app-base AS test
16+
RUN apk add --no-cache python3 g++ make
17+
RUN yarn install
1618
RUN yarn test
1719

1820
# Clear out the node_modules and create the zip
1921
FROM app-base AS app-zip-creator
20-
RUN rm -rf node_modules && \
21-
apk add zip && \
22+
COPY app/package.json app/yarn.lock ./
23+
COPY app/spec ./spec
24+
COPY app/src ./src
25+
RUN apk add zip && \
2226
zip -r /app.zip /app
2327

2428
# Dev-ready container - actual files will be mounted in

0 commit comments

Comments
 (0)