game-laptop -> game-desktop

This commit is contained in:
Gerg-L 2023-10-12 20:35:39 -04:00
parent 849c21761f
commit d24efeba64
Signed by: gerg-l
SSH key fingerprint: SHA256:FPYDHIkvMocr4wdmZXpgpJjsb2Tw6rASs2ISPbOb0KI
15 changed files with 105 additions and 103 deletions

View file

@ -1,7 +1,7 @@
keys: keys:
- &gerg-desktop age180y8kdtdlqelayyz9mq2c7xv248rh4gdfr3amjzvdcjrz6wdaqmsj762pp - &gerg-desktop age180y8kdtdlqelayyz9mq2c7xv248rh4gdfr3amjzvdcjrz6wdaqmsj762pp
- &moms-laptop age1vxx3qdsucv2v2slag67c4f0kwd8jtta4tue6m8d9xfl4ryrqvyusxgwl68 - &moms-laptop age1vxx3qdsucv2v2slag67c4f0kwd8jtta4tue6m8d9xfl4ryrqvyusxgwl68
- &game-laptop age1egxes320renph0uevtmnsz4d5aw0z794c5nwrk2z6249wv2yevgqx9cf90 - &game-desktop age1egxes320renph0uevtmnsz4d5aw0z794c5nwrk2z6249wv2yevgqx9cf90
creation_rules: creation_rules:
- path_regex: hosts/gerg-desktop/secrets.yaml$ - path_regex: hosts/gerg-desktop/secrets.yaml$
key_groups: key_groups:
@ -15,6 +15,6 @@ creation_rules:
- path_regex: hosts/game-laptop/secrets.yaml$ - path_regex: hosts/game-laptop/secrets.yaml$
key_groups: key_groups:
- age: - age:
- *game-laptop - *game-desktop
- *gerg-desktop - *gerg-desktop

View file

@ -5,7 +5,7 @@ it currently has 3 hosts:
"gerg-desktop" my main computer [specs](https://pcpartpicker.com/list/DVkMk9) "gerg-desktop" my main computer [specs](https://pcpartpicker.com/list/DVkMk9)
which I run a windows KVM VFIO virtual machine on which I run a windows KVM VFIO virtual machine on
"game-laptop" a HP Pavilion Laptop [15-ec2121nr](https://support.hp.com/us-en/document/c07918617#AbT0) "game-desktop" a HP Pavilion Laptop [15-ec2121nr](https://support.hp.com/us-en/document/c07918617#AbT0)
which I've been testing linux game compatability on which I've been testing linux game compatability on
"moms-laptop" a TOSHIBA Satellite [L855-S5309](https://fo-stage-03.icecat.biz/us/p/toshiba/pskfuu-008049/satellite-notebooks-l855-s5309-18316794.html) "moms-laptop" a TOSHIBA Satellite [L855-S5309](https://fo-stage-03.icecat.biz/us/p/toshiba/pskfuu-008049/satellite-notebooks-l855-s5309-18316794.html)

View file

@ -56,7 +56,7 @@
inherit lib; inherit lib;
nixosConfigurations = lib.mkHosts "x86_64-linux" [ nixosConfigurations = lib.mkHosts "x86_64-linux" [
"gerg-desktop" "gerg-desktop"
"game-laptop" "game-desktop"
"moms-laptop" "moms-laptop"
"iso" "iso"
]; ];
@ -65,7 +65,7 @@
diskoConfigurations = lib.mkDisko [ diskoConfigurations = lib.mkDisko [
"gerg-desktop" "gerg-desktop"
"game-laptop" "game-desktop"
"moms-laptop" "moms-laptop"
]; ];
formatter.${system} = pkgs.writeShellApplication { formatter.${system} = pkgs.writeShellApplication {

View file

@ -77,6 +77,28 @@ _:
}; };
}; };
}; };
hardware.nvidia = {
package = config.boot.kernelPackages.nvidiaPackages.latest;
nvidiaPersistenced = true;
nvidiaSettings = false;
modesetting.enable = true;
};
services.xserver = {
videoDrivers = [ "nvidia" ];
#disable DPMS
monitorSection = ''
Option "DPMS" "false"
'';
#disable screen blanking in total
serverFlagsSection = ''
Option "StandbyTime" "0"
Option "SuspendTime" "0"
Option "OffTime" "0"
Option "BlankTime" "0"
'';
};
hardware.bluetooth.enable = true; hardware.bluetooth.enable = true;
services.blueman.enable = true; services.blueman.enable = true;
boot = { boot = {
@ -88,10 +110,12 @@ _:
kernelModules = [ "kvm-amd" ]; kernelModules = [ "kvm-amd" ];
kernelPackages = pkgs.linuxPackages_latest; kernelPackages = pkgs.linuxPackages_latest;
}; };
swapDevices = [ { swapDevices = [
{
device = "/swapfile"; device = "/swapfile";
size = 16 * 1024; size = 16 * 1024;
} ]; }
];
system.stateVersion = "23.05"; system.stateVersion = "23.05";
_file = ./main.nix; _file = ./main.nix;

