File tree Expand file tree Collapse file tree 2 files changed +16
-13
lines changed Expand file tree Collapse file tree 2 files changed +16
-13
lines changed Original file line number Diff line number Diff line change 1
- FROM nginx:1.23-alpine- slim
1
+ FROM --platform=linux/amd64 node:18- slim AS builder
2
2
3
- RUN apk add --update nodejs npm
3
+ WORKDIR /usr/src/app
4
4
5
- WORKDIR /usr/share/build
5
+ RUN mkdir -p ./src \
6
+ && mkdir -p ./scripts \
7
+ && mkdir -p ./staged-themes
6
8
7
- RUN mkdir -p /usr/share/build/src \
8
- && mkdir -p /usr/share/build/scripts
9
+ COPY src/ ./src/
10
+ COPY staged-themes/ ./staged-themes
11
+ COPY scripts/ ./scripts/
12
+ COPY *.json ./
9
13
10
- COPY src/ /usr/share/build/src/
11
-
12
- COPY scripts/ /usr/share/build/scripts/
13
-
14
- COPY *.json /usr/share/build/
14
+ RUN rm package-lock.json
15
15
16
+ RUN npm install -g @oracle/
[email protected]
16
17
RUN npm install
17
- RUN npm install -g @oracle/ojet-cli
18
- RUN ojet build web --release
18
+ RUN ojet build web --release
19
+
20
+ FROM --platform=linux/amd64 nginx:1.23-alpine-slim
19
21
20
- RUN cp -R /usr/share/build /web/* /usr/share/nginx/html/
22
+ COPY --from=builder /usr/src/app /web/* /usr/share/nginx/html/
21
23
22
24
EXPOSE 80
23
25
Original file line number Diff line number Diff line change 21
21
spec :
22
22
containers :
23
23
- image : app
24
+ imagePullPolicy : " Always"
24
25
name : app
25
26
readinessProbe :
26
27
httpGet :
You can’t perform that action at this time.
0 commit comments