An open-source, self-hostable PaaS alternative to Vercel, Heroku & Netlify that lets you easily deploy static sites, databases, full-stack applications and 360+ one-click services on your own servers.
PHP coolifydatabasesdeploymentdockerdocker-composeinertiajslaravelmariadbmysqlnextjsnodejsphppostgresredisself-hostedself-hostingserverstatic-sitesveltesvelte5
Refactor container status and log drain checks scheduling
Andras Bacsai6826b6e1f81d
diff --git a/app/Console/Kernel.php b/app/Console/Kernel.phpindex dfbcf78703..30276f729b 100644--- a/app/Console/Kernel.php+++ b/app/Console/Kernel.php@@ -78,22 +78,28 @@ class Kernel extends ConsoleKernel}foreach ($containerServers as $server) {$schedule->job(new ContainerStatusJob($server))->everyTwoMinutes()->onOneServer()->before(function () {- $wait = rand(5, 20);- ray('waiting for ' . $wait . ' seconds');- Sleep::for($wait)->seconds();- ray('waited for ' . $wait . ' seconds');+ if (isCloud()) {+ $wait = rand(5, 20);+ ray('waiting for ' . $wait . ' seconds');+ Sleep::for($wait)->seconds();+ ray('waited for ' . $wait . ' seconds');+ }});if ($server->isLogDrainEnabled()) {$schedule->job(new CheckLogDrainContainerJob($server))->everyTwoMinutes()->onOneServer()->before(function () {- $wait = rand(5, 20);- Sleep::for($wait)->seconds();+ if (isCloud()) {+ $wait = rand(5, 20);+ Sleep::for($wait)->seconds();+ }});}}foreach ($servers as $server) {$schedule->job(new ServerStatusJob($server))->everyTwoMinutes()->onOneServer()->before(function () {- $wait = rand(5, 20);- Sleep::for($wait)->seconds();+ if (isCloud()) {+ $wait = rand(5, 20);+ Sleep::for($wait)->seconds();+ }});}}