-
Notifications
You must be signed in to change notification settings - Fork 29
set up new release tooling for controller/sidecar subrepos #97
set up new release tooling for controller/sidecar subrepos #97
Conversation
Skipping CI for Draft Pull Request. |
I think this is ready, but I want to test at least the basics of this locally in the gcr.io/k8s-testimages/gcb-docker-gcloud:v20240718-5ef92b5c36 image. |
fc4cbd1
to
ecff9f8
Compare
I've done the best testing I can do of this at the current moment. Once monorepo is merged to master, the cloudbuild jobs set up for sig-storage projects will start working. The cloudbuild is only initiated for This config comes from a template script, so I think we'll just have to wait. Nothing will be pushed to a release repo without manual action, so it should be safe. |
Instead of a |
Set up new cloudbuild tooling for the controller/sidecar subrepo layout. Controller and sidecar are both always built pushed to staging with the current git tag (e.g., v20240905-v0.1.0-58-g80979e8) as well as 'latest'. Controller pre-release staging build can be initiated by creating a github release (or tag) in the form `cloudbuild/TAG`. Similarly, sidecar pre-release staging build can be initiated by creating a github release (or tag) in the form `sidecar/TAG`. Signed-off-by: Blaine Gardner <[email protected]>
ecff9f8
to
0c28097
Compare
substitutions: | ||
# K8s provides custom substitutions _GIT_TAG and _PULL_BASE_REF: | ||
# https://github.com/kubernetes/test-infra/blob/master/config/jobs/image-pushing/README.md#custom-substitutions | ||
_GIT_TAG: '12345' # e.g., vYYYYMMDD-hash, vYYYYMMDD-tag, or vYYYYMMDD-tag-n-ghash |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe just leave it as an empty string?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is copy-pasted from the previous cloudbuild files -- copy-pasted from an example that I found in some docs. I don't know exactly why, but IIRC it was in the example file as well, so it seemed like it might have some use for testing/validation.
export CONTROLLER_TAG="${CONTROLLER_IMAGE}:${GIT_TAG}" | ||
|
||
# build in parallel | ||
make --jobs --output-sync build |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there any benefit for multiprocessing here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In my local testing, this increases the build speed, but it isn't significant. Maybe a 20-30% improvement. I am also testing on macos where the linux native tools don't run as efficiently. It would be hard to guess whether the improvement on the linux build environments would be more or less impactful.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/lgtm
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: BlaineEXE, shanduur The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Set up new cloudbuild tooling for the controller/sidecar subrepo layout.
Controller and sidecar are both always built pushed to staging with the current git tag (e.g., v20240905-v0.1.0-58-g80979e8) as well as 'latest'.
Controller pre-release staging build can be initiated by creating a github release (or tag) in the form
cloudbuild/TAG
.Similarly, sidecar pre-release staging build can be initiated by creating a github release (or tag) in the form
sidecar/TAG
.