Commit e7797b51 authored by John Doe's avatar John Doe

Consolidate the docs when changing a repo path

parent 03bee987
...@@ -183,24 +183,29 @@ access further configurations for your group. ...@@ -183,24 +183,29 @@ access further configurations for your group.
#### Changing a group's path #### Changing a group's path
> **Note:** If you want to retain ownership over the original namespace and Changing a group's path can have unintended side effects. Read
protect the URL redirects, then instead of changing a group's path or renaming a [how redirects will behave](../project/index.md#redirects-when-changing-repository-paths)
username, you can create a new group and transfer projects to it. before proceeding.
If you are vacating the path so it can be claimed by another group or user,
you may need to rename the group name as well since both names and paths must
be unique.
Changing a group's path can have unintended side effects. To change your group path:
* Existing web URLs for the group and anything under it (i.e. projects) will 1. Navigate to your group's **Settings > General**.
redirect to the new URLs. 1. Enter a new name under "Group path".
* Existing Git remote URLs for projects under the group will redirect to the new remote URL, and they 1. Hit **Save group**.
will show a warning with the new remote URL.
* The redirect to the new URL is permanent, that implies the original namespace
can't be claimed again by any group or user.
* If you are vacating the path so it can be claimed by another group or user,
you may need to rename the group name as well since both names and paths must be
unique
> It is currently not possible to rename a namespace if it contains a CAUTION: **Caution:**
project with container registry tags, because the project cannot be moved. It is currently not possible to rename a namespace if it contains a
project with [Container Registry](../project/container_registry.md) tags,
because the project cannot be moved.
TIP: **TIP:**
If you want to retain ownership over the original namespace and
protect the URL redirects, then instead of changing a group's path or renaming a
username, you can create a new group and transfer projects to it.
#### Enforce 2FA to group members #### Enforce 2FA to group members
......
...@@ -8,51 +8,6 @@ experience according to the best approach to their cases. ...@@ -8,51 +8,6 @@ experience according to the best approach to their cases.
There are several ways to sign into your GitLab account. There are several ways to sign into your GitLab account.
See the [authentication topic](../../topics/authentication/index.md) for more details. See the [authentication topic](../../topics/authentication/index.md) for more details.
### Why do I keep getting signed out?
When signing in to the main GitLab application, a `_gitlab_session` cookie is
set. `_gitlab_session` is cleared client-side when you close your browser
and expires after "Application settings -> Session duration (minutes)"/`session_expire_delay`
(defaults to `10080` minutes = 7 days).
When signing in to the main GitLab application, you can also check the
"Remember me" option which sets the `remember_user_token`
cookie (via [`devise`](https://github.com/plataformatec/devise)).
`remember_user_token` expires after
`config/initializers/devise.rb` -> `config.remember_for` (defaults to 2 weeks).
When the `_gitlab_session` expires or isn't available, GitLab uses the `remember_user_token`
to get you a new `_gitlab_session` and keep you signed in through browser restarts.
After your `remember_user_token` expires and your `_gitlab_session` is cleared/expired,
you will be asked to sign in again to verify your identity (which is for security reasons).
## Username
Your `username` is a unique [`namespace`](../group/index.md#namespaces)
related to your user ID.
### Changing your username
You can change your `username` from your
[profile settings](#profile-settings).
> **Note:** If you want to retain ownership over the original namespace and
protect the URL redirects, then instead of changing your username, you can
create a new group and transfer projects to it.
Alternatively, you can follow [this detailed procedure from the GitLab Team Handbook](https://about.gitlab.com/handbook/tools-and-tips/#how-to-change-your-username-at-gitlabcom).
Changing your username can have unintended side effects.
* Existing web URLs for the user and anything under it (i.e. projects) will
redirect to the new URLs.
* Existing Git remote URLs for projects under the user will redirect to the new remote URL. Git responses
will show a warning with the new remote URL.
* The redirect to the new URL is permanent, that implies the original namespace can't be claimed again by any group or user.
> It is currently not possible to rename a namespace if it contains a
project with container registry tags, because the project cannot be moved.
## User profile ## User profile
Your profile is available from the up-right corner menu bar (user's avatar) > **Profile**, Your profile is available from the up-right corner menu bar (user's avatar) > **Profile**,
...@@ -84,4 +39,49 @@ From there, you can: ...@@ -84,4 +39,49 @@ From there, you can:
- Manage [SSH keys](../../ssh/README.md#ssh) to access your account via SSH - Manage [SSH keys](../../ssh/README.md#ssh) to access your account via SSH
- Manage your [preferences](preferences.md#syntax-highlighting-theme) - Manage your [preferences](preferences.md#syntax-highlighting-theme)
to customize your own GitLab experience to customize your own GitLab experience
- Acess your audit log, a security log of important events involving your account - Access your audit log, a security log of important events involving your account
## Changing your username
Your `username` is a unique [`namespace`](../group/index.md#namespaces)
related to your user ID. Changing it can have unintended side effects, read
[how redirects will behave](../project/index.md#redirects-when-changing-repository-paths)
before proceeding.
To change your `username`:
1. Navigate to your [profile's](#profile-settings) **Settings > Account**.
1. Enter a new username under "Change username".
1. Hit **Update username**.
CAUTION: **Caution:**
It is currently not possible to change your username if it contains a
project with [Container Registry](../project/container_registry.md) tags,
because the project cannot be moved.
TIP: **Tip:**
If you want to retain ownership over the original namespace and
protect the URL redirects, then instead of changing a group's path or renaming a
username, you can create a new group and transfer projects to it.
Alternatively, you can follow [this detailed procedure from the GitLab Team Handbook](https://about.gitlab.com/handbook/tools-and-tips/#how-to-change-your-username-at-gitlabcom).
## Troubleshooting
### Why do I keep getting signed out?
When signing in to the main GitLab application, a `_gitlab_session` cookie is
set. `_gitlab_session` is cleared client-side when you close your browser
and expires after "Application settings -> Session duration (minutes)"/`session_expire_delay`
(defaults to `10080` minutes = 7 days).
When signing in to the main GitLab application, you can also check the
"Remember me" option which sets the `remember_user_token`
cookie (via [`devise`](https://github.com/plataformatec/devise)).
`remember_user_token` expires after
`config/initializers/devise.rb` -> `config.remember_for` (defaults to 2 weeks).
When the `_gitlab_session` expires or isn't available, GitLab uses the `remember_user_token`
to get you a new `_gitlab_session` and keep you signed in through browser restarts.
After your `remember_user_token` expires and your `_gitlab_session` is cleared/expired,
you will be asked to sign in again to verify your identity (which is for security reasons).
...@@ -93,6 +93,9 @@ from your fork to the upstream project ...@@ -93,6 +93,9 @@ from your fork to the upstream project
## Project settings ## Project settings
Set the project's visibility level and the access levels to its various pages
and perform actions like archiving, renaming or transferring a project.
Read through the documentation on [project settings](settings/index.md). Read through the documentation on [project settings](settings/index.md).
## Import or export a project ## Import or export a project
...@@ -105,53 +108,6 @@ Read through the documentation on [project settings](settings/index.md). ...@@ -105,53 +108,6 @@ Read through the documentation on [project settings](settings/index.md).
- [Export a project from GitLab](settings/import_export.md#exporting-a-project-and-its-data) - [Export a project from GitLab](settings/import_export.md#exporting-a-project-and-its-data)
- [Importing and exporting projects between GitLab instances](settings/import_export.md) - [Importing and exporting projects between GitLab instances](settings/import_export.md)
## Transferring an existing project into another namespace
You can transfer an existing project into a [group](../group/index.md) as long
as you have at least **Master** [permissions](../permissions.md#permissions) to
that group and if you are an **Owner** of the project.
Similarly, if you are an owner of a group, you can transfer any of its projects
under your own user.
1. Navigate to your project's **Settings > General > Advanced settings**.
1. Under "Transfer project", choose the namespace you want to transfer the
project to.
1. Confirm the transfer by typing the project's path as instructed.
Once done, you will be taken to the new project's namespace. At this point,
read what happens with the
[redirects from the old project to the new one](#redirects-when-transferring-or-renaming-projects).
NOTE: **Note:**
GitLab administrators can use the admin interface to move any project to any
namespace if needed.
## Renaming a project
## Redirects when transferring or renaming projects
When [transferring](#transfer-an-existing-project-into-a-group) or
[renaming](#renaming-a-project) a project, it is essential to smoothly
transition from the old location to the new one. GitLab provides two kinds
of redirects: web UI and Git push/pull redirects.
When visiting the old project's URL from your browser, you will be automatically
to the new location.
Starting with GitLab 10.3, Git actions will also redirect. This means that any
build scripts, automation, or Git clients will continue to work after a
rename, making any transition a lot smoother.
Every time you push/pull to a repository that has changed its location,
a redirect warning message to update your remote will be displayed instead of
rejecting your action.
NOTE: **Note:**
To avoid pulling from or pushing to an entirely incorrect repository, the old
path will be reserved.
## Project's members ## Project's members
Learn how to [add members to your projects](members/index.md). Learn how to [add members to your projects](members/index.md).
...@@ -163,3 +119,32 @@ when a project is part of a group (under a ...@@ -163,3 +119,32 @@ when a project is part of a group (under a
[group namespace](../group/index.md#namespaces)). [group namespace](../group/index.md#namespaces)).
If you choose to leave a project you will no longer be a project If you choose to leave a project you will no longer be a project
member, therefore, unable to contribute. member, therefore, unable to contribute.
## Redirects when changing repository paths
When a repository path changes, it is essential to smoothly transition from the
old location to the new one. GitLab provides two kinds of redirects: the web UI
and Git push/pull redirects.
Depending on the situation, different things apply.
When [transferring a project](settings/index.md#transferring-an-existing-project-into-another-namespace),
or [renaming a user](../profile/index.md#changing-your-username) or
[changing a group path](../group/index.md#changing-a-group-s-path):
- **The redirect to the new URL is permanent**, which means that the original
namespace can't be claimed again by any group or user.
- Existing web URLs for the namespace and anything under it (e.g., projects) will
redirect to the new URLs.
- Starting with GitLab 10.3, existing Git remote URLs for projects under the
namespace will redirect to the new remote URL. Every time you push/pull to a
repository that has changed its location, a warning message to update
your remote will be displayed instead of rejecting your action.
This means that any automation scripts, or Git clients will continue to
work after a rename, making any transition a lot smoother.
To avoid pulling from or pushing to an entirely incorrect repository, the old
path will be reserved.
When [renaming-a-repository](settings/index.md#renaming-a-repository), the same
things apply, except for the Git push/pull actions which will be rejected with a
warning message to change to the new remote URL.
# Project settings # Project settings
NOTE: **Note:**
Only project Masters and Admin users have the [permissions] to access a project
settings.
You can adjust your [project](../index.md) settings by navigating You can adjust your [project](../index.md) settings by navigating
to your project's homepage and clicking **Settings**. to your project's homepage and clicking **Settings**.
## General settings ## General settings
Adjust your project's path and name, description, avatar, [default branch](../repository/branches/index.md#default-branch), and tags: Under a project's general settings you can find everything concerning the
functionality of a project.
### General project settings
Adjust your project's name, description, avatar, [default branch](../repository/branches/index.md#default-branch), and tags:
![general project settings](img/general_settings.png) ![general project settings](img/general_settings.png)
...@@ -45,14 +54,64 @@ Here you can run housekeeping, archive, rename, transfer, or remove a project. ...@@ -45,14 +54,64 @@ Here you can run housekeeping, archive, rename, transfer, or remove a project.
#### Archiving a project #### Archiving a project
>**Note:** Only Project Owners and Admin users have the permission to archive a project NOTE: **Note:**
Only project Owners and Admin users have the [permissions] to archive a project.
An archived project will be hidden by default in the project listings.
1. Navigate to your project's **Settings > General > Advanced settings**.
1. Under "Archive project", hit the **Archive project** button.
1. Confirm the action when asked to.
An archived project can be fully restored and will therefore retain its
repository and all associated resources whilst in an archived state.
#### Renaming a repository
NOTE: **Note:**
Only project Masters and Admin users have the [permissions] to rename a
repository. Not to be confused with a project's name where it can also be
changed from the [general project settings](#general-project-settings).
A project's repository name defines its URL (the one you use to access the
project via a browser) and its place on the file disk where GitLab is installed.
To rename a repository:
1. Navigate to your project's **Settings > General > Advanced settings**.
1. Under "Rename repository", change the "Path" to your liking.
1. Hit **Rename project**.
Remember that this can have unintended side effects since everyone with the
old URL will not be able to push or pull. Read more about what happens with the
[redirects when renaming repositories](../index.md#redirects-when-changing-repository-paths).
#### Transferring an existing project into another namespace
NOTE: **Note:**
Only project Owners and Admin users have the [permissions] to transfer a project.
You can transfer an existing project into a [group](../../group/index.md) if:
1. you have at least **Master** [permissions] to that group
1. you are an **Owner** of the project.
Similarly, if you are an owner of a group, you can transfer any of its projects
under your own user.
It's possible to mark a project as archived via the Project Settings. An archived project will be hidden by default in the project listings. To transfer a project:
An archived project can be fully restored and will therefore retain it's repository and all associated resources whilst in an archived state. 1. Navigate to your project's **Settings > General > Advanced settings**.
1. Under "Transfer project", choose the namespace you want to transfer the
project to.
1. Confirm the transfer by typing the project's path as instructed.
#### Renaming a project Once done, you will be taken to the new project's namespace. At this point,
read what happens with the
[redirects from the old project to the new one](../index.md#redirects-when-changing-repository-paths).
>**Note:** Only Project Owners and Admin users have the permission to rename a project NOTE: **Note:**
GitLab administrators can use the admin interface to move any project to any
namespace if needed.
It's possible to rename a project from "Rename repository" or "Transfer project" sections. When doing so, you will need to update your local repositories to point to the new location, otherwise Git operations will be rejected. [permissions]: ../../permissions.md##project-members-permissions
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment