Skip to content

Commit

Permalink
Trivy - fix docker file
Browse files Browse the repository at this point in the history
  • Loading branch information
lwih committed Dec 29, 2023
1 parent c0e4c23 commit 1a71736
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions infra/docker/app/DockerfileCI
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@ RUN mvn dependency:go-offline -B
# Stage 2: Build the application
FROM maven:3.8.5-openjdk-17-slim as build-backend

ARG GITHUB_SHA
ARG VERSION
ARG GITHUB_SHA=NO_COMMIT
ARG VERSION=NO_VERSION

WORKDIR /tmp/backend
COPY backend/ /tmp/backend
Expand Down Expand Up @@ -74,7 +74,7 @@ ENV ENV_DB_URL=""
COPY --from=build-backend /tmp/backend/target/rapportnav-${VERSION}.jar /home/rapportnav
COPY infra/configurations/backend /home/rapportnav/configurations/


# copy frontend related things
RUN mkdir /home/rapportnav/public
# COPY --from=buildSourcemaps /tmp/frontend/build /home/rapportnav/public/
COPY --from=build-frontend /tmp/frontend/dist /home/rapportnav/public/
Expand All @@ -87,6 +87,5 @@ RUN mkdir /home/rapportnav/logs
# It must point to the front (React) files
ENV STATIC_FILES_PATH=/home/rapportnav/public


# CMD exec java -jar "/home/rapportnav/rapportnav-${VERSION}.jar"
CMD exec java -Dspring.config.additional-location="/home/rapportnav/configurations/" -Dspring.profiles.active=$ENV_PROFILE -jar "/home/rapportnav/rapportnav-${VERSION}.jar"

0 comments on commit 1a71736

Please sign in to comment.