hosts/plover: move hardware config to be hosting provider-specific

This commit is contained in:
Gabriel Arazas 2023-01-14 15:55:30 +08:00
parent 62d220eb2d
commit 2e466e4561
2 changed files with 17 additions and 7 deletions

View File

@ -9,7 +9,10 @@ let
in
{
imports = [
./hardware-configuration.nix
# Since this will be rarely configured, make sure to import the appropriate
# hardware modules depending on the hosting provider (and even just the
# server).
./modules/hardware/hetzner-cloud-cx21.nix
# The users for this host.
(lib.getUser "nixos" "admin")

View File

@ -3,10 +3,6 @@
# Most of the filesystems listed here are supposed to be overriden to default
# settings of whatever image format configuration this host system will import
# from nixos-generators.
#
# Take note that this hardware configuration is mostly considered with Hetzner
# Cloud hardware server settings in mind. Be sure to replace it whenever you
# update your cloud provider.
{
imports = [
(modulesPath + "/profiles/qemu-guest.nix")
@ -35,6 +31,17 @@
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
networking.useDHCP = false;
networking.interfaces.ens3.useDHCP = true;
networking = {
useDHCP = false;
enableIPv6 = true;
dhcpcd.persistent = true;
interfaces = {
ens3 = {
useDHCP = true;
};
ens10.useDHCP = true;
};
};
}