Skip to content

Commit

Permalink
Revert build-image Dockerfile
Browse files Browse the repository at this point in the history
Signed-off-by: Matej Vašek <matejvasek@gmail.com>
  • Loading branch information
matejvasek committed Sep 5, 2024
1 parent c8de939 commit 2430be4
Showing 1 changed file with 8 additions and 24 deletions.
32 changes: 8 additions & 24 deletions openshift/ci-operator/build-image/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,27 +1,11 @@
# DO NOT EDIT! Generated Dockerfile.
ARG OCP_VERSION=4.17
ARG GOLANG_VERSION=1.22
FROM registry.ci.openshift.org/ocp/${OCP_VERSION}:tools as tools

# Dockerfile to bootstrap build and test in openshift-ci
FROM registry.ci.openshift.org/openshift/release:rhel-9-release-golang-1.22-openshift-4.17 as builder
FROM registry.ci.openshift.org/ocp/builder:rhel-9-golang-${GOLANG_VERSION}-openshift-${OCP_VERSION}

RUN echo "[kubernetes]" >> /etc/yum.repos.d/kubernetes.repo && \
echo "name=Kubernetes" >> /etc/yum.repos.d/kubernetes.repo && \
echo "baseurl=https://pkgs.k8s.io/core:/stable:/v1.29/rpm/" >> /etc/yum.repos.d/kubernetes.repo && \
echo "enabled=1" >> /etc/yum.repos.d/kubernetes.repo && \
echo "gpgcheck=1" >> /etc/yum.repos.d/kubernetes.repo && \
echo "gpgkey=https://pkgs.k8s.io/core:/stable:/v1.29/rpm/repodata/repomd.xml.key" >> /etc/yum.repos.d/kubernetes.repo
COPY --from=tools /usr/bin/oc /usr/bin/
RUN ln -s /usr/bin/oc /usr/bin/kubectl

RUN yum install -y kubectl httpd-tools

RUN wget https://raw.githubusercontent.com/helm/helm/main/scripts/get-helm-3 && \
chmod 700 ./get-helm-3

RUN ./get-helm-3 --version v3.11.3 --no-sudo && helm version

RUN GOFLAGS='' go install github.com/mikefarah/yq/v3@latest

# go install creates $GOPATH/.cache with root permissions, we delete it here
# to avoid permission issues with the runtime users
RUN rm -rf $GOPATH/.cache

# Allow runtime users to add entries to /etc/passwd
RUN chmod g+rw /etc/passwd
# Reset the goflags to avoid the -mod=vendor flag
ENV GOFLAGS=''

0 comments on commit 2430be4

Please sign in to comment.