sablierapp / sablier

Start your containers on demand, shut them down automatically when there's no activity. Docker, Docker Swarm Mode and Kubernetes compatible.
https://sablierapp.dev/
GNU Affero General Public License v3.0
1.47k stars 50 forks source link

Caddy example not working #462

Closed thueske closed 1 day ago

thueske commented 1 day ago

Describe the bug app-1 | Error: loading http app module: provision http: server srv1: setting up route handlers: route 1: loading handler modules: position 0: loading module 'subroute': provision http.handlers.subroute: setting up subroutes: route 0: loading handler modules: position 0: loading module 'sablier': provision http.handlers.sablier: parse "url=http://sablier:10000/api/strategies/dynamic": first path segment in URL cannot contain colon

Caddyfile (copied from example)

:80 {
    route /whoami {
      sablier url=http://sablier:10000 {
        group demo
        session_duration 1m 
        dynamic {
            display_name My Whoami Service
        }
      }

      reverse_proxy whoami:80
    }
}

Context

acouvreur commented 1 day ago

Try

:80 {
    route /whoami {
-      sablier url=http://sablier:10000 {
+      sablier http://sablier:10000 {
        group demo
        session_duration 1m 
        dynamic {
            display_name My Whoami Service
        }
      }

      reverse_proxy whoami:80
    }
}