-
Notifications
You must be signed in to change notification settings - Fork 22
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
2779820
commit afd2dfd
Showing
3 changed files
with
57 additions
and
1 deletion.
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 |
---|---|---|
@@ -0,0 +1,44 @@ | ||
|
||
#### | ||
## build container | ||
|
||
FROM alpine:3.16.0 as build | ||
|
||
WORKDIR /opt/conciliator | ||
|
||
RUN apk --no-cache add alpine-conf git maven openjdk8 | ||
|
||
COPY conciliator.iml . | ||
COPY conciliator.properties . | ||
COPY pom.xml . | ||
|
||
RUN mvn verify clean --fail-never | ||
|
||
COPY src src | ||
|
||
RUN mvn package | ||
|
||
#### | ||
## application container | ||
|
||
FROM alpine:3.16.0 | ||
|
||
EXPOSE 8080 8081 | ||
|
||
RUN apk --no-cache add alpine-conf openjdk8-jre | ||
|
||
RUN setup-timezone -z America/Los_Angeles | ||
|
||
COPY --from=build /opt/conciliator/target/conciliator*.jar . | ||
|
||
CMD JARFILE=`find . -type f -name "conciliator*.jar" -print` && \ | ||
/usr/bin/java \ | ||
-Dcom.sun.management.jmxremote \ | ||
-Dcom.sun.management.jmxremote.port=8081 \ | ||
-Dcom.sun.management.jmxremote.local.only=false \ | ||
-Dcom.sun.management.jmxremote.authenticate=false \ | ||
-Dcom.sun.management.jmxremote.ssl=false \ | ||
-XX:+HeapDumpOnOutOfMemoryError \ | ||
-Xms256m -Xmx256m \ | ||
-Dlogging.level.com.codefork.refine=DEBUG -jar \ | ||
$JARFILE |
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 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 |
---|---|---|
@@ -0,0 +1,3 @@ | ||
#!/bin/sh | ||
|
||
docker run -d --restart always -p 127.0.0.1:8080:8080 -p 127.0.0.1:8081:8081 -v "$(pwd)/conciliator.log:/opt/conciliator/conciliator.log" conciliator:latest |