Skip to content

Commit

Permalink
Rebased with Master
Browse files Browse the repository at this point in the history
Signed-off-by: Rehan Khan <[email protected]>
  • Loading branch information
R3hankhan123 committed Sep 20, 2024
1 parent dd6dd68 commit 77fd619
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 9 deletions.
13 changes: 8 additions & 5 deletions backend/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,14 @@ RUN python3 -m pip install -r requirements.txt --no-cache-dir

# Downloading Argo CLI so that the samples are validated
ENV ARGO_VERSION v3.4.17
RUN curl -sLO https://github.com/argoproj/argo-workflows/releases/download/${ARGO_VERSION}/argo-linux-amd64.gz && \
gunzip argo-linux-amd64.gz && \
chmod +x argo-linux-amd64 && \
mv ./argo-linux-amd64 /usr/local/bin/argo

RUN ARCH=$(uname -m); \
if [ "$ARCH" = "x86_64" ]; then \
ARCH="amd64"; \
fi \
&& curl -sLO https://github.com/argoproj/argo-workflows/releases/download/${ARGO_VERSION}/argo-linux-${ARCH}.gz && \
gunzip argo-linux-${ARCH}.gz && \
chmod +x argo-linux-${ARCH} && \
mv ./argo-linux-${ARCH} /usr/local/bin/argo
WORKDIR /
COPY ./samples /samples
COPY backend/src/apiserver/config/sample_config.json /samples/
Expand Down
6 changes: 5 additions & 1 deletion backend/Dockerfile.driver
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,11 @@ FROM golang:1.21.7-alpine3.19 as builder
WORKDIR /go/src/github.com/kubeflow/pipelines
COPY . .

RUN GO111MODULE=on CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -tags netgo -ldflags '-extldflags "-static"' -o /bin/driver ./backend/src/v2/cmd/driver/*.go
RUN ARCH=$(uname -m) && \
if [ "$ARCH" = "x86_64" ]; then \
ARCH="amd64"; \
fi && \
GO111MODULE=on CGO_ENABLED=0 GOOS=linux GOARCH=$ARCH go build -tags netgo -ldflags '-extldflags "-static"' -o /bin/driver ./backend/src/v2/cmd/driver/*.go

# Check licenses and comply with license terms.
RUN ./hack/install-go-licenses.sh
Expand Down
6 changes: 5 additions & 1 deletion backend/Dockerfile.launcher
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,11 @@ FROM golang:1.21.7-alpine3.19 as builder
WORKDIR /go/src/github.com/kubeflow/pipelines
COPY . .

RUN GO111MODULE=on CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -tags netgo -ldflags '-extldflags "-static"' -o /bin/launcher-v2 ./backend/src/v2/cmd/launcher-v2/*.go
RUN ARCH=$(uname -m) && \
if [ "$ARCH" = "x86_64" ]; then \
ARCH="amd64"; \
fi && \
GO111MODULE=on CGO_ENABLED=0 GOOS=linux GOARCH=$ARCH go build -tags netgo -ldflags '-extldflags "-static"' -o /bin/launcher-v2 ./backend/src/v2/cmd/launcher-v2/*.go

# Check licenses and comply with license terms.
RUN ./hack/install-go-licenses.sh
Expand Down
4 changes: 2 additions & 2 deletions backend/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ image_visualization:
cd $(MOD_ROOT) && ${CONTAINER_ENGINE} build -t ${IMG_TAG_VISUALIZATION} -f backend/Dockerfile.visualization .
.PHONY: image_driver
image_driver:
cd $(MOD_ROOT) && ${CONTAINER_ENGINE} build -t ${IMG_TAG_DRIVER} -f backend/Dockerfile.driver .
cd $(MOD_ROOT) && ${CONTAINER_ENGINE} buildx build --platform $(PLATFORMS) ${IMG_TAG_DRIVER} -f backend/Dockerfile.driver --push .
.PHONY: image_launcher
image_launcher:
cd $(MOD_ROOT) && ${CONTAINER_ENGINE} build -t ${IMG_TAG_LAUNCHER} -f backend/Dockerfile.launcher .
cd $(MOD_ROOT) && ${CONTAINER_ENGINE} buildx build --platform $(PLATFORMS)${IMG_TAG_LAUNCHER} -f backend/Dockerfile.launcher --push .

0 comments on commit 77fd619

Please sign in to comment.