-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathconfiguration.nix
159 lines (143 loc) · 3.35 KB
/
configuration.nix
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
# This is your system's configuration file
# Use this to configure your system environment (it replaces /etc/nixos/configuration.nix)
{ config, pkgs, ... }:
{
imports = [
# Import your generated (nixos-generate-config) hardware configuration
./hardware-configuration.nix
];
nix = {
settings = {
# Enable flakes and new 'nix' command
experimental-features = "nix-command flakes";
# Deduplicate and optimize nix store
auto-optimise-store = true;
};
gc = {
# Enable automatic garbage collection
automatic = true;
dates = "weekly";
options = "--delete-older-than 30d";
};
};
nixpkgs = {
config = {
# Disable if you don't want unfree packages
allowUnfree = true;
};
};
networking = {
hostName = "awo";
nameservers = [ "1.1.1.1" "1.0.0.1" ];
};
# Use whatever bootloader you prefer
boot.loader.systemd-boot.enable = true;
security.polkit.enable = true;
virtualisation.docker.enable = true;
services = {
pipewire = {
enable = true;
alsa.enable = true;
alsa.support32Bit = true;
pulse.enable = true;
# If you want to use JACK applications, uncomment this
#jack.enable = true;
};
openssh = {
enable = true;
settings = {
# Forbid root login through SSH.
permitRootLogin = "no";
# Use keys only. Remove if you want to SSH using password (not recommended)
passwordAuthentication = false;
};
};
};
environment = {
shells = with pkgs; [ fish ];
systemPackages = with pkgs; [
btop
neofetch
ncdu
zoxide
neovim
wget
curl
rar
zip
unzip
ffmpeg
ffmpegthumbnailer
openjdk
xray
tun2socks
docker-compose
waybar
];
};
programs = {
sway.enable = true;
waybar.enable=true;
thefuck.enable = true;
git = {
enable = true;
config = {
user.name = "awohsen";
user.email = "[email protected]";
init.defaultBranch = "main";
};
};
zsh = {
enable = true;
ohMyZsh = {
enable = true;
theme = "gozilla";
plugins = [ "git" "sudo" "docker" "zoxide" "dirhistory"];
};
enableCompletion = true;
autosuggestions.enable = true;
syntaxHighlighting.enable = true;
};
};
users.users = {
# Replace with your username
awohsen = {
shell = pkgs.zsh;
isNormalUser = true;
initialPassword = "p@ssw0rd";
openssh.authorizedKeys.keys = [
# Add your SSH public key(s) here, if you plan on using SSH to connect
];
#Be sure to add any other groups you need (such as networkmanager, audio, docker, etc)
extraGroups = [ "wheel" "docker"];
packages = with pkgs; [
firefox
tdesktop
keepassxc
vscode
kitty
alacritty
];
};
};
fonts.fonts = with pkgs; [
corefonts
ubuntu_font_family
powerline-fonts
font-awesome
source-code-pro
noto-fonts
noto-fonts-cjk
noto-fonts-emoji
emojione
kanji-stroke-order-font
ipafont
liberation_ttf
mplus-outline-fonts.githubRelease
dina-font
proggyfonts
jetbrains-mono
];
# https://nixos.wiki/wiki/FAQ/When_do_I_update_stateVersion
system.stateVersion = "22.11";
}