Skip to content
This repository was archived by the owner on Feb 26, 2023. It is now read-only.
This repository was archived by the owner on Feb 26, 2023. It is now read-only.

PROXY_ADDRESS breaks direct access w/o reverse proxy #599

Open
@tommyalatalo

Description

@tommyalatalo

Using PROXY_ADDRESS breaks access to hashi-ui directly using http://ip:port address.

Reproduce:

  1. Skip setting PROXY_ADDRESS, configuration:
CONSUL_ADDR="http://consul.service.consul:8500"
CONSUL_ENABLE="true"
CONSUL_READ_ONLY="true"
NOMAD_ADDR="http://nomad-servers.service.consul:4646"
NOMAD_ENABLE="true"
SERVICE_IMAGE="jippi/hashi-ui"
SERVICE_VERSION="v1.3.8"
NOMAD_READ_ONLY="true"
NOMAD_HIDE_ENV_DATA="true"

Result: hashi-ui reachable at http://localhost:3000, redirects to http://localhost:3000/nomad/, works as expected.

  1. Set PROXY_ADDRESS="/hashi-ui", otherwise same config as above

Result: hashi-ui at localhost:3000 redirects to http://localhost:3000/hashi-ui/nomad/ and shows Error: Unable to connect to the backend....

Route through traefik (http://traefik:80/hashi-ui) works, configured as:

"traefik.enable=true",
"traefik.http.routers.hashi-ui.entrypoints=api",
"traefik.http.routers.hashi-ui.rule=PathPrefix(`/hashi-ui`)",
"traefik.http.routers.hashi-ui.middlewares=hashi-ui_stripprefix",
"traefik.http.middlewares.hashi-ui_stripprefix.stripprefix.prefixes=/hashi-ui",

So the sum behavior above is that I can't get hashi-ui working both with direct access and via traefik at the same time. Did I configure something wrong, or is this a bug, because I would've expected the direct access to still work?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions