added devbox, devenv, flox
This commit is contained in:
parent
febdf2702c
commit
98d681cf32
5 changed files with 199 additions and 28 deletions
46
flake.nix
46
flake.nix
|
|
@ -12,37 +12,35 @@
|
|||
lix-module.inputs.nixpkgs.follows = "nixpkgs";
|
||||
lanzaboote.url = "github:nix-community/lanzaboote";
|
||||
lanzaboote.inputs.nixpkgs.follows = "nixpkgs";
|
||||
flox.url = "github:flox/flox";
|
||||
};
|
||||
|
||||
outputs = inputs@{ self, nixpkgs, ... }:
|
||||
outputs =
|
||||
inputs@{ self, nixpkgs, ... }:
|
||||
let
|
||||
lib = nixpkgs.lib;
|
||||
hostFiles = builtins.attrNames (builtins.readDir ./hosts);
|
||||
hostNames =
|
||||
lib.filter (name:
|
||||
lib.hasSuffix ".nix" name
|
||||
&& !(lib.hasSuffix "-hardware.nix" name)
|
||||
&& name != "iso.nix"
|
||||
)
|
||||
hostFiles;
|
||||
mkHost = name: lib.nixosSystem {
|
||||
system = "x86_64-linux";
|
||||
specialArgs = { inherit inputs; };
|
||||
modules = [ (./hosts + "/${name}.nix") ];
|
||||
};
|
||||
in {
|
||||
nixosConfigurations =
|
||||
lib.genAttrs (map (lib.removeSuffix ".nix") hostNames) mkHost
|
||||
// {
|
||||
installer = nixpkgs.lib.nixosSystem {
|
||||
system = "x86_64-linux";
|
||||
specialArgs = { inherit inputs; };
|
||||
modules = [ ./hosts/iso.nix ];
|
||||
};
|
||||
hostNames = lib.filter (
|
||||
name: lib.hasSuffix ".nix" name && !(lib.hasSuffix "-hardware.nix" name) && name != "iso.nix"
|
||||
) hostFiles;
|
||||
mkHost =
|
||||
name:
|
||||
lib.nixosSystem {
|
||||
system = "x86_64-linux";
|
||||
specialArgs = { inherit inputs; };
|
||||
modules = [ (./hosts + "/${name}.nix") ];
|
||||
};
|
||||
in
|
||||
{
|
||||
nixosConfigurations = lib.genAttrs (map (lib.removeSuffix ".nix") hostNames) mkHost // {
|
||||
installer = nixpkgs.lib.nixosSystem {
|
||||
system = "x86_64-linux";
|
||||
specialArgs = { inherit inputs; };
|
||||
modules = [ ./hosts/iso.nix ];
|
||||
};
|
||||
};
|
||||
|
||||
packages.x86_64-linux.install-iso =
|
||||
self.nixosConfigurations.installer.config.system.build.isoImage;
|
||||
packages.x86_64-linux.install-iso = self.nixosConfigurations.installer.config.system.build.isoImage;
|
||||
packages.x86_64-linux.default = self.packages.x86_64-linux.install-iso;
|
||||
};
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue