Rename systems folder to hosts
This commit is contained in:
78
hosts/kardorf/default.nix
Normal file
78
hosts/kardorf/default.nix
Normal file
@ -0,0 +1,78 @@
|
||||
# Edit this configuration file to define what should be installed on
|
||||
# your system. Help is available in the configuration.nix(5) man page
|
||||
# and in the NixOS manual (accessible by running ‘nixos-help’).
|
||||
|
||||
{
|
||||
lib,
|
||||
inputs,
|
||||
config,
|
||||
pkgs,
|
||||
systems,
|
||||
...
|
||||
}:
|
||||
{
|
||||
imports = [ ./hardware-configuration.nix ];
|
||||
|
||||
networking.hostName = "kardorf"; # Define your hostname.
|
||||
networking.networkmanager.enable = true;
|
||||
services.resolved.enable = true;
|
||||
|
||||
topology.self = {
|
||||
hardware.info = "Pc Kardorf";
|
||||
};
|
||||
|
||||
time.timeZone = "Europe/Berlin";
|
||||
|
||||
modules = {
|
||||
nix-settings.enable = true;
|
||||
xserver-defaults.enable = true;
|
||||
keymap.enable = true;
|
||||
builder.enable = true;
|
||||
system.boot-efi.enable = true;
|
||||
sound.enable = true;
|
||||
locales.enable = true;
|
||||
pcmanfm.enable = true;
|
||||
i3.enable = true;
|
||||
gdm.enable = true;
|
||||
virtualbox.enable = true;
|
||||
users-julian.enable = true;
|
||||
xdg-portal.enable = true;
|
||||
polkit.enable = true;
|
||||
keyring.enable = true;
|
||||
redshift.enable = true;
|
||||
syncthing.enable = true;
|
||||
};
|
||||
|
||||
boot.loader.efi.efiSysMountPoint = "/boot/efi";
|
||||
services.xserver.videoDrivers = [ "nvidia" ];
|
||||
hardware.nvidia.package = config.boot.kernelPackages.nvidiaPackages.legacy_470;
|
||||
# hardware.nvidia.modesetting.enable = true; # for wayland
|
||||
|
||||
# Enable CUPS to print documents.
|
||||
# hardware.sane.enable = true;
|
||||
services.printing.enable = true;
|
||||
services.printing.browsing = true;
|
||||
# services.avahi.enable = true;
|
||||
# services.avahi.nssmdns = true;
|
||||
services.printing.drivers = with pkgs; [ gutenprint ];
|
||||
|
||||
# List services that you want to enable:
|
||||
services.openssh.enable = false;
|
||||
services.flatpak.enable = true;
|
||||
# Smart card reader
|
||||
services.pcscd.enable = true;
|
||||
|
||||
virtualisation.docker.enable = true;
|
||||
|
||||
# Packages needed as root
|
||||
environment.systemPackages = with pkgs; [
|
||||
vim
|
||||
htop
|
||||
mc
|
||||
gparted-xhost # needs to be installed as system package so it can be actually opened
|
||||
];
|
||||
|
||||
# ======================== DO NOT CHANGE THIS ========================
|
||||
system.stateVersion = "22.11";
|
||||
# ======================== DO NOT CHANGE THIS ========================
|
||||
}
|
60
hosts/kardorf/hardware-configuration.nix
Normal file
60
hosts/kardorf/hardware-configuration.nix
Normal file
@ -0,0 +1,60 @@
|
||||
# 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 =
|
||||
[ "ehci_pci" "ahci" "xhci_pci" "usbhid" "uas" "sd_mod" "sr_mod" ];
|
||||
boot.initrd.kernelModules = [ ];
|
||||
boot.kernelModules = [ ];
|
||||
boot.extraModulePackages = [ ];
|
||||
|
||||
fileSystems."/" = {
|
||||
device = "/dev/disk/by-uuid/97a9342e-0be0-4193-9a25-03400fc7da94";
|
||||
fsType = "btrfs";
|
||||
options = [ "subvol=root" "compress=zstd" ];
|
||||
};
|
||||
|
||||
fileSystems."/home" = {
|
||||
device = "/dev/disk/by-uuid/97a9342e-0be0-4193-9a25-03400fc7da94";
|
||||
fsType = "btrfs";
|
||||
options = [ "subvol=home" "compress=zstd" ];
|
||||
};
|
||||
|
||||
fileSystems."/nix" = {
|
||||
device = "/dev/disk/by-uuid/97a9342e-0be0-4193-9a25-03400fc7da94";
|
||||
fsType = "btrfs";
|
||||
options = [ "subvol=nix" "compress=zstd" "noatime" ];
|
||||
};
|
||||
|
||||
fileSystems."/swap" = {
|
||||
device = "/dev/disk/by-uuid/97a9342e-0be0-4193-9a25-03400fc7da94";
|
||||
fsType = "btrfs";
|
||||
options = [ "subvol=swap" "noatime" ];
|
||||
};
|
||||
|
||||
fileSystems."/boot/efi" = {
|
||||
device = "/dev/disk/by-uuid/7D48-A59C";
|
||||
fsType = "vfat";
|
||||
};
|
||||
|
||||
swapDevices = [{
|
||||
device = "/swap/swapfile";
|
||||
size = 16 * 1024;
|
||||
}];
|
||||
|
||||
# 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.docker0.useDHCP = lib.mkDefault true;
|
||||
# networking.interfaces.enp4s0.useDHCP = lib.mkDefault true;
|
||||
|
||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||
hardware.cpu.intel.updateMicrocode =
|
||||
lib.mkDefault config.hardware.enableRedistributableFirmware;
|
||||
}
|
Reference in New Issue
Block a user