Portainer Templates logo

Portainer Templates

Homedex Homedex

Stack

DockerMonitoringTools

Read-only inventory for your homelab: services, hosts, ports, routes, certificates, domains and changes, discovered from Docker, Proxmox VE, Tailscale and your reverse proxy. It never starts, stops or reconfigures anything. Source: https://github.com/HarshShah0203/homedex

Source details

Stars: 56
Forks: 1
Language: Go
License: MIT
Updated: 47 minutes ago

Configuration

Type
Compose
Platform
linux
Env vars
HOMEDEX_ADMIN_PASSWORD=''HOMEDEX_BIND=0.0.0.0HOMEDEX_PORT=7377
Restart
unless-stopped
Source

Notes

Set the admin password before you deploy: this stack publishes the UI on your LAN, and until an admin exists whoever opens the page first would choose it. Homedex stores only its Argon2id hash on first start and ignores the field afterwards; a password shorter than 12 characters stops the container with an error in its log. Then open http://<host>:7377, sign in and add your first source: the stack's read-only Docker socket proxy is prefilled as tcp://docker-socket-proxy:2375. Homedex only reads; the proxy rejects every Docker API write. Docs: github.com/HarshShah0203/homedex

Services

docker-socket-proxy

Configuration

Image
tecnativa/docker-socket-proxy:v0.4.2
Volumes
/var/run/docker.sock : /var/run/docker.sock
Env vars
CONTAINERS=1IMAGES=1INFO=1NETWORKS=1VERSION=1POST=0ALLOW_START=0ALLOW_STOP=0ALLOW_RESTARTS=0
Restart
unless-stopped

Image details

Pulls: 71.2M
User: tecnativa
Created: Mar 29, 2017
Updated: 9 hours ago
Status: active

homedex

Configuration

Image
ghcr.io/harshshah0203/homedex:${HOMEDEX_VERSION:-0.2}
Ports
${HOMEDEX_BIND:-127.0.0.1}:${HOMEDEX_PORT:-7377}:7377
Volumes
/data : homedex-data
Env vars
HOMEDEX_DATA_DIR=/dataHOMEDEX_LISTEN=:7377HOMEDEX_ADMIN_PASSWORD=${HOMEDEX_ADMIN_PASSWORD:-}
Restart
unless-stopped

Standalone Install

Select an install method, to see config/commands for deploying Homedex

Installation method

Install on Portainer

Import all app templates into your Portainer instance, for easy 1-click deploys

  1. Ensure both Docker and Portainer are installed, and up-to-date
  2. Log into your Portainer web UI
  3. Under Settings → App Templates, paste the below URL
  4. Head to Home → App Templates, and the list of apps will show up
  5. Select Homedex, fill in any config options, and hit Deploy

Template Import URL

https://raw.githubusercontent.com/Lissy93/portainer-templates/main/templates.json
Show Me demo
Original stackfile

The compose file this template deploys, straight from its repo:

# Homedex needs only this file. It pulls the published multi-arch image, so no
# checkout or Go/Node toolchain is required:
#
#   mkdir homedex
#   cd homedex
#   curl -fsSLO https://raw.githubusercontent.com/HarshShah0203/homedex/main/docker-compose.yml
#   docker compose up -d
#
# Use a new, empty directory: the download replaces any docker-compose.yml
# there, and Compose also reads a .env or docker-compose.override.yml beside it.
#
# HOMEDEX_VERSION pins a release (default: the newest 0.2.x). To build from a
# checkout instead, add docker-compose.build.yml:
#   docker compose -f docker-compose.yml -f docker-compose.build.yml up -d --build
name: homedex

services:
  docker-socket-proxy:
    image: tecnativa/docker-socket-proxy:v0.4.2
    restart: unless-stopped
    environment:
      CONTAINERS: 1
      IMAGES: 1
      INFO: 1
      NETWORKS: 1
      VERSION: 1
      POST: 0
      ALLOW_START: 0
      ALLOW_STOP: 0
      ALLOW_RESTARTS: 0
    volumes:
      # `:ro` protects the socket file from replacement; POST=0 above is what
      # filters mutating Docker API calls. A raw socket mounted read-only is
      # still a privileged Docker API connection.
      - /var/run/docker.sock:/var/run/docker.sock:ro
    read_only: true
    tmpfs:
      - /run
      - /tmp
    cap_drop:
      - ALL
    security_opt:
      - no-new-privileges:true
    networks:
      - discovery

  homedex:
    image: ghcr.io/harshshah0203/homedex:${HOMEDEX_VERSION:-0.2}
    restart: unless-stopped
    depends_on:
      - docker-socket-proxy
    ports:
      # Loopback by default: until setup completes, whoever reaches the UI first
      # sets the admin password. HOMEDEX_BIND=0.0.0.0 opens it to the LAN; set
      # HOMEDEX_ADMIN_PASSWORD with it so the setup page is never open to others.
      - "${HOMEDEX_BIND:-127.0.0.1}:${HOMEDEX_PORT:-7377}:7377"
    environment:
      HOMEDEX_DATA_DIR: /data
      HOMEDEX_LISTEN: :7377
      # Optional, empty by default (the setup wizard then creates the admin).
      # On a first start with no admin yet, Homedex stores only the Argon2id
      # hash of this password; one shorter than 12 characters stops startup
      # with an error. Once an admin exists the value is ignored and never
      # replaces it, so it can be dropped after the first start. To keep it out
      # of `docker inspect`, set HOMEDEX_ADMIN_PASSWORD_FILE to a mounted secret
      # instead (docs/SECURITY_DEPLOYMENT.md). The value is never logged.
      HOMEDEX_ADMIN_PASSWORD: ${HOMEDEX_ADMIN_PASSWORD:-}
    volumes:
      - homedex-data:/data
    read_only: true
    tmpfs:
      - /tmp
    cap_drop:
      - ALL
    security_opt:
      - no-new-privileges:true
    networks:
      - app
      - discovery

