sysadminsmedia / homebox

A continuation of HomeBox the inventory and organization system built for the Home User
https://homebox.software
GNU Affero General Public License v3.0
1.15k stars 62 forks source link

0.12 doesn't work with Traefik Reverse Proxy #107

Closed brhahlen closed 4 months ago

brhahlen commented 4 months ago

First Check

Homebox Version

0.12.0

What is the issue you are experiencing?

Version 0.12.0 of HomeBox breaks "something" (and I don't know what) that makes it not work with Traefik. The exact same configuration works with 0.11.1 (and older versions).

Also tried with main and main-rootless

How can the maintainer reproduce the issue?

Compose:

  homebox:
    extends:
      file: ../shared.yml
      service: pubnet-shared
    container_name: homebox
    # image: ghcr.io/sysadminsmedia/homebox:0.11
    image: ghcr.io/sysadminsmedia/homebox:main-rootless
    env_file: homebox.env
    environment:
      - PUID=${PUID}
      - PGID=${PGID}
      - TZ=${TZ}
    volumes:
      - ${CONF_DIR}/homebox:/data/
    labels:
      ## Traefik
      - "traefik.enable=true"
      - "traefik.docker.network=lan_net"
      ## HTTP Routers
      - "traefik.http.routers.homebox.entrypoints=web-secure"
      - "traefik.http.routers.homebox.rule=Host(`homebox.$DOMAINNAME`)"
      ## Middlewares
      - "traefik.http.routers.homebox.middlewares=ipallowlist"
      ## HTTP Services
      - "traefik.http.routers.homebox.service=homebox"
      - "traefik.http.services.homebox.loadbalancer.server.port=7745"

homebox.env:

HBOX_LOG_LEVEL=debug
HBOX_LOG_FORMAT=text
HBOX_WEB_MAX_UPLOAD_SIZE=10

Deployment

Docker (Linux)

Deployment Details

No response

chessmango commented 4 months ago

Likely related to https://github.com/sysadminsmedia/homebox/issues/103 - you'd either need to add your own healthcheck config or downgrade to 0.11.1 and wait for a fixed 0.12.x release :)

Just in case, it's worth checking whether the container is listed as unhealthy, with docker ps or docker compose ps. It's likely to be unhealthy, so Traefik won't route to it by default

tankerkiller125 commented 4 months ago

Please try v0.12.1 when you get a chance (and once the docker containers are actually published here in the next 10 or so minutes). It should resolve this issue as @chessmango is most likely correct that Traefik is not routing to the container because it's marked as unhealthy in v0.12.0

brhahlen commented 4 months ago

That indeed fixed it! Thank you for the quick turn-around.