Merge branch 'main' of github.com:asosnovsky/nixos-setup

This commit is contained in:
ari committed 2026-01-16 14:27:43 -05:00
commit 583d4e963b
11 files changed
+108 -101

No files matched your search

+1 -1
View File
@@ -69,7 +69,7 @@ def "main remote" [cmd:string, target:string = ""] {
return $valid_cmds return $valid_cmds
} }
$"($cmd) on ($target_host) with ($profile)" | print $"($cmd) on ($target_host) with ($profile)" | print
mut runcmd = $"nixos-rebuild --target-host ($target_host) --use-remote-sudo ($cmd) --flake .#($profile)" mut runcmd = $"nixos-rebuild --target-host ($target_host) --sudo ($cmd) --flake .#($profile)"
$runcmd | print $runcmd | print
bash -c $runcmd bash -c $runcmd
} }
+1 -1
View File
@@ -221,7 +221,7 @@ hotkey-overlay {
binds { binds {
Mod+Shift+H { show-hotkey-overlay; } Mod+Shift+H { show-hotkey-overlay; }
Mod+T { spawn "ghostty"; } Mod+T { spawn "ghostty"; }
Mod+Space { spawn "dms ipc call spotlight toggle"; } Mod+Space { spawn "dms" "ipc" "call" "spotlight" "toggle"; }
Mod+Z { spawn "flatpak" "run" "app.zen_browser.zen"; } Mod+Z { spawn "flatpak" "run" "app.zen_browser.zen"; }
Mod+B { spawn "chromium"; } Mod+B { spawn "chromium"; }
Mod+E { spawn "wofi-emoji"; } Mod+E { spawn "wofi-emoji"; }
+8 -8
View File
@@ -2,14 +2,14 @@ layout {
background-color "transparent" background-color "transparent"
focus-ring { focus-ring {
active-color "#42a5f5" active-color "#f9e2af"
inactive-color "#8c9199" inactive-color "#6c7086"
urgent-color "#f2b8b5" urgent-color "#f2b8b5"
} }
border { border {
active-color "#42a5f5" active-color "#f9e2af"
inactive-color "#8c9199" inactive-color "#6c7086"
urgent-color "#f2b8b5" urgent-color "#f2b8b5"
} }
@@ -18,19 +18,19 @@ layout {
} }
tab-indicator { tab-indicator {
active-color "#42a5f5" active-color "#f9e2af"
inactive-color "#8c9199" inactive-color "#6c7086"
urgent-color "#f2b8b5" urgent-color "#f2b8b5"
} }
insert-hint { insert-hint {
color "#42a5f580" color "#f9e2af80"
} }
} }
recent-windows { recent-windows {
highlight { highlight {
active-color "#0d47a1" active-color "#6e5a2f"
urgent-color "#f2b8b5" urgent-color "#f2b8b5"
} }
} }
Generated
+3 -3
View File
@@ -654,11 +654,11 @@
}, },
"nixos-hardware": { "nixos-hardware": {
"locked": { "locked": {
"lastModified": 1764440730, "lastModified": 1767185284,
"narHash": "sha256-ZlJTNLUKQRANlLDomuRWLBCH5792x+6XUJ4YdFRjtO4=", "narHash": "sha256-ljDBUDpD1Cg5n3mJI81Hz5qeZAwCGxon4kQW3Ho3+6Q=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixos-hardware", "repo": "nixos-hardware",
"rev": "9154f4569b6cdfd3c595851a6ba51bfaa472d9f3", "rev": "40b1a28dce561bea34858287fbb23052c3ee63fe",
"type": "github" "type": "github"
}, },
"original": { "original": {
+1 -2
View File
@@ -175,7 +175,6 @@
./hosts/hl-terra1.hardware-configuration.nix ./hosts/hl-terra1.hardware-configuration.nix
]; ];
}; };
} };
;
}; };
} }
+1 -1
View File
@@ -260,7 +260,7 @@ in
port = 11434; port = 11434;
acceleration = "rocm"; acceleration = "rocm";
rocmOverrideGfx = "11.0.2"; rocmOverrideGfx = "11.0.2";
package = unstablePkgs.ollama-rocm; # package = unstablePkgs.ollama-rocm;
}; };
# # Brother Printer # # Brother Printer
hardware.sane.brscan5.enable = true; hardware.sane.brscan5.enable = true;
@@ -13,7 +13,6 @@
boot.initrd.kernelModules = [ ]; boot.initrd.kernelModules = [ ];
boot.kernelModules = [ "kvm-amd" ]; boot.kernelModules = [ "kvm-amd" ];
boot.extraModulePackages = [ ]; boot.extraModulePackages = [ ];
fileSystems."/" = fileSystems."/" =
{ {
device = "/dev/disk/by-uuid/e903eb56-160d-4b77-ba66-ef54a18207f2"; device = "/dev/disk/by-uuid/e903eb56-160d-4b77-ba66-ef54a18207f2";
+22 -12
View File
@@ -1,5 +1,6 @@
{ pkgs { pkgs
, unstablePkgs , unstablePkgs
, lib
, ... , ...
}: }:
let let
@@ -18,7 +19,7 @@ in
user.enable = true; user.enable = true;
core.qemu.enable = true; core.qemu.enable = true;
nixos = { nixos = {
common.ssh-server.enable = true; common.ssh-server.enable = true;
common.hardware = { common.hardware = {
sound.enable = true; sound.enable = true;
pipewire.enable = true; pipewire.enable = true;
@@ -72,8 +73,7 @@ in
environment.systemPackages = environment.systemPackages =
(with pkgs; [ (with pkgs; [
# languages # languages
python313 # cargo
cargo
rustc rustc
go go
pipx pipx
@@ -85,6 +85,11 @@ in
# Steam # Steam
mangohud mangohud
# LLM Stuff
ollama-rocm
# stable-diffusion-cpp-rocm
lmstudio
]); ]);
services.usbmuxd.enable = true; services.usbmuxd.enable = true;
# Steam # Steam
@@ -106,20 +111,25 @@ in
hardware.xone.enable = true; # support for the xbox controller USB dongle hardware.xone.enable = true; # support for the xbox controller USB dongle
# Ollama # Ollama
services.open-webui.enable = true; services.open-webui.enable = true;
users.users.ollama = {
enable = true;
home = "/var/lib/ollama";
extraGroups = [
"render"
"video"
];
};
services.ollama = { services.ollama = {
enable = true; enable = true;
host = "0.0.0.0"; host = "0.0.0.0";
port = ports.ollama; port = ports.ollama;
acceleration = "rocm"; acceleration = "vulkan";
package = unstablePkgs.ollama-rocm; user = "ollama";
}; home = "/var/lib/ollama";
# Tabby rocmOverrideGfx = "gfx1151";
services.tabby = {
enable = true;
acceleration = "rocm";
host = "0.0.0.0";
port = ports.tabby;
}; };
hardware.graphics.enable = true;
hardware.amdgpu.opencl.enable = true;
environment.localBinInPath = true; environment.localBinInPath = true;
programs.nh = { programs.nh = {
enable = true; enable = true;
+65 -71
View File
@@ -11,6 +11,42 @@
}: }:
let let
skygUtils = import ./skyg-utils.nix; skygUtils = import ./skyg-utils.nix;
eachSystem = nixpkgs.lib.genAttrs (import systems);
allPkgs = eachSystem (
system:
import nixpkgs {
system = system;
config = {
allowUnfree = true;
};
}
);
# makeHomeManagerUsers =
# { modules ? [ ]
# , homeManagerVersion
# , user
# , system ? "x86_64-linux"
# ,
# }:
# let
# hm = (
# import ./home {
# stateVersion = homeManagerVersion;
# }makeHLServices
# );
# pkgs = allPkgs."${system}";
# in
# home-manager.lib.homeManagerConfiguration {
# inherit pkgs;
# modules = [
# (hm.makeCommonUser user)
# ]
# ++ modules;
# };
in
{
eachSystem = eachSystem;
pkgs = allPkgs;
makeNixOs = makeNixOs =
{ system ? "x86_64-linux" { system ? "x86_64-linux"
, hostName , hostName
@@ -38,77 +74,35 @@ let
}) })
] ++ configuration; ] ++ configuration;
}; };
eachSystem = nixpkgs.lib.genAttrs (import systems); makeDarwinModule =
allPkgs = eachSystem ( { system ? "x86_64-darwin"
system: , user
import nixpkgs { , homeManagerVersion ? "25.11"
system = system; , systemStateVersion ? "25.11"
config = { , hostName
allowUnfree = true; , configuration ? [ ]
}:
nix-darwin.lib.darwinSystem {
inherit system;
specialArgs = specialArgs // {
inherit system skygUtils user;
unstablePkgs = nixpkgs-unstable.legacyPackages.${system};
}; };
} modules = [
); determinate.darwinModules.default
# makeDarwinModule = home-manager.darwinModules.home-manager
# { system ? "x86_64-darwin" stylix.darwinModules.stylix
# , user (import ./macos.nix {
# , ... user = user;
# }@attrs: system = system;
# nix-darwin.lib.darwinSystem {
# modules =
# (makeImports {
# attrs = attrs;
# extraConfiguration = [
# home-manager.darwinModules.home-manager
# stylix.darwinModules.stylix
# ];
# })
# ++ [
# (import ./macos.nix {
# user = user;
# system = system;
# })
# ];
# };
# makeHomeManagerUsers =
# { modules ? [ ]
# , homeManagerVersion
# , user
# , system ? "x86_64-linux"
# ,
# }:
# let
# hm = (
# import ./home {
# stateVersion = homeManagerVersion;
# }makeHLServices
# );
# pkgs = allPkgs."${system}";
# in
# home-manager.lib.homeManagerConfiguration {
# inherit pkgs;
# modules = [
# (hm.makeCommonUser user)
# ]
# ++ modules;
# };
in
{
eachSystem = eachSystem;
pkgs = allPkgs;
makeNixOs = makeNixOs;
makeNixosConfigurations =
nodes:
builtins.listToAttrs (
builtins.map
({ hostName
, ...
}@attrs: {
name = hostName;
value = makeNixOs
{
inherit hostName;
} // attrs;
}) })
nodes (import ./main.nix {
); inherit
user
homeManagerVersion
hostName
systemStateVersion;
})
] ++ configuration;
};
} }
+5 -1
View File
@@ -1,8 +1,12 @@
{ user, system }: { user, system }:
{ pkgs, ... }: { { ... }: {
services.nix-daemon.enable = true; services.nix-daemon.enable = true;
security.pam.enableSudoTouchIdAuth = true; security.pam.enableSudoTouchIdAuth = true;
users.users.${user.name}.home = user.homepath; users.users.${user.name}.home = user.homepath;
users.users.root.home = "/var/root"; users.users.root.home = "/var/root";
nixpkgs.hostPlatform = system; nixpkgs.hostPlatform = system;
nix.enable = false;
determinate-nix.customSettings = {
flake-registry = "/etc/nix/flake-registry.json";
};
} }
+1
View File
@@ -20,6 +20,7 @@ in
# }; # };
environment.systemPackages = (with pkgs; [ environment.systemPackages = (with pkgs; [
rocmPackages.rocm-smi rocmPackages.rocm-smi
rocmPackages.rocminfo
rocmPackages.rpp rocmPackages.rpp
rocmPackages.rocm-core rocmPackages.rocm-core
rocmPackages.rocm-runtime rocmPackages.rocm-runtime