@@ -27,27 +27,26 @@ repositories to GitLab, and the GitHub user must have the [owner role](https://d
...
@@ -27,27 +27,26 @@ repositories to GitLab, and the GitHub user must have the [owner role](https://d
To perform a one-off authorization with GitHub to grant GitLab access your
To perform a one-off authorization with GitHub to grant GitLab access your
repositories:
repositories:
1. Open <https://github.com/settings/tokens/new> to create a **Personal Access
1. In GitHub, create a token:
Token**. This token is used to access your repository and push commit
1. Open <https://github.com/settings/tokens/new>.
statuses to GitHub.
1. Create a **Personal Access Token**.
1. Enter a **Token description** and update the scope to allow
The `repo` and `admin:repo_hook` should be enable to allow GitLab access to
`repo` and `admin:repo_hook` so that GitLab can access your project,
your project, update commit statuses, and create a web hook to notify
update commit statuses, and create a web hook to notify GitLab of new commits.
GitLab of new commits.
1. In GitLab, create a project:
1. On the top menu, select **Projects > Create new project**.
1. In GitLab, go to the [new project page](../../user/project/working_with_projects.md#create-a-project), select the **CI/CD for external repository** tab, and then click
1. Select **Run CI/CD for external repository**.
**GitHub**.
1. Select **GitHub**.
1. For **Personal access token**, paste the token.
1. Paste the token into the **Personal access token** field and click **List
1. Select **List Repositories**.
Repositories**. Click **Connect** to select the repository.
1. Select **Connect** to select the repository.
1. In GitHub, add a `.gitlab-ci.yml` to [configure GitLab CI/CD](../quick_start/index.md).
1. In GitHub, add a `.gitlab-ci.yml` to [configure GitLab CI/CD](../quick_start/index.md).
1. In GitLab, enable [GitHub project integration](../../user/project/integrations/github.md):
1. On the left sidebar, select **Settings > Integrations**.
1. Still in GitLab, enable the [GitHub project integration](../../user/project/integrations/github.md)
1. Select the **Active** checkbox.
from **Settings > Integrations.**
1. Paste your personal access token and HTTPS repository URL into the form and select **Save**.
1. In GitLab, create a **Personal Access Token** with `API` scope to
Check the **Active** checkbox to enable the integration, paste your
personal access token and HTTPS repository URL into the form, and **Save.**
1. Still in GitLab create a **Personal Access Token** with `API` scope to
authenticate the GitHub web hook notifying GitLab of new commits.
authenticate the GitHub web hook notifying GitLab of new commits.
1. In GitHub, from **Settings > Webhooks**, create a web hook to notify GitLab of
1. In GitHub from **Settings > Webhooks** create a web hook to notify GitLab of
new commits.
new commits.
The web hook URL should be set to the GitLab API to
The web hook URL should be set to the GitLab API to
...
@@ -92,7 +86,7 @@ To manually enable GitLab CI/CD for your repository:
...
@@ -92,7 +86,7 @@ To manually enable GitLab CI/CD for your repository:
Select the **Let me select individual events** option, then check the **Pull requests** and **Pushes** checkboxes. These settings are needed for [pipelines for external pull requests](index.md#pipelines-for-external-pull-requests).
Select the **Let me select individual events** option, then check the **Pull requests** and **Pushes** checkboxes. These settings are needed for [pipelines for external pull requests](index.md#pipelines-for-external-pull-requests).
1. In GitHub add a `.gitlab-ci.yml` to configure GitLab CI/CD.
1. In GitHub, add a `.gitlab-ci.yml` to configure GitLab CI/CD.