networks:
  app:
    internal: false
  discovery:
    internal: true

volumes:
  homedex-data:

Or deploy it directly from the source:

git clone https://github.com/HarshShah0203/homedex
cd homedex
docker compose -f docker-compose.yml up -d

More install options in our documentation, or see HarshShah0203/homedex for app-specific guidance.

Container Documentation

docker-socket-proxy Documentation

Proxy over your Docker socket to restrict which requests it accepts

Check the logs first

Nine times out of ten the logs tell you exactly what went wrong.

  • In Portainer, go to Containers, click the container, then Logs. Or run docker logs <container>
  • Exit codes help too: 137 means killed, usually out of memory. 126 or 127 means the command inside the image is broken.

Can't reach the Docker socket

homedex talks to Docker through /var/run/docker.sock. If the logs show "permission denied while trying to connect to the Docker daemon socket", the app's user can't access it.

  • Check the socket exists on the host: ls -l /var/run/docker.sock
  • Run the container as root, or add the docker group's id to the container with group_add.

Image won't pull

Test the pull directly on the host: docker pull tecnativa/docker-socket-proxy:v0.4.2

  • "manifest unknown" means the tag no longer exists.
  • "toomanyrequests" is the Docker Hub rate limit. Log in with docker login to raise it.
  • "no space left on device" means a full disk. Reclaim space with docker system prune

"exec format error"

This means the image was built for a different CPU architecture than your server.

  • Check yours with uname -m: x86_64 is amd64, aarch64 is arm64. Raspberry Pi and other ARM boards are the usual culprits.

Container keeps restarting

The unless-stopped restart policy relaunches the app after every crash, so the real error can scroll past.

  • Check the logs right after a restart, the last few lines before it died are the useful ones.
  • Get the exit code with docker inspect <container> --format '{{.State.ExitCode}}'
  • Still stuck? Redeploy once with the restart policy set to no so the failure stays visible.

Stack won't deploy

Compose stacks fail fast on small mistakes, and Portainer shows the reason just above the editor.

  • YAML only accepts spaces for indentation, a single tab breaks the whole file.

Raise an issue

Found something which isn't working as it should? Here's how to report it.

A Compose stack

Homedex is a Compose stack, a set of containers (2 of them) defined in one file and brought up together by Portainer, then started and stopped as a single app.

The services

This stack is built from 2 containers that run side by side. Here's each one, with the image it runs and anything it waits for first:

  • docker-socket-proxy runs tecnativa/docker-socket-proxy:v0.4.2
  • homedex runs ghcr.io/harshshah0203/homedex:0.2, starts after docker-socket-proxy

Volumes

A volume is where Homedex keeps its files so they survive an update or a restart. Without one, anything it saves would sit inside the container and vanish the moment it's recreated. This template mounts:

  • /var/run/docker.sock from /var/run/docker.sock on the host (a socket it talks to, not storage)
  • /data kept in the homedex-data volume Docker manages

Environment variables

Environment variables are the settings you hand over when you deploy, things like a password or a timezone. Homedex takes 12 of them, all with defaults you can leave alone or tweak:

  • CONTAINERS, defaults to 1
  • IMAGES, defaults to 1
  • INFO, defaults to 1
  • NETWORKS, defaults to 1
  • VERSION, defaults to 1
  • POST, defaults to 0
  • ALLOW_START, defaults to 0
  • ALLOW_STOP, defaults to 0
  • ALLOW_RESTARTS, defaults to 0
  • HOMEDEX_DATA_DIR, defaults to /data
  • HOMEDEX_LISTEN, defaults to :7377
  • HOMEDEX_ADMIN_PASSWORD, pulled from your own environment

Restart policy

The restart policy here is unless-stopped, so Docker restarts Homedex after a crash or reboot, but leaves it off when you stop it on purpose. You can change this on the deploy screen. The choices are no (never restart), on-failure (only after a crash), unless-stopped (restart unless you stop it), and always (bring it back no matter what).

Networking

Portainer puts these services on one shared private network, so they can find each other by name (like docker-socket-proxy) while only the ports above are open to you.

Platform

The platform is linux, the kind of system the container is built to run on. Docker and Portainer handle this on a normal Linux server.

Open source license

Homedex is open source, released under the MIT license. In plain terms the code is out in the open, so you're free to run it and change it to fit what you need.

Portainer app templates

Zooming out, this whole page comes from a Portainer app template: a short recipe telling Portainer how to set Homedex up. Add the template list to Portainer once, then deploying Homedex is a click rather than a wall of config.