nix-home updates

This commit is contained in:
John Lancaster
2025-06-25 04:20:58 +00:00
parent f0aa65cc24
commit 5ee997aae4
3 changed files with 67 additions and 41 deletions

61
flake.lock generated
View File

@@ -25,11 +25,11 @@
]
},
"locked": {
"lastModified": 1748925027,
"narHash": "sha256-BJ0qRIdvt5aeqm3zg/5if7b5rruG05zrSX3UpLqjDRk=",
"lastModified": 1750798083,
"narHash": "sha256-DTCCcp6WCFaYXWKFRA6fiI2zlvOLCf5Vwx8+/0R8Wc4=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "cb809ec1ff15cf3237c6592af9bbc7e4d983e98c",
"rev": "ff31a4677c1a8ae506aa7e003a3dba08cb203f82",
"type": "github"
},
"original": {
@@ -38,13 +38,55 @@
"type": "github"
}
},
"home-manager_2": {
"inputs": {
"nixpkgs": [
"nix-home",
"nixpkgs"
]
},
"locked": {
"lastModified": 1750033262,
"narHash": "sha256-TcFN78w6kPspxpbPsxW/8vQ1GAtY8Y3mjBaC+oB8jo4=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "66523b0efe93ce5b0ba96dcddcda15d36673c1f0",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "home-manager",
"type": "github"
}
},
"nix-home": {
"inputs": {
"home-manager": "home-manager_2",
"nixpkgs": [
"nixpkgs"
]
},
"locked": {
"lastModified": 1750820420,
"narHash": "sha256-vL0SZMO5qEUmtFnERG7PXhxk4NGch0Ao2xe9MwLCHU8=",
"ref": "refs/heads/main",
"rev": "7979ea5ca0829137eecc346f32960c3d9d3dff31",
"revCount": 25,
"type": "git",
"url": "https://gitea.john-stream.com/john/nix-home"
},
"original": {
"type": "git",
"url": "https://gitea.john-stream.com/john/nix-home"
}
},
"nixpkgs": {
"locked": {
"lastModified": 1748693115,
"narHash": "sha256-StSrWhklmDuXT93yc3GrTlb0cKSS0agTAxMGjLKAsY8=",
"lastModified": 1750506804,
"narHash": "sha256-VLFNc4egNjovYVxDGyBYTrvVCgDYgENp5bVi9fPTDYc=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "910796cabe436259a29a72e8d3f5e180fc6dfacc",
"rev": "4206c4cb56751df534751b058295ea61357bbbaa",
"type": "github"
},
"original": {
@@ -71,6 +113,7 @@
"root": {
"inputs": {
"home-manager": "home-manager",
"nix-home": "nix-home",
"nixpkgs": "nixpkgs",
"vscode-server": "vscode-server"
}
@@ -96,11 +139,11 @@
"nixpkgs": "nixpkgs_2"
},
"locked": {
"lastModified": 1729422940,
"narHash": "sha256-DlvJv33ml5UTKgu4b0HauOfFIoDx6QXtbqUF3vWeRCY=",
"lastModified": 1750353031,
"narHash": "sha256-Bx7DOPLhkr8Z60U9Qw4l0OidzHoqLDKQH5rDV5ef59A=",
"owner": "nix-community",
"repo": "nixos-vscode-server",
"rev": "8b6db451de46ecf9b4ab3d01ef76e59957ff549f",
"rev": "4ec4859b12129c0436b0a471ed1ea6dd8a317993",
"type": "github"
},
"original": {

View File

@@ -8,21 +8,26 @@
url = "github:nix-community/home-manager";
inputs.nixpkgs.follows = "nixpkgs";
};
nix-home = {
url = "git+https://gitea.john-stream.com/john/nix-home";
inputs.nixpkgs.follows = "nixpkgs";
};
};
outputs = { self, ... }@args:
outputs = { self, ... }@inputs:
let
inherit (self) outputs;
nixosSystem = args.nixpkgs.lib.nixosSystem;
pkgs = args.nixpkgs.legacyPackages.x86_64-linux;
nixosSystem = inputs.nixpkgs.lib.nixosSystem;
pkgs = inputs.nixpkgs.legacyPackages.x86_64-linux;
in
{
nixosConfigurations.lxc = nixosSystem {
system = "x86_64-linux";
modules = [
(args.nixpkgs + "/nixos/modules/virtualisation/proxmox-lxc.nix")
args.vscode-server.nixosModules.default
({ config, pkgs, ... }: {
(inputs.nixpkgs + "/nixos/modules/virtualisation/proxmox-lxc.nix")
inputs.nix-home.nixosModules.default { user = "john"; }
inputs.vscode-server.nixosModules.default
({ pkgs, ... }: {
system.stateVersion = "24.11";
nix.settings.experimental-features = [ "nix-command" "flakes" ];
services.vscode-server.enable = true;
@@ -30,25 +35,12 @@
environment.systemPackages = with pkgs; [
git
devenv
(pkgs.writeShellScriptBin "nfs" ''
sudo nixos-rebuild switch --flake $(readlink -f /etc/nixos)#lxc --impure
'')
(pkgs.writeShellScriptBin "nfsu" ''
FLAKE=$(readlink -f /etc/nixos)
nix flake update --flake $FLAKE --impure
git -C /etc/nixos add $FLAKE/flake.lock > /dev/null 2>&1
sudo nixos-rebuild switch --flake $FLAKE#lxc --impure
'')
];
})
args.home-manager.nixosModules.home-manager
{
home-manager.useGlobalPkgs = true;
home-manager.users.root = {
home.stateVersion = "24.11";
imports = [ ./git.nix ];
};
}
inputs.home-manager.nixosModules.home-manager {
home-manager.useGlobalPkgs = true;
home-manager.users.root.home.stateVersion = "24.11";
}
];
};
};

View File

@@ -1,9 +0,0 @@
{ ... }:
{
programs.git = {
enable = true;
extraConfig.credential.helper = "store --file ~/.git-credentials";
userName = "John Lancaster";
userEmail = "32917998+jsl12@users.noreply.github.com";
};
}