aboutsummaryrefslogtreecommitdiffstats
path: root/flake.nix
diff options
context:
space:
mode:
Diffstat (limited to 'flake.nix')
-rw-r--r--flake.nix101
1 files changed, 22 insertions, 79 deletions
diff --git a/flake.nix b/flake.nix
index 1e1d034..4bd26e6 100644
--- a/flake.nix
+++ b/flake.nix
@@ -1,5 +1,5 @@
{
- description = "nipsy's NixOS configuration";
+ description = "nipsy's NixOS configurations";
inputs = {
@@ -35,26 +35,22 @@
};
- outputs = inputs@{ home-manager-stable, home-manager, nixos-hardware, nixpkgs-stable, nixpkgs, nvidia-patch, sops-nix, ... }: {
+ outputs = { home-manager-stable, home-manager, nixos-hardware, nixpkgs-stable, nixpkgs, nvidia-patch, self, sops-nix, ... } @ inputs: let
+ inherit (self) outputs;
+ systems = [
+ #"aarch64-linux"
+ #"i686-linux"
+ "x86_64-linux"
+ #"aarch64-darwin"
+ #"x86_64-darwin"
+ ];
+ forAllSystems = nixpkgs.lib.genAttrs systems;
+ in {
nixosConfigurations = {
- arrakis = nixpkgs.lib.nixosSystem rec {
- system = "x86_64-linux";
-
- specialArgs = { inherit inputs nvidia-patch;
- pkgs = import nixpkgs {
- inherit system;
- config.allowUnfree = true;
- overlays = [(import ./pkgs)];
- };
-
- pkgs-stable = import nixpkgs-stable {
- inherit system;
- config.allowUnfree = true;
- };
- };
-
+ arrakis = nixpkgs.lib.nixosSystem {
+ specialArgs = { inherit inputs outputs; };
modules = [
./hosts/arrakis
home-manager.nixosModules.home-manager {
@@ -66,22 +62,8 @@
];
};
- darkstar = nixpkgs.lib.nixosSystem rec {
- system = "x86_64-linux";
-
- specialArgs = {
- pkgs = import nixpkgs {
- inherit system;
- config.allowUnfree = true;
- overlays = [(import ./pkgs)];
- };
-
- pkgs-stable = import nixpkgs-stable {
- inherit system;
- config.allowUnfree = true;
- };
- };
-
+ darkstar = nixpkgs.lib.nixosSystem {
+ specialArgs = { inherit inputs outputs; };
modules = [
./hosts/darkstar
home-manager.nixosModules.home-manager {
@@ -93,21 +75,7 @@
};
ginaz = nixpkgs.lib.nixosSystem rec {
- system = "x86_64-linux";
-
- specialArgs = {
- pkgs = import nixpkgs {
- inherit system;
- config.allowUnfree = true;
- overlays = [(import ./pkgs)];
- };
-
- pkgs-stable = import nixpkgs-stable {
- inherit system;
- config.allowUnfree = true;
- };
- };
-
+ specialArgs = { inherit inputs outputs; };
modules = [
./hosts/ginaz
home-manager.nixosModules.home-manager {
@@ -121,21 +89,7 @@
};
kaitain = nixpkgs.lib.nixosSystem rec {
- system = "x86_64-linux";
-
- specialArgs = {
- pkgs = import nixpkgs {
- inherit system;
- config.allowUnfree = true;
- overlays = [(import ./pkgs)];
- };
-
- pkgs-stable = import nixpkgs-stable {
- inherit system;
- config.allowUnfree = true;
- };
- };
-
+ specialArgs = { inherit inputs outputs; };
modules = [
./hosts/kaitain
home-manager.nixosModules.home-manager {
@@ -146,21 +100,7 @@
};
richese = nixpkgs.lib.nixosSystem rec {
- system = "x86_64-linux";
-
- specialArgs = {
- pkgs = import nixpkgs {
- inherit system;
- config.allowUnfree = true;
- overlays = [(import ./pkgs)];
- };
-
- pkgs-stable = import nixpkgs-stable {
- inherit system;
- config.allowUnfree = true;
- };
- };
-
+ specialArgs = { inherit inputs outputs; };
modules = [
./hosts/richese
home-manager.nixosModules.home-manager {
@@ -172,6 +112,9 @@
};
+ overlays = import ./overlays {inherit inputs;};
+ packages = forAllSystems (system: import ./pkgs nixpkgs.legacyPackages.${system});
+
};
}