From 1221c843bf7ac81fc16d3e5a6e7f1a7bb55e989d Mon Sep 17 00:00:00 2001 From: Nikita ROUSSEAU <48907457+nirousseau@users.noreply.github.com> Date: Fri, 19 Sep 2025 14:24:01 +0200 Subject: [PATCH 1/3] Create Containerfile --- Containerfile | 50 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) create mode 100644 Containerfile diff --git a/Containerfile b/Containerfile new file mode 100644 index 0000000000..675a9549fd --- /dev/null +++ b/Containerfile @@ -0,0 +1,50 @@ +ARG OPENMAXIO_TAG=v1.7.6 + +FROM alpine/git:latest as git + +WORKDIR /app + +RUN git clone -b "${OPENMAXIO_TAG}" --single-branch --depth 1 https://github.com/OpenMaxIO/openmaxio-object-browser \ + && pwd \ + && ls -lah ./openmaxio-object-browser + +######################################################################################################################## +FROM node:18 as uilayer + +WORKDIR /app + +COPY --from=git /app/openmaxio-object-browser/web-app . + +RUN corepack enable && corepack prepare +RUN yarn install && yarn build + +######################################################################################################################## +FROM golang:1.24 as golayer + +WORKDIR /go/src/github.com/minio/console/ + +RUN apt-get update -y && apt-get install -y ca-certificates + +COPY --from=git /app/openmaxio-object-browser/go.mod go.mod +COPY --from=git /app/openmaxio-object-browser/go.sum go.sum + +# Get dependencies - will also be cached if we won't change mod/sum +RUN go mod download + +COPY --from=git /app/openmaxio-object-browser . +ENV CGO_ENABLED=0 + +COPY --from=uilayer /app/build web-app/build +RUN go build --tags=kqueue,operator -ldflags "-w -s" -a -o console ./cmd/console + +######################################################################################################################## +FROM redhat/ubi9:latest +EXPOSE 9090 + +COPY --from=golayer /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/ +COPY --from=golayer /go/src/github.com/minio/console/console . + +RUN ./console --version + +ENTRYPOINT ["/console"] +CMD ["server"] From 8711a4a3432362467f8d497f18f6c39dc34ada47 Mon Sep 17 00:00:00 2001 From: Nikita ROUSSEAU <48907457+nirousseau@users.noreply.github.com> Date: Fri, 19 Sep 2025 14:36:02 +0200 Subject: [PATCH 2/3] Update Containerfile --- Containerfile | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/Containerfile b/Containerfile index 675a9549fd..3e6be45672 100644 --- a/Containerfile +++ b/Containerfile @@ -1,15 +1,16 @@ -ARG OPENMAXIO_TAG=v1.7.6 +ARG OPENMAXIO_TAG="v1.7.6" +ARG NODE_VERSION="18" +ARG GOLANG_VERSION="1.24" FROM alpine/git:latest as git WORKDIR /app -RUN git clone -b "${OPENMAXIO_TAG}" --single-branch --depth 1 https://github.com/OpenMaxIO/openmaxio-object-browser \ - && pwd \ - && ls -lah ./openmaxio-object-browser +ENV GIT_BRANCH="${OPENMAXIO_TAG}" +RUN git clone -b "${GIT_BRANCH}" --single-branch --depth 1 https://github.com/OpenMaxIO/openmaxio-object-browser ######################################################################################################################## -FROM node:18 as uilayer +FROM node:${NODE_VERSION} as uilayer WORKDIR /app @@ -19,7 +20,7 @@ RUN corepack enable && corepack prepare RUN yarn install && yarn build ######################################################################################################################## -FROM golang:1.24 as golayer +FROM golang:${GOLANG_VERSION} as golayer WORKDIR /go/src/github.com/minio/console/ From 33da1c6a7b2588de9e4a5ee03e5e4ee76e261047 Mon Sep 17 00:00:00 2001 From: Nikita ROUSSEAU <48907457+nirousseau@users.noreply.github.com> Date: Fri, 19 Sep 2025 14:39:18 +0200 Subject: [PATCH 3/3] Update Containerfile --- Containerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Containerfile b/Containerfile index 3e6be45672..1cb7b8adaf 100644 --- a/Containerfile +++ b/Containerfile @@ -1,8 +1,8 @@ -ARG OPENMAXIO_TAG="v1.7.6" ARG NODE_VERSION="18" ARG GOLANG_VERSION="1.24" FROM alpine/git:latest as git +ARG OPENMAXIO_TAG="v1.7.6" WORKDIR /app