diff options
| -rw-r--r-- | flake.lock | 8 | ||||
| -rw-r--r-- | flake.nix | 2 | ||||
| -rw-r--r-- | modules/nixos/base.nix | 11 | ||||
| -rw-r--r-- | systems/atlas/default.nix | 2 |
4 files changed, 8 insertions, 15 deletions
@@ -442,16 +442,16 @@ }, "nixpkgs-stable": { "locked": { - "lastModified": 1702221085, - "narHash": "sha256-Br3GCSkkvkmw46cT6wCz6ro2H1WgDMWbKE0qctbdtL0=", + "lastModified": 1702233072, + "narHash": "sha256-H5G2wgbim2Ku6G6w+NSaQaauv6B6DlPhY9fMvArKqRo=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "c2786e7084cbad90b4f9472d5b5e35ecb57958af", + "rev": "781e2a9797ecf0f146e81425c822dca69fe4a348", "type": "github" }, "original": { "id": "nixpkgs", - "ref": "nixos-23.05", + "ref": "nixos-23.11", "type": "indirect" } }, @@ -8,7 +8,7 @@ inputs = { nixpkgs.url = "nixpkgs/nixos-unstable"; - nixpkgs-stable.url = "nixpkgs/nixos-23.05"; + nixpkgs-stable.url = "nixpkgs/nixos-23.11"; darwin = { url = "github:LnL7/nix-darwin/"; inputs.nixpkgs.follows = "nixpkgs"; diff --git a/modules/nixos/base.nix b/modules/nixos/base.nix index 361829a..83212fe 100644 --- a/modules/nixos/base.nix +++ b/modules/nixos/base.nix @@ -79,18 +79,11 @@ in { defaultUserShell = pkgs.bash; mutableUsers = false; - users.root = let - # yes this is a bad way to detect which option should be used (or exists) - # but i'm lazy. please do not copy this - passwordFile = - if lib.versionAtLeast config.system.stateVersion "23.11" - then "hashedPasswordFile" - else "passwordFile"; - in { + users.root = { home = mkDefault "/root"; uid = mkDefault config.ids.uids.root; group = mkDefault "root"; - "${passwordFile}" = mkDefault config.age.secrets.rootPassword.path; + hashedPasswordFile = mkDefault config.age.secrets.rootPassword.path; }; }; } diff --git a/systems/atlas/default.nix b/systems/atlas/default.nix index 8cba9bd..bce1a04 100644 --- a/systems/atlas/default.nix +++ b/systems/atlas/default.nix @@ -42,7 +42,7 @@ users.users.atlas = { isNormalUser = true; shell = pkgs.bash; - passwordFile = config.age.secrets.userPassword.path; + hashedPasswordFile = config.age.secrets.userPassword.path; }; zramSwap.enable = true; |
