From 19f855252d67f00af39d2d0be324fb60fdba2652 Mon Sep 17 00:00:00 2001 From: Daylin Morgan Date: Fri, 15 Nov 2024 14:10:54 -0600 Subject: [PATCH] handle index.html for attic --- hosts/algiz/{ => caddy}/Caddyfile | 6 +-- hosts/algiz/caddy/index.html | 68 +++++++++++++++++++++++++++++++ hosts/algiz/services.nix | 11 ++++- 3 files changed, 81 insertions(+), 4 deletions(-) rename hosts/algiz/{ => caddy}/Caddyfile (96%) create mode 100644 hosts/algiz/caddy/index.html diff --git a/hosts/algiz/Caddyfile b/hosts/algiz/caddy/Caddyfile similarity index 96% rename from hosts/algiz/Caddyfile rename to hosts/algiz/caddy/Caddyfile index 3d56599..3925ffc 100644 --- a/hosts/algiz/Caddyfile +++ b/hosts/algiz/caddy/Caddyfile @@ -6,9 +6,9 @@ elizabeth.dayl.in, www.elizabeth-and-daylin.com { redir https://elizabeth-and-daylin.com{uri} permanent } -attic.dayl.in { - reverse_proxy http://localhost:5656 -} +#attic.dayl.in { +# reverse_proxy http://localhost:5656 +#} git.dayl.in { reverse_proxy http://localhost:3000 diff --git a/hosts/algiz/caddy/index.html b/hosts/algiz/caddy/index.html new file mode 100644 index 0000000..523748f --- /dev/null +++ b/hosts/algiz/caddy/index.html @@ -0,0 +1,68 @@ + + + + Attic Binary Cache + + + +
+
+┏━━━━━━━━━━━━━━━━┑
+┃┏━━━ @ ━━━ @ ━━┓┃
+┃┃              ┃┃
+┃┃$ attic push 
┃┃ +┃┃ ┃┃ +┃┗━━━ ╰─────╯ ━━┛┃ +┗━━━━━━━━━━━━━━━━┛ + ╲ ############### ╲ + ╲ ############### ╲ + ╲ ############### ╲ + ━━━━━━━━━━━━━━━━━━ +
+
+ + diff --git a/hosts/algiz/services.nix b/hosts/algiz/services.nix index 666bab0..8db0a7d 100644 --- a/hosts/algiz/services.nix +++ b/hosts/algiz/services.nix @@ -67,6 +67,15 @@ in }; services.caddy = enabled // { - extraConfig = builtins.readFile ./Caddyfile; + extraConfig = + builtins.readFile ./caddy/Caddyfile + + '' + ${builtins.readFile ./caddy/Caddyfile} + attic.dayl.in { + root * ${./caddy} + file_server index.html + reverse_proxy /* http://localhost:5656 + } + ''; }; }