Update caddy infra

This commit is contained in:
Jay T
2026-08-18 00:22:00 +00:00
parent 2bd55b66a4
commit 744bbd3c1e
4 changed files with 28 additions and 2 deletions
+9
View File
@@ -0,0 +1,9 @@
{
# Global option: Sets DNS-01 for all certificates using the Cloudflare plugin
acme_dns cloudflare {$CLOUDFLARE_API_TOKEN}
}
ilboo.com {
# Forward requests to port 5003 running directly on the host system
reverse_proxy host.docker.internal:5003
}
+8
View File
@@ -0,0 +1,8 @@
FROM caddy:2-builder AS builder
RUN xcaddy build \
--with github.com/caddy-dns/cloudflare
FROM caddy:2
COPY --from=builder /usr/bin/caddy /usr/bin/caddy
+10 -2
View File
@@ -1,11 +1,15 @@
services: services:
caddy: caddy:
image: caddy:latest build: .
restart: unless-stopped restart: unless-stopped
ports: ports:
- "80:80" - "80:80"
- "443:443" - "443:443"
- "443:443/udp" - "443:443/udp" # Enables HTTP/3
env_file:
- .env
extra_hosts:
- "host.docker.internal:host-gateway"
volumes: volumes:
- ./Caddyfile:/etc/caddy/Caddyfile - ./Caddyfile:/etc/caddy/Caddyfile
- caddy_data:/data - caddy_data:/data
@@ -16,3 +20,7 @@ services:
volumes: volumes:
caddy_data: caddy_data:
caddy_config: caddy_config:
networks:
caddy_net:
external: true
+1
View File
@@ -0,0 +1 @@
CLOUDFLARE_API_TOKEN=your_actual_cloudflare_api_token_here