debian-mirror-gitlab/doc/user/project/members/share_project_with_groups.md

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

86 lines
3.9 KiB
Markdown
Raw Normal View History

2021-01-29 00:20:46 +05:30
---
2021-11-18 22:05:49 +05:30
stage: Manage
group: Workspace
2022-11-25 23:54:43 +05:30
info: To determine the technical writer assigned to the Stage/Group associated with this page, see https://about.gitlab.com/handbook/product/ux/technical-writing/#assignments
2021-01-29 00:20:46 +05:30
---
2022-01-26 12:08:38 +05:30
# Share projects with other groups **(FREE)**
2018-03-17 18:26:18 +05:30
You can share projects with other [groups](../../group/index.md). This makes it
possible to add a group of users to a project with a single action.
2023-03-04 22:38:38 +05:30
For example, if `Project A` belongs to `Group 1`, the members of `Group 1` have access to the project.
If `Project A` already belongs to another `Group 2`, the owner of `Group 2` can share `Project A`
with `Group 1`, so that both members of `Group 1` and `Group 2` have access to the project.
2018-03-17 18:26:18 +05:30
2023-03-04 22:38:38 +05:30
When a project is shared with a group:
2018-03-17 18:26:18 +05:30
2023-03-04 22:38:38 +05:30
- All group members, including members of subgroups or projects that belong to the group,
are assigned the same role in the project.
Each member's role is displayed in **Project information > Members > Max role**.
- The group is listed in the **Groups** tab.
- The project is listed on the group dashboard.
2022-08-13 15:12:31 +05:30
2023-03-04 22:38:38 +05:30
Be aware of the restrictions that apply when you share projects with:
2022-08-13 15:12:31 +05:30
2023-03-04 22:38:38 +05:30
- [Groups with a more restrictive visibility level](#share-projects-with-groups-with-a-more-restrictive-visibility-level).
- [Restricted sharing](#prevent-project-sharing).
2018-03-17 18:26:18 +05:30
2023-03-04 22:38:38 +05:30
## Share projects with groups with a more restrictive visibility level
2018-03-17 18:26:18 +05:30
2023-03-04 22:38:38 +05:30
You can share projects only down the group's organization structure.
This means you can share a project with a group that has a more restrictive
[visibility level](../../public_access.md#project-and-group-visibility) than the project,
but not with a group that has a less restrictive visibility level.
2022-01-26 12:08:38 +05:30
2023-03-04 22:38:38 +05:30
For example, you can share:
2022-01-26 12:08:38 +05:30
2023-03-04 22:38:38 +05:30
- A public project with a private group.
- A public project with an internal group.
- An internal project with a private group.
2018-03-17 18:26:18 +05:30
2023-03-04 22:38:38 +05:30
This restriction applies to subgroups as well. For example, `group/subgroup01/project`:
2018-05-09 12:01:36 +05:30
2023-03-04 22:38:38 +05:30
- Can't be shared with `group`.
- Can be shared with `group/subgroup02` or `group/subgroup01/subgroup03`.
2018-03-17 18:26:18 +05:30
2023-03-04 22:38:38 +05:30
When you share a project with a group that has a more restrictive visibility level than the project:
2021-04-29 21:17:54 +05:30
2023-03-04 22:38:38 +05:30
- The group name is visible to all users that can view the project members page.
- Owners of the project have access to members of the group when they mention them in issues or merge requests.
- Project members who are direct or indirect members of the group can see
group members listed in addition to members of the project.
2018-03-17 18:26:18 +05:30
2023-03-04 22:38:38 +05:30
## Share a project with a group
2018-03-17 18:26:18 +05:30
2023-03-04 22:38:38 +05:30
> - [Changed](https://gitlab.com/gitlab-org/gitlab/-/issues/247208) in GitLab 13.11 from a form to a modal
window [with a flag](../../feature_flags.md). Disabled by default.
> - Modal window [enabled on GitLab.com and self-managed](https://gitlab.com/gitlab-org/gitlab/-/issues/247208)
in GitLab 14.8.
> - [Generally available](https://gitlab.com/gitlab-org/gitlab/-/issues/352526) in GitLab 14.9.
[Feature flag `invite_members_group_modal`](https://gitlab.com/gitlab-org/gitlab/-/issues/352526) removed.
2022-08-13 15:12:31 +05:30
2023-03-04 22:38:38 +05:30
You can share a project only with groups:
2019-10-31 01:37:42 +05:30
2023-03-04 22:38:38 +05:30
- Where you have an explicitly defined [membership](index.md).
- That contain a nested subgroup or project you have an explicitly defined role for.
- You are an administrator of.
2022-08-27 11:52:29 +05:30
2023-03-04 22:38:38 +05:30
To share a project with a group:
2022-08-27 11:52:29 +05:30
2023-03-04 22:38:38 +05:30
1. On the top bar, select **Main menu > Projects** and find your project.
1. In the left navigation menu, select **Project information > Members**.
1. Select **Invite a group**.
1. **Select a group** you want to add to the project.
1. **Select a role** you want to assign to the group.
1. Optional. Select an **Access expiration date**.
1. Select **Invite**.
2019-10-31 01:37:42 +05:30
2023-03-04 22:38:38 +05:30
## Prevent project sharing
2018-03-17 18:26:18 +05:30
2023-03-04 22:38:38 +05:30
You can prevent members of a group from
2022-08-27 11:52:29 +05:30
[sharing a project with another group](../members/share_project_with_groups.md).
2023-03-04 22:38:38 +05:30
This restriction allows for tighter control over project access.
2018-03-17 18:26:18 +05:30
2023-03-04 22:38:38 +05:30
For more information, see [Prevent a project from being shared with groups](../../group/access_and_permissions.md#prevent-a-project-from-being-shared-with-groups).