diff --git a/ops/nixos/bvm-netbox/default.nix b/ops/nixos/bvm-netbox/default.nix new file mode 100644 index 0000000000..0f543a8729 --- /dev/null +++ b/ops/nixos/bvm-netbox/default.nix @@ -0,0 +1,28 @@ +# SPDX-FileCopyrightText: 2020 Luke Granger-Brown +# +# SPDX-License-Identifier: Apache-2.0 + +{ config, ... }: +{ + imports = [ + ../lib/bvm.nix + ]; + + # Networking! + networking = { + hostName = "bvm-netbox"; + hostId = "e70e18a5"; + + interfaces.enp1s0 = { + ipv4.addresses = [{ address = "10.100.0.206"; prefixLength = 23; }]; + }; + interfaces.enp6s0 = { + ipv4.addresses = [{ address = "92.118.28.8"; prefixLength = 24; }]; + ipv6.addresses = [{ address = "2a09:a441::8"; prefixLength = 32; }]; + }; + defaultGateway = { address = "92.118.28.1"; interface = "enp6s0"; }; + defaultGateway6 = { address = "2a09:a441::1"; interface = "enp6s0"; }; + }; + + system.stateVersion = "21.05"; +} diff --git a/ops/nixos/default.nix b/ops/nixos/default.nix index 436fe2f5db..aa6684964f 100644 --- a/ops/nixos/default.nix +++ b/ops/nixos/default.nix @@ -40,6 +40,7 @@ let "bvm-ipfs" "bvm-matrix" "bvm-minecraft" + "bvm-netbox" ]; rebuilder = system: (import ./lib/rebuilder.nix (args // { system = system; })); systemCfgs = lib.genAttrs systems diff --git a/ops/nixos/installcd/default.nix b/ops/nixos/installcd/default.nix index 6e9e7d3610..0a96b8ca63 100644 --- a/ops/nixos/installcd/default.nix +++ b/ops/nixos/installcd/default.nix @@ -13,7 +13,7 @@ in { isoImage.isoName = lib.mkForce "nixos-${depot.version}-${pkgs.stdenv.hostPlatform.system}.iso"; isoImage.storeContents = [ - depot.ops.nixos.systems.bvm-minecraft + depot.ops.nixos.systems.bvm-netbox ]; system.stateVersion = "21.05"; diff --git a/ops/nixos/lib/coredns/zones/db.1.4.4.a.9.0.a.2.ip6.arpa b/ops/nixos/lib/coredns/zones/db.1.4.4.a.9.0.a.2.ip6.arpa index f545efcde2..61ee15f5e2 100644 --- a/ops/nixos/lib/coredns/zones/db.1.4.4.a.9.0.a.2.ip6.arpa +++ b/ops/nixos/lib/coredns/zones/db.1.4.4.a.9.0.a.2.ip6.arpa @@ -3,7 +3,7 @@ ; SPDX-License-Identifier: Apache-2.0 ; MNAME RNAME SERIAL REFRESH RETRY EXPIRE TTL -@ 600 IN SOA frantech-lux01.as205479.net. hostmaster.lukegb.com. 9 600 450 3600 300 +@ 600 IN SOA frantech-lux01.as205479.net. hostmaster.lukegb.com. 10 600 450 3600 300 $INCLUDE tmpl.ns @@ -13,7 +13,7 @@ $INCLUDE tmpl.ns 5.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0 3600 IN PTR bvm-nixosmgmt.public.as205479.net. 6.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0 3600 IN PTR bvm-matrix.public.as205479.net. 7.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0 3600 IN PTR bvm-minecraft.public.as205479.net. -8.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0 3600 IN PTR bvm-plesk.public.as205479.net. +8.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0 3600 IN PTR bvm-netbox.public.as205479.net. 1.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0 3600 IN PTR gw.public.as205479.net. e.f.f.f.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0 3600 IN PTR blade-paris.public.as205479.net. f.f.f.f.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0 3600 IN PTR blade-tuvok.public.as205479.net. diff --git a/ops/nixos/lib/coredns/zones/db.28.118.92.in-addr.arpa b/ops/nixos/lib/coredns/zones/db.28.118.92.in-addr.arpa index 1431f8a905..734ee82136 100644 --- a/ops/nixos/lib/coredns/zones/db.28.118.92.in-addr.arpa +++ b/ops/nixos/lib/coredns/zones/db.28.118.92.in-addr.arpa @@ -3,7 +3,7 @@ ; SPDX-License-Identifier: Apache-2.0 ; MNAME RNAME SERIAL REFRESH RETRY EXPIRE TTL -@ 600 IN SOA frantech-lux01.as205479.net. hostmaster.lukegb.com. 11 600 450 3600 300 +@ 600 IN SOA frantech-lux01.as205479.net. hostmaster.lukegb.com. 12 600 450 3600 300 $INCLUDE tmpl.ns @@ -15,7 +15,7 @@ $INCLUDE tmpl.ns 5 600 IN PTR bvm-nixosmgmt.as205479.net. 6 600 IN PTR bvm-matrix.as205479.net. 7 600 IN PTR bvm-minecraft.as205479.net. -8 600 IN PTR bvm-plesk.as205479.net. +8 600 IN PTR bvm-netbox.as205479.net. 9 600 IN PTR 92-118-28-9.ptr.as205479.net. 10 600 IN PTR 92-118-28-10.ptr.as205479.net. 11 600 IN PTR 92-118-28-11.ptr.as205479.net. diff --git a/ops/nixos/lib/coredns/zones/db.as205479.net b/ops/nixos/lib/coredns/zones/db.as205479.net index 82755c2642..46b9a98647 100644 --- a/ops/nixos/lib/coredns/zones/db.as205479.net +++ b/ops/nixos/lib/coredns/zones/db.as205479.net @@ -3,7 +3,7 @@ ; SPDX-License-Identifier: Apache-2.0 ; MNAME RNAME SERIAL REFRESH RETRY EXPIRE TTL -@ 600 IN SOA frantech-lux01.as205479.net. hostmaster.lukegb.com. 24 600 450 3600 300 +@ 600 IN SOA frantech-lux01.as205479.net. hostmaster.lukegb.com. 25 600 450 3600 300 ; NB: this are also glue records in Google Domains. $INCLUDE tmpl.ns @@ -110,6 +110,7 @@ bvm-prosody.blade 3600 IN A 10.100.0.202 bvm-ipfs.blade 3600 IN A 10.100.0.203 bvm-win10.blade 3600 IN A 10.100.0.204 bvm-matrix.blade 3600 IN A 10.100.0.205 +bvm-netbox.blade 3600 IN A 10.100.0.206 ; services ; ceph-mon: blade-tuvok, blade-janeway, blade-paris @@ -146,9 +147,9 @@ bvm-matrix 3600 IN AAAA 2a09:a441::6 bvm-minecraft.public 3600 IN CNAME bvm-minecraft.as205479.net. bvm-minecraft 3600 IN A 92.118.28.7 bvm-minecraft 3600 IN AAAA 2a09:a441::7 -bvm-plesk.public 3600 IN CNAME bvm-plesk.as205479.net. -bvm-plesk 3600 IN A 92.118.28.8 -bvm-plesk 3600 IN AAAA 2a09:a441::8 +bvm-netbox.public 3600 IN CNAME bvm-netbox.as205479.net. +bvm-netbox 3600 IN A 92.118.28.8 +bvm-netbox 3600 IN AAAA 2a09:a441::8 92-118-28-0.ptr 6000 IN A 92.118.28.0 92-118-28-1.ptr 6000 IN A 92.118.28.1