Skip to content

Add config for staging repo image build#77

Merged
k8s-ci-robot merged 1 commit intokubernetes-sigs:mainfrom
nojnhuh:cloudbuild
Feb 26, 2025
Merged

Add config for staging repo image build#77
k8s-ci-robot merged 1 commit intokubernetes-sigs:mainfrom
nojnhuh:cloudbuild

Conversation

@nojnhuh
Copy link
Contributor

@nojnhuh nojnhuh commented Feb 20, 2025

This PR adds a cloudbuild.yaml which serves as input to kubernetes/test-infra#34376 which defines how images should be built and pushed to the new staging repo added by kubernetes/k8s.io#7703.

Part of #64

@k8s-ci-robot k8s-ci-robot requested review from byako and pohly February 20, 2025 17:43
@k8s-ci-robot k8s-ci-robot added cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Feb 20, 2025
Copy link
Contributor

@pohly pohly left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks similar to things I did with cloudbuild in the past, but I don't remember enough to determine upfront whether it will work.

Has this been tested manually somehow or do we need to merge and then check whether it works?

@nojnhuh
Copy link
Contributor Author

nojnhuh commented Feb 20, 2025

This looks similar to things I did with cloudbuild in the past, but I don't remember enough to determine upfront whether it will work.

Has this been tested manually somehow or do we need to merge and then check whether it works?

I tried invoking the scripts that this runs, but I didn't try actually feeding it to cloudbuild. I expect that when this PR and kubernetes/test-infra#34376 merge, then subsequent merges to main in this repo will trigger the job and we'll see results on testgrid.

I put a hold on the test-infra PR to wait for this PR to merge first, but maybe if we time it so this PR merges right after that one, then we can get some immediate feedback whether or not it's working as expected. In the meantime I can try to trigger a build locally if that's acceptable, but I haven't touched any Google Cloud things before so please let me know if there's any damage I'm able to do that I should avoid. 😄

@pohly
Copy link
Contributor

pohly commented Feb 21, 2025

kubernetes/test-infra#34376

Let's get that merged first.

I can try to trigger a build locally if that's acceptable, but I haven't touched any Google Cloud things before so please let me know if there's any damage I'm able to do that I should avoid

You would need the right credentials, so it probably simply wouldn't work. Let's merge and try it in the real environment.

@pohly
Copy link
Contributor

pohly commented Feb 26, 2025

kubernetes/test-infra#34376 got merged. Let's proceed...

/lgtm
/approve

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Feb 26, 2025
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: nojnhuh, pohly

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Feb 26, 2025
@k8s-ci-robot k8s-ci-robot merged commit 4ed5279 into kubernetes-sigs:main Feb 26, 2025
6 checks passed
@nojnhuh nojnhuh deleted the cloudbuild branch February 26, 2025 17:39
@pohly
Copy link
Contributor

pohly commented Feb 26, 2025

It failed for commit 4ed5279 which is the merge commit for this PR:

2025/02/26 17:38:36 Build directory: .
2025/02/26 17:38:36 /home/prow/go/src/github.com/kubernetes-sigs/dra-example-driver/cloudbuild.yaml does not exist 

There's a name mismatch: the error is about cloudbuild.yaml, the file is called cloudbuild.yml.

@pohly
Copy link
Contributor

pohly commented Feb 26, 2025

Let's rename the file.

@nojnhuh
Copy link
Contributor Author

nojnhuh commented Feb 26, 2025

Done: #78

@pohly pohly moved this from 👀 In review to 🏗 In progress in Dynamic Resource Allocation Feb 26, 2025
@pohly pohly moved this from 🏗 In progress to ✅ Done in Dynamic Resource Allocation Feb 26, 2025
@nojnhuh
Copy link
Contributor Author

nojnhuh commented Feb 26, 2025

The job passed now but created a v0.1.0 tag where I was expecting just the commit SHA, so I'll take a look to see why that's happening.

https://console.cloud.google.com/artifacts/docker/k8s-staging-images/us-central1/dra-example-driver/dra-example-driver/sha256:0e8f5df34c196e5900c4d29667ce5b21ba482ef9aecc5dd19cea14fa6dde2d0c?project=k8s-staging-images

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants