Merge pull request #4326 from nextcloud/enh/4267/caddy-host-network

caddy community container - allow to access host.docker.internal
This commit is contained in:
Simon L 2024-03-04 12:43:05 +01:00 committed by GitHub
commit cc6486ae2f
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -566,6 +566,9 @@ class DockerActionManager
}
$mounts[] = ["Type" => "bind", "Source" => $volume->name, "Target" => $volume->mountPoint, "ReadOnly" => !$volume->isWritable, "BindOptions" => [ "Propagation" => "rshared"]];
}
// Special things for the caddy community container
} elseif ($container->GetIdentifier() === 'nextcloud-aio-caddy') {
$requestBody['HostConfig']['ExtraHosts'] = ['host.docker.internal:host-gateway'];
}
if (count($mounts) > 0) {