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

This commit is contained in:
ari committed 2024-07-31 11:31:51 -04:00
commit 6f980b2da3
9 files changed
+72 -33

No files matched your search

Generated
+15 -15
View File
@@ -28,11 +28,11 @@
]
},
"locked": {
"lastModified": 1721270582,
"narHash": "sha256-MdZmYPPExntE5rJu88IhJSy8Um4UyZCTXhOwvzbjDVI=",
"lastModified": 1722082646,
"narHash": "sha256-od8dBWVP/ngg0cuoyEl/w9D+TCNDj6Kh4tr151Aax7w=",
"owner": "LnL7",
"repo": "nix-darwin",
"rev": "a3e4a7b8ffc08c7dc1973822a77ad432e1ec3dec",
"rev": "0413754b3cdb879ba14f6e96915e5fdf06c6aab6",
"type": "github"
},
"original": {
@@ -43,11 +43,11 @@
},
"nixos-hardware": {
"locked": {
"lastModified": 1721331912,
"narHash": "sha256-h2yaU+QEU4pHxMySHPIsRV2T/pihDHnrXBca8BY6xgc=",
"lastModified": 1722114937,
"narHash": "sha256-MOZ9woPwdpFJcHx3wic2Mlw9aztdKjMnFT3FaeLzJkM=",
"owner": "NixOS",
"repo": "nixos-hardware",
"rev": "bb90787ea034c8b9035dfcfc9b4dc23898d414be",
"rev": "e67b60fb1b2c3aad2202d95b91d4c218cf2a4fdd",
"type": "github"
},
"original": {
@@ -59,11 +59,11 @@
},
"nixpkgs": {
"locked": {
"lastModified": 1721226092,
"narHash": "sha256-UBvzVpo5sXSi2S/Av+t+Q+C2mhMIw/LBEZR+d6NMjws=",
"lastModified": 1722087241,
"narHash": "sha256-2ShmEaFi0kJVOEEu5gmlykN5dwjWYWYUJmlRTvZQRpU=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "c716603a63aca44f39bef1986c13402167450e0a",
"rev": "8c50662509100d53229d4be607f1a3a31157fa12",
"type": "github"
},
"original": {
@@ -101,11 +101,11 @@
},
"unstable": {
"locked": {
"lastModified": 1721359386,
"narHash": "sha256-FsW0f9FpL9ECgA3d6iqk+OWhAuwR4zOvtP6Ibsfgrrw=",
"lastModified": 1722256103,
"narHash": "sha256-M8/qIGTrAw7M9syoid9fvziEvgaXvuXP1lx71Jy+wMA=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "20f734b3472ee06a29cb312c5da439c0089e258d",
"rev": "c4913a0ed9c3799ff87d06f90baf1498eec966dd",
"type": "github"
},
"original": {
@@ -122,11 +122,11 @@
]
},
"locked": {
"lastModified": 1721135958,
"narHash": "sha256-H548rpPMsn25LDKn1PCFmPxmWlClJJGnvdzImHkqjuY=",
"lastModified": 1722203588,
"narHash": "sha256-91V5FMSQ4z9bkhTCf0f86Zjw0bh367daSf0mzCIW0vU=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "afd2021bedff2de92dfce0e257a3d03ae65c603d",
"rev": "792757f643cedc13f02098d8ed506d82e19ec1da",
"type": "github"
},
"original": {
+16 -4
View File
@@ -43,10 +43,14 @@
};
homeManagerVersion = "24.05";
# Local Services
localNixCaches = [
"http://minipc1.lab.internal:5000"
"http://fwlaptop.devices.internal:5000"
];
localNixCaches = {
urls = [
"http://minipc1.lab.internal:5000"
];
keys = [
"minipc1.lab.internal:eIoib1JgcBEd0YKdW95QlRA2eCKDs+WxNhWhkA1wffc="
];
};
localDockerRegistries = [ "minipc1.lab.internal:5001" ];
# Libs
lib = (import modules/lib.nix {
@@ -186,5 +190,13 @@
configuration = (import ./hosts/hl-minipc2.nix { user = user; });
systemStateVersion = "24.05";
};
# NIXOS Homelab - terramaster 1
# -------------
nixosConfigurations."hl-terra1" = makeHLService {
hostName = "hl-terra1";
configuration = (import ./hosts/hl-terra1.nix { user = user; });
systemStateVersion = "24.05";
};
};
}
+7
View File
@@ -36,6 +36,13 @@ in
# python
python312
];
# Opengl
hardware.opengl = {
driSupport = true;
driSupport32Bit = true;
extraPackages = [ pkgs.amdvlk ];
extraPackages32 = [ pkgs.driversi686Linux.amdvlk ];
};
# Gaming
programs.gamescope.enable = true;
programs.steam = {
+11
View File
@@ -59,4 +59,15 @@
nvidiaSettings = false;
package = config.boot.kernelPackages.nvidiaPackages.production;
};
# Steam Settings
programs.steam = {
enable = true;
remotePlay.openFirewall = true;
dedicatedServer.openFirewall = true;
localNetworkGameTransfers.openFirewall = true;
};
environment.systemPackages = with pkgs; [
steam-tui
steamPackages.steamcmd
];
}
+5
View File
@@ -1,6 +1,11 @@
{ user }:
{ pkgs, lib, config, ... }: {
imports = [ ./hl-minipc1.hardware-configuration.nix ];
# Nix Stores
services.nix-serve = {
enable = true;
secretKeyFile = "/var/keys/cache-priv-key.pem";
};
# firmware updater
services.fwupd.enable = true;
# Bootloader.
+10
View File
@@ -0,0 +1,10 @@
{ user }:
{ pkgs, lib, config, ... }: {
imports = [ ./hl-minipc2.hardware-configuration.nix ];
# firmware updater
services.fwupd.enable = true;
# Bootloader.
boot.loader.systemd-boot.enable = true;
boot.loader.efi.canTouchEfiVariables = true;
}
+3 -9
View File
@@ -21,11 +21,10 @@ in
};
home-manager.users.${user.name} = {
home = {
sessionVariables = { MAMBA_ROOT_PREFIX = "$HOME/.local/micromamba"; };
sessionVariables = { };
stateVersion = version;
shellAliases = {
cat = "bat";
conda = "micromamba";
};
packages = with pkgs;
[ jq nixfmt-classic devenv ipfetch nixd ]
@@ -33,7 +32,6 @@ in
rye
uv
devbox
micromamba
terraform
kubectl
] else
@@ -75,13 +73,9 @@ in
zsh = {
enable = true;
autosuggestion.enable = true;
initExtra = (if enableDevelopmentKit then ''
export MAMBA_ROOT_PREFIX="$HOME/.local/micromamba"
source <(micromamba shell hook --root-prefix=$MAMBA_ROOT_PREFIX)
initExtra = ''
export PROMPT='%(!.%{%F{yellow}%}.)$USER@%{$fg[white]%}%M %{$fg[cyan]%}%c%{$reset_color%} $(git_prompt_info)'
'' else ''
export PROMPT='%(!.%{%F{yellow}%}.)$USER@%{$fg[white]%}%M %{$fg[cyan]%}%c%{$reset_color%} $(git_prompt_info)'
'');
'';
};
zsh.oh-my-zsh = {
enable = true;
+1 -1
View File
@@ -17,7 +17,7 @@
enable = false;
enableDevelopmentKit = false;
}
, localNixCaches ? [ ]
, localNixCaches ? { keys = [ ]; urls = [ ]; }
, ...
}:
{ ... }: {
+4 -4
View File
@@ -1,4 +1,4 @@
{ user, systemStateVersion, localNixCaches ? [ ] }:
{ user, systemStateVersion, localNixCaches ? { keys = [ ]; urls = [ ]; } }:
{ pkgs, ... }:
{
# Nix core
@@ -10,16 +10,16 @@
"https://cache.nixos.org"
"https://cache.flox.dev"
"https://devenv.cachix.org"
] ++ localNixCaches;
] ++ localNixCaches.urls;
trusted-substituters = [
"https://cache.flox.dev"
"https://devenv.cachix.org"
] ++ localNixCaches;
] ++ localNixCaches.urls;
trusted-users = [ "root" user.name ];
trusted-public-keys = [
"flox-cache-public-1:7F4OyH7ZCnFhcze3fJdfyXYLQw/aV7GEed86nQ7IsOs="
"devenv.cachix.org-1:w1cLUi8dv3hnoSPGAuibQv+f9TZLr6cv/Hm9XgU50cw="
];
] ++ localNixCaches.keys;
};
# System Packages