# Adding GitLab (cloud) organization to Xopero ONE

## Using OAuth <a href="#add_new_organization" id="add_new_organization"></a>

{% stepper %}
{% step %}
Log in to [**XMS**](#user-content-fn-1)[^1], open the **DevOps** tab on the left side of the window, and select **GitLab** from the list.

<figure><img src="https://319733277-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0CBTl43C3OO6ySL1DJ6k%2Fuploads%2Fw8tk1IOQhrlsBEbiosdc%2Fimage.png?alt=media&#x26;token=f4ffd90b-d787-4aad-b864-7176b362a2c7" alt=""><figcaption></figcaption></figure>
{% endstep %}

{% step %}
Click the **Connect** button under **GitLab**.

<figure><img src="https://319733277-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0CBTl43C3OO6ySL1DJ6k%2Fuploads%2FvDEqK84Fv8nAlyD5d34P%2Fimage.png?alt=media&#x26;token=243c7ac7-9d88-4b5b-9c27-e95d8ff909df" alt=""><figcaption></figcaption></figure>
{% endstep %}

{% step %}
[In the window that pops-up](#additional-browser-permissions), log in with a user account which has the required permissions for the repositories or projects to protect. If your **GitLab** login session is active in a different tab, the login will complete automatically.

<figure><img src="https://319733277-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0CBTl43C3OO6ySL1DJ6k%2Fuploads%2FmCYgBSFE2nZu5u5Rf4rN%2Fimage.png?alt=media&#x26;token=28fec76c-4b48-4e2c-a64e-4f2d6425231f" alt=""><figcaption></figcaption></figure>
{% endstep %}

{% step %}
Grant **Xopero ONE** access to the specified resources (when prompted).
{% endstep %}

{% step %}
Your **GitLab** organization has now been successfully added to **Xopero ONE**. Click **Custom policy** to adjust your backup policy settings, or click **Run backup** to execute the backup immediately using the current policy configuration.

<figure><img src="https://319733277-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0CBTl43C3OO6ySL1DJ6k%2Fuploads%2FWROi6XIcLXoaODGkEOPX%2Fimage.png?alt=media&#x26;token=c67d6d76-3dc7-4248-a57c-012afb2de089" alt=""><figcaption></figcaption></figure>
{% endstep %}
{% endstepper %}

***

## Using OAuth (Advanced Mode)

{% stepper %}
{% step %}
Log in to [**XMS**](#user-content-fn-1)[^1], open the **DevOps** tab on the left side of the window, and select **GitLab** from the list.

<figure><img src="https://319733277-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0CBTl43C3OO6ySL1DJ6k%2Fuploads%2Fw8tk1IOQhrlsBEbiosdc%2Fimage.png?alt=media&#x26;token=f4ffd90b-d787-4aad-b864-7176b362a2c7" alt=""><figcaption></figcaption></figure>
{% endstep %}

{% step %}
Click the **advanced mode** link under **GitLab** and **GitLab Self-managed** tiles.

<figure><img src="https://319733277-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0CBTl43C3OO6ySL1DJ6k%2Fuploads%2FkpSZOom5m9Ys5rlsjcO7%2Fimage.png?alt=media&#x26;token=d7258f18-a941-4e9c-a64b-2f313487f907" alt="" width="529"><figcaption></figcaption></figure>
{% endstep %}

{% step %}
Set your authentication method.

1. In **Authentication**, select **GitLab**.
2. For **Connect using**, choose **OAuth App**.
3. Choose whether **Xopero** should automatically add new repositories to your backup and whether it should include **GitLab** groups in the backup.

<figure><img src="https://319733277-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0CBTl43C3OO6ySL1DJ6k%2Fuploads%2Fy8K1djNTrpB1uB9iJUxw%2Fimage.png?alt=media&#x26;token=c18c1660-3379-424f-93d1-f15cf40b775b" alt=""><figcaption></figcaption></figure>
{% endstep %}

{% step %}
Configure your repository sync and default worker. Specify hours for synchronization, or set a time interval for automatic updates.

<figure><img src="https://319733277-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0CBTl43C3OO6ySL1DJ6k%2Fuploads%2Fxao0KkYPmITcz661POOw%2Fimage.png?alt=media&#x26;token=eb8b7bc6-b555-4db7-b22b-4c036a87d414" alt=""><figcaption></figcaption></figure>
{% endstep %}

{% step %}
[In the window that pops-up](#additional-browser-permissions), log in with a user account which has the required permissions for the repositories or projects to protect. If your **GitLab** login session is active in a different tab, the login will complete automatically.
{% endstep %}

{% step %}
Grant **Xopero ONE** access to the specified resources (when prompted).
{% endstep %}

{% step %}
Your **GitLab** organization has now been successfully added to **Xopero ONE**. Click **Custom policy** to adjust your backup policy settings, or click **Run backup** to execute the backup immediately using the current policy configuration.

<figure><img src="https://319733277-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0CBTl43C3OO6ySL1DJ6k%2Fuploads%2F1Lc84i3bfMEEr4wJt6DL%2Fimage.png?alt=media&#x26;token=62315ae5-6579-46b1-b7d6-f7da9d95742b" alt=""><figcaption></figcaption></figure>
{% endstep %}
{% endstepper %}

***

## Using Personal Access Token (PAT)

{% stepper %}
{% step %}
Log in to [**XMS**](#user-content-fn-1)[^1], open the **DevOps** tab on the left side of the window, and select **GitLab** from the list.

<figure><img src="https://319733277-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0CBTl43C3OO6ySL1DJ6k%2Fuploads%2Fw8tk1IOQhrlsBEbiosdc%2Fimage.png?alt=media&#x26;token=f4ffd90b-d787-4aad-b864-7176b362a2c7" alt=""><figcaption></figcaption></figure>
{% endstep %}

{% step %}
Click the **advanced mode** link under **GitLab** and **GitLab Self-managed** tiles.

<figure><img src="https://319733277-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0CBTl43C3OO6ySL1DJ6k%2Fuploads%2FFT0HbigqLLH8RP4N4xTR%2Fimage.png?alt=media&#x26;token=216868e1-6a86-4b81-aa8d-e10c294a5de9" alt="" width="529"><figcaption></figcaption></figure>
{% endstep %}

{% step %}
Set your authentication method.

1. In **Authentication**, select **GitLab**.
2. For **Connect using**, choose **Login and Personal Access Token**.
3. Enter your **username** or **email**.
4. Add or select **PAT** from the **Password Manager**.
5. Choose whether **Xopero** should automatically add new repositories to your backup and whether it should include **GitLab** groups in the backup.

<figure><img src="https://319733277-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0CBTl43C3OO6ySL1DJ6k%2Fuploads%2FkqiQ6TQCHcE5erGqg6zp%2Fimage.png?alt=media&#x26;token=fcb91bc4-330a-4fd1-bdf1-dbc5f7455797" alt=""><figcaption></figcaption></figure>
{% endstep %}

{% step %}
Configure your repository sync and default worker. Specify hours for synchronization, or set a time interval for automatic updates.

<figure><img src="https://319733277-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0CBTl43C3OO6ySL1DJ6k%2Fuploads%2Fxao0KkYPmITcz661POOw%2Fimage.png?alt=media&#x26;token=eb8b7bc6-b555-4db7-b22b-4c036a87d414" alt=""><figcaption></figcaption></figure>
{% endstep %}

{% step %}
Click **Proceed** to complete adding your **GitLab** organization and grant **Xopero ONE** access to the specified resources.
{% endstep %}
{% endstepper %}

***

## Additional browser permissions

When adding an organization, you may be prompted to grant additional permissions to the **Xopero ONE** application— make sure your browser allows **Xopero** to open pop-up windows.

<figure><img src="https://content.gitbook.com/content/0CBTl43C3OO6ySL1DJ6k/blobs/92JwIolq3nNcqZWYoX80/1.PNG" alt=""><figcaption></figcaption></figure>

Depending on your browser, you can either adjust the settings to allow pop-ups or permit the authorization window to open once.

<figure><img src="https://content.gitbook.com/content/0CBTl43C3OO6ySL1DJ6k/blobs/yMSRLkEP2cPAsr3MksgJ/Pop-ups%20xone.png" alt="Mozilla pop-up allowance"><figcaption></figcaption></figure>

[^1]: Xopero ONE Management Service
