igor: Adapt disk layout
This commit is contained in:
parent
a029bd12e4
commit
685d8ade01
3 changed files with 58 additions and 31 deletions
|
|
@ -13,36 +13,35 @@
|
||||||
../../modules/timezone.nix
|
../../modules/timezone.nix
|
||||||
../../modules/keybase.nix
|
../../modules/keybase.nix
|
||||||
../../modules/ssh.nix
|
../../modules/ssh.nix
|
||||||
|
../../modules/tailscale
|
||||||
./disko-config.nix
|
./disko-config.nix
|
||||||
|
./hardware-configuration.nix
|
||||||
];
|
];
|
||||||
|
|
||||||
config.networking =
|
config.networking = {
|
||||||
let
|
hostName = "igor";
|
||||||
extIface = "ens3";
|
domain = "failco.de";
|
||||||
in
|
wireless.enable = false;
|
||||||
{
|
useDHCP = false;
|
||||||
hostName = "igor";
|
enableIPv6 = false;
|
||||||
domain = "failco.de";
|
networkmanager.enable = true;
|
||||||
wireless.enable = false;
|
interfaces.eth0 = {
|
||||||
useDHCP = false;
|
ipv4.addresses = [
|
||||||
enableIPv6 = false;
|
{
|
||||||
interfaces.${extIface} = {
|
address = "192.168.178.2";
|
||||||
ipv4.addresses = [
|
prefixLength = 24;
|
||||||
{
|
}
|
||||||
address = "192.168.0.2";
|
|
||||||
prefixLength = 24;
|
|
||||||
}
|
|
||||||
];
|
|
||||||
};
|
|
||||||
defaultGateway = "192.168.0.1";
|
|
||||||
nameservers = [
|
|
||||||
"192.168.0.1"
|
|
||||||
"1.1.1.1"
|
|
||||||
"8.8.8.8"
|
|
||||||
];
|
];
|
||||||
|
|
||||||
firewall.enable = true;
|
|
||||||
};
|
};
|
||||||
|
defaultGateway = "192.168.178.1";
|
||||||
|
nameservers = [
|
||||||
|
"192.168.178.1"
|
||||||
|
"1.1.1.1"
|
||||||
|
"8.8.8.8"
|
||||||
|
];
|
||||||
|
|
||||||
|
firewall.enable = true;
|
||||||
|
};
|
||||||
|
|
||||||
config.security.sudo = {
|
config.security.sudo = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
|
@ -72,5 +71,5 @@
|
||||||
|
|
||||||
config.programs.zsh.enable = true;
|
config.programs.zsh.enable = true;
|
||||||
|
|
||||||
config.system.stateVersion = "24.05";
|
config.system.stateVersion = "24.11";
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -2,10 +2,14 @@
|
||||||
disko.devices = {
|
disko.devices = {
|
||||||
disk.main = {
|
disk.main = {
|
||||||
type = "disk";
|
type = "disk";
|
||||||
device = "/dev/mmcblk0";
|
device = "/dev/sda";
|
||||||
content = {
|
content = {
|
||||||
type = "gpt";
|
type = "gpt";
|
||||||
partitions = {
|
partitions = {
|
||||||
|
boot = {
|
||||||
|
size = "1M";
|
||||||
|
type = "EF02";
|
||||||
|
};
|
||||||
ESP = {
|
ESP = {
|
||||||
priority = 1;
|
priority = 1;
|
||||||
name = "ESP";
|
name = "ESP";
|
||||||
|
|
@ -26,18 +30,32 @@
|
||||||
extraArgs = [ "-f" ];
|
extraArgs = [ "-f" ];
|
||||||
|
|
||||||
subvolumes = {
|
subvolumes = {
|
||||||
"/rootfs" = { mountpoint = "/"; };
|
"/rootfs" = {
|
||||||
|
mountpoint = "/";
|
||||||
|
mountOptions = [
|
||||||
|
"compress=zstd"
|
||||||
|
"noatime"
|
||||||
|
];
|
||||||
|
};
|
||||||
"/home" = {
|
"/home" = {
|
||||||
mountOptions = [ "compress=zstd" ];
|
mountOptions = [
|
||||||
|
"compress=zstd"
|
||||||
|
"noatime"
|
||||||
|
];
|
||||||
mountpoint = "/home";
|
mountpoint = "/home";
|
||||||
};
|
};
|
||||||
"/nix" = {
|
"/nix" = {
|
||||||
mountOptions = [ "compress=zstd" "noatime" ];
|
mountOptions = [
|
||||||
|
"compress=zstd"
|
||||||
|
"noatime"
|
||||||
|
];
|
||||||
mountpoint = "/nix";
|
mountpoint = "/nix";
|
||||||
};
|
};
|
||||||
"/swap" = {
|
"/swap" = {
|
||||||
mountpoint = "/.swapvol";
|
mountpoint = "/.swapvol";
|
||||||
swap = { swapfile.size = "2G"; };
|
swap = {
|
||||||
|
swapfile.size = "2G";
|
||||||
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
||||||
10
hosts/igor/hardware-configuration.nix
Normal file
10
hosts/igor/hardware-configuration.nix
Normal file
|
|
@ -0,0 +1,10 @@
|
||||||
|
{
|
||||||
|
config,
|
||||||
|
lib,
|
||||||
|
pkgs,
|
||||||
|
...
|
||||||
|
}:
|
||||||
|
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
Loading…
Add table
Add a link
Reference in a new issue