Self-host GitLab EE/CE
- You should be the Workspace Owner to be able to see the GitOps sidebar item and add Git Provider.
- You should have a project created in GitLab.
Step 1 - Setting up
Go to Settings from the top nav bar, select GitOps under Workspace, and then click Add a Git provider.
Fill in the URL where the GitLab instance is running.
Step 2 - OAuth application info
Step 2.1 - Register GitLab instance-wide OAuth application (performed by GitLab Admin)
Login the GitLab instance specified in Step 1 as an Admin user. The admin user will see a wrench icon on the top nav bar like below:
Go to "Applications" from the sidebar, then click "New application" button.
Fill in the form with the provided info on the Bytebase setup wizard.
- Name: can be other names than "Bytebase", as long as the GitLab admin can identify this application is for "Bytebase" later
- Redirect URI: begins with the host:port where the Bytebase console is running, and followed by /oauth/callback. This is the URI GitLab uses to callback Bytebase during the OAuth flow
- Trusted: Yes
- Confidential: Yes
- Scopes: api
Click the "Submit" button after filling the info on GitLab and you will see a created application, like below:
Step 2.2 - Verify setup
Fill in the Application ID and Secret onto the corresponding fields on the Bytebase setup wizard:
After you click "Next", Bytebase will kick off an OAuth flow to verify the setup. If you are not currently logged into the GitLab instance used in the setup. You will be prompted to login to complete the OAuth.
Step 3 - Confirm and add
When everything is setup properly, you will be informed that the setup is correct. Click "Confirm and add".
Now you have successfully added a Git provider, developers can now link their Bytebase projects with one of their owned repositories from this Git provider.
- GitLab instance-wide applications. For GitLab, this is the OAuth application type Bytebase needs to register.