Personal Nix flake
nixos home-manager nix
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

feat: Initial colmena implementation

+177 -15
+105 -12
flake.lock
··· 161 161 "type": "github" 162 162 } 163 163 }, 164 + "colmena": { 165 + "inputs": { 166 + "flake-compat": "flake-compat_2", 167 + "flake-utils": "flake-utils", 168 + "nix-github-actions": "nix-github-actions", 169 + "nixpkgs": [ 170 + "nixpkgs" 171 + ], 172 + "stable": "stable" 173 + }, 174 + "locked": { 175 + "lastModified": 1762034856, 176 + "narHash": "sha256-QVey3iP3UEoiFVXgypyjTvCrsIlA4ecx6Acaz5C8/PQ=", 177 + "owner": "zhaofengli", 178 + "repo": "colmena", 179 + "rev": "349b035a5027f23d88eeb3bc41085d7ee29f18ed", 180 + "type": "github" 181 + }, 182 + "original": { 183 + "owner": "zhaofengli", 184 + "repo": "colmena", 185 + "type": "github" 186 + } 187 + }, 164 188 "crane": { 165 189 "locked": { 166 190 "lastModified": 1771121070, ··· 319 343 "flake-compat_2": { 320 344 "flake": false, 321 345 "locked": { 346 + "lastModified": 1650374568, 347 + "narHash": "sha256-Z+s0J8/r907g149rllvwhb4pKi8Wam5ij0st8PwAh+E=", 348 + "owner": "edolstra", 349 + "repo": "flake-compat", 350 + "rev": "b4a34015c698c7793d592d66adbab377907a2be8", 351 + "type": "github" 352 + }, 353 + "original": { 354 + "owner": "edolstra", 355 + "repo": "flake-compat", 356 + "type": "github" 357 + } 358 + }, 359 + "flake-compat_3": { 360 + "flake": false, 361 + "locked": { 322 362 "lastModified": 1767039857, 323 363 "narHash": "sha256-vNpUSpF5Nuw8xvDLj2KCwwksIbjua2LZCqhV1LNRDns=", 324 364 "owner": "NixOS", ··· 332 372 "type": "github" 333 373 } 334 374 }, 335 - "flake-compat_3": { 375 + "flake-compat_4": { 336 376 "flake": false, 337 377 "locked": { 338 378 "lastModified": 1767039857, ··· 348 388 "type": "github" 349 389 } 350 390 }, 351 - "flake-compat_4": { 391 + "flake-compat_5": { 352 392 "flake": false, 353 393 "locked": { 354 394 "lastModified": 1696426674, ··· 364 404 "type": "github" 365 405 } 366 406 }, 367 - "flake-compat_5": { 407 + "flake-compat_6": { 368 408 "flake": false, 369 409 "locked": { 370 410 "lastModified": 1733328505, ··· 558 598 } 559 599 }, 560 600 "flake-utils": { 601 + "locked": { 602 + "lastModified": 1659877975, 603 + "narHash": "sha256-zllb8aq3YO3h8B/U0/J1WBgAL8EX5yWf5pMj3G0NAmc=", 604 + "owner": "numtide", 605 + "repo": "flake-utils", 606 + "rev": "c0e246b9b83f637f4681389ecabcb2681b4f3af0", 607 + "type": "github" 608 + }, 609 + "original": { 610 + "owner": "numtide", 611 + "repo": "flake-utils", 612 + "type": "github" 613 + } 614 + }, 615 + "flake-utils_2": { 561 616 "inputs": { 562 617 "systems": "systems_2" 563 618 }, ··· 593 648 }, 594 649 "git-hooks-nix": { 595 650 "inputs": { 596 - "flake-compat": "flake-compat_2", 651 + "flake-compat": "flake-compat_3", 597 652 "gitignore": "gitignore_2", 598 653 "nixpkgs": "nixpkgs" 599 654 }, ··· 769 824 }, 770 825 "jovian": { 771 826 "inputs": { 772 - "nix-github-actions": "nix-github-actions", 827 + "nix-github-actions": "nix-github-actions_2", 773 828 "nixpkgs": [ 774 829 "nixpkgs" 775 830 ] ··· 813 868 }, 814 869 "make-shell": { 815 870 "inputs": { 816 - "flake-compat": "flake-compat_4" 871 + "flake-compat": "flake-compat_5" 817 872 }, 818 873 "locked": { 819 874 "lastModified": 1733933815, ··· 865 920 } 866 921 }, 867 922 "nix-github-actions": { 923 + "inputs": { 924 + "nixpkgs": [ 925 + "colmena", 926 + "nixpkgs" 927 + ] 928 + }, 929 + "locked": { 930 + "lastModified": 1737420293, 931 + "narHash": "sha256-F1G5ifvqTpJq7fdkT34e/Jy9VCyzd5XfJ9TO8fHhJWE=", 932 + "owner": "nix-community", 933 + "repo": "nix-github-actions", 934 + "rev": "f4158fa080ef4503c8f4c820967d946c2af31ec9", 935 + "type": "github" 936 + }, 937 + "original": { 938 + "owner": "nix-community", 939 + "repo": "nix-github-actions", 940 + "type": "github" 941 + } 942 + }, 943 + "nix-github-actions_2": { 868 944 "inputs": { 869 945 "nixpkgs": [ 870 946 "jovian", ··· 886 962 "type": "github" 887 963 } 888 964 }, 889 - "nix-github-actions_2": { 965 + "nix-github-actions_3": { 890 966 "inputs": { 891 967 "nixpkgs": [ 892 968 "nixneovimplugins", ··· 945 1021 }, 946 1022 "nixneovimplugins": { 947 1023 "inputs": { 948 - "flake-utils": "flake-utils", 1024 + "flake-utils": "flake-utils_2", 949 1025 "nixpkgs": [ 950 1026 "nixpkgs" 951 1027 ], ··· 1061 1137 }, 1062 1138 "nixpkgs-schemas": { 1063 1139 "inputs": { 1064 - "flake-compat": "flake-compat_5", 1140 + "flake-compat": "flake-compat_6", 1065 1141 "flake-parts": "flake-parts_4", 1066 1142 "git-hooks-nix": "git-hooks-nix_2", 1067 1143 "nixpkgs": [ ··· 1175 1251 "nixneovimplugins", 1176 1252 "flake-utils" 1177 1253 ], 1178 - "nix-github-actions": "nix-github-actions_2", 1254 + "nix-github-actions": "nix-github-actions_3", 1179 1255 "nixpkgs": [ 1180 1256 "nixneovimplugins", 1181 1257 "nixpkgs" ··· 1197 1273 }, 1198 1274 "pre-commit": { 1199 1275 "inputs": { 1200 - "flake-compat": "flake-compat_3", 1276 + "flake-compat": "flake-compat_4", 1201 1277 "gitignore": "gitignore_3", 1202 1278 "nixpkgs": [ 1203 1279 "lanzaboote", ··· 1289 1365 "agenix": "agenix", 1290 1366 "agenix-rekey": "agenix-rekey", 1291 1367 "caelestia": "caelestia", 1368 + "colmena": "colmena", 1292 1369 "disko": "disko", 1293 1370 "dms": "dms", 1294 1371 "ez-configs": "ez-configs", ··· 1312 1389 "nixvim": "nixvim", 1313 1390 "nur": "nur", 1314 1391 "spicetify-nix": "spicetify-nix", 1315 - "stable": "stable", 1392 + "stable": "stable_2", 1316 1393 "stylix": "stylix", 1317 1394 "unstable": "unstable", 1318 1395 "wayland-pipewire-idle-inhibit": "wayland-pipewire-idle-inhibit" ··· 1361 1438 } 1362 1439 }, 1363 1440 "stable": { 1441 + "locked": { 1442 + "lastModified": 1767313136, 1443 + "narHash": "sha256-16KkgfdYqjaeRGBaYsNrhPRRENs0qzkQVUooNHtoy2w=", 1444 + "owner": "NixOS", 1445 + "repo": "nixpkgs", 1446 + "rev": "ac62194c3917d5f474c1a844b6fd6da2db95077d", 1447 + "type": "github" 1448 + }, 1449 + "original": { 1450 + "owner": "NixOS", 1451 + "ref": "nixos-25.05", 1452 + "repo": "nixpkgs", 1453 + "type": "github" 1454 + } 1455 + }, 1456 + "stable_2": { 1364 1457 "locked": { 1365 1458 "lastModified": 1771574726, 1366 1459 "narHash": "sha256-D1PA3xQv/s4W3lnR9yJFSld8UOLr0a/cBWMQMXS+1Qg=",
+4
flake.nix
··· 73 73 url = "github:oddlama/agenix-rekey"; 74 74 inputs.nixpkgs.follows = "nixpkgs"; 75 75 }; 76 + colmena = { 77 + url = "github:zhaofengli/colmena"; 78 + inputs.nixpkgs.follows = "nixpkgs"; 79 + }; 76 80 disko = { 77 81 url = "github:nix-community/disko"; 78 82 inputs.nixpkgs.follows = "nixpkgs";
+42
nix/flakeModules/colmena.nix
··· 1 + # Adapted from https://github.com/juspay/colmena-flake 2 + { 3 + inputs, 4 + lib, 5 + self, 6 + withSystem, 7 + ... 8 + }: { 9 + flake = withSystem "x86_64-linux" ({system, ...}: let 10 + nixosConfigurations = 11 + self.nixosConfigurations 12 + |> lib.filterAttrs (_: val: val.config.my.deploy.enable); 13 + hostConfigs = 14 + nixosConfigurations 15 + |> builtins.mapAttrs (name: value: { 16 + imports = 17 + value._module.args.modules 18 + ++ [ 19 + ({config, ...}: { 20 + deployment = let 21 + defaultNames = builtins.attrNames colmenaConfig.defaults.deployment; 22 + namesToIgnore = defaultNames ++ ["enable"]; 23 + in 24 + removeAttrs config.my.deploy namesToIgnore; 25 + }) 26 + ]; 27 + }); 28 + colmenaConfig = { 29 + meta = { 30 + nixpkgs = self.lib.mkPkgs {inherit system;}; 31 + nodeSpecialArgs = 32 + nixosConfigurations 33 + |> builtins.mapAttrs (_: value: value._module.specialArgs); 34 + }; 35 + defaults.deployment = { 36 + allowLocalDeployment = true; 37 + }; 38 + }; 39 + in { 40 + colmenaHive = inputs.colmena.lib.makeHive (colmenaConfig // hostConfigs); 41 + }); 42 + }
+1
nix/flakeModules/default.nix
··· 1 1 {...}: { 2 2 imports = [ 3 3 ./agenixRekey.nix 4 + ./colmena.nix 4 5 ./ezConfigs.nix 5 6 ./gitHooks.nix 6 7 ];
+1
nix/nixos/modules/default.nix
··· 23 23 ./boot 24 24 ./ci 25 25 ./desktop 26 + ./deploy 26 27 ./gaming 27 28 ./gui 28 29 ./hardware
+20
nix/nixos/modules/deploy/default.nix
··· 1 + { 2 + config, 3 + inputs, 4 + lib, 5 + ... 6 + }: { 7 + options.my.deploy = let 8 + colmenaModule = inputs.colmena.nixosModules.deploymentOptions { 9 + inherit lib; 10 + name = config.networking.hostName; 11 + }; 12 + deployOptions = colmenaModule.options.deployment; 13 + in 14 + deployOptions 15 + // { 16 + enable = 17 + lib.mkEnableOption "deployment" 18 + // {default = !config.my.deprecated;}; 19 + }; 20 + }
+3 -2
nix/overlays/lix.nix
··· 1 1 # As instructed on https://lix.systems/add-to-config/ 2 - {...}: final: prev: let 2 + {inputs, ...}: final: prev: let 3 3 inherit (prev) lib; 4 + inherit (prev.stdenv.hostPlatform) system; 4 5 rev = "stable"; 5 6 nix = final.lixPackageSets.${rev}.lix; 6 7 in { 7 8 # Workaround for infrec found here https://github.com/NixOS/nixpkgs/pull/445223#issuecomment-3330902652 8 9 inherit nix; 10 + inherit (inputs.colmena.packages.${system}) colmena; 9 11 nix-direnv = prev.nix-direnv.override {inherit nix;}; 10 12 inherit 11 13 (final.lixPackageSets.${rev}) 12 - colmena 13 14 nix-eval-jobs 14 15 nix-fast-build 15 16 nixpkgs-review
+1 -1
nix/shells/maintenance.nix
··· 22 22 packages = 23 23 (with pkgs; [ 24 24 age-plugin-yubikey 25 - agenix-rekey 25 + colmena 26 26 just 27 27 rage 28 28 ])