-
Notifications
You must be signed in to change notification settings - Fork 0
/
miner.nix
181 lines (162 loc) · 3.11 KB
/
miner.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
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
{ config, pkgs, ... }:
{
#
# ==> miner <==
#
imports = [
./hardware-configuration.nix
./private.nix
];
system = {
copySystemConfiguration = true;
};
boot = {
loader = {
systemd-boot.enable = true;
efi.canTouchEfiVariables = true;
grub.device = /dev/sda;
grub.memtest86 = true;
};
};
i18n = {
consoleFont = "Lat2-Terminus16";
consoleKeyMap = "us";
defaultLocale = "en_US.UTF-8";
};
hardware = {
trackpoint = {
enable = true;
sensitivity = 40;
speed = 40;
fakeButtons = false;
};
pulseaudio = {
enable = false;
};
};
networking = {
useDHCP = true;
firewall = {
enable = true;
allowedTCPPorts = [ 22 ];
allowPing = true;
};
};
security.sudo = {
enable = true;
wheelNeedsPassword = false;
};
time = {
timeZone = "America/New_York";
hardwareClockInLocalTime = true;
};
nixpkgs.config = {
allowUnfree = true;
allowBroken = true;
cudaSupport = true;
enableCuda = true;
};
services = {
openssh.enable = true;
xserver = {
videoDrivers = [ "nvidia" ];
enable = true;
layout = "us";
autorun = true;
desktopManager.plasma5.enable = true;
displayManager.sddm.enable = true;
};
ethminer = {
enable = true;
pool = "eth-us-east1.nanopool.org";
maxPower = 113;
recheckInterval = 2000;
toolkit = "cuda";
apiPort = -3333;
rig = "RIG";
wallet = "WALLET";
registerMail = "EMAIL";
};
};
environment = {
variables = {
NIX_PATH = pkgs.lib.mkOverride 0 "nixpkgs=/etc/nixos/nixpkgs:nixos-config=/etc/nixos/configuration.nix";
#NIX_PATH = pkgs.lib.mkOverride 0 "nixpkgs=/nix/var/nix/profiles/per-user/root/channels/nixos:nixos-config=/etc/nixos/configuration.nix";
BROWSER = "google-chrome-stable";
EDITOR = "vim";
};
interactiveShellInit = ''
alias vi="vim-with-plugins"
export PS1="\[$(tput setaf 10)\]\h \[$(tput setaf 13)\]\$(git branch 2>/dev/null | grep '^*' | colrm 1 2) \[$(tput setaf 12)\]\$PWD \[$(tput setaf 5)\]:\[$(tput sgr0)\]\T\[$(tput setaf 5)\]: \[$(tput sgr0)\]";
'';
systemPackages = with pkgs; [
wget
curl
bind
sysstat
vnstat
dstat
htop
screen
tmux
mosh
nmap
zip
unzip
iftop
iptraf-ng
bmon
tcptrack
nethogs
speedtest-cli
vim
lsof
pciutils
tcpdump
netcat
jwhois
strace
openvpn
git
ruby
python3
gnupg
parted
hdparm
gparted
dmidecode
screen
smartmontools
openssl
file
gcc
binutils
kdiff3
vpnc
openconnect
jq
traceroute
atop
libffi
exiftool
libpqxx
groff
sddm
cmake
boost
libofx
iotop
atop
ctop
ftop
lsscsi
lshw
# GUI
xscreensaver
spectacle
wireshark
firefox
google-chrome
];
};
}