Skip to content
Merged
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
3 changes: 2 additions & 1 deletion Containerfile
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,8 @@ COPY --from=builder /app-root/LICENSE /licenses/
# Add uv to final image for derived images to add additional dependencies
# with command:
# $ uv pip install <dependency>
RUN pip3.12 install "uv==0.8.15"
# Temporarily disabled due to temp directory issues
# RUN pip3.12 install "uv==0.8.15"

USER root

Expand Down
8 changes: 6 additions & 2 deletions docker-compose.yaml
Original file line number Diff line number Diff line change
@@ -1,15 +1,19 @@
services:
# Red Hat llama-stack distribution with FAISS
llama-stack:
build:
context: .
dockerfile: test.containerfile
platform: linux/amd64
container_name: llama-stack
ports:
- "8321:8321" # Expose llama-stack on 8321 (adjust if needed)
volumes:
- ./run.yaml:/app-root/run.yaml:Z
- ./run.yaml:/opt/app-root/run.yaml:Z
environment:
- OPENAI_API_KEY=${OPENAI_API_KEY}
- BRAVE_SEARCH_API_KEY=${BRAVE_SEARCH_API_KEY:-}
- TAVILY_SEARCH_API_KEY=${TAVILY_SEARCH_API_KEY:-}
networks:
- lightspeednet
healthcheck:
Expand Down Expand Up @@ -44,4 +48,4 @@ services:

networks:
lightspeednet:
driver: bridge
driver: bridge
40 changes: 12 additions & 28 deletions test.containerfile
Original file line number Diff line number Diff line change
@@ -1,28 +1,12 @@
# vim: set filetype=dockerfile
FROM registry.access.redhat.com/ubi9/ubi-minimal

ARG APP_ROOT=/app-root

ENV PATH="$PATH:/root/.local/bin"

WORKDIR ${APP_ROOT}
COPY run.yaml ./
COPY pyproject.toml ./
COPY uv.lock ./
COPY LICENSE ./
COPY README.md ./
COPY src/ ./src/

RUN microdnf install -y --nodocs --setopt=keepcache=0 --setopt=tsflags=nodocs \
python3.12 python3.12-devel python3.12-pip git tar gcc gcc-c++ make

RUN curl -LsSf https://astral.sh/uv/install.sh | sh

RUN uv -h

# Install from pyproject.toml using uv sync for version consistency
# Note: using --no-install-project since this is llama-stack container, not lightspeed-stack
# Include dev deps for testing (pytest, behave, etc.)
RUN uv sync --locked --no-install-project --group dev --group llslibdev

CMD ["uv", "run", "llama", "stack", "run", "run.yaml"]
# Custom Red Hat llama-stack image with missing dependencies
FROM quay.io/opendatahub/llama-stack:rhoai-v2.25-latest

# Install missing dependencies
USER root
RUN pip install faiss-cpu==1.11.0 && \
mkdir -p /app-root && \
chown -R 1001:0 /app-root && \
chmod -R 775 /app-root

# Switch back to the original user
USER 1001
Loading