services:
  dockge:
    volumes:
      - /var/run/docker.sock:/var/run/docker.sock
      - /srv/dockge/stacks:/srv/dockge/stacks
    environment:
      DOCKGE_STACKS_DIR: /srv/dockge/stacks
      
      # RUNTIPI Environment
      RUNTIPI_APP_PORT: "${APP_PORT}"
      RUNTIPI_APP_ID: "${APP_ID}"
      RUNTIPI_APP_DATA_DIR: "${APP_DATA_DIR}"
      RUNTIPI_APP_EXPOSED: "${APP_EXPOSED:-}"
      RUNTIPI_APP_DOMAIN: "${APP_DOMAIN}"
      RUNTIPI_APP_HOST: "${APP_HOST}"
      RUNTIPI_LOCAL_DOMAIN: "${LOCAL_DOMAIN}"
      RUNTIPI_DOMAIN: "${DOMAIN}"
      RUNTIPI_ROOT_DOMAIN: "${ROOT_DOMAIN}"
      HOST_UID: "${HOST_UID}"
      HOST_GID: "${HOST_GID}"
      PUID: "${HOST_UID}"
      PGID: "${HOST_GID}"
      TZ: "${TZ:?Did you forget to define TZ in the root RunTipi .env.local?}"
    labels:
      traefik.http.routers.dockge.rule: Host(`dockge.${ROOT_DOMAIN}`)${APP_ROUTE_OPTIONAL:-}
      traefik.http.routers.dockge.middlewares: authentik_sysmgr@file

      # traefik.enable: true
      # # traefik.http.services.dockge.loadbalancer.server.port: 5001
      # traefik.http.routers.dockge.entrypoints: websecure
      # traefik.http.routers.dockge.service: dockge
      # traefik.http.routers.dockge.tls.certresolver: myresolver
