diff options
Diffstat (limited to 'modules/server/virtualisation/containers/anubis.nix')
| -rw-r--r-- | modules/server/virtualisation/containers/anubis.nix | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/modules/server/virtualisation/containers/anubis.nix b/modules/server/virtualisation/containers/anubis.nix new file mode 100644 index 0000000..d3b0d8a --- /dev/null +++ b/modules/server/virtualisation/containers/anubis.nix @@ -0,0 +1,36 @@ +{ config, ... }: +let + port = builtins.toString 8092; +in +{ + services.caddy.virtualHosts."fuwn.me".extraConfig = '' + reverse_proxy localhost:${port} + + header Onion-Location http://fuwnme4wbs5x36jjf2usedw2zscozwhazykhyfkjsmudtb7egs3mb7yd.onion{path} + ''; + + # @blocked { + # path /proxy/illegaldrugs.net/cgi-bin/news.php* + # path /proxy/scholasticdiversity.us.to/scriptures/* + # path /proxy/jsreed5.org/oeis/* + # path /proxy/mastogem.picasoft.net/thread/* + # path /proxy/mastogem.picasoft.net/toot/* + # } + + # respond @blocked 403 + + virtualisation.oci-containers.containers.anubis = { + image = "ghcr.io/techarohq/anubis:latest"; + autoStart = true; + ports = [ "127.0.0.1:${port}:${port}" ]; + extraOptions = config.modules.containers.extraOptions ++ [ "--network=host" ]; + + environment = { + BIND = ":${port}"; + OG_PASSTHROUGH = "true"; + SERVE_ROBOTS_TXT = "false"; + TARGET = "http://127.0.0.1:8084"; + USE_REMOTE_ADDRESS = "true"; + }; + }; +} |