-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
0d9f6bc
commit 16f1546
Showing
3 changed files
with
14 additions
and
56 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,23 @@ | ||
FROM amazoncorretto:11.0.17 | ||
LABEL version=5.8.0 description="EPAM Report portal. Complex migrations service" maintainer="Ivan Kustau <[email protected]>, Hleb Kanonik <[email protected]>" | ||
FROM gradle:6.3-jdk11 AS build | ||
ARG APP_VERSION | ||
WORKDIR /usr/app | ||
COPY . /usr/app | ||
RUN gradle build --exclude-task test -Dorg.gradle.project.version=${APP_VERSION}; | ||
|
||
# For ARM build use flag: `--platform linux/arm64` | ||
FROM --platform=$BUILDPLATFORM amazoncorretto:11.0.17 | ||
LABEL version=${APP_VERSION} description="EPAM Report portal. Complex migrations service" maintainer="Ivan Kustau <[email protected]>, Hleb Kanonik <[email protected]>" | ||
ARG APP_VERSION=${APP_VERSION} | ||
ENV APP_DIR=/usr/app JAVA_OPTS="-Xmx1g -XX:+UseG1GC -XX:InitiatingHeapOccupancyPercent=70 -Djava.security.egd=file:/dev/./urandom" | ||
|
||
# Install MinIO Client (mc) | ||
RUN yum install -y curl && \ | ||
curl https://dl.min.io/client/mc/release/linux-amd64/mc \ | ||
-o /usr/local/bin/mc && \ | ||
chmod +x /usr/local/bin/mc | ||
|
||
COPY ./complex-migrations-*-exec.jar complex-migrations-5.8.0-exec.jar | ||
RUN echo 'exec java ${JAVA_OPTS} -jar complex-migrations-5.8.0-exec.jar' > /start.sh && chmod +x /start.sh | ||
|
||
ENV JAVA_OPTS="-Xmx1g -XX:+UseG1GC -XX:InitiatingHeapOccupancyPercent=70 -Djava.security.egd=file:/dev/./urandom" | ||
WORKDIR $APP_DIR | ||
COPY --from=build $APP_DIR/build/libs/complex-migrations-*exec.jar . | ||
VOLUME ["/tmp"] | ||
EXPOSE 8080 | ||
|
||
ENTRYPOINT ./start.sh | ||
ENTRYPOINT exec java ${JAVA_OPTS} -jar ${APP_DIR}/complex-migrations-*exec.jar |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.