nixos-config/initialize.nix
2021-10-06 07:12:50 -07:00

30 lines
656 B
Nix

{ hostname, build-timestamp, ... }:
{ config, lib, pkgs, ... }:
let
# Get info on this host so we know what to load
host-config = import (./. + "/config/hosts/${hostname}.nix");
in {
imports = [
./lib
./config
#home-manager-module
(./. + "/config/hardware/${hostname}.nix")
(./. + "/config/host-config/${hostname}.nix")
(./. + "/config/profile-config/${host-config.profile}.nix")
(./. + "/config/domain-config/${host-config.domain}.nix")
(./. + "/config/site-config/${host-config.site}.nix")
];
config = {
instance = {
inherit hostname build-timestamp;
};
nixpkgs.pkgs = pkgs;
};
}