Radish alpha
r
rad:z254T5p17bdFPmzfDojsdjo4HjpoZ
Radicle Infrastructure as Code (NixOS, OpenTofu, …)
Radicle
Git
os/seed: Double as files.radicle.xyz
Lorenz Leutgeb committed 7 months ago
commit d23086c1de9d1cdf3a76428da1f97b86bb5863fc
parent bccad95
3 files changed +16 -3
modified dns/dnsconfig.js
@@ -44,9 +44,6 @@ D("radicle.xyz", REG_NONE, DnsProvider(DSP_CLOUDFLARE),
    PTR("_services._dns-sd._udp", "_radicle-node._tcp.radicle.xyz."),


-
    A("files", "65.109.236.201"),
-

-

    A("iris", "95.217.156.6"),
    AAAA("iris", "2a01:4f9:c010:dfaa::1"),
    SSHFP("iris", 4, 1, "1ffe43af8f30c34373515fa24f1b9fe69532a9d5"),
@@ -80,6 +77,7 @@ D("radicle.xyz", REG_NONE, DnsProvider(DSP_CLOUDFLARE),
    SSHFP("seed", 4, 1, "9033b89019264dbad5a744057166a5e1b7af92f7"),

    ALIAS("attic", "seed"),
+
    ALIAS("files", "seed"),
    ALIAS("grafana", "seed"),
    ALIAS("logs", "seed"),
    ALIAS("loki", "seed"),
modified os/host/seed/default.nix
@@ -21,6 +21,7 @@
    ./radicle.nix
    ./grafana.nix
    ./victorialogs.nix
+
    ./files.nix

    (modulesPath + "/profiles/qemu-guest.nix")
  ];
added os/host/seed/files.nix
@@ -0,0 +1,14 @@
+
let
+
  name = "files.radicle.xyz";
+
in {
+
  services.nginx.virtualHosts.${name} = {
+
    root = "/var/www/${name}";
+
    extraConfig = ''
+
      add_header 'Access-Control-Allow-Origin' 'https://radicle.xyz';
+
      autoindex on;
+
    '';
+
    addSSL = true;
+
    enableACME = true;
+
    serverName = name;
+
  };
+
}