mirror of
https://github.com/nextcloud/all-in-one.git
synced 2025-12-19 22:16:49 +00:00
add whiteboard container
Signed-off-by: Simon L. <szaimen@e.mail.de>
This commit is contained in:
parent
9a4f132998
commit
546f11a654
14 changed files with 151 additions and 4 deletions
|
|
@ -95,6 +95,10 @@ class ContainerDefinitionFetcher
|
|||
if (!$this->configurationManager->isDockerSocketProxyEnabled()) {
|
||||
continue;
|
||||
}
|
||||
} elseif ($entry['container_name'] === 'nextcloud-aio-whiteboard') {
|
||||
if (!$this->configurationManager->isWhiteboardEnabled()) {
|
||||
continue;
|
||||
}
|
||||
}
|
||||
|
||||
$ports = new ContainerPorts();
|
||||
|
|
@ -200,6 +204,10 @@ class ContainerDefinitionFetcher
|
|||
if (!$this->configurationManager->isDockerSocketProxyEnabled()) {
|
||||
continue;
|
||||
}
|
||||
} elseif ($value === 'nextcloud-aio-whiteboard') {
|
||||
if (!$this->configurationManager->isWhiteboardEnabled()) {
|
||||
continue;
|
||||
}
|
||||
}
|
||||
$dependsOn[] = $value;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -120,6 +120,11 @@ class ConfigurationController
|
|||
} else {
|
||||
$this->configurationManager->SetDockerSocketProxyEnabledState(0);
|
||||
}
|
||||
if (isset($request->getParsedBody()['whiteboard'])) {
|
||||
$this->configurationManager->SetWhiteboardEnabledState(1);
|
||||
} else {
|
||||
$this->configurationManager->SetWhiteboardEnabledState(0);
|
||||
}
|
||||
}
|
||||
|
||||
if (isset($request->getParsedBody()['delete_collabora_dictionaries'])) {
|
||||
|
|
|
|||
|
|
@ -164,6 +164,21 @@ class ConfigurationManager
|
|||
$this->WriteConfig($config);
|
||||
}
|
||||
|
||||
public function isWhiteboardEnabled() : bool {
|
||||
$config = $this->GetConfig();
|
||||
if (isset($config['isWhiteboardEnabled']) && $config['isWhiteboardEnabled'] === 1) {
|
||||
return true;
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
public function SetWhiteboardEnabledState(int $value) : void {
|
||||
$config = $this->GetConfig();
|
||||
$config['isWhiteboardEnabled'] = $value;
|
||||
$this->WriteConfig($config);
|
||||
}
|
||||
|
||||
public function SetClamavEnabledState(int $value) : void {
|
||||
$config = $this->GetConfig();
|
||||
$config['isClamavEnabled'] = $value;
|
||||
|
|
|
|||
|
|
@ -417,6 +417,12 @@ class DockerActionManager
|
|||
if (in_array('caddy', $communityContainers, true)) {
|
||||
$replacements[1] = gethostbyname('nextcloud-aio-caddy');
|
||||
}
|
||||
} elseif ($out[1] === 'WHITEBOARD_ENABLED') {
|
||||
if ($this->configurationManager->isWhiteboardEnabled()) {
|
||||
$replacements[1] = 'yes';
|
||||
} else {
|
||||
$replacements[1] = '';
|
||||
}
|
||||
} else {
|
||||
$secret = $this->configurationManager->GetSecret($out[1]);
|
||||
if ($secret === "") {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue