Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

swirl behind traefik? #55

Open
emboss64 opened this issue Jul 12, 2023 · 3 comments
Open

swirl behind traefik? #55

emboss64 opened this issue Jul 12, 2023 · 3 comments

Comments

@emboss64
Copy link

I was wondering if anyone ever tried using swirl behind traefik, as I have not found a way to make it work with a base path other than / as the ui has all the references pointing to that.

This is the traefik config I'm trying to use:

    deploy:
      labels:
        - "traefik.enable=true"
        - "traefik.http.routers.swirl.entrypoints=https"
        - "traefik.http.routers.swirl.tls=true"
        - "traefik.http.services.swirl.loadbalancer.server.port=8001"
        - "traefik.http.routers.swirl.rule=PathPrefix(`/swirl`)"
        - "traefik.http.routers.swirl.middlewares=swirl-stripprefix"
        - "traefik.http.middlewares.swirl-stripprefix.stripprefix.prefixes=/swirl"
        - "traefik.http.middlewares.swirl-stripprefix.stripprefix.forceslash=true"
@nexovec
Copy link

nexovec commented Jul 21, 2023

I'm not sure this will be helpful, but I did try running swirl with traefik and after 2 weeks of not even being able to recognize services properly. I ultimately ended up replacing it with apache web server.

But still, here are some things that might help:

  • Make sure swirl and traefik are on the same docker network.
  • Try to run it locally in docker-compose with docker as a provider.
  • Make sure you have set the provider to swarm correctly(not just docker).
  • Check the service is even visible at all in the traefik dashboard.

The labels do look correct, but as I've said, I couldn't do it either.

@emboss64
Copy link
Author

Yup, it's not really a problem of the ingress config but of swirl not being able to handle a path other than the root path as it's base path

I'll have to give this experimental plugin a go: https://github.com/traefik/plugin-rewritebody

@nexovec
Copy link

nexovec commented Aug 30, 2023

Is it possible for you to paste your swirl and traefik docker compose labels in here?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants