move the mk-network into the proxmox-vm
This commit is contained in:
parent
8606bc412a
commit
89345cb548
|
@ -1,19 +0,0 @@
|
||||||
{ hostname, ip, ... }:
|
|
||||||
{
|
|
||||||
networking = {
|
|
||||||
useDHCP = false;
|
|
||||||
hostName = hostname;
|
|
||||||
hosts = {
|
|
||||||
"127.0.0.1" = [ "${hostname}.2li.local" ];
|
|
||||||
ip = [ "${hostname}.2li.local" ];
|
|
||||||
};
|
|
||||||
defaultGateway = "10.7.89.1";
|
|
||||||
nameservers = [ "10.7.89.2" ];
|
|
||||||
interfaces.ens18.ipv4.addresses = [
|
|
||||||
{
|
|
||||||
address = ip;
|
|
||||||
prefixLength = 24;
|
|
||||||
}
|
|
||||||
];
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -1,8 +1,22 @@
|
||||||
{ inputs, hostname, ip, ... }:
|
{ inputs, hostname, ip, ... }:
|
||||||
{
|
{
|
||||||
imports = [
|
networking = {
|
||||||
(import "${inputs.self}/modules/mk-network" { inherit hostname ip; })
|
useDHCP = false;
|
||||||
];
|
hostName = hostname;
|
||||||
|
hosts = {
|
||||||
|
"127.0.0.1" = [ "${hostname}.2li.local" ];
|
||||||
|
ip = [ "${hostname}.2li.local" ];
|
||||||
|
};
|
||||||
|
defaultGateway = "10.7.89.1";
|
||||||
|
nameservers = [ "10.7.89.2" ];
|
||||||
|
interfaces.ens18.ipv4.addresses = [
|
||||||
|
{
|
||||||
|
address = ip;
|
||||||
|
prefixLength = 24;
|
||||||
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
boot.initrd.availableKernelModules = [
|
boot.initrd.availableKernelModules = [
|
||||||
"ata_piix"
|
"ata_piix"
|
||||||
"uhci_hcd"
|
"uhci_hcd"
|
||||||
|
@ -27,12 +41,5 @@
|
||||||
swapDevices = [
|
swapDevices = [
|
||||||
{ device = "/dev/disk/by-label/swap"; }
|
{ device = "/dev/disk/by-label/swap"; }
|
||||||
];
|
];
|
||||||
|
|
||||||
# Inspired by
|
|
||||||
# https://github.com/NixOS/nixpkgs/blob/master/nixos/modules/profiles/minimal.nix
|
|
||||||
environment.noXlibs = true;
|
|
||||||
documentation.enable = false;
|
|
||||||
documentation.nixos.enable = false;
|
|
||||||
programs.command-not-found.enable = false;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user