Skip to content

Take control over your live stream video by running it yourself. Streaming + chat out of the box.

792 B
Raw Blame
# Caddyfile for ActivityPub federation testing
# Routes requests to owncast.local, owncast2.local, and snac.local to their respective backends

{
	# Disable automatic HTTPS since we use mkcert certificates
	auto_https off
	# Disable admin API
	admin off
	# Suppress logging
	log {
		level error
	}
}

# HTTPS listener using mkcert certificates
https://:{$PROXY_PORT} {
	tls {$CERT_FILE} {$KEY_FILE}

	# Route based on Host header
	@owncast host owncast.local
	@owncast2 host owncast2.local
	@snac host snac.local

	handle @owncast {
		reverse_proxy localhost:{$OWNCAST_PORT}
	}

	handle @owncast2 {
		reverse_proxy localhost:{$OWNCAST2_PORT}
	}

	handle @snac {
		reverse_proxy localhost:{$SNAC_PORT}
	}

	# Default: return error for unknown hosts
	handle {
		respond "Unknown host" 404
	}
}