DockerActionManager: fix bug with collabora using seccomp if it is globally disabled

Signed-off-by: Simon L. <szaimen@e.mail.de>
This commit is contained in:
Simon L. 2025-11-24 10:08:12 +01:00
parent 595b5db9fb
commit 0fe8008777
2 changed files with 14 additions and 5 deletions

View file

@ -415,9 +415,11 @@ readonly class DockerActionManager {
// Special things for the collabora container which should not be exposed in the containers.json
} elseif ($container->GetIdentifier() === 'nextcloud-aio-collabora') {
// Load reference seccomp profile for collabora
$seccompProfile = (string)file_get_contents(DataConst::GetCollaboraSeccompProfilePath());
$requestBody['HostConfig']['SecurityOpt'] = ["label:disable", "seccomp=$seccompProfile"];
if (!$this->configurationManager->isSeccompDisabled()) {
// Load reference seccomp profile for collabora
$seccompProfile = (string)file_get_contents(DataConst::GetCollaboraSeccompProfilePath());
$requestBody['HostConfig']['SecurityOpt'] = ["label:disable", "seccomp=$seccompProfile"];
}
// Additional Collabora options
if ($this->configurationManager->GetAdditionalCollaboraOptions() !== '') {