13

We are working on migrating from gitolite to gitlab , But have encountered a problem with subgroups which are created on git. It looks like there is no feature in gitlab to create a subgroup

eg: in Git

group1/group2/project1.git
group1/project2.git
group1/group2/project3.git
group1/group3/project4.git

It looks like when i import the repo's using bundle it is not able to identify the sub groups. Also there is no option to create a sub group on the gitlab UI. (Maybe i'm not looking at the proper terminology. maybe subgroub is not the correct work )

Apologies for the use of incorrect terms as I am new to this

Thanks in advance Regards Niro

12

Gitlab 9.0 now has support for subgroups, with a few limitations. You can create up to 20 levels of subgroups. Users can be assigned to subgroups and projects can be created in them. Users assigned to the parent group have the same permission for all descendant groups from that parent.

Rules (from the docs):

  • You need to be an Owner of a group in order to be able to create a subgroup.
  • Some words are reserved and may not be used as subgroup names.
  • Permissions inherited from a parent group can only be changed in the parent, not in the child.
  • Permissions can be overridden in the child group by explicitly adding the user to the subgroup again.

Additional current limitations (from the docs -- these may be fixed in future releases):

  • GitLab Pages are not currently working for projects hosted under a subgroup. That means that only projects hosted under the first parent group will work.
  • Group level labels don't work in subgroups / sub projects
  • It is not possible to share a project with a group that's an ancestor of the group the project is in. That means you can only share as you walk down the hierarchy. For example, group/subgroup01/project cannot be shared with group, but can be shared with group/subgroup02 or group/subgroup01/subgroup03.

Original answer for older versions:

No, it's not currently supported to create subgroups in Gitlab. (Note that this is also not supported in most other Git hosting sites that I know of, including Github, Bitbucket, and Gitorious.)

On my server, our workaround is to use dots in the name, for example "group1.group2".


You could suggest the feature, but I doubt that it will go anywhere unless you sponsor it or find someone to implement it.

1
  • 1
    In addition to Gitolite, at least Gerrit and Deveo support subgroups, e.g. naming repositories with slashes.
    – kontulai
    Feb 27 '17 at 21:40
6

This is now possible with GitLab 9.0 CE/EE, which is due to be released on 22nd March 2017

You can download the latest packages as shown in https://about.gitlab.com/downloads/

Once downloaded and installed, You can then have the ability to create hierarchical groups. All the documentation is available in the link below

https://gitlab.com//help/user/group/subgroups/index.md

2

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.