infra-dashboard/Dockerfile
Maddox ea9f8fca25 Initial commit - shareable infra dashboard
Externalize hardcoded host inventory and diagram topology into
JSON config files (hosts.json, diagram.json) loaded at runtime.
Add .env for configurable port, SSH key path, and refresh interval.
Include example configs and README for standalone deployment.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-03 14:57:56 -05:00

14 lines
593 B
Docker

FROM python:3.12-slim
WORKDIR /app
RUN apt-get update && apt-get install -y --no-install-recommends openssh-client gosu && rm -rf /var/lib/apt/lists/*
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
COPY app.py .
COPY templates/ templates/
COPY entrypoint.sh /entrypoint.sh
RUN mkdir -p /app/ssh /app/config && chmod 700 /app/ssh
RUN useradd -m -s /bin/bash dashboard && chown -R dashboard:dashboard /app
RUN chmod +x /entrypoint.sh
ENV PYTHONUNBUFFERED=1 REFRESH_INTERVAL=60 SSH_TIMEOUT=10 SSH_KEY_PATH=/app/ssh/id_ed25519
EXPOSE 5000
ENTRYPOINT ["/entrypoint.sh"]