From 1163568fcf6712a431e8f2b77eda9ab581be3f1a Mon Sep 17 00:00:00 2001 From: Erwin Boskma Date: Fri, 9 Dec 2022 10:40:13 +0100 Subject: [PATCH] Enable hidpi, configure libinput, enable nvidia support in docker --- machines/mimir/configuration.nix | 15 ++++++++++--- machines/mimir/hardware-configuration.nix | 27 +++++++++-------------- 2 files changed, 22 insertions(+), 20 deletions(-) diff --git a/machines/mimir/configuration.nix b/machines/mimir/configuration.nix index a93e88f..dcf28f3 100644 --- a/machines/mimir/configuration.nix +++ b/machines/mimir/configuration.nix @@ -41,13 +41,20 @@ enable = true; home-manager = true; }; - docker.enable = true; + docker = { + enable = true; + enableNvidia = true; + enableTcpSocket = true; + }; fonts.enable = true; gnome.enable = true; # greetd.enable = true; lightdm.enable = true; networking.enable = true; - nix-common.enable = true; + nix-common = { + enable = true; + cross-systems = [ "aarch64-linux" ]; + }; sound.enable = true; systemd.enable = true; }; @@ -79,6 +86,9 @@ 12345 5555 5556 + + # sccache server + 10501 ]; }; }; @@ -141,4 +151,3 @@ system.stateVersion = "22.11"; # Did you read the comment? } - diff --git a/machines/mimir/hardware-configuration.nix b/machines/mimir/hardware-configuration.nix index 157b30e..6b51c19 100644 --- a/machines/mimir/hardware-configuration.nix +++ b/machines/mimir/hardware-configuration.nix @@ -39,11 +39,12 @@ powerManagement.cpuFreqGovernor = "ondemand"; hardware = { - video.hidpi.enable = false; + video.hidpi.enable = true; enableAllFirmware = true; nvidia.modesetting.enable = true; opengl = { + driSupport32Bit = true; extraPackages = with pkgs; [ vaapiVdpau ]; @@ -53,25 +54,17 @@ services.xserver = { videoDrivers = [ "nvidia" ]; - # Section "Screen" - # Identifier "Screen0" - # Device "Device0" - # Monitor "Monitor0" - # DefaultDepth 24 - # Option "Stereo" "0" - # Option "nvidiaXineramaInfoOrder" "DFP-2" - # Option "metamodes" "DP-4: nvidia-auto-select +3840+0 {ForceCompositionPipeline=On, ForceFullCompositionPipeline=On, AllowGSYNCCompatible=On}, DP-0: nvidia-auto-select +0+0 {ForceCompositionPipeline=On, ForceFullCompositionPipeline=On, AllowGSYNCCompatible=On}" - # Option "SLI" "Off" - # Option "MultiGPU" "Off" - # Option "BaseMosaic" "off" - # SubSection "Display" - # Depth 24 - # EndSubSection - # EndSection - screenSection = '' Option "metamodes" "DP-0: nvidia-auto-select +0+0 {ForceFullCompositionPipeline=On, AllowGSYNCCompatible=On}, DP-4: nvidia-auto-select +3840+0 {ForceFullCompositionPipeline=On, AllowGSYNCCompatible=On}" Option "TripleBuffer" "On" ''; + + libinput = { + enable = true; + mouse = { + naturalScrolling = true; + accelSpeed = "1.0"; + }; + }; }; }