Skip to content

Commit

Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
image pushing: configure jobs for all Kubernetes-CSI repos
Browse files Browse the repository at this point in the history
This is part of rolling out multi-architecture image building for GCR,
see kubernetes-csi/csi-release-tools#86
pohly committed May 28, 2020

Verified

This commit was signed with the committer’s verified signature.
frostming Frost Ming
1 parent 822ccd5 commit fa84bf0
Showing 2 changed files with 264 additions and 6 deletions.
53 changes: 53 additions & 0 deletions config/jobs/image-pushing/k8s-staging-csi-gen.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
#! /bin/sh

output="$(dirname $0)/k8s-staging-csi.yaml"
repos="
csi-driver-host-path
csi-test
external-attacher
external-provisioner
external-resizer
external-snapshotter
livenessprobe
node-driver-registrar
"

cat >"$output" <<EOF
# Automatically generated by k8s-staging-csi-gen.sh.
postsubmits:
EOF

for repo in $repos; do
cat >>"$output" <<EOF
kubernetes-csi/$repo:
- name: post-$repo-push-images
cluster: k8s-infra-prow-build-trusted
annotations:
testgrid-dashboards: sig-storage-csi-$repo
decorate: true
branches:
# For publishing canary images. Publishing canary images for release branches can
# be added later, but then will depend on which release branches in each repo have
# the necessary cloud build files.
- ^master$
# This is a regex for semver, from https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string.
# This is okay for upcoming releases, but old releases will not have the necessary cloud build
# files and thus the job will fail.
- ^v(0|[1-9]\d*)\.(0|[1-9]\d*)\.(0|[1-9]\d*)(?:-((?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\.(?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\+([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?$
spec:
serviceAccountName: gcb-builder
containers:
- image: gcr.io/k8s-testimages/image-builder:v20200422-c760048
command:
- /run.sh
args:
# this is the project GCB will run in, which is the same as the GCR
# images are pushed to.
- --project=k8s-staging-csi
# This is the same as above, but with -gcb appended.
- --scratch-bucket=gs://k8s-staging-csi-gcb
- --env-passthrough=PULL_BASE_REF
- .
EOF
done
217 changes: 211 additions & 6 deletions config/jobs/image-pushing/k8s-staging-csi.yaml
Original file line number Diff line number Diff line change
@@ -1,18 +1,223 @@
# Automatically generated by k8s-staging-csi-gen.sh.

postsubmits:
# This is the github repo we'll build from. This block needs to be repeated
# for each repo.
kubernetes-csi/csi-driver-host-path:
- name: post-csi-driver-host-path-push-images
cluster: k8s-infra-prow-build-trusted
annotations:
testgrid-dashboards: sig-storage-csi-csi-driver-host-path
decorate: true
branches:
# For publishing canary images. Publishing canary images for release branches can
# be added later, but then will depend on which release branches in each repo have
# the necessary cloud build files.
- ^master$
# This is a regex for semver, from https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string.
# This is okay for upcoming releases, but old releases will not have the necessary cloud build
# files and thus the job will fail.
- ^v(0|[1-9]\d*)\.(0|[1-9]\d*)\.(0|[1-9]\d*)(?:-((?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\.(?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\+([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?$
spec:
serviceAccountName: gcb-builder
containers:
- image: gcr.io/k8s-testimages/image-builder:v20200422-c760048
command:
- /run.sh
args:
# this is the project GCB will run in, which is the same as the GCR
# images are pushed to.
- --project=k8s-staging-csi
# This is the same as above, but with -gcb appended.
- --scratch-bucket=gs://k8s-staging-csi-gcb
- --env-passthrough=PULL_BASE_REF
- .
kubernetes-csi/csi-test:
- name: post-csi-test-push-images
cluster: k8s-infra-prow-build-trusted
annotations:
testgrid-dashboards: sig-storage-csi-csi-test
decorate: true
branches:
# For publishing canary images. Publishing canary images for release branches can
# be added later, but then will depend on which release branches in each repo have
# the necessary cloud build files.
- ^master$
# This is a regex for semver, from https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string.
# This is okay for upcoming releases, but old releases will not have the necessary cloud build
# files and thus the job will fail.
- ^v(0|[1-9]\d*)\.(0|[1-9]\d*)\.(0|[1-9]\d*)(?:-((?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\.(?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\+([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?$
spec:
serviceAccountName: gcb-builder
containers:
- image: gcr.io/k8s-testimages/image-builder:v20200422-c760048
command:
- /run.sh
args:
# this is the project GCB will run in, which is the same as the GCR
# images are pushed to.
- --project=k8s-staging-csi
# This is the same as above, but with -gcb appended.
- --scratch-bucket=gs://k8s-staging-csi-gcb
- --env-passthrough=PULL_BASE_REF
- .
kubernetes-csi/external-attacher:
- name: post-external-attacher-push-images
cluster: k8s-infra-prow-build-trusted
annotations:
testgrid-dashboards: sig-storage-csi-external-attacher
decorate: true
branches:
# For publishing canary images. Publishing canary images for release branches can
# be added later, but then will depend on which release branches in each repo have
# the necessary cloud build files.
- ^master$
# This is a regex for semver, from https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string.
# This is okay for upcoming releases, but old releases will not have the necessary cloud build
# files and thus the job will fail.
- ^v(0|[1-9]\d*)\.(0|[1-9]\d*)\.(0|[1-9]\d*)(?:-((?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\.(?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\+([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?$
spec:
serviceAccountName: gcb-builder
containers:
- image: gcr.io/k8s-testimages/image-builder:v20200422-c760048
command:
- /run.sh
args:
# this is the project GCB will run in, which is the same as the GCR
# images are pushed to.
- --project=k8s-staging-csi
# This is the same as above, but with -gcb appended.
- --scratch-bucket=gs://k8s-staging-csi-gcb
- --env-passthrough=PULL_BASE_REF
- .
kubernetes-csi/external-provisioner:
- name: post-external-provisioner-push-images
cluster: k8s-infra-prow-build-trusted
annotations:
testgrid-dashboards: sig-storage-csi-external-provisioner
decorate: true
branches:
# For publishing canary images. Publishing canary images for release branches can
# be added later, but then will depend on which release branches in each repo have
# the necessary cloud build files.
- ^master$
# This is a regex for semver, from https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string.
# This is okay for upcoming releases, but old releases will not have the necessary cloud build
# files and thus the job will fail.
- ^v(0|[1-9]\d*)\.(0|[1-9]\d*)\.(0|[1-9]\d*)(?:-((?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\.(?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\+([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?$
spec:
serviceAccountName: gcb-builder
containers:
- image: gcr.io/k8s-testimages/image-builder:v20200422-c760048
command:
- /run.sh
args:
# this is the project GCB will run in, which is the same as the GCR
# images are pushed to.
- --project=k8s-staging-csi
# This is the same as above, but with -gcb appended.
- --scratch-bucket=gs://k8s-staging-csi-gcb
- --env-passthrough=PULL_BASE_REF
- .
kubernetes-csi/external-resizer:
- name: post-external-resizer-push-images
cluster: k8s-infra-prow-build-trusted
annotations:
testgrid-dashboards: sig-storage-csi-external-resizer
decorate: true
branches:
# For publishing canary images. Publishing canary images for release branches can
# be added later, but then will depend on which release branches in each repo have
# the necessary cloud build files.
- ^master$
# This is a regex for semver, from https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string.
# This is okay for upcoming releases, but old releases will not have the necessary cloud build
# files and thus the job will fail.
- ^v(0|[1-9]\d*)\.(0|[1-9]\d*)\.(0|[1-9]\d*)(?:-((?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\.(?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\+([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?$
spec:
serviceAccountName: gcb-builder
containers:
- image: gcr.io/k8s-testimages/image-builder:v20200422-c760048
command:
- /run.sh
args:
# this is the project GCB will run in, which is the same as the GCR
# images are pushed to.
- --project=k8s-staging-csi
# This is the same as above, but with -gcb appended.
- --scratch-bucket=gs://k8s-staging-csi-gcb
- --env-passthrough=PULL_BASE_REF
- .
kubernetes-csi/external-snapshotter:
- name: post-external-snapshotter-push-images
cluster: k8s-infra-prow-build-trusted
annotations:
testgrid-dashboards: sig-storage-csi-external-snapshotter
decorate: true
branches:
# For publishing canary images. Publishing canary images for release branches can
# be added later, but then will depend on which release branches in each repo have
# the necessary cloud build files.
- ^master$
# This is a regex for semver, from https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string.
# This is okay for upcoming releases, but old releases will not have the necessary cloud build
# files and thus the job will fail.
- ^v(0|[1-9]\d*)\.(0|[1-9]\d*)\.(0|[1-9]\d*)(?:-((?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\.(?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\+([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?$
spec:
serviceAccountName: gcb-builder
containers:
- image: gcr.io/k8s-testimages/image-builder:v20200422-c760048
command:
- /run.sh
args:
# this is the project GCB will run in, which is the same as the GCR
# images are pushed to.
- --project=k8s-staging-csi
# This is the same as above, but with -gcb appended.
- --scratch-bucket=gs://k8s-staging-csi-gcb
- --env-passthrough=PULL_BASE_REF
- .
kubernetes-csi/livenessprobe:
- name: post-livenessprobe-push-images
cluster: k8s-infra-prow-build-trusted
annotations:
testgrid-dashboards: sig-storage-csi-livenessprobe
decorate: true
branches:
# For publishing canary images. Publishing canary images for release branches can
# be added later, but then will depend on which release branches in each repo have
# the necessary cloud build files.
- ^master$
# This is a regex for semver, from https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string.
# This is okay for upcoming releases, but old releases will not have the necessary cloud build
# files and thus the job will fail.
- ^v(0|[1-9]\d*)\.(0|[1-9]\d*)\.(0|[1-9]\d*)(?:-((?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\.(?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\+([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?$
spec:
serviceAccountName: gcb-builder
containers:
- image: gcr.io/k8s-testimages/image-builder:v20200422-c760048
command:
- /run.sh
args:
# this is the project GCB will run in, which is the same as the GCR
# images are pushed to.
- --project=k8s-staging-csi
# This is the same as above, but with -gcb appended.
- --scratch-bucket=gs://k8s-staging-csi-gcb
- --env-passthrough=PULL_BASE_REF
- .
kubernetes-csi/node-driver-registrar:
# The name should be changed to match the repo name above
- name: post-node-driver-registrar-push-images
cluster: k8s-infra-prow-build-trusted
annotations:
# This is the name of some testgrid dashboard to report to.
testgrid-dashboards: sig-storage-csi-node-driver-registrar
decorate: true
branches:
# For publishing canary images
# For publishing canary images. Publishing canary images for release branches can
# be added later, but then will depend on which release branches in each repo have
# the necessary cloud build files.
- ^master$
# this is a regex for semver, from https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string
# This is a regex for semver, from https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string.
# This is okay for upcoming releases, but old releases will not have the necessary cloud build
# files and thus the job will fail.
- ^v(0|[1-9]\d*)\.(0|[1-9]\d*)\.(0|[1-9]\d*)(?:-((?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\.(?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\+([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?$
spec:
serviceAccountName: gcb-builder

0 comments on commit fa84bf0

Please sign in to comment.