Compare commits

..

1 Commits

Author SHA1 Message Date
h7x4
f502a8ce4f kommode/gitea: add robots.txt 2025-12-30 00:34:26 +09:00
11 changed files with 126 additions and 857 deletions

View File

@@ -1,32 +0,0 @@
name: "Build topology graph"
on:
push:
branches:
- main
jobs:
evals:
runs-on: debian-latest
steps:
- uses: actions/checkout@v6
- name: Install sudo
run: apt-get update && apt-get -y install sudo
- uses: https://github.com/cachix/install-nix-action@v31
- name: Configure Nix
run: echo -e "show-trace = true\nmax-jobs = auto\ntrusted-users = root\nexperimental-features = nix-command flakes\nbuild-users-group =" > /etc/nix/nix.conf
- name: Build topology graph
run: nix build .#topology -L
- name: Upload topology graph
uses: https://git.pvv.ntnu.no/Projects/rsync-action@v2
with:
source: result/*.svg
quote-source: false
target: ${{ gitea.ref_name }}/topology_graph/
username: gitea-web
ssh-key: ${{ secrets.WEB_SYNC_SSH_KEY }}
host: pages.pvv.ntnu.no
known-hosts: "pages.pvv.ntnu.no ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIH2QjfFB+city1SYqltkVqWACfo1j37k+oQQfj13mtgg"

168
flake.lock generated
View File

@@ -1,26 +1,5 @@
{ {
"nodes": { "nodes": {
"devshell": {
"inputs": {
"nixpkgs": [
"nix-topology",
"nixpkgs"
]
},
"locked": {
"lastModified": 1728330715,
"narHash": "sha256-xRJ2nPOXb//u1jaBnDP56M7v5ldavjbtR6lfGqSvcKg=",
"owner": "numtide",
"repo": "devshell",
"rev": "dd6b80932022cea34a019e2bb32f6fa9e494dfef",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "devshell",
"type": "github"
}
},
"disko": { "disko": {
"inputs": { "inputs": {
"nixpkgs": [ "nixpkgs": [
@@ -42,40 +21,6 @@
"type": "github" "type": "github"
} }
}, },
"flake-compat": {
"flake": false,
"locked": {
"lastModified": 1696426674,
"narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=",
"owner": "edolstra",
"repo": "flake-compat",
"rev": "0f9255e01c2351cc7d116c072cb317785dd33b33",
"type": "github"
},
"original": {
"owner": "edolstra",
"repo": "flake-compat",
"type": "github"
}
},
"flake-utils": {
"inputs": {
"systems": "systems"
},
"locked": {
"lastModified": 1726560853,
"narHash": "sha256-X6rJYSESBVr3hBoH0WbKE5KvhPU5bloyZ2L4K60/fPQ=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "c1dfcf08411b08f6b8615f7d8971a2bfa81d5e8a",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "flake-utils",
"type": "github"
}
},
"gergle": { "gergle": {
"inputs": { "inputs": {
"nixpkgs": [ "nixpkgs": [
@@ -97,28 +42,6 @@
"url": "https://git.pvv.ntnu.no/Grzegorz/gergle.git" "url": "https://git.pvv.ntnu.no/Grzegorz/gergle.git"
} }
}, },
"gitignore": {
"inputs": {
"nixpkgs": [
"nix-topology",
"pre-commit-hooks",
"nixpkgs"
]
},
"locked": {
"lastModified": 1709087332,
"narHash": "sha256-HG2cCnktfHsKV0s4XW83gU3F57gaTljL9KNSuG6bnQs=",
"owner": "hercules-ci",
"repo": "gitignore.nix",
"rev": "637db329424fd7e46cf4185293b9cc8c88c95394",
"type": "github"
},
"original": {
"owner": "hercules-ci",
"repo": "gitignore.nix",
"type": "github"
}
},
"greg-ng": { "greg-ng": {
"inputs": { "inputs": {
"nixpkgs": [ "nixpkgs": [
@@ -247,37 +170,13 @@
"url": "https://git.pvv.ntnu.no/Drift/nix-gitea-themes.git" "url": "https://git.pvv.ntnu.no/Drift/nix-gitea-themes.git"
} }
}, },
"nix-topology": {
"inputs": {
"devshell": "devshell",
"flake-utils": "flake-utils",
"nixpkgs": [
"nixpkgs"
],
"pre-commit-hooks": "pre-commit-hooks"
},
"locked": {
"lastModified": 1765969653,
"narHash": "sha256-qVpQxyvdByeDfb+d+jhbyNna2Ie+w85iHpt4Qu0rv/E=",
"owner": "oddlama",
"repo": "nix-topology",
"rev": "0ed73e5a1b65eb8ed388d070ebe8dedb9182f466",
"type": "github"
},
"original": {
"owner": "oddlama",
"ref": "main",
"repo": "nix-topology",
"type": "github"
}
},
"nixpkgs": { "nixpkgs": {
"locked": { "locked": {
"lastModified": 1767043167, "lastModified": 1764806471,
"narHash": "sha256-wN04/SL+8tV0D2HBIgt9dpX/03U18xoJ+8PT+dcn30E=", "narHash": "sha256-Qk0SArnS83KqyS9wNt1YoTkkYKDraNrjRWKUtB9DKoM=",
"rev": "0b43a6ee07997a6e319e92dcbf276c2736506944", "rev": "6707b1809330d0f912f5813963bb29f6f194ee81",
"type": "tarball", "type": "tarball",
"url": "https://releases.nixos.org/nixos/25.11-small/nixos-25.11.2789.0b43a6ee0799/nixexprs.tar.xz" "url": "https://releases.nixos.org/nixos/25.11-small/nixos-25.11.896.6707b1809330/nixexprs.tar.xz"
}, },
"original": { "original": {
"type": "tarball", "type": "tarball",
@@ -286,44 +185,17 @@
}, },
"nixpkgs-unstable": { "nixpkgs-unstable": {
"locked": { "locked": {
"lastModified": 1767031366, "lastModified": 1764854611,
"narHash": "sha256-SJz8tVEnXusU8OzN5ixAXQgzXv8fNIzp9ztzUyobh4s=", "narHash": "sha256-MVzFp4ZKwdh6U1wy4fJe/GY3Hb4cvvyJbAZOhaeBQoo=",
"rev": "d23fedd87fcd067b1d160323fae0d0e4f995527d", "rev": "3a4b875aef660bbd148e86b92cffea2a360c3275",
"type": "tarball", "type": "tarball",
"url": "https://releases.nixos.org/nixos/unstable-small/nixos-26.05pre918279.d23fedd87fcd/nixexprs.tar.xz" "url": "https://releases.nixos.org/nixos/unstable-small/nixos-26.05pre906534.3a4b875aef66/nixexprs.tar.xz"
}, },
"original": { "original": {
"type": "tarball", "type": "tarball",
"url": "https://nixos.org/channels/nixos-unstable-small/nixexprs.tar.xz" "url": "https://nixos.org/channels/nixos-unstable-small/nixexprs.tar.xz"
} }
}, },
"pre-commit-hooks": {
"inputs": {
"flake-compat": "flake-compat",
"gitignore": "gitignore",
"nixpkgs": [
"nix-topology",
"nixpkgs"
],
"nixpkgs-stable": [
"nix-topology",
"nixpkgs"
]
},
"locked": {
"lastModified": 1730797577,
"narHash": "sha256-SrID5yVpyUfknUTGWgYkTyvdr9J1LxUym4om3SVGPkg=",
"owner": "cachix",
"repo": "pre-commit-hooks.nix",
"rev": "1864030ed24a2b8b4e4d386a5eeaf0c5369e50a9",
"type": "github"
},
"original": {
"owner": "cachix",
"repo": "pre-commit-hooks.nix",
"type": "github"
}
},
"pvv-calendar-bot": { "pvv-calendar-bot": {
"inputs": { "inputs": {
"nixpkgs": [ "nixpkgs": [
@@ -352,11 +224,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1767080188, "lastModified": 1765978548,
"narHash": "sha256-BmyPuWeSQ9XREyi0KSerWRfJndmyzHNJLysBJld/KwA=", "narHash": "sha256-VDSPpw+/Mgo+JujoW12CRlkTs9o0tX/FEL2AR5kl5+Q=",
"ref": "main", "ref": "main",
"rev": "08a216f4473e26aa2a5349e72633c0ab24e8ffbd", "rev": "961f021d27f86b2aedd16290dbf85bdd9d50fd42",
"revCount": 534, "revCount": 532,
"type": "git", "type": "git",
"url": "https://git.pvv.ntnu.no/Projects/nettsiden.git" "url": "https://git.pvv.ntnu.no/Projects/nettsiden.git"
}, },
@@ -376,7 +248,6 @@
"minecraft-heatmap": "minecraft-heatmap", "minecraft-heatmap": "minecraft-heatmap",
"minecraft-kartverket": "minecraft-kartverket", "minecraft-kartverket": "minecraft-kartverket",
"nix-gitea-themes": "nix-gitea-themes", "nix-gitea-themes": "nix-gitea-themes",
"nix-topology": "nix-topology",
"nixpkgs": "nixpkgs", "nixpkgs": "nixpkgs",
"nixpkgs-unstable": "nixpkgs-unstable", "nixpkgs-unstable": "nixpkgs-unstable",
"pvv-calendar-bot": "pvv-calendar-bot", "pvv-calendar-bot": "pvv-calendar-bot",
@@ -446,21 +317,6 @@
"repo": "sops-nix", "repo": "sops-nix",
"type": "github" "type": "github"
} }
},
"systems": {
"locked": {
"lastModified": 1681028828,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
"owner": "nix-systems",
"repo": "default",
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
"type": "github"
},
"original": {
"owner": "nix-systems",
"repo": "default",
"type": "github"
}
} }
}, },
"root": "root", "root": "root",

View File

@@ -11,9 +11,6 @@
disko.url = "github:nix-community/disko/v1.11.0"; disko.url = "github:nix-community/disko/v1.11.0";
disko.inputs.nixpkgs.follows = "nixpkgs"; disko.inputs.nixpkgs.follows = "nixpkgs";
nix-topology.url = "github:oddlama/nix-topology/main";
nix-topology.inputs.nixpkgs.follows = "nixpkgs";
pvv-nettsiden.url = "git+https://git.pvv.ntnu.no/Projects/nettsiden.git?ref=main"; pvv-nettsiden.url = "git+https://git.pvv.ntnu.no/Projects/nettsiden.git?ref=main";
pvv-nettsiden.inputs.nixpkgs.follows = "nixpkgs"; pvv-nettsiden.inputs.nixpkgs.follows = "nixpkgs";
@@ -153,6 +150,12 @@
self.nixosModules.bluemap self.nixosModules.bluemap
]; ];
}; };
bob = stableNixosConfig "bob" {
modules = [
disko.nixosModules.disko
{ disko.devices.disk.disk1.device = "/dev/vda"; }
];
};
ildkule = stableNixosConfig "ildkule" { }; ildkule = stableNixosConfig "ildkule" { };
#ildkule-unstable = unstableNixosConfig "ildkule" { }; #ildkule-unstable = unstableNixosConfig "ildkule" { };
shark = stableNixosConfig "shark" { }; shark = stableNixosConfig "shark" { };
@@ -164,6 +167,7 @@
]; ];
modules = [ modules = [
inputs.nix-gitea-themes.nixosModules.default inputs.nix-gitea-themes.nixosModules.default
self.nixosModules.robots-txt
]; ];
}; };
@@ -243,54 +247,14 @@
bluemap = pkgs.callPackage ./packages/bluemap.nix { }; bluemap = pkgs.callPackage ./packages/bluemap.nix { };
out-of-your-element = pkgs.callPackage ./packages/out-of-your-element.nix { }; out-of-your-element = pkgs.callPackage ./packages/out-of-your-element.nix { };
} } //
//
# Mediawiki extensions
(lib.pipe null [ (lib.pipe null [
(_: pkgs.callPackage ./packages/mediawiki-extensions { }) (_: pkgs.callPackage ./packages/mediawiki-extensions { })
(lib.flip builtins.removeAttrs ["override" "overrideDerivation"]) (lib.flip builtins.removeAttrs ["override" "overrideDerivation"])
(lib.mapAttrs' (name: lib.nameValuePair "mediawiki-${name}")) (lib.mapAttrs' (name: lib.nameValuePair "mediawiki-${name}"))
]) ])
// // lib.genAttrs allMachines
# Machines (machine: self.nixosConfigurations.${machine}.config.system.build.toplevel);
lib.genAttrs allMachines
(machine: self.nixosConfigurations.${machine}.config.system.build.toplevel)
//
# Nix-topology
(let
topology' = import inputs.nix-topology {
pkgs = import nixpkgs {
system = "x86_64-linux";
overlays = [ inputs.nix-topology.overlays.default ];
};
specialArgs = {
values = import ./values.nix;
};
modules = [
./topology
{
nixosConfigurations = lib.mapAttrs (_name: nixosCfg: nixosCfg.extendModules {
modules = [
inputs.nix-topology.nixosModules.default
./topology/service-extractors/greg-ng.nix
];
}) self.nixosConfigurations;
}
];
};
in {
topology = topology'.config.output;
topology-png = pkgs.runCommand "pvv-config-topology-png" {
nativeBuildInputs = [ pkgs.writableTmpDirAsHomeHook ];
} ''
mkdir -p "$out"
for file in '${topology'.config.output}'/*.svg; do
${lib.getExe pkgs.imagemagick} -density 300 -background none "$file" "$out"/"$(basename "''${file%.svg}.png")"
done
'';
});
}; };
}; };
} }

View File

@@ -58,11 +58,7 @@ in {
max-y = 90; max-y = 90;
}]; }];
marker-sets = { marker-sets = {
_includes = [ (format.lib.mkInclude { _includes = [ (format.lib.mkInclude "${bluemap-export}/nether.hocon") ];
required = true;
type = "file";
value = "${bluemap-export}/nether.hocon";
}) ];
}; };
}; };
}; };

View File

@@ -193,6 +193,109 @@ in {
}; };
}; };
environment.robots-txt."gitea" = {
virtualHost = domain;
rules = [
{
pre_comment = ''
Gitea internals
See these for more information:
- https://gitea.com/robots.txt
- https://codeberg.org/robots.txt
'';
User-agent = "*";
Disallow = [
"/api/*"
"/avatars"
"/*/*/src/commit/*"
"/*/*/commit/*"
"/*/*/*/refs/*"
"/*/*/*/star"
"/*/*/*/watch"
"/*/*/labels"
"/*/*/activity/*"
"/vendor/*"
"/swagger.*.json"
"/repo/create"
"/repo/migrate"
"/org/create"
"/*/*/fork"
"/*/*/watchers"
"/*/*/stargazers"
"/*/*/forks"
"*/.git/"
"/*.git"
"/*.atom"
"/*.rss"
];
}
{
pre_comment = "Language Spam";
Disallow = "/*?lang=";
}
{
pre_comment = ''
AI bots
Sourced from:
- https://www.vg.no/robots.txt
- https://codeberg.org/robots.txt
'';
User-agent = [
"AI2Bot"
"Ai2Bot-Dolma"
"Amazonbot"
"Applebot-Extended"
"Bytespider"
"CCBot"
"ChatGPT-User"
"Claude-Web"
"ClaudeBot"
"Crawlspace"
"Diffbot"
"FacebookBot"
"FriendlyCrawler"
"GPTBot"
"Google-Extended"
"ICC-Crawler"
"ImagesiftBot"
"Kangaroo Bot"
"Meta-ExternalAgent"
"OAI-SearchBot"
"Omgili"
"Omgilibot"
"PanguBot"
"PerplexityBot"
"PetalBot"
"Scrapy"
"SemrushBot-OCOB"
"Sidetrade indexer bot"
"Timpibot"
"VelenPublicWebCrawler"
"Webzio-Extended"
"YouBot"
"anthropic-ai"
"cohere-ai"
"cohere-training-data-crawler"
"facebookexternalhit"
"iaskspider/2.0"
"img2dataset"
"meta-externalagent"
"omgili"
"omgilibot"
];
Disallow = "/";
}
{
Crawl-delay = "2";
}
{
Sitemap = "https://${domain}/sitemap.xml";
}
];
};
networking.firewall.allowedTCPPorts = [ sshPort ]; networking.firewall.allowedTCPPorts = [ sshPort ];
systemd.services.gitea-dump = { systemd.services.gitea-dump = {

View File

@@ -1,240 +0,0 @@
{ config, pkgs, lib, values, ... }:
let
inherit
(config.lib.topology)
mkInternet
mkRouter
mkSwitch
mkDevice
mkConnection
mkConnectionRev;
in {
imports = [
./non-nixos-machines.nix
];
### Networks
networks.pvv = {
name = "PVV Network";
cidrv4 = values.ipv4-space;
cidrv6 = values.ipv6-space;
};
networks.site-vpn = {
name = "OpenVPN Site to Site";
style = {
primaryColor = "#9dd68d";
secondaryColor = null;
pattern = "dashed";
};
};
networks.ntnu = {
name = "NTNU";
cidrv4 = values.ntnu.ipv4-space;
cidrv6 = values.ntnu.ipv6-space;
};
nodes.internet = mkInternet {
connections = mkConnection "ntnu" "wan1";
};
nodes.ntnu = mkRouter "NTNU" {
interfaceGroups = [ ["wan1"] ["eth1" "eth2" "eth3"] ];
connections.eth1 = mkConnection "ntnu-pvv-router" "wan1";
connections.eth2 = mkConnection "ntnu-veggen" "wan1";
connections.eth3 = mkConnection "stackit" "*";
interfaces.eth1.network = "ntnu";
};
### Brus
nodes.ntnu-pvv-router = mkRouter "NTNU PVV Gateway" {
interfaceGroups = [ ["wan1"] ["eth1"] ];
connections.eth1 = mkConnection "knutsen" "em1";
interfaces.eth1.network = "pvv";
};
nodes.knutsen = mkRouter "knutsen" {
deviceIcon = "${pkgs.super-tiny-icons}/share/icons/SuperTinyIcons/svg/freebsd.svg";
interfaceGroups = [ ["em0"] ["em1"] ["vpn1"] ];
connections.em0 = mkConnection "nintendo" "eth0";
# connections.vpn1 = mkConnection "ludvigsen" "vpn1";
interfaces.vpn1.network = "site-vpn";
interfaces.vpn1.virtual = true;
interfaces.vpn1.icon = "${pkgs.super-tiny-icons}/share/icons/SuperTinyIcons/svg/openvpn.svg";
interfaces.em0.network = "pvv";
interfaces.em1.network = "ntnu";
};
nodes.nintendo = mkSwitch "Nintendo (brus switch)" {
interfaceGroups = [ (lib.genList (i: "eth${toString i}") 16) ];
connections = let
connections' = [
(mkConnection "bekkalokk" "enp2s0")
# (mkConnection "bicep" "enp6s0f0") # NOTE: physical machine is dead at the moment
(mkConnection "buskerud" "eth1")
# (mkConnection "knutsen" "eth1")
(mkConnection "powerpuff-cluster" "eth1")
(mkConnection "lupine-1" "enp0s31f6")
(mkConnection "lupine-2" "enp0s31f6")
(mkConnection "lupine-3" "enp0s31f6")
(mkConnection "lupine-4" "enp0s31f6")
(mkConnection "lupine-5" "enp0s31f6")
(mkConnection "innovation" "em0")
(mkConnection "microbel" "eth0")
(mkConnection "isvegg" "eth0")
(mkConnection "ameno" "eth0")
(mkConnection "sleipner" "eno0")
];
in
assert (lib.length connections' <= 15);
builtins.listToAttrs (
lib.zipListsWith
(a: b: lib.nameValuePair a b)
(lib.genList (i: "eth${toString (i + 1)}") 15)
connections'
);
};
nodes.buskerud = mkDevice "buskerud" {
deviceIcon = ./icons/proxmox.svg;
interfaceGroups = [ [ "eth1" ] ];
interfaces.eth1.network = "pvv";
};
nodes.shark = {
guestType = "proxmox";
parent = config.nodes.buskerud.id;
interfaces.ens18.network = "pvv";
};
### Powerpuff
nodes.powerpuff-cluster = mkDevice "Powerpuff Cluster" {
deviceIcon = ./icons/proxmox.svg;
hardware.info = "Dell PowerEdge R730 x 3";
interfaceGroups = [ [ "eth1" ] ];
};
nodes.kommode = {
guestType = "proxmox";
parent = config.nodes.powerpuff-cluster.id;
interfaces.ens18.network = "pvv";
};
nodes.bicep = {
guestType = "proxmox";
parent = config.nodes.powerpuff-cluster.id;
# hardware.info = "HP Proliant DL370G6";
interfaces.ens18.network = "pvv";
};
nodes.ustetind = {
guestType = "proxmox LXC";
parent = config.nodes.powerpuff-cluster.id;
# TODO: the interface name is likely wrong
# interfaceGroups = [ [ "eth0" ] ];
interfaces.eth0 = {
network = "pvv";
# mac = "";
addresses = [
"129.241.210.234"
"2001:700:300:1900::234"
];
gateways = [
values.hosts.gateway
values.hosts.gateway6
];
};
};
### PVV
nodes.ntnu-veggen = mkRouter "NTNU-Veggen" {
interfaceGroups = [ ["wan1"] ["eth1"] ];
connections.eth1 = mkConnection "ludvigsen" "re0";
};
nodes.ludvigsen = mkRouter "ludvigsen" {
deviceIcon = "${pkgs.super-tiny-icons}/share/icons/SuperTinyIcons/svg/freebsd.svg";
interfaceGroups = [ [ "re0" ] [ "em0" ] [ "vpn1" ] ];
connections.em0 = mkConnection "pvv-switch" "eth0";
interfaces.vpn1.network = "site-vpn";
interfaces.vpn1.virtual = true;
interfaces.vpn1.icon = "${pkgs.super-tiny-icons}/share/icons/SuperTinyIcons/svg/openvpn.svg";
interfaces.re0.network = "ntnu";
interfaces.em0.network = "pvv";
};
nodes.pvv-switch = mkSwitch "PVV Switch (Terminalrommet)" {
interfaceGroups = [ (lib.genList (i: "eth${toString i}") 16) ];
connections = let
connections' = [
(mkConnection "brzeczyszczykiewicz" "eno1")
(mkConnection "georg" "eno1")
(mkConnection "wegonke" "enp4s0")
(mkConnection "demiurgen" "eno1")
(mkConnection "sanctuary" "ethernet_0")
(mkConnection "torskas" "eth0")
(mkConnection "skrott" "eth0")
(mkConnection "homeassistant" "eth0")
(mkConnection "orchid" "eth0")
(mkConnection "principal" "em0")
];
in
assert (lib.length connections' <= 15);
builtins.listToAttrs (
lib.zipListsWith
(a: b: lib.nameValuePair a b)
(lib.genList (i: "eth${toString (i + 1)}") 15)
connections'
);
};
### Openstack
nodes.stackit = mkDevice "stackit" {
interfaceGroups = [ [ "*" ] ];
interfaces."*".network = "ntnu";
};
nodes.ildkule = {
guestType = "openstack";
parent = config.nodes.stackit.id;
interfaces.ens4.network = "ntnu";
};
nodes.wenche = {
guestType = "openstack";
parent = config.nodes.stackit.id;
interfaces.ens18.network = "pvv";
};
nodes.bakke = {
guestType = "openstack";
parent = config.nodes.stackit.id;
interfaces.enp2s0.network = "pvv";
};
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 40 KiB

View File

@@ -1,5 +0,0 @@
<?xml version="1.0" encoding="utf-8"?><!-- Uploaded to: SVG Repo, www.svgrepo.com, Generator: SVG Repo Mixer Tools -->
<svg width="800px" height="800px" viewBox="0 0 1024 1024" xmlns="http://www.w3.org/2000/svg">
<circle cx="512" cy="512" r="512" style="fill:#e57000"/>
<path d="M512 497.8 342.7 311.6c6.6-6.6 14.2-11.7 22.9-15.5 8.7-3.8 18.1-5.7 28.1-5.7 10.7.1 20.4 2.2 29.3 6.3 8.9 4.1 16.6 9.8 23.1 17l65.8 71.9 65.4-71.9c6.8-7.2 14.7-12.9 23.6-17 9-4.1 18.7-6.2 29.2-6.3 10 .1 19.4 2 28.1 5.7 8.7 3.8 16.4 8.9 22.9 15.5L512 497.8m0 28.4L342.7 712.4c6.6 6.6 14.2 11.7 22.9 15.5 8.7 3.8 18.1 5.7 28.1 5.7 10.5-.1 20.2-2.2 29.2-6.3s16.9-9.8 23.6-17l65.4-71.9 65.8 71.9c6.5 7.2 14.2 12.9 23.1 17 8.9 4.1 18.6 6.2 29.3 6.3 10-.1 19.4-2 28.1-5.7 8.7-3.8 16.4-8.9 22.9-15.5L512 526.2M497.8 512 370.3 372.2c-7.4-7.9-16-14.1-25.9-18.7-9.8-4.5-20.5-6.8-31.9-6.9-11 .1-21.3 2.2-30.8 6.3-9.6 4.1-17.9 9.8-25.1 16.9L385.9 512 256.5 654.2c7.2 7.4 15.6 13.2 25.1 17.4 9.6 4.2 19.8 6.3 30.8 6.3 11.5-.1 22.2-2.4 32.1-6.9 9.9-4.5 18.5-10.8 25.7-18.7L497.8 512m28.4 0 127.5 140.3c7.2 7.9 15.8 14.1 25.7 18.7 9.9 4.5 20.6 6.8 32.1 6.9 11-.1 21.3-2.2 30.8-6.3 9.6-4.2 17.9-9.9 25.1-17.4L638.1 512l129.4-142.2c-7.2-7.2-15.6-12.8-25.1-16.9-9.6-4.1-19.8-6.2-30.8-6.3-11.4.1-22.1 2.4-31.9 6.9-9.8 4.5-18.5 10.8-25.9 18.7L526.2 512" style="fill:#fff"/>
</svg>

Before

Width:  |  Height:  |  Size: 1.3 KiB

View File

@@ -1,362 +0,0 @@
{ config, pkgs, lib, values, ... }:
let
inherit (config.lib.topology) mkDevice;
in {
nodes.balduzius = mkDevice "balduzius" {
guestType = "proxmox";
parent = config.nodes.powerpuff-cluster.id;
deviceIcon = "${pkgs.super-tiny-icons}/share/icons/SuperTinyIcons/svg/debian.svg";
interfaceGroups = [ [ "ens18" ] ];
interfaces.ens18 = {
network = "pvv";
mac = "00:0c:29:de:05:0f";
addresses = [
"129.241.210.192"
"2001:700:300:1900::1:42"
];
gateways = [
values.hosts.gateway
values.hosts.gateway6
];
};
services = {
kdc = {
name = "Heimdal KDC";
info = "kdc.pvv.ntnu.no";
details.kdc.text = "0.0.0.0:88";
details.kpasswd.text = "0.0.0.0:464";
};
};
};
nodes.tom = mkDevice "tom" {
guestType = "proxmox";
parent = config.nodes.powerpuff-cluster.id;
deviceIcon = "${pkgs.super-tiny-icons}/share/icons/SuperTinyIcons/svg/debian.svg";
interfaceGroups = [ [ "ens18" ] ];
interfaces.ens18 = {
network = "pvv";
mac = "00:0c:29:4d:f7:56";
addresses = [
"129.241.210.180"
"2001:700:300:1900::180"
];
gateways = [
values.hosts.gateway
values.hosts.gateway6
];
};
services = {
apache2 = {
name = "Apache2 - user websites";
info = "www.pvv.ntnu.no/~";
details.listen.text = "0.0.0.0:443";
};
};
};
nodes.hildring = mkDevice "hildring" {
guestType = "proxmox";
parent = config.nodes.powerpuff-cluster.id;
deviceType = "loginbox";
deviceIcon = "${pkgs.super-tiny-icons}/share/icons/SuperTinyIcons/svg/debian.svg";
interfaceGroups = [ [ "eth0" ] ];
interfaces.eth0 = {
network = "pvv";
mac = "00:0c:29:e7:dd:79";
addresses = [
"129.241.210.176"
"2001:700:300:1900::1:9"
];
gateways = [
values.hosts.gateway
values.hosts.gateway6
];
};
};
nodes.drolsum = mkDevice "drolsum" {
guestType = "proxmox";
parent = config.nodes.powerpuff-cluster.id;
deviceType = "loginbox";
deviceIcon = "${pkgs.super-tiny-icons}/share/icons/SuperTinyIcons/svg/debian.svg";
# TODO: the interface name is likely wrong
interfaceGroups = [ [ "eth0" ] ];
interfaces.eth0 = {
network = "pvv";
# mac = "";
addresses = [
"129.241.210.217"
"2001:700:300:1900::217"
"2001:700:300:1900::1:217"
];
gateways = [
values.hosts.gateway
values.hosts.gateway6
];
};
};
nodes.microbel = mkDevice "microbel" {
deviceIcon = "${pkgs.super-tiny-icons}/share/icons/SuperTinyIcons/svg/debian.svg";
hardware.info = "Supermicro X8ST3";
interfaceGroups = [ [ "eth0" "eth1" ] ];
interfaces.eth0 = {
mac = "00:25:90:24:76:2c";
addresses = [
"129.241.210.179"
"2001:700:300:1900::1:2"
];
gateways = [
values.hosts.gateway
values.hosts.gateway6
];
};
};
nodes.innovation = mkDevice "innovation" {
deviceIcon = "${pkgs.super-tiny-icons}/share/icons/SuperTinyIcons/svg/freebsd.svg";
hardware.info = "Dell Optiplex 9010";
interfaceGroups = [ [ "em0" ] ];
interfaces.em0 = {
mac = "18:03:73:20:18:d3";
addresses = [
"129.241.210.214"
"2001:700:300:1900::1:56"
];
gateways = [
values.hosts.gateway
values.hosts.gateway6
];
};
services = {
minecraft = {
name = "Minecraft";
icon = "services.minecraft";
info = "minecraft.pvv.ntnu.no";
details.listen.text = "0.0.0.0:25565";
};
};
};
nodes.principal = mkDevice "principal" {
deviceIcon = "${pkgs.super-tiny-icons}/share/icons/SuperTinyIcons/svg/freebsd.svg";
# TODO: the interface name is likely wrong
interfaceGroups = [ [ "em0" ] ];
interfaces.em0 = {
# mac = "";
addresses = [
"129.241.210.233"
"2001:700:300:1900::1:233"
];
gateways = [
values.hosts.gateway
values.hosts.gateway6
];
};
};
nodes.homeassistant = mkDevice "homeassistant" {
deviceIcon = "services.home-assistant";
hardware.info = "Raspberry Pi 4B";
# TODO: the interface name is likely wrong
interfaceGroups = [ [ "eth0" ] ];
interfaces.eth0 = {
# mac = "";
addresses = [
"129.241.210.229"
"2001:700:300:1900::4:229"
];
gateways = [
values.hosts.gateway
values.hosts.gateway6
];
};
};
nodes.sleipner = mkDevice "sleipner" {
deviceIcon = "${pkgs.super-tiny-icons}/share/icons/SuperTinyIcons/svg/debian.svg";
interfaceGroups = [ [ "eno0" "enp2s0" ] ];
interfaces.enp2s0 = {
mac = "00:25:90:57:35:8e";
addresses = [
"129.241.210.193"
"2001:700:300:1900:fab:cab:dab:7ab"
];
gateways = [
values.hosts.gateway
values.hosts.gateway6
];
};
};
nodes.isvegg = mkDevice "isvegg" {
deviceIcon = "${pkgs.super-tiny-icons}/share/icons/SuperTinyIcons/svg/debian.svg";
# TODO: the interface name is likely wrong
interfaceGroups = [ [ "eth0" ] ];
interfaces.eth0 = {
# mac = "";
addresses = [
"129.241.210.175"
"2001:700:300:1900::1:a"
];
gateways = [
values.hosts.gateway
values.hosts.gateway6
];
};
};
nodes.ameno = mkDevice "ameno" {
deviceIcon = "${pkgs.super-tiny-icons}/share/icons/SuperTinyIcons/svg/ubuntu.svg";
interfaceGroups = [ [ "eth0" ] ];
interfaces.eth0 = {
mac = "b8:27:eb:62:1d:d8";
addresses = [
"129.241.210.230"
"129.241.210.211"
"129.241.210.153"
"2001:700:300:1900:ba27:ebff:fe62:1dd8"
"2001:700:300:1900::4:230"
];
gateways = [
values.hosts.gateway
values.hosts.gateway6
];
};
services = {
bind = {
name = "Bind DNS";
icon = ./icons/bind9.png;
info = "hostmaster.pvv.ntnu.no";
details.listen.text = "0.0.0.0:53";
};
};
};
nodes.skrott = mkDevice "skrott" {
# TODO: the interface name is likely wrong
interfaceGroups = [ [ "eth0" ] ];
interfaces.eth0 = {
# mac = "";
addresses = [
"129.241.210.235"
];
gateways = [
values.hosts.gateway
values.hosts.gateway6
];
};
};
nodes.torskas = mkDevice "torskas" {
deviceIcon = "${pkgs.super-tiny-icons}/share/icons/SuperTinyIcons/svg/arch_linux.svg";
hardware.info = "Raspberry pi 4B";
# TODO: the interface name is likely wrong
interfaceGroups = [ [ "eth0" ] ];
interfaces.eth0 = {
# mac = "";
addresses = [
"129.241.210.241"
"2001:700:300:1900::241"
];
gateways = [
values.hosts.gateway
values.hosts.gateway6
];
};
};
nodes.wegonke = mkDevice "wegonke" {
deviceType = "terminal";
deviceIcon = "${pkgs.super-tiny-icons}/share/icons/SuperTinyIcons/svg/debian.svg";
hardware.info = "ASUSTeK G11CD-K";
interfaceGroups = [ [ "enp4s0" ] ];
interfaces.enp4s0 = {
mac = "70:4d:7b:a3:32:57";
addresses = [
"129.241.210.218"
"2001:700:300:1900::1:218"
];
gateways = [
values.hosts.gateway
values.hosts.gateway6
];
};
};
nodes.demiurgen = mkDevice "demiurgen" {
deviceType = "terminal";
deviceIcon = "${pkgs.super-tiny-icons}/share/icons/SuperTinyIcons/svg/debian.svg";
interfaceGroups = [ [ "eno1" ] ];
interfaces.eno1 = {
mac = "18:03:73:1f:f4:1f";
addresses = [
"129.241.210.201"
"2001:700:300:1900::1:4e"
];
gateways = [
values.hosts.gateway
values.hosts.gateway6
];
};
};
nodes.sanctuary = mkDevice "sanctuary" {
deviceType = "terminal";
deviceIcon = "${pkgs.super-tiny-icons}/share/icons/SuperTinyIcons/svg/windows.svg";
interfaceGroups = [ [ "ethernet_0" ] ];
interfaces.ethernet_0 = {
addresses = [
"129.241.210.170"
"2001:700:300:1900::1337"
];
gateways = [
values.hosts.gateway
values.hosts.gateway6
];
};
};
nodes.orchid = mkDevice "orchid" {
deviceType = "terminal";
deviceIcon = "${pkgs.super-tiny-icons}/share/icons/SuperTinyIcons/svg/debian.svg";
hardware.info = "Ryzen1600 Nvidia GTX 1060";
# TODO: the interface name is likely wrong
interfaceGroups = [ [ "eth0" ] ];
interfaces.eth0 = {
addresses = [
"129.241.210.210"
"2001:700:300:1900::210"
];
gateways = [
values.hosts.gateway
values.hosts.gateway6
];
};
};
}

View File

@@ -1,11 +0,0 @@
{ config, lib, ... }:
let
cfg = config.services.greg-ng or { enable = false; };
in
{
config.topology.self.services.greg-ng = lib.mkIf cfg.enable {
name = "Greg-ng";
icon = ../icons/greg-ng.png;
details.listen = { text = "${cfg.settings.host}:${toString cfg.settings.port}"; };
};
}