Debian Codegraph @

images/openshift-ci/Dockerfile

raw
1 # This Dockerfile is used by openshift CI
2 # It builds an image containing crc and nss-wrapper for remote deployments, as well as the google cloud-sdk for nested GCE environments.
3
4 FROM registry.ci.openshift.org/openshift/release:rhel-8-release-golang-1.20-openshift-4.15 AS builder
5 WORKDIR /go/src/github.com/crc-org/crc
6 COPY . .
7 RUN make release
8
9 FROM registry.access.redhat.com/ubi9/ubi
10 COPY --from=builder /go/src/github.com/crc-org/crc /opt/crc
11 COPY --from=builder /go/src/github.com/crc-org/crc/out/linux-amd64/crc /bin/crc
12 COPY --from=builder /go/src/github.com/crc-org/crc/out/linux-amd64/e2e.test /bin/e2e.test
13 COPY --from=builder /go/src/github.com/crc-org/crc/out/linux-amd64/integration.test /bin/integration.test
14 COPY --from=builder /go/src/github.com/crc-org/crc/out/windows-amd64/crc.exe /opt/crc.exe
15 COPY --from=builder /go/src/github.com/crc-org/crc/out/windows-amd64/e2e.test.exe /opt/e2e.test.exe
16 COPY --from=builder /go/src/github.com/crc-org/crc/out/windows-amd64/integration.test.exe /opt/integration.test.exe
17 COPY --from=builder /go/src/github.com/crc-org/crc/images/openshift-ci/mock-nss.sh /bin/mock-nss.sh
18 COPY --from=builder /go/src/github.com/crc-org/crc/images/openshift-ci/google-cloud-sdk.repo /etc/yum.repos.d/google-cloud-sdk.repo
19 COPY --from=builder /go/src/github.com/crc-org/crc/images/openshift-ci/azure-cli.repo /etc/yum.repos.d/azure-cli.repo
20
21 RUN yum update -y && \
22 yum install --setopt=tsflags=nodocs -y \
23 google-cloud-sdk \
24 nss_wrapper \
25 unzip \
26 sshpass \
27 jq \
28 azure-cli \
29 openssh-clients && \
30 yum clean all && rm -rf /var/cache/yum/*
31 RUN mkdir /output && chown 1000:1000 /output
32 USER 1000:1000
33 ENV PATH /bin
34 ENV HOME /output
35 WORKDIR /output