mirror of
https://github.com/nextcloud/all-in-one.git
synced 2025-12-19 22:16:49 +00:00
harden pulling images from docker hub issues
Signed-off-by: Simon L <szaimen@e.mail.de>
This commit is contained in:
parent
f0210e8594
commit
93dd64f5ee
2 changed files with 24 additions and 0 deletions
|
|
@ -48,6 +48,15 @@ class DockerController
|
|||
}
|
||||
}
|
||||
|
||||
// Check if docker hub is reachable in order to make sure that we do not try to pull an image if it is down
|
||||
// and try to mitigate issues that are arising due to that
|
||||
if ($pullImage) {
|
||||
if (!$this->dockerActionManager->isDockerHubReachable($container)) {
|
||||
$pullImage = false;
|
||||
error_log('Not pulling the image for the ' . $container->GetContainerName() . ' container because docker hub does not seem to be reachable.');
|
||||
}
|
||||
}
|
||||
|
||||
$this->dockerActionManager->DeleteContainer($container);
|
||||
$this->dockerActionManager->CreateVolumes($container);
|
||||
if ($pullImage) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue