1
0
mirror of https://github.com/Andrey0189/nixos-config-reborn.git synced 2025-09-15 10:06:00 +03:00

moving slim3 coniguration to the hosts directory

This commit is contained in:
andrey_varnavskiy
2024-11-29 16:39:55 +05:00
parent 5b48fce03b
commit ecddf1a6f5
3 changed files with 63 additions and 7 deletions

View File

@@ -28,15 +28,17 @@
in {
# slim3 - system hostname
nixosConfigurations.${hostname} = nixpkgs.lib.nixosSystem {
nixosConfigurations = {
${hostname} = nixpkgs.lib.nixosSystem {
specialArgs = {
inherit inputs system stateVersion hostname user;
};
modules = [
./nixos/configuration.nix
./hosts/${hostname}/configuration.nix
];
};
};
homeConfigurations.${user} = home-manager.lib.homeManagerConfiguration {
pkgs = nixpkgs.legacyPackages.${system};

View File

@@ -0,0 +1,15 @@
{ stateVersion, hostname, ... }:
{
imports =
[
./hardware-configuration.nix
../../nixos/packages.nix
../../nixos/modules
];
networking.hostName = hostname;
system.stateVersion = stateVersion;
}

View File

@@ -0,0 +1,39 @@
# Do not modify this file! It was generated by nixos-generate-config
# and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead.
{ config, lib, pkgs, modulesPath, ... }:
{
imports =
[ (modulesPath + "/installer/scan/not-detected.nix")
];
boot.initrd.availableKernelModules = [ "nvme" "xhci_pci" "usb_storage" "sd_mod" "rtsx_pci_sdmmc" ];
boot.initrd.kernelModules = [ ];
boot.kernelModules = [ "kvm-amd" ];
boot.extraModulePackages = [ ];
fileSystems."/" =
{ device = "/dev/disk/by-uuid/69019f25-749c-4480-bbfc-72eef4c49313";
fsType = "ext4";
};
fileSystems."/boot" =
{ device = "/dev/disk/by-uuid/12CE-A600";
fsType = "vfat";
options = [ "fmask=0022" "dmask=0022" ];
};
swapDevices = [ ];
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
# (the default) this is the recommended approach. When using systemd-networkd it's
# still possible to use this option, but it's recommended to use it in conjunction
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
networking.useDHCP = lib.mkDefault true;
# networking.interfaces.enp4s0f4u2.useDHCP = lib.mkDefault true;
# networking.interfaces.wlp2s0.useDHCP = lib.mkDefault true;
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
}