mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-07-13 21:50:33 +03:00
nixos/paperless: fix time.timeZone setting
This attribute set isn't passed through the NixOS config resolution mechanism, which means that we can't use lib.mkDefault here. Instead, just put it before any user overrides so that if the user specifies this environment variable it'll just override it anyway.
This commit is contained in:
parent
accf3b38d5
commit
55d9a2c596
1 changed files with 5 additions and 5 deletions
|
@ -16,13 +16,13 @@ let
|
||||||
PAPERLESS_MEDIA_ROOT = cfg.mediaDir;
|
PAPERLESS_MEDIA_ROOT = cfg.mediaDir;
|
||||||
PAPERLESS_CONSUMPTION_DIR = cfg.consumptionDir;
|
PAPERLESS_CONSUMPTION_DIR = cfg.consumptionDir;
|
||||||
GUNICORN_CMD_ARGS = "--bind=${cfg.address}:${toString cfg.port}";
|
GUNICORN_CMD_ARGS = "--bind=${cfg.address}:${toString cfg.port}";
|
||||||
} // (
|
} // optionalAttrs (config.time.timeZone != null) {
|
||||||
lib.mapAttrs (_: toString) cfg.extraConfig
|
PAPERLESS_TIME_ZONE = config.time.timeZone;
|
||||||
) // optionalAttrs (config.time.timeZone != null) {
|
|
||||||
PAPERLESS_TIME_ZONE = lib.mkDefault config.time.timeZone;
|
|
||||||
} // optionalAttrs enableRedis {
|
} // optionalAttrs enableRedis {
|
||||||
PAPERLESS_REDIS = "unix://${redisServer.unixSocket}";
|
PAPERLESS_REDIS = "unix://${redisServer.unixSocket}";
|
||||||
};
|
} // (
|
||||||
|
lib.mapAttrs (_: toString) cfg.extraConfig
|
||||||
|
);
|
||||||
|
|
||||||
manage = let
|
manage = let
|
||||||
setupEnv = lib.concatStringsSep "\n" (mapAttrsToList (name: val: "export ${name}=\"${val}\"") env);
|
setupEnv = lib.concatStringsSep "\n" (mapAttrsToList (name: val: "export ${name}=\"${val}\"") env);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue