33 lines
687 B
Nix
33 lines
687 B
Nix
{ lib, ... }:
|
|
|
|
let
|
|
domain = "s3.giugl.io";
|
|
network = import ./network.nix;
|
|
in
|
|
{
|
|
services = {
|
|
minio.enable = true;
|
|
|
|
nginx.virtualHosts.${domain} = {
|
|
forceSSL = true;
|
|
enableACME = true;
|
|
locations."/" = {
|
|
proxyPass = "http://127.0.0.1:9000";
|
|
extraConfig = ''
|
|
client_max_body_size 500M;
|
|
allow 10.0.0.0/24;
|
|
${lib.concatMapStrings (x: "allow ${x};") network.gdevices }
|
|
allow ${network.manduria-wg};
|
|
deny all;
|
|
'';
|
|
};
|
|
};
|
|
};
|
|
|
|
networking.extraHosts = ''
|
|
${network.architect-lan} ${domain}
|
|
${network.architect-wg} ${domain}
|
|
${network.architect-ts} ${domain}
|
|
'';
|
|
}
|