Inline common configuration

This commit is contained in:
2024-07-11 21:53:03 -07:00
parent 1506edcd1a
commit bd9a9de9fc
4 changed files with 49 additions and 42 deletions

View File

@@ -1,23 +0,0 @@
{ hostName, ... }:
{
networking = {
inherit hostName;
networkmanager.enable = true;
};
boot.loader = {
systemd-boot.enable = true;
efi.canTouchEfiVariables = true;
};
nixpkgs.config.allowUnfree = true;
nix.settings.experimental-features = [ "nix-command" "flakes" ];
users.users = {
nettika = {
isNormalUser = true;
extraGroups = [ "wheel" "networkmanager" ];
};
};
}

View File

@@ -2,33 +2,22 @@
description = "Nettika NixOS Configurations"; description = "Nettika NixOS Configurations";
inputs = { inputs = {
nixpkgs.url = "github:nixos/nixpkgs/nixos-24.05";
nixpkgs-unstable.url = "github:nixos/nixpkgs/nixos-unstable";
nixos-hardware.url = "github:nixos/nixos-hardware/master"; nixos-hardware.url = "github:nixos/nixos-hardware/master";
nixpkgs-unstable.url = "github:nixos/nixpkgs/nixos-unstable";
nixpkgs.url = "github:nixos/nixpkgs/nixos-24.05";
}; };
outputs = { nixpkgs, nixos-hardware, ... }: { outputs = { nixpkgs, nixos-hardware, ... }@inputs: {
nixosConfigurations = { nixosConfigurations = {
marauder = nixpkgs.lib.nixosSystem { marauder = nixpkgs.lib.nixosSystem {
system = "x86_64-linux"; system = "x86_64-linux";
modules = [ modules = [ ./marauder/configuration.nix ];
./marauder/configuration.nix specialArgs = { inherit inputs; };
./common.nix
nixos-hardware.nixosModules.asus-rog-strix-g513im
];
specialArgs = {
hostName = "marauder";
};
}; };
monolith = nixpkgs.lib.nixosSystem { monolith = nixpkgs.lib.nixosSystem {
system = "x86_64-linux"; system = "x86_64-linux";
modules = [ modules = [ ./monolith/configuration.nix ];
./monolith/configuration.nix specialArgs = { inherit inputs; };
./common.nix
];
specialArgs = {
hostName = "monolith";
};
}; };
}; };
}; };

View File

@@ -1,10 +1,32 @@
{ pkgs, ... }: { pkgs, inputs, ... }:
{ {
imports = [ imports = [
./backup.nix ./backup.nix
./hardware-configuration.nix ./hardware-configuration.nix
inputs.nixos-hardware.nixosModules.asus-rog-strix-g513im
]; ];
networking = {
hostName = "marauder";
networkmanager.enable = true;
};
boot.loader = {
systemd-boot.enable = true;
efi.canTouchEfiVariables = true;
};
users.users = {
nettika = {
isNormalUser = true;
extraGroups = [ "wheel" "networkmanager" ];
};
};
nixpkgs.config.allowUnfree = true;
nix.settings.experimental-features = [ "nix-command" "flakes" ];
environment.systemPackages = with pkgs; [ environment.systemPackages = with pkgs; [
# Chat clients # Chat clients
discord discord

View File

@@ -1,4 +1,23 @@
{ ... }: { { ... }: {
networking = {
hostName = "marauder";
networkmanager.enable = true;
};
boot.loader = {
systemd-boot.enable = true;
efi.canTouchEfiVariables = true;
};
users.users = {
nettika = {
isNormalUser = true;
extraGroups = [ "wheel" "networkmanager" ];
};
};
nix.settings.experimental-features = [ "nix-command" "flakes" ];
time.timeZone = "America/Los_Angeles"; time.timeZone = "America/Los_Angeles";
system.stateVersion = "24.05"; system.stateVersion = "24.05";