mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-07-14 14:10:33 +03:00
nixos/gogs: Fix module when no passwords provided
If neither database.password or database.passwordFile were provided, it would try and fail to coerce null to a string. This fixes the situation where there is no password for the database. Resolves #27950
This commit is contained in:
parent
ea1d5e9c7a
commit
6460e459de
1 changed files with 1 additions and 1 deletions
|
@ -257,7 +257,7 @@ in
|
|||
in the Nix store. Use database.passwordFile instead.'';
|
||||
|
||||
# Create database passwordFile default when password is configured.
|
||||
services.gogs.database.passwordFile = mkIf (cfg.database.password != "")
|
||||
services.gogs.database.passwordFile =
|
||||
(mkDefault (toString (pkgs.writeTextFile {
|
||||
name = "gogs-database-password";
|
||||
text = cfg.database.password;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue