Compare commits
2 commits
main
...
onlyoffice
Author | SHA1 | Date | |
---|---|---|---|
eef20d52d5 | |||
2971d1bbc0 |
4 changed files with 54 additions and 3 deletions
|
@ -46,6 +46,7 @@
|
||||||
pkgs = import ./pkgs {
|
pkgs = import ./pkgs {
|
||||||
sources = inputs;
|
sources = inputs;
|
||||||
system = "x86_64-linux";
|
system = "x86_64-linux";
|
||||||
|
config.allowUnfree = true;
|
||||||
};
|
};
|
||||||
evalConfig = config: (nixpkgs.lib.nixosSystem {
|
evalConfig = config: (nixpkgs.lib.nixosSystem {
|
||||||
system = "x86_64-linux";
|
system = "x86_64-linux";
|
||||||
|
@ -54,7 +55,6 @@
|
||||||
nix-hexchen.nixosModules.network.nftables
|
nix-hexchen.nixosModules.network.nftables
|
||||||
{
|
{
|
||||||
nixpkgs.pkgs = pkgs.lib.mkForce pkgs;
|
nixpkgs.pkgs = pkgs.lib.mkForce pkgs;
|
||||||
nixpkgs.config.allowUnfree = true;
|
|
||||||
imports = [ profiles.container profiles.nopersist ];
|
imports = [ profiles.container profiles.nopersist ];
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
|
|
|
@ -20,6 +20,7 @@
|
||||||
../../services/nginx-pages.nix
|
../../services/nginx-pages.nix
|
||||||
../../services/vaultwarden.nix
|
../../services/vaultwarden.nix
|
||||||
../../services/tracktrain.nix
|
../../services/tracktrain.nix
|
||||||
|
../../services/onlyoffice.nix
|
||||||
../../services/uffd.nix
|
../../services/uffd.nix
|
||||||
|
|
||||||
./lxc.nix
|
./lxc.nix
|
||||||
|
|
|
@ -19,8 +19,6 @@
|
||||||
|
|
||||||
hexchen.bindmounts."/var/lib/gitea" = "/persist/gitea";
|
hexchen.bindmounts."/var/lib/gitea" = "/persist/gitea";
|
||||||
|
|
||||||
nixpkgs.config.allowUnfree = true;
|
|
||||||
|
|
||||||
services.gitea = {
|
services.gitea = {
|
||||||
enable = true;
|
enable = true;
|
||||||
appName = "0x0: git for all creatures";
|
appName = "0x0: git for all creatures";
|
||||||
|
|
52
services/onlyoffice.nix
Normal file
52
services/onlyoffice.nix
Normal file
|
@ -0,0 +1,52 @@
|
||||||
|
{ config, lib, pkgs, evalConfig, ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
containers.onlyoffice = {
|
||||||
|
privateNetwork = true;
|
||||||
|
hostAddress = "192.168.142.1";
|
||||||
|
localAddress = "192.168.142.10";
|
||||||
|
autoStart = true;
|
||||||
|
bindMounts = {
|
||||||
|
"/persist" = {
|
||||||
|
hostPath = "/persist/containers/onlyoffice";
|
||||||
|
isReadOnly = false;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
extraFlags = [ "--system-call-filter=proc_create_mount_point" ];
|
||||||
|
path = evalConfig ({ config, lib, pkgs, ... }: {
|
||||||
|
system.stateVersion = "21.11";
|
||||||
|
|
||||||
|
services.postgresql = {
|
||||||
|
enable = true;
|
||||||
|
|
||||||
|
ensureDatabases = [ "onlyoffice" ];
|
||||||
|
ensureUsers = [ {
|
||||||
|
name = "onlyoffice";
|
||||||
|
ensurePermissions = {
|
||||||
|
"DATABASE onlyoffice" = "ALL PRIVILEGES";
|
||||||
|
};
|
||||||
|
} ];
|
||||||
|
authentication = ''
|
||||||
|
local all all trust
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
|
services.rabbitmq = {
|
||||||
|
enable = true;
|
||||||
|
dataDir = "/persist/rabbitmq";
|
||||||
|
};
|
||||||
|
|
||||||
|
services.onlyoffice = {
|
||||||
|
enable = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
networking.firewall.allowedTCPPorts = [ 8000 ];
|
||||||
|
});
|
||||||
|
};
|
||||||
|
|
||||||
|
services.nginx.virtualHosts."onlyoffice-staging.infra4future.de" = {
|
||||||
|
enableACME = true;
|
||||||
|
forceSSL = true;
|
||||||
|
locations."/".proxyPass = "http://${config.containers.onlyoffice.localAddress}:8000";
|
||||||
|
};
|
||||||
|
}
|
Loading…
Reference in a new issue