Wed Jun 5 01:28:56 PM CEST 2024
This commit is contained in:
parent
214a6d0a63
commit
d092fc690d
|
@ -33,8 +33,10 @@
|
||||||
hardware.opengl = {
|
hardware.opengl = {
|
||||||
enable = true;
|
enable = true;
|
||||||
driSupport = true;
|
driSupport = true;
|
||||||
|
driSupport32Bit = true;
|
||||||
};
|
};
|
||||||
security.polkit.enable = true;
|
security.polkit.enable = true;
|
||||||
|
nixpkgs.config.allowUnfree = true;
|
||||||
networking.hostName = host;
|
networking.hostName = host;
|
||||||
boot.loader.systemd-boot = {
|
boot.loader.systemd-boot = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
@ -46,9 +48,11 @@
|
||||||
time.timeZone = "Europe/Brussels";
|
time.timeZone = "Europe/Brussels";
|
||||||
|
|
||||||
nix.settings = {
|
nix.settings = {
|
||||||
substituters = [ "https://hyprland.cachix.org" ];
|
substituters = [ "https://hyprland.cachix.org" "https://nix-community.cachix.org" "https://cuda-maintainers.cachix.org"];
|
||||||
trusted-public-keys = [
|
trusted-public-keys = [
|
||||||
"hyprland.cachix.org-1:a7pgxzMz7+chwVL3/pzj6jIBMioiJM7ypFP8PwtkuGc="
|
"hyprland.cachix.org-1:a7pgxzMz7+chwVL3/pzj6jIBMioiJM7ypFP8PwtkuGc="
|
||||||
|
"nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs="
|
||||||
|
"cuda-maintainers.cachix.org-1:0dq3bujKpuEPMCX6U4WylrUDZ9JyUG0VpVZa7CNfq5E="
|
||||||
];
|
];
|
||||||
experimental-features = [ "nix-command" "flakes" ];
|
experimental-features = [ "nix-command" "flakes" ];
|
||||||
trusted-users = [ "root" "user" ];
|
trusted-users = [ "root" "user" ];
|
||||||
|
|
|
@ -171,10 +171,8 @@
|
||||||
border-radius: 7px;
|
border-radius: 7px;
|
||||||
color: #ffffff;
|
color: #ffffff;
|
||||||
background-color: #1f2430;
|
background-color: #1f2430;
|
||||||
margin-left:4px;
|
margin-left:3px;
|
||||||
margin-right:4px;
|
margin-right:3px;
|
||||||
margin-top:2px;
|
|
||||||
margin-bottom:2px;
|
|
||||||
}
|
}
|
||||||
#taskbar button.active {
|
#taskbar button.active {
|
||||||
background-color: #023269;
|
background-color: #023269;
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
{ pkgs, ... }:
|
{ pkgs, config, ... }:
|
||||||
let
|
let
|
||||||
mkConnection = name: cfg: {
|
mkConnection = name: cfg: {
|
||||||
connection = {
|
connection = {
|
||||||
|
@ -35,10 +35,54 @@ connections = {
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
services.pcscd.enable = true;
|
services.pcscd.enable = true;
|
||||||
|
services.xserver.videoDrivers = ["nvidia"];
|
||||||
hardware.opengl.extraPackages = [
|
hardware.opengl.extraPackages = [
|
||||||
pkgs.intel-compute-runtime
|
pkgs.intel-compute-runtime
|
||||||
pkgs.intel-media-driver
|
pkgs.intel-media-driver
|
||||||
];
|
];
|
||||||
|
services.thermald.enable = true;
|
||||||
|
services.fwupd.enable = true;
|
||||||
|
environment.systemPackages = with pkgs; [
|
||||||
|
wireguard-tools
|
||||||
|
|
||||||
|
# CUDA
|
||||||
|
pciutils
|
||||||
|
file
|
||||||
|
gnumake
|
||||||
|
gcc
|
||||||
|
cudatoolkit
|
||||||
|
];
|
||||||
|
hardware.nvidia = {
|
||||||
|
package = config.boot.kernelPackages.nvidiaPackages.stable;
|
||||||
|
modesetting.enable = true;
|
||||||
|
powerManagement.enable = false;
|
||||||
|
powerManagement.finegrained = true;
|
||||||
|
open = false;
|
||||||
|
nvidiaSettings = true;
|
||||||
|
prime = {
|
||||||
|
intelBusId = "PCI:0:2:0";
|
||||||
|
nvidiaBusId = "PCI:1:0:0";
|
||||||
|
offload = {
|
||||||
|
enable = true;
|
||||||
|
enableOffloadCmd = true;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
systemd.services.nvidia-control-devices = {
|
||||||
|
wantedBy = [ "multi-user.target" ];
|
||||||
|
serviceConfig.ExecStart = "${pkgs.linuxPackages.nvidia_x11.bin}/bin/nvidia-smi";
|
||||||
|
};
|
||||||
|
specialisation = {
|
||||||
|
on-the-go.configuration = {
|
||||||
|
system.nixos.tags = [ "docked" ];
|
||||||
|
hardware.nvidia = {
|
||||||
|
powerManagement.finegrained = pkgs.lib.mkForce false;
|
||||||
|
prime.offload.enable = pkgs.lib.mkForce false;
|
||||||
|
prime.offload.enableOffloadCmd = pkgs.lib.mkForce false;
|
||||||
|
prime.sync.enable = pkgs.lib.mkForce true;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
services.udev.packages = [ pkgs.yubikey-personalization ];
|
services.udev.packages = [ pkgs.yubikey-personalization ];
|
||||||
|
|
||||||
# Calendar
|
# Calendar
|
||||||
|
@ -46,7 +90,6 @@ in
|
||||||
services.gnome.evolution-data-server.enable = true;
|
services.gnome.evolution-data-server.enable = true;
|
||||||
services.gnome.gnome-online-accounts.enable = true;
|
services.gnome.gnome-online-accounts.enable = true;
|
||||||
services.gnome.gnome-keyring.enable = true;
|
services.gnome.gnome-keyring.enable = true;
|
||||||
environment.systemPackages = with pkgs; [ wireguard-tools ];
|
|
||||||
|
|
||||||
# Add the server using gnome-online-accounts:
|
# Add the server using gnome-online-accounts:
|
||||||
# nix-shell -p gnome.gnome-control-center --run "gnome-control-center"
|
# nix-shell -p gnome.gnome-control-center --run "gnome-control-center"
|
||||||
|
@ -90,26 +133,26 @@ in
|
||||||
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=1" "_netdev" ];
|
options = [ "x-systemd.automount" "x-systemd.mount-timeout=1" "_netdev" "noauto" "timeo=1" ];
|
||||||
};
|
};
|
||||||
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=1" "_netdev" ];
|
options = [ "x-systemd.automount" "x-systemd.mount-timeout=1" "_netdev" "noauto" "timeo=1" ];
|
||||||
};
|
};
|
||||||
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=1" "_netdev" ];
|
options = [ "x-systemd.automount" "x-systemd.mount-timeout=1" "_netdev" "noauto" "timeo=1" ];
|
||||||
};
|
};
|
||||||
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=1" "_netdev" ];
|
options = [ "x-systemd.automount" "x-systemd.mount-timeout=1" "_netdev" "noauto" "timeo=1" ];
|
||||||
};
|
};
|
||||||
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=1" "_netdev" ];
|
options = [ "x-systemd.automount" "x-systemd.mount-timeout=1" "_netdev" "noauto" "timeo=1" ];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,8 +1,13 @@
|
||||||
{ inputs, pkgs, ... }:
|
{ inputs, config, pkgs, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
# AMD GPU
|
# AMD CPU
|
||||||
boot.initrd.kernelModules = [ "amdgpu" ];
|
boot.blacklistedKernelModules = [ "k10temp" ];
|
||||||
|
boot.extraModulePackages = [ config.boot.kernelPackages.zenpower ];
|
||||||
|
boot.kernelModules = [ "zenpower" ];
|
||||||
|
|
||||||
|
# AMD CPU & GPU
|
||||||
|
boot.initrd.kernelModules = [ "amdgpu amd_pstate=active" ];
|
||||||
services.pcscd.enable = true;
|
services.pcscd.enable = true;
|
||||||
services.udev.packages = [ pkgs.yubikey-personalization ];
|
services.udev.packages = [ pkgs.yubikey-personalization ];
|
||||||
services.logind.extraConfig = ''
|
services.logind.extraConfig = ''
|
||||||
|
|
Loading…
Reference in New Issue