From 97ca9854283164ffc115e6e12aa13ac63f7daae0 Mon Sep 17 00:00:00 2001 From: Ekaitz Zarraga Date: Thu, 1 May 2025 22:55:33 +0200 Subject: debian: Add config --- debian_server/etc/caddy/Caddyfile | 64 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 64 insertions(+) create mode 100644 debian_server/etc/caddy/Caddyfile (limited to 'debian_server/etc/caddy/Caddyfile') diff --git a/debian_server/etc/caddy/Caddyfile b/debian_server/etc/caddy/Caddyfile new file mode 100644 index 0000000..e1bb5b1 --- /dev/null +++ b/debian_server/etc/caddy/Caddyfile @@ -0,0 +1,64 @@ +# The Caddyfile is an easy way to configure your Caddy web server. +# +# Unless the file starts with a global options block, the first +# uncommented line is always the address of your site. +# +# To use your own domain name (with automatic HTTPS), first make +# sure your domain's A/AAAA DNS records are properly pointed to +# this machine's public IP, then replace ":80" below with your +# domain name. +# +# Refer to the Caddy docs for more information: +# https://caddyserver.com/docs/caddyfile + +{ + admin off +} + +cdn.elenq.tech { + root * /var/www/elenq + file_server +} + +ekaitz.elenq.tech { + root * /var/www/ekaitz + file_server +} + +thoughts.elenq.tech { + root * /var/www/thoughts + file_server +} + +publishing.elenq.tech { + root * /var/www/elenq_publishing + file_server + redir / /en +} + +www.publishing.elenq.tech { + redir https://publishing.elenq.tech{uri} permanent +} + +postdata.biz { + root * /var/www/postdata + file_server + redir / /es +} + +www.postdata.biz { + redir https://postdata.biz{uri} permanent +} + +git.elenq.tech { + @assets path /cgit.css /cgit.js /cgit.png /favicon.ico /robots.txt + handle @assets { + root * /usr/share/cgit + file_server + } + + reverse_proxy unix//run/fcgiwrap.socket { + transport fastcgi { + env SCRIPT_FILENAME /usr/lib/cgit/cgit.cgi + } +} -- cgit v1.2.3