mirror of
https://github.com/sstent/vmimages.git
synced 2025-12-06 06:01:51 +00:00
66 lines
1.8 KiB
Nix
66 lines
1.8 KiB
Nix
{
|
|
description = "NixOS configuration";
|
|
|
|
inputs = {
|
|
# Main nixpkgs channel
|
|
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
|
|
# Import home-manager modules
|
|
home-manager.url = "github:nix-community/home-manager";
|
|
home-manager.inputs.nixpkgs.follows = "nixpkgs";
|
|
# Import deploy-rs for deployments
|
|
deploy-rs.url = "github:serokell/deploy-rs";
|
|
deploy-rs.inputs.nixpkgs.follows = "nixpkgs";
|
|
|
|
# Import nixos hardware quirks settings
|
|
#nixos-hardware.url = "github:NixOS/nixos-hardware";
|
|
|
|
#ssssh secret!! Agenix install
|
|
agenix.url = "github:ryantm/agenix";
|
|
|
|
#import nixos-generators for building images
|
|
nixos-generators = {
|
|
url = "github:nix-community/nixos-generators";
|
|
inputs.nixpkgs.follows = "nixpkgs";
|
|
};
|
|
|
|
};
|
|
|
|
outputs =
|
|
inputs@{ self, nixpkgs, home-manager, nixos-generators, deploy-rs, agenix, ... }: {
|
|
nixosConfigurations = {
|
|
HyperV = nixpkgs.lib.nixosSystem {
|
|
system = "x86_64-linux";
|
|
# specialArgs = { inherit inputs; }; # Pass flake inputs to our config
|
|
modules = [
|
|
./hosts/HyperV/configuration.nix
|
|
./modules
|
|
];
|
|
};
|
|
|
|
};
|
|
|
|
packages.x86_64-linux = {
|
|
HV = nixos-generators.nixosGenerate {
|
|
system = "x86_64-linux";
|
|
modules = [
|
|
./hosts/HyperV/configuration.nix
|
|
./hosts/HyperV/hyperv.nix
|
|
./modules
|
|
];
|
|
format = "hyperv";
|
|
};
|
|
};
|
|
|
|
deploy.nodes.HyperV = {
|
|
sshUser = "sstent";
|
|
user = "root";
|
|
hostname = "192.168.1.230";
|
|
remoteBuild = true;
|
|
magicRollback = false;
|
|
profiles.system.path = deploy-rs.lib.x86_64-linux.activate.nixos
|
|
self.nixosConfigurations.HyperV;
|
|
};
|
|
|
|
};
|
|
}
|