# BillCare — exdev Caddy 서브도메인 스니펫
# host 포트 83 → billcare-frontend
# 인증서: acme.sh 로 발급한 billcare 전용 LE cert
#   /Users/aidev/dev/exAIChatbot2.0/docker/nginx/certs/billcare/{fullchain,privkey}.pem
#   (Caddy 컨테이너 마운트: /etc/caddy/certs/billcare/)

# BillCare
https://{$BILLCARE_DOMAIN:billcare.exdev.co.kr} {
	tls /etc/caddy/certs/billcare/fullchain.pem /etc/caddy/certs/billcare/privkey.pem
	handle {
		reverse_proxy host.docker.internal:{$BILLCARE_HOST_PORT:83} {
			flush_interval -1
			transport http {
				read_timeout 120s
				write_timeout 120s
				versions 1.1 2
			}
			header_up Host {host}
			header_up X-Real-IP {remote_host}
			header_up X-Forwarded-For {remote_host}
			header_up X-Forwarded-Proto {scheme}
		}
	}
}
