deduplicate flake outputs
This commit is contained in:
parent
a938b33679
commit
ad1f4d2cc5
71
flake.lock
71
flake.lock
|
@ -39,6 +39,60 @@
|
|||
"url": "https://git.qenya.tel/qenya/birdsong"
|
||||
}
|
||||
},
|
||||
"colmena": {
|
||||
"inputs": {
|
||||
"flake-compat": "flake-compat",
|
||||
"flake-utils": "flake-utils",
|
||||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
],
|
||||
"stable": "stable"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1711386353,
|
||||
"narHash": "sha256-gWEpb8Hybnoqb4O4tmpohGZk6+aerAbJpywKcFIiMlg=",
|
||||
"owner": "zhaofengli",
|
||||
"repo": "colmena",
|
||||
"rev": "cd65ef7a25cdc75052fbd04b120aeb066c3881db",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "zhaofengli",
|
||||
"repo": "colmena",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"flake-compat": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1650374568,
|
||||
"narHash": "sha256-Z+s0J8/r907g149rllvwhb4pKi8Wam5ij0st8PwAh+E=",
|
||||
"owner": "edolstra",
|
||||
"repo": "flake-compat",
|
||||
"rev": "b4a34015c698c7793d592d66adbab377907a2be8",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "edolstra",
|
||||
"repo": "flake-compat",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"flake-utils": {
|
||||
"locked": {
|
||||
"lastModified": 1659877975,
|
||||
"narHash": "sha256-zllb8aq3YO3h8B/U0/J1WBgAL8EX5yWf5pMj3G0NAmc=",
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"rev": "c0e246b9b83f637f4681389ecabcb2681b4f3af0",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"home-manager": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
|
@ -139,12 +193,29 @@
|
|||
"inputs": {
|
||||
"agenix": "agenix",
|
||||
"birdsong": "birdsong",
|
||||
"colmena": "colmena",
|
||||
"home-manager": "home-manager_2",
|
||||
"nixpkgs": "nixpkgs",
|
||||
"nur": "nur",
|
||||
"plasma-manager": "plasma-manager"
|
||||
}
|
||||
},
|
||||
"stable": {
|
||||
"locked": {
|
||||
"lastModified": 1696039360,
|
||||
"narHash": "sha256-g7nIUV4uq1TOVeVIDEZLb005suTWCUjSY0zYOlSBsyE=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "32dcb45f66c0487e92db8303a798ebc548cadedc",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "NixOS",
|
||||
"ref": "nixos-23.05",
|
||||
"repo": "nixpkgs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"systems": {
|
||||
"locked": {
|
||||
"lastModified": 1681028828,
|
||||
|
|
22
flake.nix
22
flake.nix
|
@ -23,10 +23,15 @@
|
|||
};
|
||||
};
|
||||
|
||||
colmena = {
|
||||
url = "github:zhaofengli/colmena";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
|
||||
birdsong.url = "git+https://git.qenya.tel/qenya/birdsong?ref=main";
|
||||
};
|
||||
|
||||
outputs = inputs@{ self, nixpkgs, home-manager, plasma-manager, nur, agenix, birdsong, ... }: {
|
||||
outputs = inputs@{ self, nixpkgs, home-manager, plasma-manager, nur, agenix, colmena, birdsong, ... }: {
|
||||
nixosModules.default = {
|
||||
nix.settings.experimental-features = "nix-command flakes";
|
||||
nix.nixPath = [ "nixpkgs=flake:nixpkgs" ];
|
||||
|
@ -48,14 +53,7 @@
|
|||
];
|
||||
};
|
||||
|
||||
# TODO: simplify
|
||||
nixosConfigurations = {
|
||||
"kilgharrah" = nixpkgs.lib.nixosSystem { modules = [ ./hosts/kilgharrah self.nixosModules.default ]; };
|
||||
"tohru" = nixpkgs.lib.nixosSystem { modules = [ ./hosts/tohru self.nixosModules.default ]; };
|
||||
"yevaud" = nixpkgs.lib.nixosSystem { modules = [ ./hosts/yevaud self.nixosModules.default ]; };
|
||||
"orm" = nixpkgs.lib.nixosSystem { modules = [ ./hosts/orm self.nixosModules.default ]; };
|
||||
"kalessin" = nixpkgs.lib.nixosSystem { modules = [ ./hosts/kalessin self.nixosModules.default ]; };
|
||||
};
|
||||
nixosConfigurations = (colmena.lib.makeHive self.outputs.colmena).nodes;
|
||||
|
||||
# The name of this output type is not standardised. I have picked
|
||||
# "homeManagerModules" as the discussion here suggests it's the most common:
|
||||
|
@ -75,10 +73,12 @@
|
|||
colmena = {
|
||||
meta = {
|
||||
nixpkgs = import nixpkgs { system = "x86_64-linux"; };
|
||||
nodeNixpkgs = builtins.mapAttrs (name: value: value.pkgs) self.nixosConfigurations;
|
||||
nodeNixpkgs = {
|
||||
kalessin = import nixpkgs { system = "aarch64-linux"; };
|
||||
};
|
||||
specialArgs = { inherit inputs; };
|
||||
};
|
||||
|
||||
# TODO: eliminate duplication with nixosConfigurations
|
||||
defaults.imports = [ self.nixosModules.default ];
|
||||
kilgharrah.imports = [ ./hosts/kilgharrah ];
|
||||
tohru.imports = [ ./hosts/tohru ];
|
||||
|
|
Loading…
Reference in a new issue