# Internal Caddy for the podium container — TLS terminates at the front proxy.
:80 {
	encode zstd gzip

	# HappyView (dashboard, admin API, XRPC) mounted under /hv
	@hv path /hv /hv/*
	handle @hv {
		reverse_proxy podium-hv:3000
	}

	# Standard XRPC path for protocol-native consumers
	handle /xrpc/* {
		rewrite * /hv{uri}
		reverse_proxy podium-hv:3000
	}

	# The Podium frontend
	handle {
		root * /srv
		try_files {path} /index.html
		file_server
	}
}
