File tree Expand file tree Collapse file tree 2 files changed +8
-12
lines changed
Expand file tree Collapse file tree 2 files changed +8
-12
lines changed Original file line number Diff line number Diff line change @@ -35,23 +35,20 @@ WORKDIR /usr/src
3535
3636COPY --from=source /usr/src /usr/src
3737
38- COPY --from=frontend /usr/src/web/dist /usr/src/web/dist
38+ COPY --from=frontend /usr/src/boot/src/main/resources /usr/src/boot/src/main/resources
3939
40- RUN set -ex && \
41- cd web && bash copy-build.sh && \
42- cd .. && ./gradlew -Pversion=${VERSION} :boot:bootjar -x test --no-daemon
40+ RUN ./gradlew -Pversion=${VERSION} :boot:bootjar -x test
4341
4442FROM eclipse-temurin:17.0.14_7-jre-noble
4543
4644LABEL authors=
"ReaJason<[email protected] >" 4745
4846WORKDIR /app
4947
50- COPY --from=backend /usr/src/boot/build/libs/*.jar app.jar
51-
5248RUN groupadd -r spring && \
53- useradd -r -g spring spring && \
54- chown spring:spring /app/app.jar
49+ useradd -r -g spring spring
50+
51+ COPY --from=backend --chown=spring:spring /usr/src/boot/build/libs/*.jar app.jar
5552
5653USER spring:spring
5754
Original file line number Diff line number Diff line change 44
55WORKDIR /app
66
7- COPY build/libs/*.jar app.jar
8-
97RUN groupadd -r spring && \
10- useradd -r -g spring spring && \
11- chown spring:spring /app/app.jar
8+ useradd -r -g spring spring
9+
10+ COPY --chown=spring:spring build/libs/*.jar app.jar
1211
1312USER spring:spring
1413
You can’t perform that action at this time.
0 commit comments