flake: reformat with nixfmt

This commit is contained in:
Infinidoge 2025-01-28 20:33:04 -05:00
parent a79e641851
commit eaf4f56ac0
Signed by: Infinidoge
SSH key fingerprint: SHA256:oAMyvotlNFraMmZmr+p6AxnNfW/GioTs1pOn3V4tQ7A
117 changed files with 2667 additions and 1592 deletions

View file

@ -1,4 +1,10 @@
{ config, pkgs, lib, ... }: {
{
config,
pkgs,
lib,
...
}:
{
imports = [
./hardware-configuration.nix
./filesystems.nix
@ -11,7 +17,10 @@
persist = {
directories = [
{ directory = "/var/lib/dnsmasq/"; user = "dnsmasq"; }
{
directory = "/var/lib/dnsmasq/";
user = "dnsmasq";
}
];
files = [
@ -82,7 +91,10 @@
"sys-devices-pci0000:00-0000:00:02.0-drm-card0-card0\\x2deDP\\x2d1-intel_backlight.device"
"sys-devices-pci0000:00-0000:00:02.0-drm-card1-card1\\x2deDP\\x2d1-intel_backlight.device"
];
after = [ "system-systemd\\x2dbacklight.slice" "systemd-backlight@backlight:intel_backlight.service" ];
after = [
"system-systemd\\x2dbacklight.slice"
"systemd-backlight@backlight:intel_backlight.service"
];
serviceConfig.Type = "oneshot";
script = "${lib.getExe pkgs.brightnessctl} set 50%";
};
@ -99,8 +111,16 @@
#}
{
hostName = "infini-dl360";
systems = [ "x86_64-linux" "aarch64-linux" ];
supportedFeatures = [ "nixos-test" "benchmark" "big-parallel" "kvm" ];
systems = [
"x86_64-linux"
"aarch64-linux"
];
supportedFeatures = [
"nixos-test"
"benchmark"
"big-parallel"
"kvm"
];
protocol = "ssh-ng";
maxJobs = 32;
speedFactor = 16;
@ -114,26 +134,33 @@
address = [ "10.10.0.3/32" ];
listenPort = 51820;
privateKeyFile = "/home/infinidoge/tmp/bb-vpn.key";
peers = [{
publicKey = "SYpnrGvxx8l4w9c7KVRVW6GyNDr/iK+maPPMw/Ua7XY=";
allowedIPs = [ "10.9.0.0/24" ];
endpoint = "66.23.193.252:55555";
persistentKeepalive = 25;
}];
peers = [
{
publicKey = "SYpnrGvxx8l4w9c7KVRVW6GyNDr/iK+maPPMw/Ua7XY=";
allowedIPs = [ "10.9.0.0/24" ];
endpoint = "66.23.193.252:55555";
persistentKeepalive = 25;
}
];
};
specialisation.router.configuration = {
networking = {
interfaces."enp0s13f0u1" = {
ipv4.addresses = [{
address = "192.168.100.1";
prefixLength = 24;
}];
ipv4.addresses = [
{
address = "192.168.100.1";
prefixLength = 24;
}
];
};
firewall.interfaces."enp0s13f0u1" = {
allowedTCPPorts = [ 53 ];
allowedUDPPorts = [ 53 67 ];
allowedUDPPorts = [
53
67
];
};
nat = {
@ -146,7 +173,10 @@
services.dnsmasq = {
enable = true;
settings = {
server = [ "8.8.8.8" "1.1.1.1" ];
server = [
"8.8.8.8"
"1.1.1.1"
];
domain-needed = true;
bogus-priv = true;
no-resolv = true;

View file

@ -13,12 +13,26 @@ in
services.autorandr.profiles =
let
scale = { x = scaleFactor'; y = scaleFactor'; };
scale = {
x = scaleFactor';
y = scaleFactor';
};
config = {
framework = { mode = "2256x1504"; primary = true; inherit scale; };
portable-second = { mode = "1920x1080"; rotate = "left"; };
dock = { mode = "1280x1024"; };
dorm = { mode = "1920x1080"; };
framework = {
mode = "2256x1504";
primary = true;
inherit scale;
};
portable-second = {
mode = "1920x1080";
rotate = "left";
};
dock = {
mode = "1280x1024";
};
dorm = {
mode = "1920x1080";
};
};
fingerprints = {
framework = "00ffffffffffff0009e5ca0b000000002f200104a51c137803de50a3544c99260f505400000001010101010101010101010101010101115cd01881e02d50302036001dbe1000001aa749d01881e02d50302036001dbe1000001a000000fe00424f452043510a202020202020000000fe004e4531333546424d2d4e34310a0073";
@ -32,30 +46,57 @@ in
config = lib.mapAttrs (_: v: lib.removeAttrs v [ "fingerprint" ]) config;
};
in
lib.mapAttrs (_: mkConfig) (with config'; {
main = {
eDP-1 = framework // { position = "0x0"; };
};
portable-second = {
eDP-1 = framework // { position = "1080x716"; };
DP-4 = portable-second // { position = "0x0"; };
};
docked = {
eDP-1 = framework // { position = "0x210"; };
DP-1-3 = dock // { position = "1805x0"; };
};
docked-alt = {
eDP-1 = framework // { position = "1080x716"; };
DP-4 = portable-second // { position = "0x0"; };
DP-1-3 = dock // { position = "2885x506"; };
};
dorm = {
eDP-1 = framework // { position = "1920x0"; };
DP-4 = dorm // { position = "0x0"; };
};
dorm-2 = {
eDP-1 = framework // { position = "1920x0"; };
DP-3 = dorm // { position = "0x0"; };
};
});
lib.mapAttrs (_: mkConfig) (
with config';
{
main = {
eDP-1 = framework // {
position = "0x0";
};
};
portable-second = {
eDP-1 = framework // {
position = "1080x716";
};
DP-4 = portable-second // {
position = "0x0";
};
};
docked = {
eDP-1 = framework // {
position = "0x210";
};
DP-1-3 = dock // {
position = "1805x0";
};
};
docked-alt = {
eDP-1 = framework // {
position = "1080x716";
};
DP-4 = portable-second // {
position = "0x0";
};
DP-1-3 = dock // {
position = "2885x506";
};
};
dorm = {
eDP-1 = framework // {
position = "1920x0";
};
DP-4 = dorm // {
position = "0x0";
};
};
dorm-2 = {
eDP-1 = framework // {
position = "1920x0";
};
DP-3 = dorm // {
position = "0x0";
};
};
}
);
}

View file

@ -1,7 +1,13 @@
{ lib, ... }:
{
boot.initrd.availableKernelModules = [ "xhci_pci" "thunderbolt" "nvme" "usb_storage" "sd_mod" ];
boot.initrd.availableKernelModules = [
"xhci_pci"
"thunderbolt"
"nvme"
"usb_storage"
"sd_mod"
];
boot.initrd.kernelModules = [ ];
boot.kernelModules = [ "kvm-intel" ];
boot.extraModulePackages = [ ];