mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-06-15 05:59:17 +03:00
Revert "nixos: rename system.{stateVersion,defaultChannel} -> system.nixos.\1"
This reverts commit 095fe5b43d
.
Pointless renames considered harmful. All they do is force people to
spend extra work updating their configs for no benefit, and hindering
the ability to switch between unstable and stable versions of NixOS.
Like, what was the value of having the "nixos." there? I mean, by
definition anything in a NixOS module has something to do with NixOS...
This commit is contained in:
parent
28e11a0b6b
commit
96190535e5
21 changed files with 34 additions and 36 deletions
|
@ -146,7 +146,7 @@ in
|
|||
};
|
||||
superUser = mkOption {
|
||||
type = types.str;
|
||||
default= if versionAtLeast config.system.nixos.stateVersion "17.09" then "postgres" else "root";
|
||||
default= if versionAtLeast config.system.stateVersion "17.09" then "postgres" else "root";
|
||||
internal = true;
|
||||
description = ''
|
||||
NixOS traditionally used 'root' as superuser, most other distros use 'postgres'.
|
||||
|
@ -165,14 +165,14 @@ in
|
|||
|
||||
services.postgresql.package =
|
||||
# Note: when changing the default, make it conditional on
|
||||
# ‘system.nixos.stateVersion’ to maintain compatibility with existing
|
||||
# ‘system.stateVersion’ to maintain compatibility with existing
|
||||
# systems!
|
||||
mkDefault (if versionAtLeast config.system.nixos.stateVersion "17.09" then pkgs.postgresql96
|
||||
else if versionAtLeast config.system.nixos.stateVersion "16.03" then pkgs.postgresql95
|
||||
mkDefault (if versionAtLeast config.system.stateVersion "17.09" then pkgs.postgresql96
|
||||
else if versionAtLeast config.system.stateVersion "16.03" then pkgs.postgresql95
|
||||
else pkgs.postgresql94);
|
||||
|
||||
services.postgresql.dataDir =
|
||||
mkDefault (if versionAtLeast config.system.nixos.stateVersion "17.09" then "/var/lib/postgresql/${config.services.postgresql.package.psqlSchema}"
|
||||
mkDefault (if versionAtLeast config.system.stateVersion "17.09" then "/var/lib/postgresql/${config.services.postgresql.package.psqlSchema}"
|
||||
else "/var/db/postgresql");
|
||||
|
||||
services.postgresql.authentication = mkAfter
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue