# Production Caddyfile for appointment booking application
# Replace your-admin-domain.com with your actual admin domain
{
	on_demand_tls {
		ask http://app:3000/api/public/domains
	}
}

:443 {
	reverse_proxy app:3000

	encode gzip

	log {
		output file /data/access.log {
			roll_size 100mb
			roll_keep 10
		}
		format json
	}

	tls {
		on_demand
		protocols tls1.2 tls1.3
	}
}

your-admin-domain.com {
	reverse_proxy app:3000

	encode gzip

	log {
		output file /data/access.log {
			roll_size 100mb
			roll_keep 10
		}
		format json
	}

	tls {
		protocols tls1.2 tls1.3
	}
}