-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
Team Repository creation in Organisation #5114
Comments
We have a similar issue with repo creation for team member. Our artix linux package repository setup:
As it is right now, only administrators can create a repository in org B? Would be nice to have a more fine grained user privileges, so that in our case, team members of org B can create a repo without being administrator. |
@meerkampdvv @udeved @lunny Not sure how complex adding this functionality to Gitea would be? Our team is using Gitea as part of a new product we're building, but we have not yet looked at the Gitea-code or contributed any changes. |
@altinnadmin |
Looks exactly like what we would need, maintainers(non-admin team members) of a given org can create repos from api, granted they have privs to do so. |
How about add an option on team settings which allow team members to create repositories or transfer repositories to the organization? |
lunny +, it is need, now I found one bug - <<<I found another problem when I do the owners of the organization, then they can not do push in the repository of the organization, if they are not administrators Gitea. Here I've all described: |
can transfer to 1.8.0 or 1.9.0? |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs during the next 2 weeks. Thank you for your contributions. |
any plan for release? This is what my company wants too. |
No people are working on this. |
There are related access issues that need to be considered if this feature are introduced. If a user belongs to a team that has "Create repo access" and creates a repo, only the owner would have admin (or indeed any) access to the repo. So the repo creator shall probably be automatically added as repo admin when creating the repo (no problem). Then if the creator want's someone else to access the repo he/she need to add them as collaborator. But probably he rather would like to give access to a whole team (the team with create repo access or some other team). However adding repositories to teams is also currently limited to the organization owner. So for "create repo access" to be truly useful, I think one or both of the following features would be needed as well:
|
If I understand the problem properly, perhaps the create repository page should work like this:
For example, "My Org", for which user Martin is the admin, has four teams:
As we can see, Bob belongs to teams "Developers", "Project Managers" and "Special Admins". But he is not the org admin. When Bob wants to create a repo, he must choose to which team he wants to add the repo to; valid options are "Project Managers" and "Special Admins". However, if John wants to create a repo, Gitea will automatically add it to "Project Managers" because that's the only team giving John the ability to create a repo for that organization. The explanation is very complex, but implementation should be simple. |
This should have special right (unit) for this than |
@guillep2k I don't think access rights settings should be added to the repo creation page, it should not be too complex. If Bob adds a repo "New Cool Software", he probably wants "Developers" to be able to start work on it (because project managers are not going to do that). He might not even be member of developers himself. Thus he still need to go to the organization admin (owner) to do that. I think being able to create a repository should imply you shall have full access to that repo (i.e. repo admin), otherwise it would be limited to only owners having full access to the new repo. In your case (3), I therefore think the creator automatically shall become repo admin. For Bob to be able to start assigning Developers to work on the software, it should be possible to add Teams as collaborators (same as Team Repos but seen from repo settings page). Drawback for that is that Bob as repo admin will be able to see all teams in the organization. I am not sure if there can be any reason to keep team names secret for those that doesn't belong to them, I don't see any purpose of that (you can anyhow see all members of the organization you belong to) |
@davidsvantesson Currently there's no way to add the repository to a team unless you are the team manager; i.e. the org admin.
Fair enough, this will solve that. However, I don't much like the fact that you must know the team names in advance to do this; I'd rather have a list in the case of teams (it shouldn't be too long). And there's the potential problem of name clashing. Can a user and a team be both named
I agree, at least if team members are kept private. But changing the current behavior would be a breaking change. I see value on @lafriks suggestion, here:
So granting this unit to a user should also come with the ability of seeing all the teams in the organization. The org admin will be advised about it in the permission description. If the user creating the repo automatically gains admin rights over it, the org admin must have nonetheless the ability to revoke those admin rights from that user at any time. |
Not seeing teams you don't belong to can be seen as a convenience or a security/integrity issue. It is actually possible to list all teams in an organization you are member of in the API (but not the members). I created #8045 as a concrete suggestion on adding team access. |
I meant listing the team names, not their members. |
So could this be closed as per #8045 ? |
Unfortunately no. That PR makes it possible to add teams from the repository settings, which in my opinion is necessary to make a fix of this issue really useful. After getting that done, I plan to submit another PR to also add a team setting to allow creation of organization repository. I think that is what is requested in this issue. |
I didn't use the correct keyword in the PR, but I think this issue is included in Gitea 1.11 and thus can be closed. |
@techknowlogick can you change the milestone |
[x]
):Description
I created a Organisation "sufo" added a team "suo-team". The User "derme" is not owner of the Organization but Member of the Team.
The User derme is not able to create Repositories for the Organisation. The Team has Administrator rights for the Team Repositories.
Is this the Correct behavior ? in case a Team Member wants to create a new Repo he has to ask the Org Owner ?
The text was updated successfully, but these errors were encountered: