network/flake.nix

42 lines
946 B
Nix
Raw Normal View History

2021-03-05 20:05:50 +01:00
{
description = "Zentralwerk network";
inputs = {
nixpkgs.url = "github:nixos/nixpkgs";
};
outputs = { self, nixpkgs }:
let
system = "x86_64-linux";
systems = [ system ];
forAllSystems = nixpkgs.lib.genAttrs systems;
in
rec {
2021-03-19 01:41:12 +01:00
lib =
import ./nix/lib { inherit nixpkgs; };
2021-03-05 20:05:50 +01:00
packages = forAllSystems (system:
import ./nix/pkgs { inherit self nixpkgs system; }
);
2021-03-05 20:05:50 +01:00
nixosModule = { ... }: {
imports = nixpkgs.lib.filesystem.listFilesRecursive ./nix/nixos-modules;
};
nixosConfigurations.test_vm =
nixpkgs.lib.nixosSystem {
inherit system;
modules = [ nixosModule ];
extraModules = [ ({ ... }: {
networking.hostName = "test_vm";
}) ];
};
nixosConfigurations.server1 =
nixpkgs.lib.nixosSystem {
inherit system;
modules = [];
};
};
}