Skip to content

Commit ee9bb5b

Browse files
authored
Merge pull request trustyai-explainability#11 from red-hat-data-services/RHOAIENG-30264
Add konflux dockerfiles
2 parents d7de2ad + 4863be1 commit ee9bb5b

File tree

1 file changed

+56
-0
lines changed

1 file changed

+56
-0
lines changed

Dockerfile.konflux

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
ARG UBI_MINIMAL_BASE_IMAGE=registry.access.redhat.com/ubi9/ubi-minimal
2+
ARG UBI_BASE_IMAGE_TAG=latest
3+
4+
## Rust builder ################################################################
5+
# Specific debian version so that compatible glibc version is used
6+
FROM rust:1.84.0 AS rust-builder
7+
8+
WORKDIR /app
9+
10+
COPY rust-toolchain.toml rust-toolchain.toml
11+
12+
RUN rustup component add rustfmt
13+
14+
## Gateway builder #########################################################
15+
FROM rust-builder AS gateway-builder
16+
17+
COPY *.toml /app/
18+
COPY src/ /app/src/
19+
# COPY config/config.yaml /app/config/config.yaml
20+
21+
WORKDIR /app
22+
23+
RUN cargo install --root /app/ --path .
24+
25+
## Tests stage ##################################################################
26+
FROM gateway-builder AS tests
27+
RUN cargo test
28+
29+
## Lint stage ###################################################################
30+
FROM gateway-builder AS lint
31+
RUN cargo clippy --all-targets --all-features -- -D warnings
32+
33+
## Formatting check stage #######################################################
34+
FROM gateway-builder AS format
35+
RUN cargo fmt --check
36+
37+
## Release Image ################################################################
38+
39+
FROM ${UBI_MINIMAL_BASE_IMAGE}:${UBI_BASE_IMAGE_TAG} AS gateway-release
40+
ENV GATEWAY_CONFIG=/app/config/config.yaml
41+
COPY config/config.yaml /app/config/config.yaml
42+
43+
COPY --from=gateway-builder /app/bin/ /app/bin/
44+
45+
RUN microdnf install -y --disableplugin=subscription-manager shadow-utils compat-openssl11 && \
46+
microdnf clean all --disableplugin=subscription-manager
47+
48+
CMD ["/app/bin/vllm-orchestrator-gateway"]
49+
50+
LABEL name="rhoai/odh-trustyai-vllm-orchestrator-gateway-rhel9" \
51+
com.redhat.component="odh-trustyai-vllm-orchestrator-gateway-rhel9" \
52+
io.k8s.display-name="odh-trustyai-vllm-orchestrator-gateway-rhel9" \
53+
io.k8s.description="The vLLM Orchestrator Gateway serves as ant HTTP gateway that provides multiple OpenAI-compatible chat completion endpoints with configurable detector-based filtering, routing client requests to a backend orchestrator while adding specific detector configurations per route. It acts as a routing layer that transforms standard chat completion requests by injecting detector specifications and fallback messages, enabling route-specific content filtering policies through a simple REST API gateway pattern." \
54+
description="The vLLM Orchestrator Gateway serves as ant HTTP gateway that provides multiple OpenAI-compatible chat completion endpoints with configurable detector-based filtering, routing client requests to a backend orchestrator while adding specific detector configurations per route. It acts as a routing layer that transforms standard chat completion requests by injecting detector specifications and fallback messages, enabling route-specific content filtering policies through a simple REST API gateway pattern." \
55+
summary="The vLLM Orchestrator Gateway is an OpenAI-compatible REST gateway that routes chat requests with configurable detector-based filtering and route-specific safety policies." \
56+
com.redhat.license_terms="https://www.redhat.com/licenses/Red_Hat_Standard_EULA_20191108.pdf"

0 commit comments

Comments
 (0)