Help with caddy reverse proxy

I can't figure out how to setup coder and caddy together. Can you share a possible config file Domain coder.evokerking.dev Wildcard Domain *.coder.evokerking.dev Email: [email protected] DNS Provider: Cloudflare
9 Replies
Codercord
Codercord•2mo ago
<#1349350932269502484>
Category
Help needed
Product
Coder (v2)
Platform
Linux
Logs
Please post any relevant logs/error messages.
Phorcys
Phorcys•2mo ago
i'll try to find one, could you share your current config and any error messages?
HappyShark
HappyShark•2mo ago
There's some docs here on how to get it set up with docker compose https://coder.com/docs/tutorials/reverse-proxy-caddy
Use Caddy as a Reverse Proxy | Coder Docs
Learn how to use Caddy as a reverse proxy
From An unknown user
From An unknown user
HappyShark
HappyShark•2mo ago
The following should work as a caddyfile if you can get zone and api tokens { on_demand_tls { ask http://example.com } } coder.evokerking.dev, *.coder.evokerking.dev { reverse_proxy coder:7080 tls { dns cloudflare { zone_token <zone_token_goes_here> api_token <api_token_goes_here } } you'll need to use a caddy docker image that has the cloudflare plugin installed
FROM caddy:2.9.1-builder AS builder

RUN xcaddy build --with github.com/caddy-dns/cloudflare

FROM caddy:2.9.1

COPY --from=builder /usr/bin/caddy /usr/bin/caddy
FROM caddy:2.9.1-builder AS builder

RUN xcaddy build --with github.com/caddy-dns/cloudflare

FROM caddy:2.9.1

COPY --from=builder /usr/bin/caddy /usr/bin/caddy
and there's a guide on how to get the tokens here
HappyShark
HappyShark•2mo ago
GitHub
GitHub - caddy-dns/cloudflare: Caddy module: dns.providers.cloudflare
Caddy module: dns.providers.cloudflare. Contribute to caddy-dns/cloudflare development by creating an account on GitHub.
Phorcys
Phorcys•2mo ago
(@evokerking👑)
evokerking👑
evokerking👑OP•2mo ago
yes?
Phorcys
Phorcys•2mo ago
I was pinging you so you could take a look at the reply!
Codercord
Codercord•3w ago
@Phorcys closed the thread.

Did you find this page helpful?