debian-mirror-gitlab/doc/user/project/pages/pages_access_control.md

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

54 lines
2.9 KiB
Markdown
Raw Normal View History

2019-12-26 22:10:19 +05:30
---
2022-06-21 17:19:12 +05:30
stage: Create
group: Editor
2021-02-22 17:27:13 +05:30
info: 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
2019-12-26 22:10:19 +05:30
---
2021-09-04 01:27:46 +05:30
# GitLab Pages access control **(FREE)**
2019-12-26 22:10:19 +05:30
2020-11-24 15:15:51 +05:30
You can enable Pages access control on your project
if your administrator has [enabled the access control feature](../../../administration/pages/index.md#access-control)
2022-07-23 23:45:48 +05:30
on your GitLab instance. When enabled, only authenticated
2019-12-26 22:10:19 +05:30
[members of your project](../../permissions.md#project-members-permissions)
2022-07-23 23:45:48 +05:30
(at least Guest) can access your website, by default:
2019-12-26 22:10:19 +05:30
2020-05-24 23:13:21 +05:30
<i class="fa fa-youtube-play youtube" aria-hidden="true"></i>
For a demonstration, see [Pages access controls](https://www.youtube.com/watch?v=tSPAr5mQYc8).
2020-01-01 13:55:28 +05:30
1. Navigate to your project's **Settings > General** and expand **Visibility, project features, permissions**.
2019-12-26 22:10:19 +05:30
2021-01-03 14:25:43 +05:30
1. Toggle the **Pages** button to enable the access control. If you don't see the toggle button,
that means it isn't enabled. Ask your administrator to [enable it](../../../administration/pages/index.md#access-control).
2019-12-26 22:10:19 +05:30
1. The Pages access control dropdown allows you to set who can view pages hosted
with GitLab Pages, depending on your project's visibility:
- If your project is private:
2021-03-08 18:12:59 +05:30
- **Only project members**: Only project members are able to browse the website.
- **Everyone**: Everyone, both logged into and logged out of GitLab, is able to browse the website, no matter their project membership.
2019-12-26 22:10:19 +05:30
- If your project is internal:
2021-03-08 18:12:59 +05:30
- **Only project members**: Only project members are able to browse the website.
- **Everyone with access**: Everyone logged into GitLab is able to browse the website, no matter their project membership.
- **Everyone**: Everyone, both logged into and logged out of GitLab, is able to browse the website, no matter their project membership.
2019-12-26 22:10:19 +05:30
- If your project is public:
2021-03-08 18:12:59 +05:30
- **Only project members**: Only project members are able to browse the website.
- **Everyone with access**: Everyone, both logged into and logged out of GitLab, is able to browse the website, no matter their project membership.
2019-12-26 22:10:19 +05:30
2022-07-23 23:45:48 +05:30
1. Select **Save changes**. Note that your changes may not take effect immediately. GitLab Pages uses
2021-03-11 19:13:27 +05:30
a caching mechanism for efficiency. Your changes may not take effect until that cache is
invalidated, which usually takes less than a minute.
2019-12-26 22:10:19 +05:30
The next time someone tries to access your website and the access control is
2021-03-08 18:12:59 +05:30
enabled, they're presented with a page to sign into GitLab and verify they
2019-12-26 22:10:19 +05:30
can access the website.
## Terminating a Pages session
2021-01-03 14:25:43 +05:30
To sign out of your GitLab Pages website, revoke the application access token
for GitLab Pages:
2019-12-26 22:10:19 +05:30
2021-01-03 14:25:43 +05:30
1. In the top menu, select your profile, and then select **Settings**.
2021-11-11 11:23:49 +05:30
1. On the left sidebar, select **Applications**.
2021-01-03 14:25:43 +05:30
1. Scroll to the **Authorized applications** section, find the **GitLab Pages**
entry, and select its **Revoke** button.