Fix server readiness check in ContainerStatusJob and ServerStatusJob

This commit is contained in:
Andras Bacsai
2023-11-17 14:46:04 +01:00
parent 60171093c5
commit 467471f54a
3 changed files with 13 additions and 6 deletions

View File

@@ -39,7 +39,9 @@ class ContainerStatusJob implements ShouldQueue, ShouldBeEncrypted
{
ray("checking container statuses for {$this->server->id}");
try {
$this->server->checkServerRediness();
if (!$this->server->isServerReady()) {
throw new \Exception('Server is not ready.');
};
$containers = instant_remote_process(["docker container ls -q"], $this->server);
if (!$containers) {
return;