Add multi-host configuration
based loosely on https://github.com/tom-on-the-internet/system-configuration
This commit is contained in:
parent
f554a9038b
commit
8f0f5b9bbf
13 changed files with 254 additions and 240 deletions
37
flake.nix
37
flake.nix
|
@ -1,5 +1,5 @@
|
|||
{
|
||||
description = "A very basic flake";
|
||||
description = "Elnu's NixOS configuration";
|
||||
|
||||
inputs = {
|
||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
|
||||
|
@ -9,40 +9,13 @@
|
|||
};
|
||||
};
|
||||
|
||||
outputs = { self, nixpkgs, home-manager }:
|
||||
outputs = inputs@{ self, nixpkgs, home-manager }:
|
||||
let
|
||||
user = "elnu";
|
||||
system = "x86_64-linux";
|
||||
pkgs = import nixpkgs {
|
||||
inherit system;
|
||||
config.allowUnfree = true;
|
||||
};
|
||||
lib = nixpkgs.lib;
|
||||
in {
|
||||
nixosConfigurations = {
|
||||
elnu = lib.nixosSystem {
|
||||
inherit system;
|
||||
modules = [
|
||||
./configuration.nix
|
||||
home-manager.nixosModules.home-manager {
|
||||
home-manager.useGlobalPkgs = true;
|
||||
home-manager.useUserPackages = true;
|
||||
home-manager.users.${user} = {
|
||||
imports = [
|
||||
./home.nix
|
||||
./vim.nix
|
||||
./wallpaper.nix
|
||||
./picom.nix
|
||||
./i3.nix
|
||||
./polybar
|
||||
./rofi
|
||||
./git.nix
|
||||
./terminal.nix
|
||||
];
|
||||
};
|
||||
}
|
||||
];
|
||||
};
|
||||
nixosConfigurations = import ./hosts {
|
||||
inherit (nixpkgs) lib;
|
||||
inherit inputs nixpkgs home-manager user;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue