Minimal with flake update

This commit is contained in:
2025-10-14 11:07:12 +02:00
parent c266448821
commit f8557c66ea
14 changed files with 178 additions and 310 deletions

View File

@@ -5,10 +5,18 @@
services.locate.enable = true;
services.openssh.enable = true;
hardware.enableAllFirmware = true;
# Nix fun
nixpkgs.config.allowUnfree = true;
nix.settings.experimental-features = [ "flakes" "nix-command" ];
programs.gnupg.agent = {
enable = true;
pinentryPackage = with pkgs; pinentry-all;
enableSSHSupport = true;
};
time.timeZone = "Europe/Berlin";
programs.nix-ld.enable = true; # Linking support
@@ -16,14 +24,16 @@
services.avahi.enable = true;
services.avahi.nssmdns4 = true;
environment = { systemPackages = with pkgs; [ xorg.xrandr git starship zoxide rsync ]; };
environment = {
systemPackages = with pkgs; [ yazi tmux git starship zoxide rsync ];
};
nix.optimise.automatic = true;
nix.gc = {
automatic = true;
dates = "weekly";
options = "--delete-older-than 14d"; # Two weeks cache then forget
options = "--delete-older-than 7d"; # Two weeks cache then forget
};
networking = { networkmanager = { enable = true; }; };

View File

@@ -6,10 +6,6 @@ in {
enableCuda = mkOption {
type = types.bool;
default = false;
description = ''
Enable CUDA support for Blender and other packages.
Warning: This can cause very long build times.
'';
};
nvidiaOpen = mkOption {
type = types.bool;
@@ -29,16 +25,5 @@ in {
nvidiaSettings = true;
package = config.boot.kernelPackages.nvidiaPackages.stable;
};
# Apply CUDA-specific settings if enabled
nixpkgs.config.cudaSupport = config.enableCuda;
hardware.enableAllFirmware = true;
environment.systemPackages = (if config.enableCuda then
[
(pkgs.blender.override { cudaSupport = true; })
]
else
[ ]);
};
}

View File

@@ -1,10 +0,0 @@
{ ... }:
{
imports = [ ../hardware/nvidia.nix ];
services.ollama = {
enable = true;
acceleration = "cuda";
};
}

View File

@@ -6,4 +6,6 @@
hardware.sane.extraBackends = [ pkgs.sane-airscan ];
hardware.sane.disabledDefaultBackends = [ "escl" ];
services.udev.packages = [ pkgs.sane-airscan ];
services.printing.enable = true;
}

View File

@@ -1,5 +0,0 @@
{ ... }:
{
services.printing.enable = true;
}

View File

@@ -1,34 +0,0 @@
{ ... }:
{
# For web mounting
services.davfs2.enable = true;
# Load the secret
sops = {
secrets = {
webdav_authstring = {
mode = "0600";
path = "/etc/davfs2/secrets";
};
};
};
systemd.mounts = [{
description = "Webdav mount point";
after = [ "network-online.target" ];
wants = [ "network-online.target" ];
what = "https://dav.hahn1.one";
where = "/webdav";
type = "davfs";
options = "uid=1000,gid=1000,file_mode=0664,dir_mode=2775,_netdev";
mountConfig.TimeoutSec = "5s";
}];
systemd.automounts = [{
description = "Webdav automount";
where = "/webdav";
wantedBy = [ "multi-user.target" ];
automountConfig = { TimeoutIdleSec = "2m"; };
}];
}