-
Notifications
You must be signed in to change notification settings - Fork 270
/
Dockerfile
69 lines (57 loc) · 2.93 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
# Builder
FROM registry.access.redhat.com/ubi9/ubi:9.4-1123.1719560047@sha256:081c96d1b1c7cd1855722d01f1ca53360510443737b1eb33284c6c4c330e537c AS builder
SHELL ["/bin/bash", "-c"]
# renovate: datasource=github-releases depName=stedolan/jq
ARG JQ_VERSION=1.6
# renovate: datasource=github-releases depName=mikefarah/yq
ARG YQ_VERSION=v4.44.3
# renovate: datasource=github-releases depName=helm/helm
ARG HELM_VERSION=v3.16.1
# renovate: datasource=github-releases depName=open-policy-agent/conftest
ARG CONFTEST_VERSION=v0.55.0
# renovate: datasource=github-releases depName=stackrox/kube-linter
ARG KUBE_LINTER_VERSION=v0.6.8
# renovate: datasource=github-releases depName=helm/chart-testing
ARG CT_VERSION=v3.11.0
RUN curl -L "https://github.com/stedolan/jq/releases/download/jq-${JQ_VERSION}/jq-linux64" -o /usr/local/bin/jq && \
chmod +x /usr/local/bin/jq && \
jq --version
RUN curl -L "https://github.com/mikefarah/yq/releases/download/${YQ_VERSION}/yq_linux_amd64" -o /usr/local/bin/yq && \
chmod +x /usr/local/bin/yq && \
yq --version
RUN curl -L "https://get.helm.sh/helm-${HELM_VERSION}-linux-amd64.tar.gz" -o /tmp/helm.tar.gz && \
tar -xzf /tmp/helm.tar.gz && \
mv linux-amd64/helm /usr/local/bin/helm && \
helm version
RUN curl -L "https://github.com/open-policy-agent/conftest/releases/download/${CONFTEST_VERSION}/conftest_${CONFTEST_VERSION//v}_Linux_x86_64.tar.gz" -o /tmp/conftest.tar.gz && \
tar -xzf /tmp/conftest.tar.gz && \
mv conftest /usr/local/bin/conftest && \
conftest --version
RUN curl -L "https://github.com/stackrox/kube-linter/releases/download/${KUBE_LINTER_VERSION}/kube-linter-linux.tar.gz" -o /tmp/kube-linter-linux.tar.gz && \
tar -xzf /tmp/kube-linter-linux.tar.gz && \
mv kube-linter /usr/local/bin/kube-linter && \
kube-linter version
RUN curl -L "https://github.com/helm/chart-testing/releases/download/${CT_VERSION}/chart-testing_${CT_VERSION//v}_linux_amd64.tar.gz" -o /tmp/chart-testing.tar.gz && \
tar -C /tmp -xzf /tmp/chart-testing.tar.gz && \
mv /tmp/ct /usr/local/bin/ct && \
ct version
# Runnable
FROM ghcr.io/redhat-cop/containers-quickstarts/jenkins-agent-python:v4.16
LABEL name="redhat-cop/jenkins-agent-helm" \
io.k8s.display-name="Jenkins Agent helm" \
io.k8s.description="The jenkins agent helm." \
com.redhat.component="redhat-cop/containers-quickstarts/jenkins-agent-helm"
COPY --from=builder /usr/local/bin/jq /usr/local/bin/jq
COPY --from=builder /usr/local/bin/yq /usr/local/bin/yq
COPY --from=builder /usr/local/bin/helm /usr/local/bin/helm
COPY --from=builder /usr/local/bin/conftest /usr/local/bin/conftest
COPY --from=builder /usr/local/bin/kube-linter /usr/local/bin/kube-linter
COPY --from=builder /usr/local/bin/ct /usr/local/bin/ct
COPY --from=builder /tmp/etc ${HOME}/.ct
RUN jq --version && \
yq --version && \
helm version && \
conftest --version && \
kube-linter version && \
ct version && \
ls -l "${HOME}/.ct"