mirror of
https://github.com/fruworg/infrastructure.git
synced 2024-11-16 05:17:17 +03:00
95 lines
1.9 KiB
Caddyfile
95 lines
1.9 KiB
Caddyfile
{
|
|
email im@fruw.org
|
|
acme_dns google_domains {$CADDY_API_KEY}
|
|
}
|
|
|
|
fruw.org {
|
|
root * /var/caddy/hugo
|
|
file_server
|
|
}
|
|
|
|
ok.fruw.org {
|
|
@block {
|
|
not client_ip {$WHITE_LIST}
|
|
}
|
|
handle @block {
|
|
basicauth {
|
|
{$CADDY_LOGIN} {$CADDY_PASSWORD}
|
|
}
|
|
reverse_proxy localhost:50009 {
|
|
header_up X-Real-IP {remote_host}
|
|
}
|
|
}
|
|
respond "IP bleached! :)"
|
|
}
|
|
|
|
vault.fruw.org {
|
|
handle_path /admin {
|
|
@block {
|
|
not client_ip {$WHITE_LIST}
|
|
}
|
|
handle @block {
|
|
redir https://ok.fruw.org
|
|
}
|
|
reverse_proxy localhost:50000
|
|
}
|
|
reverse_proxy localhost:50000
|
|
}
|
|
|
|
mail.fruw.org {
|
|
@block {
|
|
not client_ip {$WHITE_LIST}
|
|
}
|
|
handle @block {
|
|
redir https://ok.fruw.org
|
|
}
|
|
reverse_proxy localhost:50001
|
|
}
|
|
|
|
matrix.fruw.org, matrix.fruw.org:8448 {
|
|
rewrite / /_matrix/static/
|
|
reverse_proxy /_matrix/* localhost:50003
|
|
}
|
|
|
|
git.fruw.org {
|
|
rewrite / /fruworg
|
|
reverse_proxy localhost:50005
|
|
}
|
|
|
|
turn.fruw.org {
|
|
respond "whoa! eturnal server is runnig" 200
|
|
}
|
|
|
|
rclone.fruw.org {
|
|
@block {
|
|
not client_ip {$WHITE_LIST}
|
|
}
|
|
handle @block {
|
|
redir https://ok.fruw.org
|
|
}
|
|
reverse_proxy 127.0.0.1:53682
|
|
respond "nothing to auth" 404
|
|
}
|
|
|
|
cs.fruw.org {
|
|
respond "whoa! cstrike server is runnig" 200
|
|
}
|
|
|
|
doom.fruw.org {
|
|
respond "oops! doom2 server is not running" 503
|
|
}
|
|
|
|
fs.fruw.org, http://fs.fruw.org {
|
|
root * /var/caddy/fs
|
|
file_server browse
|
|
}
|
|
|
|
ip.fruw.org, http://ip.fruw.org {
|
|
templates
|
|
respond "{{.RemoteIP}}"
|
|
}
|
|
|
|
*.fruw.org {
|
|
respond "hello there"
|
|
}
|