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

Support aliases and groups in allowed_* config options for Koji #2320

Merged

Conversation

lbarcziova
Copy link
Member

@lbarcziova lbarcziova commented Jan 24, 2024

Introduce aliases all_admins and all_committers and also support groups in allowed_pr_authors and allowed_committers config options

Fixes packit/packit#2088
Requires packit/ogr#834

TODO:


RELEASE NOTES BEGIN
allowed_pr_authors and allowed_committers now allow specifying groups and also aliases all_admins and all_committers (corresponding to the access to the repository).
RELEASE NOTES END

Copy link
Contributor

@lbarcziova lbarcziova marked this pull request as ready for review January 25, 2024 21:21
Copy link
Contributor

Copy link
Contributor

packit_service/worker/checker/distgit.py Outdated Show resolved Hide resolved
Introduce aliases `all_admins` and `all_committers` and also support
groups in allowed_pr_authors and allowed_committers config options

Fixes packit/packit#2088
Requires packit/ogr#834
Comment on lines +295 to +296
all_admins = "all_admins"
all_committers = "all_committers"
Copy link
Member

Choose a reason for hiding this comment

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

I'm just wondering about the all_ prefix. An alias is technically a project-specific virtual group, and if we use a @ symbol for groups, we could use something similar for the aliases.

Copy link
Member Author

Choose a reason for hiding this comment

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

personally I like the original proposal, having it like the current implementation, but no strong opinion. @packit/the-packit-team anyone has any preferences?

Copy link
Member

Choose a reason for hiding this comment

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

I don't have strong opinions either.
But I wouldn't use the @ symbol. I agree that we have created a group, but it is a "packit" group and it will not show up in the fedoraproject UI; for this reason I think it is misleading to use @
We can have another symbol but it will not "immediately suggest" to the user the "group idea", so I don't know if it is worth having it?

Copy link
Member

Choose a reason for hiding this comment

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

I just think that using a symbol is a little more consistent and gives the feeling that it's some special identifier, on the other hand all_admins is also pretty self-explanatory:

allowed_pr_authors:
    - $admins
    - @packager
    - packit-stg
allowed_pr_authors:
    - all_admins
    - @packager
    - packit-stg

I'm fine with both.

Copy link
Member

Choose a reason for hiding this comment

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

If we used $, we could call it a variable rather than alias: $admins expands to all users with admin access to the project

Copy link
Member Author

Choose a reason for hiding this comment

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

We already have the aliases for targets and these also do not use any special symbols. So if we would like to be consistent, I would go with the original idea.

Copy link
Contributor

@lbarcziova lbarcziova added the mergeit When set, zuul wil gate and merge the PR. label Jan 29, 2024
Copy link
Contributor

Build succeeded (gate pipeline).
https://softwarefactory-project.io/zuul/t/packit-service/buildset/df6813e5a09c45c482b2558f9f352582

✔️ pre-commit SUCCESS in 2m 18s

@softwarefactory-project-zuul softwarefactory-project-zuul bot merged commit f3ec1ad into packit:main Jan 29, 2024
3 checks passed
@lbarcziova lbarcziova deleted the koji-allowed-aliases branch January 29, 2024 08:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
mergeit When set, zuul wil gate and merge the PR.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

koji_build: allow to set allowed_commiter to maintainers
3 participants