3.4 KiB
type | stage | group | info |
---|---|---|---|
reference | Manage | Import | To determine the technical writer assigned to the Stage/Group associated with this page, see https://about.gitlab.com/handbook/engineering/ux/technical-writing/#assignments |
Custom group-level project templates (PREMIUM)
Introduced in GitLab 11.6.
Group owners can set a subgroup to be the source of project templates that are selectable when a new project is created in the group. These templates can be selected when you go to New project > Create from template in the group and select the Group tab.
Every project in the subgroup, but not nested subgroups, can be selected by members of the group when a new project is created.
- Public projects can be selected by any signed-in user as a template for a new project, if all enabled project features except for GitLab Pages and Security & Compliance are set to Everyone With Access. The same applies to internal projects.
- Private projects can be selected only by users who are members of the projects.
Repository and database information that is copied over to each new project is identical to the data exported with the GitLab Project Import/Export.
To set custom project templates at the instance level, see Custom instance-level project templates.
Set up group-level project templates
To set up custom project templates in a group, add the subgroup that contains the project templates to the group settings:
- In the group, create a subgroup.
- Add projects to the new subgroup as your templates.
- In the left menu for the group, go to Settings > General.
- Expand Custom project templates and select the subgroup.
If all enabled project features (except for GitLab Pages) are set to Everyone With Access, then every project template in the subgroup is available to every member of the group.
Any projects added to the subgroup later can be selected the next time a group member creates a new project.
Example structure
Here's a sample group/project structure for project templates, for a hypothetical Acme Co:
# GitLab instance and group
gitlab.com/acmeco/
# Subgroups
internal
tools
# Subgroup for handling project templates
websites
templates
# Project templates
client-site-django
client-site-gatsby
client-site-hTML
# Other projects
client-site-a
client-site-b
client-site-c
...