Office : Fix.
This commit is contained in:
parent
36edcf45b7
commit
f856f61991
|
@ -1,7 +1,22 @@
|
|||
# NOTE: Imperative part:
|
||||
# 1. You need to change PSQL tables owner from root to onlyoffice, too. They don't do that automatically for some reason.
|
||||
# 2. TODO: Generate JWT secret at /var/lib/onlyoffice/jwt, i.e. 9wLfMGha1YrfvWpb5hyYjZf8pvJQ3swS
|
||||
# See https://git.voronind.com/voronind/nixos/issues/74
|
||||
{ container, pkgs, util, ... } @args: let
|
||||
cfg = container.config.office;
|
||||
in {
|
||||
systemd.tmpfiles.rules = container.mkContainerDir cfg [
|
||||
"data"
|
||||
];
|
||||
|
||||
containers.office = container.mkContainer cfg {
|
||||
bindMounts = {
|
||||
"/var/lib/onlyoffice" = {
|
||||
hostPath = "${cfg.storage}/data";
|
||||
isReadOnly = false;
|
||||
};
|
||||
};
|
||||
|
||||
config = { ... }: container.mkContainerConfig cfg {
|
||||
services.onlyoffice = let
|
||||
dbName = "onlyoffice";
|
||||
|
@ -14,6 +29,8 @@ in {
|
|||
postgresUser = dbName;
|
||||
postgresPasswordFile = "${pkgs.writeText "OfficeDbPassword" dbName}";
|
||||
|
||||
jwtSecretFile = "/var/lib/onlyoffice/jwt";
|
||||
|
||||
examplePort = cfg.port;
|
||||
enableExampleServer = true;
|
||||
};
|
||||
|
|
|
@ -114,6 +114,7 @@
|
|||
address = "10.1.0.21";
|
||||
domain = "office.${domain}";
|
||||
port = 8000;
|
||||
storage = "${storage}/office";
|
||||
};
|
||||
paper = {
|
||||
inherit (media) paper;
|
||||
|
|
|
@ -46,7 +46,7 @@ in {
|
|||
(import ../../container/Iot.nix args)
|
||||
(import ../../container/Jobber.nix args)
|
||||
(import ../../container/Mail.nix args)
|
||||
# (import ../../container/Office.nix args)
|
||||
(import ../../container/Office.nix args)
|
||||
(import ../../container/Paper.nix args)
|
||||
(import ../../container/Pass.nix args)
|
||||
(import ../../container/Paste.nix args)
|
||||
|
|
Loading…
Reference in a new issue