I want any user in our Group that created a new repository to automatically have maintainer rights for that repo.
I can't find any administrative settings on Gitlab.com that would imply the ability to do this automatically.
I have all users in the group set to "Developer" privileges on all repos but I'd like to have the user that created the repo to be set as "Maintainer" upon repo creation.
I haven't tried this, but here is the idea.
Setup a System Hook for project_create event:
https://docs.gitlab.com/ce/api/system_hooks.html
https://docs.gitlab.com/ce/system_hooks/system_hooks.html
In hook body owner_name is hopefully the creator.
So in your script you can then make an API call to promote user:
https://docs.gitlab.com/ee/api/members.html#add-a-member-to-a-group-or-project
Related
Also i need to know how to make project admin to get notification when a contributor makes a pull request in azure devops.
How to restrict project admin only to create new repository, the
master branch in azure devops
It's is not possible to modify any Permissions to Project Admin by default Project Admin has all the permissions (As the name indicates he/she will be the project admin)
You will see the below error when you tried to modify the permission
Also i need to know how to make project admin to get notification when
a contributor makes a pull request in azure devops.
ProjectSetting->Notification->New Subscription->Code(git)->A pull Request is created or updated
Under the Deliver to you have the options called
Members of xxx by role
Team Preference
Custom Email address
Members of xxx Team
SOAP
You can set this to a custom email address and point the project admin email address there.
I would like to enable a group of users to fork any repo from a GitLab group and subsequently send PR's to repos in that GitLab group but not be able to push to repos in that GitLab group.
Is this possible using one of the standard access levels; Guest/Reporter/Developer ?
You can set yourself as the only one with write access:
That way, many people can send pull requests to your branch, but only you can merge them.
Turns out that the 'Reporter' access level does exactly what I need.
What I did was;
Grant one user group Owner access to the repo group (the release managers in my context)
Grant another user group Reporter access to the repo group (the feature devs)
The release managers now have full access, the feature devs can fork and send PR's (merge requests in GL vocab).
YouTrack supports integration with GitLab, which I would like to use.
When I create a new integration, YouTrack asks for a private token and gives me the option to navigate to my own user profile on our GitLab server to copy my token.
Does that mean that all future actions performed by YouTrack will be performed with my user account? Should I create a separate user for YouTrack?
It does mean that all future actions are performed with this user, but all those actions are read-only. The only modifying action is that if you delete/disable the integration, YouTrack will delete a web hook that it registers in GitLab.
I have a project which our research lab is working, but only a few members can have access to the codes. We are using Git and BitBucket, but we want to use the server lab as our main repository. I have the following constraints:
We don't have admin rights;
Only a few members can have access to the files;
Every lab member already has its own login in the server.
How can I make this work?
I was thinking to ask the admin to add a group in the server, which would have read/write rights in our Git repository folder. Does it work? Is there a better way to manage these Git repositories with these constraints?
In addition to what Borealid wrote in his answer, you could also use gitolite. It allows you to have much more fine-grained access control (e.g. you can prevent users from deleting your repositories or prevent (some of) them from pushing to certain branches). It doesn't require root access.
Having a POSIX group which is granted access to the repository directory is a fine way to do things.
Just be aware that you have to trust the other group members - they could delete the directory entirely, without using the git client.
I want to update my own comment for a commit in the check-in history but I receive error as snapshot as below.
I understand that my account is not an admin/owner of the repository but it should be allowed me to update my own comment! On TFS side, I can do this actually.
Is there any work-around for me? I don't want to provide admin right to all users.
You don't have to give every user admin rights. But the error returned by your pre-revprop-change hook script tells you that only admins or project owners can change log messages.
So either change your pre-revprop-change hook script to allow all users to do that, or add yourself to the owners group or admin group.