Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions .github/workflows/docker-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ jobs:
packages: write
strategy:
matrix:
image: [extproc, llm-katan, dashboard]
image: [extproc, llm-katan, dashboard, model-downloader]
# Multi-architecture build strategy:
# - AMD64: Native build on ubuntu-latest (fast)
# - ARM64: Cross-compilation on ubuntu-latest (faster than emulation)
Expand Down Expand Up @@ -171,6 +171,10 @@ jobs:
echo "context=." >> $GITHUB_OUTPUT
echo "dockerfile=./dashboard/backend/Dockerfile" >> $GITHUB_OUTPUT
echo "platform=linux/${{ matrix.arch }}" >> $GITHUB_OUTPUT
elif [ "${{ matrix.image }}" = "model-downloader" ]; then
echo "context=." >> $GITHUB_OUTPUT
echo "dockerfile=./Dockerfile.model-downloader" >> $GITHUB_OUTPUT
echo "platform=linux/${{ matrix.arch }}" >> $GITHUB_OUTPUT
fi

- name: Generate tags
Expand Down Expand Up @@ -236,7 +240,7 @@ jobs:
packages: write
strategy:
matrix:
image: [extproc, llm-katan, dashboard]
image: [extproc, llm-katan, dashboard, model-downloader]

steps:
- name: Log in to GitHub Container Registry
Expand Down
24 changes: 24 additions & 0 deletions Dockerfile.model-downloader
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
FROM python:3.11-slim

# Set environment variables
ENV PIP_DISABLE_PIP_VERSION_CHECK=1 \
PIP_NO_CACHE_DIR=1 \
PYTHONUNBUFFERED=1

# Add OCI labels
LABEL org.opencontainers.image.source="https://github.com/vllm-project/semantic-router" \
org.opencontainers.image.description="Lightweight model downloader for Semantic Router with huggingface_hub pre-installed"

WORKDIR /app

# Install minimal dependencies in a single layer
RUN apt-get update && \
apt-get install -y --no-install-recommends \
ca-certificates \
&& rm -rf /var/lib/apt/lists/* /var/cache/apt/archives/* \
&& pip install --no-cache-dir "huggingface_hub>=0.19.0" \
&& find /usr/local -type d -name '__pycache__' -exec rm -rf {} + 2>/dev/null || true \
&& find /usr/local -type f -name '*.pyc' -delete

# Set default entrypoint to bash to allow script execution from arguments
ENTRYPOINT ["/bin/bash", "-c"]
Loading