Skip to content

Commit

Permalink
Fix docker multistage build
Browse files Browse the repository at this point in the history
  • Loading branch information
mklkj committed Oct 29, 2023
1 parent fb6ab6a commit 0c02cdb
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
FROM node:21
WORKDIR /home/gradle/src/app
FROM node:21 as fronted
COPY --chown=node:node . /home/node/src
WORKDIR /home/node/src/app
RUN npm install && npm run build

FROM gradle:7-jdk11 AS build
COPY --chown=gradle:gradle . /home/gradle/src
COPY --from=fronted --chown=gradle:gradle /home/node/src /home/gradle/src
WORKDIR /home/gradle/src
RUN gradle buildFatJar --no-daemon

Expand Down

0 comments on commit 0c02cdb

Please sign in to comment.