Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding a gh-action for generated java job #2197

Merged

Conversation

yue9944882
Copy link
Member

@brendandburns this automated workflow can help us to do the code generation via manually running workflow, in the end,a PR will be opened. see an example at https://github.com/yue9944882/java/pull/23/files

Signed-off-by: yue9944882 <291271447@qq.com>
@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Apr 2, 2022
@k8s-ci-robot k8s-ci-robot added approved Indicates a PR has been approved by an approver from all required OWNERS files. size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Apr 2, 2022
with:
path: gen
repository: kubernetes-client/gen
token: ${{ secrets.PAT_TOKEN }}
Copy link
Contributor

Choose a reason for hiding this comment

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

I don't think we need a token do we? This should be fully public.

Copy link
Member Author

Choose a reason for hiding this comment

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

the default token doesnt allow any cross-repo read/write even tho the repo is public. so we have to use a PAT token here, i granted the token merely read access

@brendandburns
Copy link
Contributor

Generally looks good. One small comment.

We should consider creating a shared robot account so that we don't have to use our own personal access tokens.

@brendandburns
Copy link
Contributor

Also, fwiw, this won't regenerate the fluent APIs so this is only going to work for patch updates (for now).

@k8s-ci-robot k8s-ci-robot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. and removed size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Apr 6, 2022
@yue9944882
Copy link
Member Author

We should consider creating a shared robot account so that we don't have to use our own personal access tokens.

yeah the configured PAT token in this repo is current from my account, but the good news is that the permission is limitted (read only). ideally we should replace my personal token w/ a robot token.

Also, fwiw, this won't regenerate the fluent APIs so this is only going to work for patch updates (for now).

@brendandburns nice catch, now i added fluent generation to the job.

@yue9944882 yue9944882 force-pushed the generate-openapi-java-job branch 3 times, most recently from 267693c to b6459e9 Compare April 6, 2022 05:21
Signed-off-by: yue9944882 <291271447@qq.com>
@yue9944882 yue9944882 force-pushed the generate-openapi-java-job branch from b6459e9 to 28fbc77 Compare April 6, 2022 06:13
@yue9944882
Copy link
Member Author

@brendandburns also we need to pick this to release-15 branch after it's merged

@brendandburns
Copy link
Contributor

/lgtm
/approve

Thanks!

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

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: brendandburns, yue9944882

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:
  • OWNERS [brendandburns,yue9944882]

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 merged commit c2aa519 into kubernetes-client:master Apr 6, 2022
k8s-ci-robot added a commit that referenced this pull request Apr 7, 2022
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/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants