Skip to content

Commit

Permalink
Remove HC from Dockerfile
Browse files Browse the repository at this point in the history
  • Loading branch information
alainbodiguel committed Mar 25, 2024
1 parent 037ddfe commit 0bcd329
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 9 deletions.
5 changes: 1 addition & 4 deletions docker/docker-files/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -17,16 +17,13 @@ RUN mvn install \
###################
# PACKAGING STAGE #
###################
FROM gisaia/arlas-openjdk:17-distroless
FROM gisaia/arlas-openjdk-17-distroless:20240325094836

# application placed into /opt/app
WORKDIR /opt/app
COPY --from=build /opt/build/arlas-tagger.jar /opt/app/
COPY --from=build /opt/build/conf/configuration.yaml /opt/app/
EXPOSE 9998

HEALTHCHECK --interval=5m --timeout=3s \
CMD curl http://localhost:9998/admin/healthcheck | grep -v "\"healthy\":false" || exit 1

ENV JDK_JAVA_OPTIONS="-Xmx512m -XX:+ExitOnOutOfMemoryError"
CMD ["arlas-tagger.jar", "server", "/opt/app/configuration.yaml"]
5 changes: 1 addition & 4 deletions docker/docker-files/Dockerfile-package-only
Original file line number Diff line number Diff line change
@@ -1,16 +1,13 @@
###################
# PACKAGING STAGE #
###################
FROM gisaia/arlas-openjdk:17-distroless
FROM gisaia/arlas-openjdk-17-distroless:20240325094836

# application placed into /opt/app
WORKDIR /opt/app
ADD arlas-tagger/target/arlas-tagger*.jar /opt/app/arlas-tagger.jar
ADD conf/configuration.yaml /opt/app/configuration.yaml
EXPOSE 9998

HEALTHCHECK --interval=5m --timeout=3s \
CMD curl http://localhost:9998/admin/healthcheck | grep -v "\"healthy\":false" || exit 1

ENV JDK_JAVA_OPTIONS="-Xmx512m -XX:+ExitOnOutOfMemoryError"
CMD ["arlas-tagger.jar", "server", "/opt/app/configuration.yaml"]
7 changes: 6 additions & 1 deletion docker/docker-files/docker-compose-arlas-server.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ version: '3'

services:
arlas-server:
image: gisaia/arlas-server:${ARLAS_VERSION:-24.0.1}
image: gisaia/arlas-server:${ARLAS_VERSION:-24.1.2}
container_name: arlas-server
environment:
- ARLAS_HOST="arlas-server"
Expand All @@ -16,4 +16,9 @@ services:
- ARLAS_SERVICE_EXPLORE_ENABLE="${ARLAS_SERVICE_EXPLORE_ENABLE:-true}"
ports:
- 19999:9999
healthcheck:
test: ["CMD","java","HttpHealthcheck.java","http://localhost:9999/admin/healthcheck"]
interval: 5s
timeout: 10s
retries: 3

5 changes: 5 additions & 0 deletions docker/docker-files/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,3 +48,8 @@ services:
- 19998:9998
volumes:
- ${ARLAS_AUTH_LOCAL_CERT_FILE:-/tmp}:${ARLAS_AUTH_CERT_FILE:-/opt/app/arlas.pem}:ro
healthcheck:
test: ["CMD","java","HttpHealthcheck.java","http://localhost:9998/admin/healthcheck"]
interval: 5s
timeout: 10s
retries: 3

0 comments on commit 0bcd329

Please sign in to comment.