Route Path & Service listening routes

hi,

Given a simple service running in a docker container which return foo for a get request at /
I want this service to be accessed from https://api.foo.com/bar

This actually reach the service:
- traefik.http.routers.fooservice.rule=Host(`api.foo.com`) && PathPrefix(`/bar`)"

But then I get an error message saying the service does not have a route for /bar
Basically the request actually reach the service, but not as root / but as /bar

I have tried to use
"traefik.http.middlewares.fooservice-stripprefix.stripprefix.prefixes=/bar"

but didnt seem to do much.
Did I miss something?

Thanks for the help!

Hello,

Could provide a reproducible example? (small docker-compose file)

ok I fixed the problem.
I misunderstood how chaining middleware worked and https middleware was the only one used - and stripprefix.prefixes=/bar was not used.