refactor for defaults in default and physical machine

This commit is contained in:
Tyler Starr 2024-09-27 13:57:17 -07:00
parent 08be9f6272
commit acb8519f43
8 changed files with 66 additions and 58 deletions

View File

@ -3,8 +3,9 @@
inherit system;
specialArgs = { inherit user inputs; };
modules = [
../default/physical/configuration.nix
./configuration.nix
../default # shared by all configs
../default/physical/configuration.nix # shared by physical machines
./configuration.nix # bulwark specific
./hardware.nix
../../modules
agenix.nixosModules.default

View File

@ -0,0 +1,34 @@
{ config, pkgs, user, lib, inputs, ... }:
{
imports = [
./git.nix
./backup.nix
./home-default.nix
];
nix = {
package = pkgs.nixFlakes;
extraOptions = "experimental-features = nix-command flakes";
settings.auto-optimise-store = true;
gc = {
automatic = true;
dates = "weekly";
options = "--delete-older-than 7d";
};
};
# Add non-free packages
nixpkgs.config.allowUnfree = true;
nixpkgs.overlays = import ../../lib/overlays.nix;
# Set your time zone.
time.timeZone = "America/Los_Angeles";
i18n.defaultLocale = "en_US.UTF-8";
environment.systemPackages = with pkgs; [
inputs.agenix.packages.x86_64-linux.default
];
# Did you read the comment?
system.stateVersion = "23.11";
}

View File

@ -0,0 +1,20 @@
{ config, pkgs, user, ... }:
{
home-manager.users.${user} = {
home.username = "${user}";
home.homeDirectory = "/home/${user}";
programs.home-manager.enable = true;
programs.direnv = {
enable = true;
enableBashIntegration = true;
nix-direnv.enable = true;
};
home.packages = with pkgs; [
];
# Did you read the comment?
home.stateVersion = "23.11";
};
}

View File

@ -1,53 +1,19 @@
{ config, pkgs, user, lib, inputs, ... }:
{
imports = [
../git.nix
../backup.nix
./home-configuration.nix
];
nix = {
package = pkgs.nixFlakes;
extraOptions = "experimental-features = nix-command flakes";
settings.auto-optimise-store = true;
gc = {
automatic = true;
dates = "weekly";
options = "--delete-older-than 7d";
};
};
# Add non-free packages
nixpkgs.config.allowUnfree = true;
nixpkgs.config.permittedInsecurePackages = [ "electron-25.9.0" "openssl-1.1.1w" ];
nixpkgs.overlays = import ../../../lib/overlays.nix;
# Hardware options
#hardware.bluetooth.enable = true;
#hardware.bluetooth.package = pkgs.bluez;
#hardware.sensor.iio.enable = true;
#hardware.graphics.enable = true;
#hardware.graphics.enable32Bit = true;
# Use the systemd-boot EFI boot loader.
boot.loader.systemd-boot.enable = true;
boot.loader.efi.canTouchEfiVariables = true;
# Set your time zone.
time.timeZone = "America/Los_Angeles";
i18n.defaultLocale = "en_US.UTF-8";
# Define user account.
users.users.${user} = {
isNormalUser = true;
extraGroups = [ "dialout" "wheel" "docker" "libvirtd" ];
shell = pkgs.bash;
};
environment.systemPackages = with pkgs; [
inputs.agenix.packages.x86_64-linux.default
];
# Did you read the comment?
system.stateVersion = "23.11";
}

View File

@ -1,25 +1,9 @@
{ config, pkgs, user, ... }:
{
home-manager.users.${user} = {
home.username = "${user}";
home.homeDirectory = "/home/${user}";
programs.home-manager.enable = true;
programs.direnv = {
enable = true;
enableBashIntegration = true;
nix-direnv.enable = true;
};
programs.vscode = {
enable = true;
package = pkgs.vscode.fhs;
};
home.packages = with pkgs; [
];
# Did you read the comment?
home.stateVersion = "23.11";
};
}

View File

@ -3,8 +3,9 @@
inherit system;
specialArgs = { inherit user inputs; };
modules = [
../default/physical/configuration.nix
./configuration.nix
../default # shared by all configs
../default/physical/configuration.nix # shared by physical machines
./configuration.nix # kestrel specific
./hardware.nix
../../modules
agenix.nixosModules.default

View File

@ -3,8 +3,9 @@
inherit system;
specialArgs = { inherit user inputs; };
modules = [
../default/physical/configuration.nix
./configuration.nix
../default # shared by all configs
../default/physical/configuration.nix # shared by physical machines
./configuration.nix # shivan specific
./hardware.nix
../../modules
agenix.nixosModules.default

View File

@ -3,8 +3,9 @@
inherit system;
specialArgs = { inherit user inputs; };
modules = [
../default/physical/configuration.nix
./configuration.nix
../default # shared by all configs
../default/physical/configuration.nix # shared by physical machines
./configuration.nix # torus specific
./hardware.nix
../../modules
agenix.nixosModules.default