hosts/hydra-2: add host
This commit is contained in:
parent
4027b812a2
commit
701f8bd41f
@ -66,6 +66,12 @@
|
||||
./hosts/hydra-1/configuration.nix
|
||||
];
|
||||
};
|
||||
hydra-2 = nixpkgs.lib.nixosSystem {
|
||||
system = "x86_64-linux";
|
||||
modules = [
|
||||
./hosts/hydra-2/configuration.nix
|
||||
];
|
||||
};
|
||||
minecraft-2 = nixpkgs.lib.nixosSystem {
|
||||
system = "x86_64-linux";
|
||||
modules = [
|
||||
|
34
hosts/hydra-2/configuration.nix
Normal file
34
hosts/hydra-2/configuration.nix
Normal file
@ -0,0 +1,34 @@
|
||||
{ config, pkgs, ... }:
|
||||
|
||||
{
|
||||
imports =
|
||||
[
|
||||
./hardware-configuration.nix
|
||||
../../configuration/common
|
||||
../../configuration/proxmox-vm
|
||||
];
|
||||
|
||||
boot.loader.grub.enable = true;
|
||||
boot.loader.grub.version = 2;
|
||||
boot.loader.grub.device = "/dev/vda";
|
||||
|
||||
networking.hostName = "hydra-2";
|
||||
|
||||
networking.useDHCP = false;
|
||||
networking.interfaces.ens18.ipv6.addresses = [ { address = "2001:638:904:ffc1::100"; prefixLength = 64; } ];
|
||||
networking.interfaces.ens18.ipv4.addresses = [ { address = "141.24.50.112"; prefixLength = 24; } ];
|
||||
networking.defaultGateway6 = { address = "mtr 2001:638:904:ffc1::1"; interface = "ens18"; };
|
||||
networking.defaultGateway = { address = "141.24.50.1"; interface = "ens18"; };
|
||||
networking.nameservers = [ "2001:638:904:ffcc::3" "2001:638:904:ffcc::4" "141.24.40.3" "141.24.40.4" ];
|
||||
|
||||
# Allow Hydra to fetch remote URLs in restricted mode
|
||||
nix.settings.allowed-uris = "http:// https://";
|
||||
|
||||
clerie.monitoring = {
|
||||
enable = true;
|
||||
id = "211";
|
||||
pubkey = "aWtxaM6GKhPwIJWRIQSqJwUa6nhfnD89JkkN9bt2NwE=";
|
||||
};
|
||||
|
||||
system.stateVersion = "22.11";
|
||||
}
|
32
hosts/hydra-2/hardware-configuration.nix
Normal file
32
hosts/hydra-2/hardware-configuration.nix
Normal file
@ -0,0 +1,32 @@
|
||||
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
||||
# and may be overwritten by future invocations. Please make changes
|
||||
# to /etc/nixos/configuration.nix instead.
|
||||
{ config, lib, pkgs, modulesPath, ... }:
|
||||
|
||||
{
|
||||
imports =
|
||||
[ (modulesPath + "/profiles/qemu-guest.nix")
|
||||
];
|
||||
|
||||
boot.initrd.availableKernelModules = [ "ata_piix" "uhci_hcd" "virtio_pci" "sr_mod" "virtio_blk" ];
|
||||
boot.initrd.kernelModules = [ ];
|
||||
boot.kernelModules = [ "kvm-intel" ];
|
||||
boot.extraModulePackages = [ ];
|
||||
|
||||
fileSystems."/" =
|
||||
{ device = "/dev/disk/by-uuid/8ca81275-100c-4c09-82b5-665b1542444f";
|
||||
fsType = "ext4";
|
||||
};
|
||||
|
||||
swapDevices = [ ];
|
||||
|
||||
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
|
||||
# (the default) this is the recommended approach. When using systemd-networkd it's
|
||||
# still possible to use this option, but it's recommended to use it in conjunction
|
||||
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
|
||||
networking.useDHCP = lib.mkDefault true;
|
||||
# networking.interfaces.ens18.useDHCP = lib.mkDefault true;
|
||||
# networking.interfaces.ens19.useDHCP = lib.mkDefault true;
|
||||
|
||||
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
||||
}
|
Loading…
Reference in New Issue
Block a user