Wed Jun 5 02:11:35 AM CEST 2024

This commit is contained in:
Thomas Avé 2024-06-05 02:11:35 +02:00
parent b0f2924fbf
commit 1ae78f195d
3 changed files with 48 additions and 13 deletions

View File

@ -34,6 +34,7 @@
enable = true; enable = true;
driSupport = true; driSupport = true;
}; };
security.polkit.enable = true;
networking.hostName = host; networking.hostName = host;
boot.loader.systemd-boot = { boot.loader.systemd-boot = {
enable = true; enable = true;

View File

@ -114,6 +114,7 @@ in {
"${waybar}" "${waybar}"
"${wl-paste} --type text --watch cliphist store" "${wl-paste} --type text --watch cliphist store"
"${wl-paste} --type image --watch cliphist store" "${wl-paste} --type image --watch cliphist store"
"${pkgs.mate.mate-polkit}/bin/polkit-mate"
]; ];
env = [ env = [
"WLR_NO_HARDWARE_CURSORS,1" "WLR_NO_HARDWARE_CURSORS,1"

View File

@ -1,5 +1,38 @@
{ pkgs, ... }: { pkgs, ... }:
let
mkConnection = name: cfg: {
connection = {
id = name;
type = "wifi";
};
ipv4 = {
method = "auto";
};
ipv6 = {
method = "auto";
};
wifi = {
ssid = name;
mode = "infrastructure";
};
wifi-security = {
auth-alg = "open";
key-mgmt = "wpa-psk";
psk = cfg.id;
};
};
connections = {
"The Buttshark" = {
id = "$THE_BUTTSHARK";
};
"5G Research Tower (5000 Watt)" = {
id = "$RESEARCH_TOWER";
};
"5G Research Tower (2400 Watt)" = {
id = "$RESEARCH_TOWER";
};
};
in
{ {
services.pcscd.enable = true; services.pcscd.enable = true;
hardware.opengl.extraPackages = [ hardware.opengl.extraPackages = [
@ -25,7 +58,7 @@
dns = [ "10.0.0.1" "fdc9:281f:04d7:9ee9::1" ]; dns = [ "10.0.0.1" "fdc9:281f:04d7:9ee9::1" ];
privateKeyFile = "/home/user/.secrets/Wireguard/Aloria.key"; privateKeyFile = "/home/user/.secrets/Wireguard/Aloria.key";
listenPort = 51820; listenPort = 51820;
postUp = "resolvectl dns %i 10.0.0.1; resolvectl domain %i ~thomasave.be;"; # postUp = "resolvectl dns %i 10.0.0.1; resolvectl domain %i ~thomasave.be;";
peers = [{ peers = [{
publicKey = "/9ppjm3yeD0duDvxrqgcHscHmftXko+0s2RbivNEy2c="; publicKey = "/9ppjm3yeD0duDvxrqgcHscHmftXko+0s2RbivNEy2c=";
allowedIPs = [ "10.0.0.1/8" "192.168.1.2/32" ]; allowedIPs = [ "10.0.0.1/8" "192.168.1.2/32" ];
@ -34,13 +67,13 @@
}]; }];
}; };
}; };
networking.wireless = { networking.networkmanager = {
enable = true; enable = true;
environmentFile = "/home/user/.secrets/Wireless/Aloria.env"; ensureProfiles = {
networks = { environmentFiles = [
"The Buttshark" = { "/home/user/.secrets/Wireless/Aloria.env"
psk = "@THE_BUTTSHARK@"; ];
}; profiles = pkgs.lib.mapAttrs mkConnection connections;
}; };
}; };
@ -48,26 +81,26 @@
fileSystems."/home/server" = { fileSystems."/home/server" = {
device = "10.1:/home/server"; device = "10.1:/home/server";
fsType = "nfs"; fsType = "nfs";
options = [ "x-systemd.automount" "x-systemd.mount-timeout=30" "_netdev" "noauto" ]; options = [ "x-systemd.automount" "x-systemd.mount-timeout=1" "_netdev" ];
}; };
fileSystems."/home/user/Workspace" = { fileSystems."/home/user/Workspace" = {
device = "10.1:/home/server/Workspace"; device = "10.1:/home/server/Workspace";
fsType = "nfs"; fsType = "nfs";
options = [ "x-systemd.automount" "x-systemd.mount-timeout=30" "_netdev" "noauto" ]; options = [ "x-systemd.automount" "x-systemd.mount-timeout=1" "_netdev" ];
}; };
fileSystems."/home/user/Documents" = { fileSystems."/home/user/Documents" = {
device = "10.1:/home/server/Storage/Thomas/Documents"; device = "10.1:/home/server/Storage/Thomas/Documents";
fsType = "nfs"; fsType = "nfs";
options = [ "x-systemd.automount" "x-systemd.mount-timeout=30" "_netdev" "noauto" ]; options = [ "x-systemd.automount" "x-systemd.mount-timeout=1" "_netdev" ];
}; };
fileSystems."/home/user/Pictures" = { fileSystems."/home/user/Pictures" = {
device = "10.1:/home/server/Storage/Thomas/Pictures"; device = "10.1:/home/server/Storage/Thomas/Pictures";
fsType = "nfs"; fsType = "nfs";
options = [ "x-systemd.automount" "x-systemd.mount-timeout=30" "_netdev" "noauto" ]; options = [ "x-systemd.automount" "x-systemd.mount-timeout=1" "_netdev" ];
}; };
fileSystems."/home/user/Videos" = { fileSystems."/home/user/Videos" = {
device = "10.1:/home/server/Storage/Thomas/Videos"; device = "10.1:/home/server/Storage/Thomas/Videos";
fsType = "nfs"; fsType = "nfs";
options = [ "x-systemd.automount" "x-systemd.mount-timeout=30" "_netdev" "noauto" ]; options = [ "x-systemd.automount" "x-systemd.mount-timeout=1" "_netdev" ];
}; };
} }