Skip to content

Commit

Permalink
chore(RHTAPREL-435): pin base image and update labels
Browse files Browse the repository at this point in the history
- pin base image in Dockerfile
- specify labels that we should not be overriding

Signed-off-by: Scott Hebert <[email protected]>
  • Loading branch information
scoheb committed Oct 11, 2023
1 parent 4c7ee6d commit 4fbd2b4
Showing 1 changed file with 16 additions and 8 deletions.
24 changes: 16 additions & 8 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM registry.access.redhat.com/ubi8/ubi
FROM registry.access.redhat.com/ubi8/ubi:8.8-1067.1696517599

ARG COSIGN_VERSION=2.1.1
ARG KUBECTL_VERSION=1.27.2
Expand All @@ -7,13 +7,14 @@ ARG JQ_VERSION=1.6
ARG YQ_VERSION=4.34.1
ARG GLAB_VERSION=1.31.0

RUN curl -L https://github.com/stedolan/jq/releases/download/jq-{JQ_VERSION}/jq-linux64 -o /usr/bin/jq &&\
curl -L https://github.com/mikefarah/yq/releases/download/v${YQ_VERSION}/yq_linux_amd64 -o /usr/bin/yq &&\
curl -L https://dl.k8s.io/release/v${KUBECTL_VERSION}/bin/linux/amd64/kubectl -o /usr/bin/kubectl &&\
curl -L https://mirror.openshift.com/pub/openshift-v4/x86_64/clients/ocp/${OCP_VERSION}/opm-linux.tar.gz |tar -C /usr/bin -xzf - &&\
curl -L https://gitlab.com/gitlab-org/cli/-/releases/v${GLAB_VERSION}/downloads/glab_${GLAB_VERSION}_Linux_x86_64.tar.gz | tar -C /usr -xzf - bin/glab &&\
chmod +x /usr/bin/{jq,yq,kubectl,opm,glab} &&\
rpm -ivh https://github.com/sigstore/cosign/releases/download/v${COSIGN_VERSION}/cosign-${COSIGN_VERSION}.x86_64.rpm
#RUN curl -L https://github.com/stedolan/jq/releases/download/jq-{JQ_VERSION}/jq-linux64 -o /usr/bin/jq
RUN curl -L https://github.com/mikefarah/yq/releases/download/v${YQ_VERSION}/yq_linux_amd64 -o /usr/bin/yq
RUN curl -L https://dl.k8s.io/release/v${KUBECTL_VERSION}/bin/linux/amd64/kubectl -o /usr/bin/kubectl
#RUN curl -L https://mirror.openshift.com/pub/openshift-v4/x86_64/clients/ocp/${OCP_VERSION}/opm-linux.tar.gz |tar -C /usr/bin -xzf -
RUN curl -L https://gitlab.com/gitlab-org/cli/-/releases/v${GLAB_VERSION}/downloads/glab_${GLAB_VERSION}_Linux_x86_64.tar.gz | tar -C /usr -xzf - bin/glab
#RUN chmod +x /usr/bin/{jq,yq,kubectl,opm,glab}
RUN chmod +x /usr/bin/{yq,kubectl,glab}
RUN rpm -ivh https://github.com/sigstore/cosign/releases/download/v${COSIGN_VERSION}/cosign-${COSIGN_VERSION}.x86_64.rpm

RUN dnf -y --setopt=tsflags=nodocs install \
git \
Expand All @@ -36,6 +37,13 @@ COPY pyxis /home/pyxis
COPY utils /home/utils
COPY templates /home/templates

# It is mandatory to set these labels
LABEL description="RHTAP Release Service Utils"
LABEL io.k8s.description="RHTAP Release Service Utils"
LABEL io.k8s.display-name="release-service-utils"
LABEL io.openshift.tags="rhtap"
LABEL summary="RHTAP Release Service Utils"

# Set HOME variable to something else than `/` to avoid 'permission denied' problems when writing files.
ENV HOME=/tekton/home
ENV PATH="$PATH:/home/pyxis:/home/utils"

0 comments on commit 4fbd2b4

Please sign in to comment.