add health check into docker container

Signed-off-by: Peter Siegmund <developer@mars3142.org>
This commit is contained in:
2024-10-15 09:54:58 +02:00
parent 4ddcabd6c9
commit 34dd6323ef

View File

@@ -25,5 +25,7 @@ USER app
COPY --chown=app --from=build /usr/src/app/build/libs/*-SNAPSHOT.jar /usr/app/eureka.jar
HEALTHCHECK CMD curl --fail http://localhost:8761/actuator/health/liveness || exit 1
EXPOSE 8761
CMD ["java", "-jar", "/usr/app/eureka.jar"]