Skip to content

Commit ec52bc4

Browse files
committed
add healthcheck to dockerfiles
1 parent 316bbfd commit ec52bc4

3 files changed

Lines changed: 10 additions & 0 deletions

File tree

Changelog.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
# Changelog
22

3+
## next
4+
* Added healthcheck to Dockerfiles
5+
36
## 4.2.2.
47
* Removed the `client_credentials` grant_type option when the OAuth2 protocol is selected. Both in the GUI as on the Server.
58

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
11
FROM ghcr.io/openconext/openconext-basecontainers/apache2:latest
22
COPY ./build/ /var/www/html
33
COPY ./docker/conf/000-default.conf /etc/apache2/sites-enabled/000-default.conf
4+
5+
HEALTHCHECK --interval=10s --timeout=10s --start-period=10s --retries=3 \
6+
CMD ["curl", "--fail", "http://localhost/internal/health"]
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
11
FROM eclipse-temurin:21-jdk-alpine
22
COPY target/*.jar app.jar
3+
4+
HEALTHCHECK --interval=10s --timeout=10s --start-period=10s --retries=3 \
5+
CMD ["wget", "--no-verbose", "--tries=1", "--spider", "http://localhost:8080/internal/health"]
6+
37
ENTRYPOINT ["java","-jar","/app.jar"]

0 commit comments

Comments
 (0)