feat: add cert-manager crds
continuous-integration/drone/push Build is passing Details

This commit is contained in:
Robert Kaussow 2023-01-24 09:21:27 +01:00
parent 2a0bf090ed
commit 5223e1a98a
Signed by: xoxys
GPG Key ID: 4E692A2EAECC03C0
3 changed files with 12 additions and 1 deletions

View File

@ -29,6 +29,8 @@ ENV KUBECONFORM_VERSION="${KUBECONFORM_VERSION:-v0.5.0}"
ENV CALICO_VERSION="${CALICO_VERSION:-v3.25.0}"
# renovate: datasource=github-releases depName=fluxcd/flux2
ENV FLUXCD_VERSION="${FLUXCD_VERSION:-v0.38.3}"
# renovate: datasource=github-releases depName=cert-manager/cert-manager
ENV CERTMANAGER_VERSION="${CERTMANAGER_VERSION:-v1.11.0}"
RUN apk --update add curl tar bash python3 py3-yaml && \
curl -SsfL -o /usr/local/bin/kubectl "https://dl.k8s.io/release/${KUBECTL_VERSION}/bin/linux/amd64/kubectl" && \
@ -50,12 +52,16 @@ RUN apk --update add curl tar bash python3 py3-yaml && \
chmod 755 /usr/local/bin/openapi2jsonschema && \
mkdir -p /etc/kube-tools/schemas/flux/master-standalone-strict && \
mkdir -p /etc/kube-tools/schemas/calico/master-standalone-strict && \
mkdir -p /etc/kube-tools/schemas/cert-manager/master-standalone-strict && \
curl -SsfL "https://github.com/fluxcd/flux2/releases/download/${FLUXCD_VERSION}/crd-schemas.tar.gz" \
| tar xz -C /etc/kube-tools/schemas/flux/master-standalone-strict && \
curl -SsfL -o /tmp/calico.crds.yaml "https://raw.githubusercontent.com/projectcalico/calico/${CALICO_VERSION}/manifests/calico.yaml" && \
cd /etc/kube-tools/schemas/calico/master-standalone-strict && \
openapi2jsonschema /tmp/calico.crds.yaml && \
for file in *.json ; do mv $file ${file//_v1/_v3} ; done && \
curl -SsfL -o /tmp/cert-manager.crds.yaml "https://github.com/cert-manager/cert-manager/releases/download/${CERTMANAGER_VERSION}/cert-manager.crds.yaml" && \
cd /etc/kube-tools/schemas/cert-manager/master-standalone-strict && \
openapi2jsonschema /tmp/cert-manager.crds.yaml && \
rm -rf /var/cache/apk/* && \
rm -rf /tmp/*

View File

@ -40,6 +40,7 @@ kubeconform_config=(
"-schema-location" "default"
"-schema-location" "/etc/kube-tools/schemas/flux"
"-schema-location" "/etc/kube-tools/schemas/calico/master-standalone-strict/{{ .ResourceKind }}_{{ .ResourceAPIVersion }}.json"
"-schema-location" "/etc/kube-tools/schemas/cert-manager/master-standalone-strict/{{ .ResourceKind }}_{{ .ResourceAPIVersion }}.json"
"-exit-on-error"
"-summary"
"-skip" "Secret,CustomResourceDefinition"

View File

@ -7,7 +7,11 @@
"extractVersion": "^kustomize\\/(?<version>v\\d+\\.\\d+\\.\\d+)$"
},
{
"matchPackageNames": ["fluxcd/flux2", "projectcalico/calico"],
"matchPackageNames": [
"fluxcd/flux2",
"projectcalico/calico",
"cert-manager/cert-manager"
],
"automerge": true
},
{