1
0
Fork 0
nix-configuration/hosts/Shura/default.nix

73 lines
2.2 KiB
Nix
Raw Normal View History

2024-02-29 09:53:34 -05:00
{ config, pkgs, lib, ... }:
let
# Copy bluetooth device configs
shure-aonic-bluetooth = pkgs.writeText "info" (builtins.readFile ./bluetooth/shure-aonic-bluetooth-params);
xbox-elite-bluetooth = pkgs.writeText "info" (builtins.readFile ./bluetooth/xbox-elite-controller-bluetooth-params);
mano-touchpad-bluetooth = pkgs.writeText "info" (builtins.readFile ./bluetooth/mano-touchpad-bluetooth-params);
# Use gremlin user's monitor configuration for GDM (desktop monitor primary). See https://discourse.nixos.org/t/gdm-monitor-configuration/6356/4
monitorsXmlContent = builtins.readFile ./monitors.xml;
monitorsConfig = pkgs.writeText "gdm_monitors.xml" monitorsXmlContent;
in
{
imports = [ ./hardware-configuration.nix ];
2024-02-29 09:53:34 -05:00
system.stateVersion = "24.05";
host = {
role = "workstation";
apps = {
2024-03-11 12:27:30 -04:00
development = {
enable = true;
kubernetes.enable = true;
};
2024-03-04 10:57:41 -05:00
dj.enable = true;
2024-02-29 09:53:34 -05:00
gaming.enable = true;
2024-03-22 18:18:38 -04:00
kdeconnect.enable = true;
2024-03-04 10:57:41 -05:00
media.enable = true;
office.enable = true;
2024-02-29 09:53:34 -05:00
recording.enable = true;
social.enable = true;
2024-05-01 21:10:26 -04:00
writing.enable = true;
2024-02-29 09:53:34 -05:00
};
ui = {
flatpak.enable = true;
gnome.enable = true;
};
users = {
aires = {
enable = true;
services.syncthing = {
enable = true;
2024-04-13 17:02:35 -04:00
enableTray = false; # Recent versions of STT don't recognize Gnome's tray. Uninstalling for now.
2024-02-29 09:53:34 -05:00
};
};
gremlin = {
enable = true;
services.syncthing = {
enable = true;
2024-04-13 17:02:35 -04:00
enableTray = false;
2024-02-29 09:53:34 -05:00
};
};
};
};
# Move files into target system
systemd.tmpfiles.rules = [
# Use gremlin user's monitor config for GDM (defined above)
"L+ /run/gdm/.config/monitors.xml - - - - ${monitorsConfig}"
# Install Bluetooth device profiles
"d /var/lib/bluetooth/AC:50:DE:9F:AB:88/ 0700 root root" # First, make sure the directory exists
"L+ /var/lib/bluetooth/AC:50:DE:9F:AB:88/00:0E:DD:72:2F:0C/info - - - - ${shure-aonic-bluetooth}"
"L+ /var/lib/bluetooth/AC:50:DE:9F:AB:88/F4:6A:D7:3A:16:75/info - - - - ${xbox-elite-bluetooth}"
"L+ /var/lib/bluetooth/AC:50:DE:9F:AB:88/F8:5D:3C:7D:9A:00/info - - - - ${mano-touchpad-bluetooth}"
];
# Configure the virtual machine created by nixos-rebuild build-vm
virtualisation.vmVariant.virtualisation = {
2024-03-04 10:57:41 -05:00
memorySize = 4096;
2024-02-29 09:53:34 -05:00
cores = 4;
};
}