feat: really easy to import in old versions of the site

This commit is contained in:
silver 2024-06-14 21:28:52 +01:00
parent 34f8f0eb8c
commit 5c8dcdef00
Signed by: silver
GPG key ID: 54E2C71918E93B74
2 changed files with 48 additions and 28 deletions

View file

@ -0,0 +1,43 @@
{year}: {
config,
pkgs,
lib,
inputs,
...
}:
with lib; {
imports = [];
config = {
assertions = [
{
assertion = asserts.assertOneOf "year" year [
"2009"
"2017"
];
}
];
services.skynet.acme.domains = [
"${year}.skynet.ie"
];
services.skynet.dns.records = [
{
record = year;
r_type = "CNAME";
value = config.services.skynet.host.name;
}
];
services.nginx = {
virtualHosts = {
"${year}.skynet.ie" = {
forceSSL = true;
useACMEHost = "skynet";
root = "${inputs."skynet_website_${year}".defaultPackage."x86_64-linux"}";
};
};
};
};
}