Add host-configuration.nix example

This commit is contained in:
NullBite 2023-12-26 01:52:13 -05:00
parent 5a8d1d37de
commit 791e059a69
Signed by: nullbite
GPG Key ID: 6C4D545385D4925A
3 changed files with 31 additions and 2 deletions

1
.gitignore vendored
View File

@ -1 +1,2 @@
hardware-configuration.nix
host-configuration.nix

View File

@ -11,7 +11,7 @@
./hardware-configuration.nix
# manually defined device specific configuration
./custom-hardware-configuration.nix
./host-configuration.nix
];
# Use the systemd-boot EFI boot loader.
@ -21,7 +21,6 @@
# networking.hostName = "nixos"; # Define your hostname.
networking.hostName = "slab";
# Pick only one of the below networking options.
# networking.wireless.enable = true; # Enables wireless support via wpa_supplicant.
networking.networkmanager.enable = true; # Easiest to use and most distros use this by default.

View File

@ -0,0 +1,29 @@
{ config, lib, pkgs, modulesPath, ... }:
{
### set hostname
# networking.hostname = "hostname";
# cryptsetup
boot.initrd.luks.devices = {
lvmroot = {
# device="/dev/disk/by-uuid/<UUID>";
allowDiscards = true;
fallbackToPassword = true;
preLVM = true;
};
};
# bootloader setup
boot.loader = {
efi = {
canTouchEfiVariables = true;
# efiSysMountPoint = "/efi";
};
grub = {
enable = true;
efiSupport = true;
device = "nodev";
};
};
}