View file

@ -1,30 +0,0 @@
_:
{ config, ... }:
{
hardware.nvidia = {
package = config.boot.kernelPackages.nvidiaPackages.latest;
prime = {
sync.enable = true;
amdgpuBusId = "PCI:5:0:0";
nvidiaBusId = "PCI:1:0:0";
};
nvidiaPersistenced = true;
nvidiaSettings = false;
modesetting.enable = true;
};
services.xserver = {
videoDrivers = [ "nvidia" ];
#disable DPMS
monitorSection = ''
Option "DPMS" "false"
'';
#disable screen blanking in total
serverFlagsSection = ''
Option "StandbyTime" "0"
Option "SuspendTime" "0"
Option "OffTime" "0"
Option "BlankTime" "0"
'';
};
_file = ./prime.nix;
}

View file

@ -10,10 +10,12 @@ _:
"miniflux" "miniflux"
config.services.gitea.database.user config.services.gitea.database.user
]; ];
ensureUsers = [ { ensureUsers = [
{
name = "miniflux"; name = "miniflux";
ensurePermissions."DATABASE miniflux" = "ALL PRIVILEGES"; ensurePermissions."DATABASE miniflux" = "ALL PRIVILEGES";
} ]; }
];
settings.unix_socket_permissions = "0770"; settings.unix_socket_permissions = "0770";
}; };

View file

@ -91,9 +91,11 @@ _:
system.stateVersion = "23.05"; system.stateVersion = "23.05";
swapDevices = [ { swapDevices = [
{
device = "/swapfile"; device = "/swapfile";
size = 8 * 1024; size = 8 * 1024;
} ]; }
];
_file = ./main.nix; _file = ./main.nix;
} }

View file

@ -39,8 +39,7 @@ in
if config == { } then if config == { } then
unstable.legacyPackages.${system} unstable.legacyPackages.${system}
else else
import unstable { inherit system config; } import unstable { inherit system config; };
;
} }
) )
[ "x86_64-linux" ] [ "x86_64-linux" ]

View file

