update: initial homelab commit
This commit is contained in:
parent
e52403ef07
commit
c22d68423e
4 changed files with 178 additions and 13 deletions
|
|
@ -1,12 +1,51 @@
|
|||
{ pkgs, ... }: {
|
||||
|
||||
imports =
|
||||
[ # Include the results of the hardware scan.
|
||||
./hardware-configuration.nix
|
||||
];
|
||||
|
||||
services.vscode-server = {
|
||||
enable = true;
|
||||
enableFHS = true;
|
||||
installPath = "$HOME/.vscodium-server";
|
||||
};
|
||||
programs.nix-ld.enable = true;
|
||||
|
||||
boot.kernelPackages = pkgs.linuxPackages_latest;
|
||||
boot.loader.systemd-boot.enable = true;
|
||||
boot.loader.efi.canTouchEfiVariables = true;
|
||||
|
||||
networking.hostName = "fedfer-main-homelab-nixos";
|
||||
networking.hostName = "veneficium-main-homelab-nixos";
|
||||
|
||||
systemd.network.enable = true;
|
||||
networking.networkmanager.enable = true;
|
||||
|
||||
# Set your time zone.
|
||||
time.timeZone = "Europe/Rome";
|
||||
|
||||
# Select internationalisation properties.
|
||||
i18n.defaultLocale = "en_US.UTF-8";
|
||||
|
||||
i18n.extraLocaleSettings = {
|
||||
LC_ADDRESS = "it_IT.UTF-8";
|
||||
LC_IDENTIFICATION = "it_IT.UTF-8";
|
||||
LC_MEASUREMENT = "it_IT.UTF-8";
|
||||
LC_MONETARY = "it_IT.UTF-8";
|
||||
LC_NAME = "it_IT.UTF-8";
|
||||
LC_NUMERIC = "it_IT.UTF-8";
|
||||
LC_PAPER = "it_IT.UTF-8";
|
||||
LC_TELEPHONE = "it_IT.UTF-8";
|
||||
LC_TIME = "it_IT.UTF-8";
|
||||
};
|
||||
|
||||
# Configure keymap in X11
|
||||
services.xserver.xkb = {
|
||||
layout = "it";
|
||||
variant = "";
|
||||
};
|
||||
|
||||
# Configure console keymap
|
||||
console.keyMap = "it2";
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
nano
|
||||
|
|
@ -15,8 +54,18 @@
|
|||
parted
|
||||
];
|
||||
|
||||
users.users.veneficium = {
|
||||
isNormalUser = true;
|
||||
description = "Veneficium";
|
||||
extraGroups = [ "networkmanager" "wheel" ];
|
||||
packages = with pkgs; [];
|
||||
};
|
||||
|
||||
|
||||
programs.zsh.enable = true;
|
||||
|
||||
services.openssh.enable = true;
|
||||
|
||||
# Allow unfree packages
|
||||
nixpkgs.config.allowUnfree = true;
|
||||
|
||||
|
|
@ -24,6 +73,6 @@
|
|||
nix.settings.experimental-features = [ "nix-command" "flakes" ];
|
||||
|
||||
#DO NOT CHANGE THIS! IMPORTANT! DO NOT CHANGE THIS!
|
||||
system.stateVersion = "23.11"; #DO NOT CHANGE THIS!
|
||||
system.stateVersion = "24.05"; #DO NOT CHANGE THIS!
|
||||
|
||||
}
|
||||
|
|
|
|||
39
hosts/main-homelab/hardware-configuration.nix
Normal file
39
hosts/main-homelab/hardware-configuration.nix
Normal 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 = [ "vmd" "xhci_pci" "ahci" "nvme" "usbhid" "usb_storage" "sd_mod" ];
|
||||
boot.initrd.kernelModules = [ ];
|
||||
boot.kernelModules = [ "kvm-intel" ];
|
||||
boot.extraModulePackages = [ ];
|
||||
|
||||
fileSystems."/" =
|
||||
{ device = "/dev/disk/by-uuid/58d4396b-d87c-419b-ac35-c4d282ef05b1";
|
||||
fsType = "ext4";
|
||||
};
|
||||
|
||||
fileSystems."/boot" =
|
||||
{ device = "/dev/disk/by-uuid/F5D9-1046";
|
||||
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.enp4s0.useDHCP = lib.mkDefault true;
|
||||
# networking.interfaces.wlp0s20f3.useDHCP = lib.mkDefault true;
|
||||
|
||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue