Refactor isso configuration to use structured server settings and update service dependencies
This commit is contained in:
@@ -18,13 +18,16 @@ in
|
|||||||
inherit (cfg) enable;
|
inherit (cfg) enable;
|
||||||
settings = {
|
settings = {
|
||||||
guard.require-author = true;
|
guard.require-author = true;
|
||||||
server.listen = "http://${cfg.ip}:${toString cfg.port}/";
|
server = {
|
||||||
|
listen = "http://${cfg.ip}:${toString cfg.port}/";
|
||||||
|
public-endpoint = cfg.url;
|
||||||
|
};
|
||||||
admin = {
|
admin = {
|
||||||
enabled = true;
|
enabled = true;
|
||||||
password = "$ISSO_ADMIN_PASSWORD";
|
password = "$ISSO_ADMIN_PASSWORD";
|
||||||
};
|
};
|
||||||
general = {
|
general = {
|
||||||
host = cfg.url;
|
host = "https://blog.${cfg.domain}";
|
||||||
max-age = "1h";
|
max-age = "1h";
|
||||||
notify = "smtp";
|
notify = "smtp";
|
||||||
reply-notifications = true;
|
reply-notifications = true;
|
||||||
@@ -41,6 +44,10 @@ in
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
systemd.services.isso.serviceConfig.EnvironmentFile = config.sops.secrets.isso.path;
|
systemd.services.isso = {
|
||||||
|
after = [ "network-online.target" ];
|
||||||
|
wants = [ "network-online.target" ];
|
||||||
|
serviceConfig.EnvironmentFile = config.sops.secrets.isso.path;
|
||||||
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
{ lib, config, ... }:
|
{ lib, config, ... }:
|
||||||
let
|
let
|
||||||
cfg = config.my.servers.paperless;
|
cfg = config.my.servers.paperless;
|
||||||
port = config.services.paperless.port;
|
inherit (config.services.paperless) port;
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
options.my.servers.paperless.enable = lib.mkEnableOption "Paperless-ngx document management system";
|
options.my.servers.paperless.enable = lib.mkEnableOption "Paperless-ngx document management system";
|
||||||
|
|||||||
Reference in New Issue
Block a user