40 lines
1.0 KiB
Nix
Raw Normal View History

2021-11-18 11:49:04 -08:00
{
description = "Definition of the Seattle NixOps network.";
inputs = {
nixpkgs.url = "nixpkgs/nixos-21.05";
fudo-secrets.url = "path:/state/secrets";
fudo-nixos = {
2021-11-19 13:51:02 -08:00
url = "path:/state/nixops/fudo-nixos";
# url = "git+ssh://fudo_git@git.fudo.org:2222/fudosys/NixOS.git?ref=nixops-flake";
inputs.nixpkgs.follows = "nixpkgs";
};
2021-11-18 11:52:14 -08:00
};
2021-11-18 11:49:04 -08:00
2021-11-19 22:30:51 -08:00
outputs = { self, nixpkgs, fudo-nixos, fudo-secrets, ... } @ inputs:
with nixpkgs.lib; {
nixopsConfigurations.default = let
deployment-hosts = filterAttrs
(hostname: hostOpts: hostOpts.domain == "sea.fudo.org")
2021-11-18 11:49:04 -08:00
fudo-nixos.fudoHosts;
2021-11-19 22:30:51 -08:00
build-timestamp = self.sourceInfo.lastModified;
host-gen-config = import ./host-config.nix {
inherit inputs build-timestamp;
};
host-configs = mapAttrs host-gen-config deployment-hosts;
in {
inherit nixpkgs;
network = {
description = "Seattle NixOps network";
enableRollback = true;
};
} // host-configs;
};
2021-11-18 11:49:04 -08:00
}