blob: 6daddfcd8e4123c3de98a69439b43d4dc8b9b4c8 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
|
{ config, pkgs, ... }:
let unstable = import <nixos-unstable> { config.allowUnfree = true; };
in {
imports =
[
./hardware-configuration.nix
<home-manager/nixos>
];
hardware.graphics.enable = true;
hardware.nvidia = {
modesetting.enable = true;
package = config.boot.kernelPackages.nvidiaPackages.stable;
nvidiaSettings = true;
open = true;
};
boot.kernelParams = [ "acpi_backlight=none" ];
boot.initrd.kernelModules = [ "nvidia" ];
boot.loader = {
grub = {
enable = true;
efiSupport = true;
devices = ["nodev"];
useOSProber = true;
extraEntries = ''
GRUB_SAVEDEFAULT=true
menuentry "Windows" {
insmod part_gpt
insmod fat
insmod search_fs_uuid
insmod chain
chainloader /EFI/Microsoft/Boot/bootmgfw.efi
}
menuentry "Reboot" {
reboot
}
menuentry "Poweroff" {
halt
}
'';
default = "saved";
theme = pkgs.stdenv.mkDerivation {
pname = "distro-grub-themes";
version = "3.1";
src = pkgs.fetchFromGitHub {
owner = "AdisonCavani";
repo = "distro-grub-themes";
rev = "v3.1";
hash = "sha256-ZcoGbbOMDDwjLhsvs77C7G7vINQnprdfI37a9ccrmPs=";
};
installPhase = "cp -r customize/hp $out";
};
};
efi.canTouchEfiVariables = true;
systemd-boot.enable = false;
};
system.activationScripts.diff = {
supportsDryActivation = true;
text = ''
${pkgs.nvd}/bin/nvd --nix-bin-dir=${pkgs.nix}/bin diff /run/current-system "$systemConfig"
'';
};
networking.hostName = "aargh-omen";
networking.networkmanager.enable = true;
time.timeZone = "Asia/Kolkata";
time.hardwareClockInLocalTime = true;
i18n.defaultLocale = "en_IN";
i18n.extraLocaleSettings = {
LC_ADDRESS = "en_IN";
LC_IDENTIFICATION = "en_IN";
LC_MEASUREMENT = "en_IN";
LC_MONETARY = "en_IN";
LC_NAME = "en_IN";
LC_NUMERIC = "en_IN";
LC_PAPER = "en_IN";
LC_TELEPHONE = "en_IN";
LC_TIME = "en_IN";
};
services.xserver.enable = true;
services.xserver.videoDrivers = [ "nvidia" ];
services.xserver.displayManager.gdm.enable = true;
services.xserver.desktopManager.gnome.enable = true;
services.xserver.xkb = {
layout = "us";
variant = "";
};
services.printing.enable = true;
services.pulseaudio.enable = false;
security.rtkit.enable = true;
services.pipewire = {
enable = true;
alsa.enable = true;
alsa.support32Bit = true;
pulse.enable = true;
};
services.ollama = {
enable = true;
acceleration = "cuda";
};
users.users.aargh = {
isNormalUser = true;
description = "Aargh";
extraGroups = [ "networkmanager" "wheel" ];
packages = with pkgs; [];
shell = pkgs.fish;
};
programs.fish.enable = true;
home-manager.users.aargh = { pkgs, ... }: {
programs.firefox.enable = true;
home.stateVersion = "25.05";
};
home-manager.backupFileExtension = "hm-backup";
nixpkgs.config.allowUnfree = true;
nixpkgs.config.cudaSupport = true;
nix.settings.experimental-features = "nix-command flakes";
# $ nix search wget
environment.systemPackages = with pkgs; [
fastfetch
vim
wget
git
nmap
dust
vscode
discord
localsend
bitwarden
gnome-tweaks
jetbrains.pycharm-professional
jetbrains.clion
gnome-tweaks
unstable.neovim
home-manager
zoxide
starship
tmux
cmake
gcc
cargo
python311
linuxPackages.nvidia_x11
unstable.cudaPackages.cuda_cudart
unstable.cudaPackages.cudatoolkit
];
#fuck - located here for quick navigation
environment.sessionVariables = {
CUDA_HOME = "${pkgs.cudatoolkit}";
CUDA_PATH = "${pkgs.cudatoolkit}";
LD_LIBRARY_PATH = "${pkgs.linuxPackages.nvidia_x11}/lib";
};
services.openssh.enable = true;
services.flatpak.enable = true;
services.mongodb = {
enable = true;
bind_ip = "127.0.0.1";
package = pkgs.mongodb;
};
# Open ports in the firewall.
networking.firewall.allowedTCPPorts = [ 53317 ];
networking.firewall.allowedUDPPorts = [ 53317 ];
# Or disable the firewall altogether.
# networking.firewall.enable = false;
# This value determines the NixOS release from which the default
# settings for stateful data, like file locations and database versions
# on your system were taken. It‘s perfectly fine and recommended to leave
# this value at the release version of the first install of this system.
# Before changing this value read the documentation for this option
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
system.stateVersion = "25.05"; # Did you read the comment?
}
|