1. My Caddy version (caddy version
):
2.0.0-rc.2
2. How I run Caddy:
using Docker Container base image 2.0.0-rc.2-alpine
a. System environment:
Docker
b. Command:
paste command here
c. Service/unit/compose file:
paste full file contents here
d. My complete Caddyfile or JSON config:
JSON Config:
> {
> "admin": {
> "listen": ":2019"
> },
> "apps": {
> "http": {
> "servers": {
> "reverse_proxy_master": {
> "listen": [
> "0.0.0.0:443"
> ],
> "@id": "reverse_proxy_master",
> "routes": [],
> "experimental_http3": false
> }
> }
> },
> "tls": {
> "automation": {
> "policies": [
> {
> "issuer": {
> "ca": "https://acme-staging-v02.api.letsencrypt.org/directory",
> "module": "acme"
> }
> }
> ]
> }
> }
> }
> }
paste config here, replacing this text
DO NOT REDACT anything except credentials
3. The problem I’m having:
Trying to add reverse proxy handler using IP:
http://:2019/id/reverse_proxy_master/route
Request:
> {
> "@id":"zenssl.xyz",
> "match": [
> {
> "host": [
> "zenssl.xyz"
> ]
> }
> ],
> "handle": [
> {
> "handler": "subroute",
> "routes": [
> {
> "handle": [
> {
> "handler": "reverse_proxy",
> "transport" : {
> "protocol": "http"
> },
> "headers": {
> "request": {
> "set": {
> "Host": [
> "{http.request.host}"
> ],
> "X-Forwarded-For": [
> "{http.request.remote}"
> ],
> "X-Forwarded-Port": [
> "{http.request.port}"
> ],
> "X-Forwarded-Proto": [
> "{http.request.scheme}"
> ],
> "X-Real-Ip": [
> "{http.request.remote}"
> ]
> }
> }
> },
> "upstreams": [
> {
> "dial": "166.62.10.36"
> }
> ]
> }
>
> ],
> "match": [
> {
> "path": [
> "/"
> ]
> }
> ]
> }
> ]
> }
> ],
> "terminal": false
> }
4. Error messages and/or full log output:
{
“error”: “loading new config: loading http app module: decoding module config: http: json: unknown field “route””
}