44 lines
1018 B
Nix
Executable File
44 lines
1018 B
Nix
Executable File
{
|
|
lib,
|
|
pkgs,
|
|
config,
|
|
...
|
|
}:
|
|
with lib;
|
|
let
|
|
cfg = config.nas-apps.collabora;
|
|
in
|
|
{
|
|
imports = [ ./options.nix ];
|
|
|
|
config = mkIf cfg.enable {
|
|
virtualisation.oci-containers.containers."${cfg.name}" = {
|
|
autoStart = cfg.autoStart;
|
|
image = cfg.image;
|
|
extraOptions = [
|
|
"--cap-add=MKNOD"
|
|
"--privileged"
|
|
];
|
|
ports = [ "${cfg.port}:9980" ];
|
|
volumes = [
|
|
# ...
|
|
];
|
|
environmentFiles = cfg.environmentFiles;
|
|
environment = {
|
|
PUID = cfg.puid;
|
|
PGID = cfg.pgid;
|
|
TZ = cfg.timeZone;
|
|
username = cfg.username;
|
|
# password = cfg.password; # get from env file
|
|
domain = "office.mjallen.dev";
|
|
aliasgroup1 = "https://cloud\.mjallen\.dev:443";
|
|
aliasgroup2 = "https://cloud\.mjallen\.dev:443";
|
|
# DONT_GEN_SSL_CERT = cfg.dontGenSslCert;
|
|
server_name = cfg.serverName;
|
|
dictionaries = cfg.dictionaries;
|
|
extra_params = cfg.extraParams;
|
|
};
|
|
};
|
|
};
|
|
}
|