mirror of
https://github.com/tiennm99/coolify.git
synced 2026-09-20 04:23:16 +00:00
fix(healthcheck): allow more time for Coolify startup (#11299)
This commit is contained in:
1 parent
81ed9a3af2
commit
bb9f5e5768
3 files changed
+19
-2
No files matched your search
@@ -27,7 +27,8 @@ services:
|
|||||||
healthcheck:
|
healthcheck:
|
||||||
test: curl --fail http://127.0.0.1:8080/api/health || exit 1
|
test: curl --fail http://127.0.0.1:8080/api/health || exit 1
|
||||||
interval: 5s
|
interval: 5s
|
||||||
retries: 10
|
retries: 24
|
||||||
|
start_period: 1m
|
||||||
timeout: 2s
|
timeout: 2s
|
||||||
depends_on:
|
depends_on:
|
||||||
postgres:
|
postgres:
|
||||||
|
|||||||
@@ -27,7 +27,8 @@ services:
|
|||||||
healthcheck:
|
healthcheck:
|
||||||
test: curl --fail http://127.0.0.1:8080/api/health || exit 1
|
test: curl --fail http://127.0.0.1:8080/api/health || exit 1
|
||||||
interval: 5s
|
interval: 5s
|
||||||
retries: 10
|
retries: 24
|
||||||
|
start_period: 1m
|
||||||
timeout: 2s
|
timeout: 2s
|
||||||
depends_on:
|
depends_on:
|
||||||
postgres:
|
postgres:
|
||||||
|
|||||||
@@ -0,0 +1,15 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
use Symfony\Component\Yaml\Yaml;
|
||||||
|
|
||||||
|
it('allows Coolify enough time to start before counting healthcheck failures', function (string $composeFile) {
|
||||||
|
$compose = Yaml::parseFile(dirname(__DIR__, 2).'/'.$composeFile);
|
||||||
|
|
||||||
|
expect($compose['services']['coolify']['healthcheck'])
|
||||||
|
->start_period->toBe('1m')
|
||||||
|
->interval->toBe('5s')
|
||||||
|
->retries->toBe(24);
|
||||||
|
})->with([
|
||||||
|
'stable' => 'docker-compose.prod.yml',
|
||||||
|
'nightly' => 'other/nightly/docker-compose.prod.yml',
|
||||||
|
]);
|
||||||
Reference in new issue
Block a user