1. Caddy version (
2. How I run Caddy:
a. System environment:
c. Service/unit/compose file:
d. My complete Caddyfile or JSON config:
paste config here, replacing this text
DO NOT REDACT anything except credentials
3. The problem I’m having:
I just have a small question. Can we do reverse proxy from https to http like that :
Cause the config is accepted by Caddy v2 (no errors) but it’s not working. I have a 502 Error.
Can you help me please.
4. Error messages and/or full log output:
5. What I already tried:
6. Links to relevant resources:
Yes, absolutely. That’s one of the things Caddy excels at.
You didn’t fill out the template, so I’m unsure how to help you. How are you running Caddy? What’s in your logs? Are you sure your other server is running and can be reached from Caddy?
This is my logs https://pastebin.com/Jb1v8mtq
The other http service is available on web access with direct http://IP:port
Caddy container is started with this docker-compose file :
Those error logs don’t make sense with the Caddyfile you posted above. Please post your full, unredacted Caddyfile and logs.
Also, please put ``` on lines before and after any config/logs/code you post here, it will preserve the whitespace and make it easier to read. It’s not necessary to put it in pastebin.
Your logs show that you’re trying to get a wildcard cert for
*.opybox.com but your config doesn’t have that… that is why we are confused. We require full, undredacted config and logs so we can help troubleshoot problems.
This is my full Caddyfile : https://pastebin.com/ExyG9atj
And my docker-compose :
Thanks for your help
To get wildcard certificates, you need to enable the DNS challenge. That requires building Caddy with one of the DNS plugins to add support for that: Automatic HTTPS — Caddy Documentation
The other option is to enable on-demand TLS: Automatic HTTPS — Caddy Documentation
This topic was automatically closed after 30 days. New replies are no longer allowed.