From 0aa8ba4345966879a1e80573bdeeac72f3cd8f18 Mon Sep 17 00:00:00 2001 From: chayleaf Date: Thu, 19 Oct 2023 12:15:25 +0700 Subject: [PATCH] hydra: increase cpu usage limit; add minimal fish config --- home/common/fish.nix | 2 +- system/hosts/server/home.nix | 6 +++--- system/modules/common.nix | 11 ++++++++++- 3 files changed, 14 insertions(+), 5 deletions(-) diff --git a/home/common/fish.nix b/home/common/fish.nix index 40ee7cc..f7fa37d 100644 --- a/home/common/fish.nix +++ b/home/common/fish.nix @@ -88,7 +88,7 @@ set -gx NOMCOMPAT ${nom-compat} # for posix compatibility - set -gx SHELL zsh + set -gx SHELL ${pkgs.zsh}/bin/zsh set -g fish_color_autosuggestion 777 brblack set -g fish_color_command green diff --git a/system/hosts/server/home.nix b/system/hosts/server/home.nix index 5066820..899a19a 100644 --- a/system/hosts/server/home.nix +++ b/system/hosts/server/home.nix @@ -161,14 +161,14 @@ in { } ]; nix.distributedBuilds = true; - # limit CI CPU usage since I'm running everything else off this server too - systemd.services.nix-daemon.serviceConfig.CPUQuota = "100%"; + # limit CI CPU usage to 30% since I'm running everything else off this server too + systemd.services.nix-daemon.serviceConfig.CPUQuota = "240%"; nix.daemonCPUSchedPolicy = "idle"; nix.daemonIOSchedClass = "idle"; systemd.services.hydra-evaluator = lib.mkIf config.services.hydra.enable { # https://github.com/NixOS/hydra/issues/1186 environment.GC_DONT_GC = "1"; - serviceConfig.CPUQuota = "100%"; + serviceConfig.CPUQuota = "240%"; serviceConfig.CPUSchedulingPolicy = "idle"; serviceConfig.IOSchedulingClass = "idle"; }; diff --git a/system/modules/common.nix b/system/modules/common.nix index 5708bfb..5a88a29 100644 --- a/system/modules/common.nix +++ b/system/modules/common.nix @@ -100,7 +100,16 @@ in { kitty.terminfo # rxvt-unicode-unwrapped.terminfo ]); - # TODO: minimal fish config + programs.fish.interactiveShellInit = lib.mkIf cfg.minimal '' + set -gx SHELL ${pkgs.zsh}/bin/zsh + set -g fish_color_autosuggestion 777 brblack + set -g fish_color_command green + set -g fish_color_operator white + set -g fish_color_param white + set -g fish_key_bindings fish_vi_key_bindings + set -g fish_cursor_insert line + set -g fish_cursor_replace underscore + ''; programs.vim = lib.mkIf cfg.minimal { defaultEditor = lib.mkDefault true; package = pkgs.vim-full.customize {