reinstate deploy-rs overlay
This commit is contained in:
parent
afd6aa4072
commit
ed44f28e07
1 changed files with 25 additions and 20 deletions
45
flake.nix
45
flake.nix
|
@ -28,30 +28,34 @@
|
|||
nixos-hardware.url = "github:NixOS/nixos-hardware/master";
|
||||
};
|
||||
outputs = inputs@{ flake-parts, ... }:
|
||||
flake-parts.lib.mkFlake { inherit inputs; } ({ self, ... }: {
|
||||
flake-parts.lib.mkFlake { inherit inputs; } ({ withSystem, self, ... }: {
|
||||
imports = [ inputs.devshell.flakeModule ];
|
||||
systems = [ "x86_64-linux" "aarch64-linux" ];
|
||||
flake = {
|
||||
deploy = {
|
||||
sshUser = "root";
|
||||
fastConnection = true;
|
||||
nodes = {
|
||||
nodes = withSystem "x86_64-linux" ({ pkgs, ... }: {
|
||||
smolboi = {
|
||||
hostname = "smolboi";
|
||||
profiles.system.path = inputs.deploy-rs.lib.x86_64-linux.activate.nixos
|
||||
profiles.system.path =
|
||||
pkgs.deploy-rs.lib.activate.nixos
|
||||
self.nixosConfigurations.smolboi;
|
||||
};
|
||||
zeus = {
|
||||
hostname = "zeus";
|
||||
profiles.system.path = inputs.deploy-rs.lib.x86_64-linux.activate.nixos
|
||||
profiles.system.path =
|
||||
pkgs.deploy-rs.lib.activate.nixos
|
||||
self.nixosConfigurations.zeus;
|
||||
};
|
||||
}) // withSystem "aarch64-linux" ({ pkgs, ... }: {
|
||||
orangepihole = {
|
||||
hostname = "orangepihole";
|
||||
profiles.system.path = inputs.deploy-rs.lib.aarch64-linux.activate.nixos
|
||||
profiles.system.path =
|
||||
pkgs.deploy-rs.lib.activate.nixos
|
||||
self.nixosConfigurations.orangepihole;
|
||||
};
|
||||
};
|
||||
});
|
||||
};
|
||||
nixosConfigurations = {
|
||||
smolboi = inputs.nixpkgs.lib.nixosSystem {
|
||||
|
@ -105,20 +109,21 @@
|
|||
};
|
||||
};
|
||||
};
|
||||
perSystem = { pkgs, inputs', system, ... }: {
|
||||
# _module.args.pkgs = import inputs'.nixpkgs {
|
||||
# inherit system;
|
||||
# overlays = [
|
||||
# inputs.deploy-rs.overlay
|
||||
# (final: prev: {
|
||||
# deploy-rs = {
|
||||
# inherit (pkgs) deploy-rs;
|
||||
# lib = prev.deploy-rs.lib;
|
||||
# };
|
||||
# })
|
||||
# ];
|
||||
# };
|
||||
devshells.default = { packages = with pkgs; [ deploy-rs sops ]; };
|
||||
perSystem = { pkgs, system, ... }: {
|
||||
_module.args.pkgs = import inputs.nixpkgs {
|
||||
inherit system;
|
||||
overlays = [
|
||||
inputs.deploy-rs.overlay
|
||||
(final: prev: {
|
||||
deploy-rs = {
|
||||
inherit (inputs.nixpkgs.legacyPackages.${system}) deploy-rs;
|
||||
lib = prev.deploy-rs.lib;
|
||||
};
|
||||
})
|
||||
];
|
||||
config = { };
|
||||
};
|
||||
devshells.default = { packages = with pkgs; [ deploy-rs.deploy-rs sops ]; };
|
||||
checks = inputs.deploy-rs.lib.${system}.deployChecks self.deploy;
|
||||
formatter = pkgs.nixfmt;
|
||||
};
|
||||
|
|
Loading…
Reference in a new issue