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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add input documentation #21

Merged
merged 2 commits into from
Jun 13, 2022
Merged

Add input documentation #21

merged 2 commits into from
Jun 13, 2022

Conversation

m-kuhn
Copy link
Owner

@m-kuhn m-kuhn commented Jun 8, 2022

No description provided.

README.md Outdated
| Name | Type | Description |
|--------------------|---------|-----------------------------------|
| `add_labels` | String | Comma separated list of labels to add to the backport PR. |
| `github_token` | String | Token for the GitHub API. Set this to a personal access token (PAT) if you want github workflows to run on the opened PR. |
Copy link

Choose a reason for hiding this comment

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

This is pretty good, thanks! Wondering, do you know what exact permissions the PAT needs? Is giving repository access enough?

Copy link
Owner Author

Choose a reason for hiding this comment

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

If I remember correctly, yes. Would be nice to add this as well.

Copy link

Choose a reason for hiding this comment

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

also thanks from the MapServer team! (this action is excellent) thanks again.

Copy link

Choose a reason for hiding this comment

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

Trying to figure out how to run the github actions on the backport PRs, I've stumbled into more issues... I did give the backport bot PAT repository access, and marked the user as collaborator to the project, but eventulaly got:

remote: Permission to geoserver/geoserver.git denied to geoserver-bot.
fatal: unable to access 'https://github.com/geoserver/geoserver.git/': The requested URL returned error: 403

I did give it read permissions (thought it was enough since random users with no permissions at all can open PRs), now I'm trying with Triage permissions. Do you remember what kind of relationship was setup betwene qgis-bot and the QGIS project?

Copy link
Owner Author

Choose a reason for hiding this comment

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

The backport branch will be created in the base repository, so the user will need to be able to create branches there too.

Copy link

Choose a reason for hiding this comment

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

Oh ok... I'm not sure Triage will work then, says "manage PRs" but does not talk about creating branches. Maybe I need to give it "write" permissions instead.

Copy link

@aaime aaime Jun 13, 2022

Choose a reason for hiding this comment

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

Confirmed, the PAT needs repo access and the user has to be added as a collaborator, with write permissions.
I've shared the secret as a "repository secret" in order to make the action yaml work as written, although I believe it would be possible to make it an environment secret too, by changing the action and make it run in that same environment.

Copy link
Owner Author

Choose a reason for hiding this comment

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

Thank you for the feedback. Adjusted accordingly.

@m-kuhn m-kuhn merged commit 0301adb into main Jun 13, 2022
@m-kuhn m-kuhn deleted the m-kuhn-patch-1 branch June 13, 2022 12:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants