Created
April 30, 2020 19:58
-
-
Save tokudan/181b3a9f032e14fc23cac7dfded2a27b to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
firstserver = { | |
deployment.targetEnv = "hetzner"; | |
deployment.storeKeysOnMachine = false; | |
deployment.hetzner.mainIPv4 = "1.2.3.4"; | |
deployment.hetzner.partitions = '' | |
clearpart --all --initlabel | |
part raid.11 --size=1024 --ondisk=sda | |
part raid.21 --size=1024 --ondisk=sdb | |
raid /boot --fstype=ext3 --device=boot --label=boot --level=RAID1 raid.11 raid.21 | |
part raid.12 --size=196608 --ondisk=sda | |
part raid.22 --size=196608 --ondisk=sdb | |
raid / --fstype=ext3 --device=root --label=root --level=RAID1 raid.12 raid.22 | |
part raid.13 --size=16384 --ondisk=sda | |
part raid.23 --size=16384 --ondisk=sdb | |
raid swap --fstype=swap --device=swap --label=swap --level=RAID1 raid.13 raid.23 | |
''; | |
# Network addresses are also specific to this system... | |
networking.interfaces.eth0.ipv6.addresses = [ { | |
address = "2a01::2"; | |
prefixLength = 64; | |
} ]; | |
networking.nameservers = [ | |
"8.8.8.8" | |
]; | |
# This is hardware-specific: | |
services.smartd.enable = true; | |
}; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ ... }: | |
{ | |
network.enableRollback = true; | |
firstserver = { | |
imports = [ | |
./machines/firstserver/default.nix # this is the configuration.nix for the server | |
]; | |
}; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment