diff --git a/nixos/modules/services/web-apps/outline.nix b/nixos/modules/services/web-apps/outline.nix index 6046b2005858..bb0ab5f2751c 100644 --- a/nixos/modules/services/web-apps/outline.nix +++ b/nixos/modules/services/web-apps/outline.nix @@ -836,12 +836,18 @@ in ${ if (cfg.databaseUrl == "local") then '' - export DATABASE_URL="''${DATABASE_URL:-${lib.escapeShellArg localPostgresqlUrl}}" + if [ -z "''${DATABASE_URL:-}" ]; then + DATABASE_URL=${lib.escapeShellArg localPostgresqlUrl} + fi + export DATABASE_URL export PGSSLMODE="''${PGSSLMODE:-disable}" '' else '' - export DATABASE_URL="''${DATABASE_URL:-${lib.escapeShellArg cfg.databaseUrl}}" + if [ -z "''${DATABASE_URL:-}" ]; then + DATABASE_URL=${lib.escapeShellArg cfg.databaseUrl} + fi + export DATABASE_URL '' } diff --git a/nixos/tests/outline.nix b/nixos/tests/outline.nix index 15abc22270d4..0956d2607f7b 100644 --- a/nixos/tests/outline.nix +++ b/nixos/tests/outline.nix @@ -7,10 +7,7 @@ xanderio ]; - node.pkgsReadOnly = false; - - nodes.outline = { - virtualisation.memorySize = 2 * 1024; + containers.outline = { services.outline = { enable = true; forceHttps = false;