feat: add collabora office

This commit is contained in:
Felix Schröter 2022-02-07 23:52:38 +01:00
parent d7c6a77451
commit 8f38f9d636
Signed by: felschr
GPG key ID: 671E39E6744C807D
2 changed files with 21 additions and 0 deletions

View file

@ -67,6 +67,7 @@ in with builtins; {
domains = [
"home.felschr.com"
"cloud.felschr.com"
"office.felschr.com"
"media.felschr.com"
"news.felschr.com"
"mqtt.felschr.com"

View file

@ -31,6 +31,26 @@ in {
}];
};
# Office
# TODO move to own config
virtualisation.oci-containers.containers.collabora-office = {
image = "collabora/code";
ports = [ "9980:9980" ];
environment = {
domain = builtins.replaceStrings [ "." ] [ "\\." ] "office.felschr.com";
extra_params = "--o:ssl.enable=false --o:ssl.termination=true";
};
extraOptions = [ "--network=host" ];
};
services.nginx.virtualHosts."office.felschr.com" = {
forceSSL = true;
enableACME = true;
locations."/" = {
proxyPass = "http://localhost:9980";
proxyWebsockets = true;
};
};
# ensure that postgres is running *before* running the setup
systemd.services."nextcloud-setup" = {
requires = [ "postgresql.service" ];