OpenRAG is a comprehensive, single package Retrieval-Augmented Generation platform built on Langflow, Docling, and Opensearch.
Python
operator ubi base build (#1652)
mingfb7c7e513e96
diff --git a/.github/workflows/operator-ci.yml b/.github/workflows/operator-ci.ymlindex 72e40f477..5db9aa791 100644--- a/.github/workflows/operator-ci.yml+++ b/.github/workflows/operator-ci.yml@@ -108,5 +108,8 @@ jobs:file: kubernetes/operator/Dockerfileplatforms: linux/amd64push: false+ build-args: |+ TARGETOS=linux+ TARGETARCH=amd64cache-from: type=gha,scope=operator-amd64cache-to: type=gha,mode=max,scope=operator-amd64diff --git a/.github/workflows/operator-release.yml b/.github/workflows/operator-release.ymlindex c7315bfea..b971454cb 100644--- a/.github/workflows/operator-release.yml+++ b/.github/workflows/operator-release.yml@@ -60,6 +60,9 @@ jobs:platforms: ${{ matrix.platform }}push: truetags: ${{ env.IMAGE }}:${{ steps.tag.outputs.value }}-${{ matrix.arch }}+ build-args: |+ TARGETOS=linux+ TARGETARCH=${{ matrix.arch }}cache-from: type=gha,scope=operator-${{ matrix.arch }}cache-to: type=gha,mode=max,scope=operator-${{ matrix.arch }}diff --git a/kubernetes/helm/operator/values.yaml b/kubernetes/helm/operator/values.yamlindex fac8a9219..86de9396f 100644--- a/kubernetes/helm/operator/values.yaml+++ b/kubernetes/helm/operator/values.yaml@@ -47,7 +47,7 @@ securityContext:- ALL# readOnlyRootFilesystem: true# runAsNonRoot: true- # runAsUser: 1000+ # runAsUser: 65532 # Match Dockerfile default, or use any non-root UID# Resource limits and requestsresources:diff --git a/kubernetes/operator/Dockerfile b/kubernetes/operator/Dockerfileindex 4a6a070a9..d4e175fff 100644--- a/kubernetes/operator/Dockerfile+++ b/kubernetes/operator/Dockerfile@@ -1,4 +1,7 @@FROM golang:1.26.0 AS builder+ARG TARGETOS+ARG TARGETARCH+WORKDIR /workspaceCOPY go.mod go.sum ./@@ -8,10 +11,19 @@ COPY api/ api/COPY cmd/ cmd/COPY internal/ internal/-RUN CGO_ENABLED=0 GOOS=linux go build -a -o manager cmd/main.go+RUN CGO_ENABLED=0 GOOS=${TARGETOS:-linux} GOARCH=${TARGETARCH} go build -a -o manager cmd/main.go++FROM registry.access.redhat.com/ubi9/ubi-minimal:latest++# Install necessary CA certificates for HTTPS connections+RUN microdnf install -y ca-certificates && \+ microdnf clean all && \+ rm -rf /var/cache/yum-FROM gcr.io/distroless/static:nonrootWORKDIR /COPY --from=builder /workspace/manager .++# Use non-root user (default ubi-minimal user)USER 65532:65532+ENTRYPOINT ["/manager"]diff --git a/kubernetes/operator/Makefile b/kubernetes/operator/Makefileindex 134ff6d17..d5438be40 100644--- a/kubernetes/operator/Makefile+++ b/kubernetes/operator/Makefile@@ -87,16 +87,22 @@ run: manifests generate fmt vet ## Run the operator locally (uses current kubecogo run ./cmd/main.go.PHONY: docker-build-docker-build: ## Build the operator container image.- $(CONTAINER_TOOL) build -t $(IMG) .+docker-build: ## Build the operator container image for the local platform.+ $(CONTAINER_TOOL) build -t $(IMG) \+ --build-arg TARGETOS=linux \+ --build-arg TARGETARCH=$$(go env GOARCH) \+ ..PHONY: docker-pushdocker-push: ## Push the operator container image.$(CONTAINER_TOOL) push $(IMG).PHONY: docker-buildx-docker-buildx: ## Build and push multi-arch image via buildx.- $(CONTAINER_TOOL) buildx build --platform linux/amd64,linux/arm64 --push -t $(IMG) .+docker-buildx: ## Build and push multi-arch image (amd64 + arm64) via buildx.+ $(CONTAINER_TOOL) buildx build \+ --platform linux/amd64,linux/arm64 \+ --build-arg TARGETOS=linux \+ --push -t $(IMG) .##@ Deployment