@ -22,7 +22,8 @@
''; '';
defaultSession = "none+dwm"; defaultSession = "none+dwm";
}; };
windowManager.session = [ { windowManager.session = [
{
name = "dwm"; name = "dwm";
start = '' start = ''
update_time () { update_time () {
@ -41,7 +42,8 @@
dont_stop & dont_stop &
waitPID=$! waitPID=$!
''; '';
} ]; }
];
}; };
environment.systemPackages = builtins.attrValues { environment.systemPackages = builtins.attrValues {
inherit (suckless.packages.${pkgs.system}) dmenu dwm st; inherit (suckless.packages.${pkgs.system}) dmenu dwm st;

View file

@ -19,7 +19,8 @@ _:
]; ];
}; };
distributedBuilds = true; distributedBuilds = true;
buildMachines = [ { buildMachines = [
{
hostName = "gerg-desktop"; hostName = "gerg-desktop";
protocol = "ssh-ng"; protocol = "ssh-ng";
maxJobs = 32; maxJobs = 32;
@ -36,7 +37,8 @@ _:
sshUser = "builder"; sshUser = "builder";
sshKey = "/etc/ssh/ssh_host_ed25519_key"; sshKey = "/etc/ssh/ssh_host_ed25519_key";
publicHostKey = config.local.keys.gerg-desktop_fingerprint; publicHostKey = config.local.keys.gerg-desktop_fingerprint;
} ]; }
];
}; };
programs.ssh.knownHosts = { programs.ssh.knownHosts = {
gerg-desktop = { gerg-desktop = {
@ -50,7 +52,7 @@ _:
let let
keys = [ keys = [
config.local.keys.root_moms-laptop config.local.keys.root_moms-laptop
config.local.keys.root_game-laptop config.local.keys.root_game-desktop
]; ];
in in
lib.mkIf config.local.remoteBuild.isBuilder { lib.mkIf config.local.remoteBuild.isBuilder {

View file

@ -7,7 +7,7 @@ _:
gerg_gerg-phone = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIDU6BnoHIgMLgZVGuvi03J9l5Z1yP1P5Q8QPyjRHyi77"; gerg_gerg-phone = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIDU6BnoHIgMLgZVGuvi03J9l5Z1yP1P5Q8QPyjRHyi77";
gerg_gerg-windows = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAILpYY2uw0OH1Re+3BkYFlxn0O/D8ryqByJB/ljefooNc"; gerg_gerg-windows = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAILpYY2uw0OH1Re+3BkYFlxn0O/D8ryqByJB/ljefooNc";
root_moms-laptop = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIIq9YTf4jlVCKBKn44m4yJvj94C7pTOyaa4VjZFohNqD"; root_moms-laptop = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIIq9YTf4jlVCKBKn44m4yJvj94C7pTOyaa4VjZFohNqD";
root_game-laptop = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJUKHZasYQUAmRBiqtx1drDxfq18/N4rKydCtPHx461I"; root_game-desktop = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJUKHZasYQUAmRBiqtx1drDxfq18/N4rKydCtPHx461I";
root_gerg-desktop = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIIeHsGcmOdIMzV+SNe4WFcA3CPHCNb1aqxThkXtm7G/1"; root_gerg-desktop = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIIeHsGcmOdIMzV+SNe4WFcA3CPHCNb1aqxThkXtm7G/1";
gerg-desktop_fingerprint = "BQxvBOWsTw1gdNDR0KzrSRmbVhDrJdG05vYXkVmw8yA"; gerg-desktop_fingerprint = "BQxvBOWsTw1gdNDR0KzrSRmbVhDrJdG05vYXkVmw8yA";
gerg_gerg-desktop = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJWbwkFJmRBgyWyWU+w3ksZ+KuFw9uXJN3PwqqE7Z/i8"; gerg_gerg-desktop = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJWbwkFJmRBgyWyWU+w3ksZ+KuFw9uXJN3PwqqE7Z/i8";

View file

@ -101,8 +101,7 @@ let
if cfg.mirroredBoots != [ ] then if cfg.mirroredBoots != [ ] then
cfg.mirroredBoots cfg.mirroredBoots
else else
[ efi.efiSysMountPoint ] [ efi.efiSysMountPoint ];
;
in in
pkgs.writeShellScript "install-systemd-boot.sh" ( pkgs.writeShellScript "install-systemd-boot.sh" (
lib.concatMapStrings lib.concatMapStrings
@ -111,8 +110,7 @@ let
'') '')
installDirs installDirs
) )
+ cfg.extraInstallCommands + cfg.extraInstallCommands;
;
in in
{ {
disabledModules = [ disabledModules = [
@ -324,12 +322,14 @@ in
config = mkIf cfg.enable { config = mkIf cfg.enable {
assertions = assertions =
[ { [
{
assertion = assertion =
(config.boot.kernelPackages.kernel.features or { efiBootStub = true; }) (config.boot.kernelPackages.kernel.features or { efiBootStub = true; })
? efiBootStub; ? efiBootStub;
message = "This kernel does not support the EFI boot stub"; message = "This kernel does not support the EFI boot stub";
} ] }
]
++ concatMap ++ concatMap
(filename: [ (filename: [
{ {
@ -368,8 +368,7 @@ in
} is invalid: files cannot be placed in the nixos/.extra-files directory"; } is invalid: files cannot be placed in the nixos/.extra-files directory";
} }
]) ])
(builtins.attrNames cfg.extraFiles) (builtins.attrNames cfg.extraFiles);
;
boot.loader.grub.enable = mkDefault false; boot.loader.grub.enable = mkDefault false;

View file

@ -82,10 +82,12 @@ in
extraConfig = '' extraConfig = ''
font-size=10 font-size=10
''; '';
fonts = [ { fonts = [
{
name = "OverpassMono"; name = "OverpassMono";
package = pkgs.nerdfonts.override { fonts = [ "Overpass" ]; }; package = pkgs.nerdfonts.override { fonts = [ "Overpass" ]; };
} ]; }
];
}; };
systemd.services = { systemd.services = {
"autovt@tty1".enable = false; "autovt@tty1".enable = false;