Hi there!
Background
Pretty new to traefik/reverse proxying in general. I have traefik and some services setup using docker-compose. One of those services is Piwigo, a self-hosted photo manager. Here is my traefik config in the docker-compose.yml:
reverse-proxy:
# The official v2 Traefik docker image
image: traefik:v2.2
# Enables the web UI and tells Traefik to listen to docker
command: --api.insecure=true --providers.docker
ports:
# The HTTP port
- "80:80"
# The Web UI (enabled by --api.insecure=true)
- "8080:8080"
volumes:
# So that Traefik can listen to the Docker events
- /var/run/docker.sock:/var/run/docker.sock
and here are the labels used in my piwigo config in the docker-compose.yml:
labels:
- traefik.http.routers.piwigo.rule=Host(`localhost`) && PathPrefix(`/piwigo`)
- traefik.http.routers.piwigo.middlewares=piwigo-stripprefix
- traefik.http.middlewares.piwigo-stripprefix.stripprefix.prefixes=/piwigo
Issue
When I go to piwigo in my browser using localhost/piwigo
the page is deplayed minus any CSS it seems.
However, when I try accessing the page using the port I forwarded in my docker-compose.yml, localhost:8585
, the page loads normally.
The other services I have configured all display correctly using similar labels. From reading the documentation, I think it has something to do with the reverse proxy not passing the headers correctly to the piwigo service. Or I could be totally wrong. I am not sure what label is missing in my piwigo config in the docker-compose.yml. Would someone be able to point me in the right direction?
Thanks!