This commit is contained in:
fwastring 2025-04-07 14:02:44 +02:00
commit 125ad513d7
16 changed files with 197 additions and 82 deletions

View file

@ -14,17 +14,18 @@
boot.extraModulePackages = [ ];
fileSystems."/" =
{ device = "/dev/disk/by-uuid/af77f921-bcba-43c6-8670-a90e1bde1915";
{ device = "/dev/disk/by-uuid/0f9de0d5-cdca-42a8-bb8a-070e3147396a";
fsType = "ext4";
};
fileSystems."/boot" =
{ device = "/dev/disk/by-uuid/346C-F5FE";
{ device = "/dev/disk/by-uuid/3340-1019";
fsType = "vfat";
options = [ "fmask=0077" "dmask=0077" ];
};
swapDevices =
[ { device = "/dev/disk/by-uuid/3fa47cf3-f18d-4ab7-80e5-39bfaeada0d1"; }
[ { device = "/dev/disk/by-uuid/36870c0d-2200-4850-a8af-7021f6776651"; }
];
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking

View file

@ -0,0 +1,53 @@
# This is your system's configuration file.
# Use this to configure your system environment (it replaces /etc/nixos/configuration.nix)
{
inputs,
lib,
config,
pkgs,
myhostname,
...
}: {
# You can import other NixOS modules here
imports = [
./hardware-configuration.nix
../../config/users.nix
];
environment.systemPackages = with pkgs; [
unstable.lego
];
networking.firewall = {
enable = true;
allowedTCPPorts = [ 80 443 3000 8384 22000];
allowedUDPPortRanges = [
{ from = 4000; to = 4007; }
{ from = 8000; to = 8010; }
];
};
networking.firewall.allowedUDPPorts = [ 22000 21027 ];
services = {
openssh = {
enable = true;
ports = [22];
settings = {
PermitRootLogin = "no";
PasswordAuthentication = false;
X11Forwarding = true;
};
extraConfig = ''
AllowUsers fw
'';
};
};
security.rtkit.enable = true;
networking.hostName = myhostname;
services.xserver.dpi = 100;
system.stateVersion = "24.11";
}

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 = [ "ohci_pci" "ehci_pci" "ahci" "firewire_ohci" "usb_storage" "usbhid" "sd_mod" "sr_mod" ];
boot.initrd.kernelModules = [ ];
boot.kernelModules = [ "kvm-intel" "wl" ];
boot.extraModulePackages = [ config.boot.kernelPackages.broadcom_sta ];
fileSystems."/" =
{ device = "/dev/disk/by-uuid/1c7e7116-3486-45a8-90c0-d3deea8e96b0";
fsType = "ext4";
};
fileSystems."/boot" =
{ device = "/dev/disk/by-uuid/B70D-941F";
fsType = "vfat";
options = [ "fmask=0077" "dmask=0077" ];
};
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.wlp3s0b1.useDHCP = lib.mkDefault true;
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
}

View file

@ -30,7 +30,7 @@
];
fileSystems."/data" = {
fsType = "fuse.mergerfs";
device = "/mnt/drive*";
device = "/mnt/extern*";
options = ["cache.files=partial" "dropcacheonclose=true" "category.create=mfs"];
};
@ -96,7 +96,11 @@
console.keyMap = "sv-latin1";
programs.zsh.enable = true;
security.auditd.enable = true;
services = {
fail2ban = {
enable = true;
};
xserver = {
enable = true;
displayManager = {

View file

@ -12,7 +12,8 @@
imports = [
./hardware-configuration.nix
../../config/base.nix
../../config/users.nix
../../shared/openssh.nix
../../jobb/users.nix
];
environment.systemPackages = with pkgs; [