diff --git a/doc/changelog.md b/doc/changelog.md index 40a966e68..4d0f97f04 100644 --- a/doc/changelog.md +++ b/doc/changelog.md @@ -1,5 +1,7 @@ # ChangeLog * **0.46-SNAPSHOT**: + - Docker-compose healthcheck configuration support ([1825](https://github.com/fabric8io/docker-maven-plugin/pull/1825)) + - Docker container wait timeout default value made configurable using startContainerWaitTimeout configuration option ([1825](https://github.com/fabric8io/docker-maven-plugin/pull/1825)) * **0.45.1 (2024-09-29)**: - Make copy docker-buildx binary to temporary config directory work on windows too ([1819](https://github.com/fabric8io/docker-maven-plugin/pull/1819)) diff --git a/it/docker-compose-dependon/docker-compose.yml b/it/docker-compose-dependon/docker-compose.yml index bc5dca9c7..9c847f853 100644 --- a/it/docker-compose-dependon/docker-compose.yml +++ b/it/docker-compose-dependon/docker-compose.yml @@ -10,6 +10,12 @@ services: build: context: . dockerfile: Postgres.Dockerfile + healthcheck: + test: pg_isready -U postgres + interval: 2s + timeout: 2s + retries: 10 + start_period: 1s environment: POSTGRES_PASSWORD: supersecret tmpfs: diff --git a/src/main/asciidoc/inc/external/_docker_compose.adoc b/src/main/asciidoc/inc/external/_docker_compose.adoc index 35707be13..abc613659 100644 --- a/src/main/asciidoc/inc/external/_docker_compose.adoc +++ b/src/main/asciidoc/inc/external/_docker_compose.adoc @@ -55,7 +55,7 @@ In addition to the `docker-compose.yml` you can add all known options for <> attached to dependent containers, while Docker Compose applies checks when starting the depending container. Keep in mind that execution of a container is continued as soon as any wait condition is fulfilled. \ No newline at end of file diff --git a/src/main/asciidoc/inc/start/_configuration.adoc b/src/main/asciidoc/inc/start/_configuration.adoc index 6966d7673..3feef06c0 100644 --- a/src/main/asciidoc/inc/start/_configuration.adoc +++ b/src/main/asciidoc/inc/start/_configuration.adoc @@ -19,6 +19,12 @@ In addition to the <>, this goal supports the following gl | Starts docker images in parallel while dependencies expressed as <> or <> are respected. This option can significantly reduce the startup time because independent containers do not need to wait for each other. | `docker.startParallel` +| *startContainerWaitTimeout* +| Overrides the default across all the containers wait timeout (