Skip to content

Switch to PAT_TOKEN for git branch push #4086

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

yue9944882
Copy link
Member

@yue9944882 yue9944882 commented Jun 6, 2025

https://github.com/kubernetes-client/java/actions/runs/15476712105/job/43573728659

The github action lost permission to push branch after maven release even though the maven release was successful. Looks like the permission got tighten again recently because we didn't have this error when publishing 24.0.0.. This PR proposes to use PAT_TOKEN which has the repo write permission to automate the version release process.

remote: Permission to kubernetes-client/java.git denied to github-actions[bot].
fatal: unable to access 'https://github.com/kubernetes-client/java.git/': The requested URL returned error: 403

We need to choose a poison between having a long manual release process and the risk of increasing the permission for github action..

/cc @brendandburns

@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: 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:

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 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. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Jun 6, 2025
@brendandburns
Copy link
Contributor

Why is this permission required for the checkout step?

@yue9944882
Copy link
Member Author

@brendandburns The checkout step is where we initialize the identity/permission for the follow-up git commands including push, tag, etc..

https://github.com/actions/checkout/blob/main/README.md?plain=1#L50-L52

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. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants