Revert of #26430
The change caused issues and is therefore reverted. The updated documentation reflects the actual permissions required Signed-off-by: Severin Wischmann <severinwischmann@nianticlabs.com>
This commit is contained in:
@@ -0,0 +1,5 @@
|
||||
---
|
||||
'@backstage/integration-react': patch
|
||||
---
|
||||
|
||||
Revert of change #26430
|
||||
@@ -19,6 +19,7 @@ should point to your Backstage backend auth handler.
|
||||
1. Set this to `http://localhost:7007/api/auth/gitlab/handler/frame` for local development.
|
||||
2. Set this to `http://{APP_FQDN}:{APP_BACKEND_PORT}/api/auth/gitlab/handler/frame` for non-local deployments.
|
||||
3. Select the following scopes from the list:
|
||||
- [x] `api` Grants full read-write access to the api. This is only required if users need to be able to create merge requests with their own permissions.
|
||||
- [x] `read_user` Grants read-only access to the authenticated user's profile through the /user API endpoint, which includes username, public email, and full name. Also grants access to read-only API endpoints under /users.
|
||||
- [x] `read_repository` Grants read-only access to repositories on private projects using Git-over-HTTP (not using the API).
|
||||
- [x] `write_repository` Grants read-write access to repositories on private projects using Git-over-HTTP (not using the API).
|
||||
|
||||
@@ -105,7 +105,7 @@ describe('ScmAuth', () => {
|
||||
additionalScope: { repoWrite: true },
|
||||
}),
|
||||
).resolves.toMatchObject({
|
||||
token: 'read_user read_api read_repository write_repository',
|
||||
token: 'read_user read_api read_repository write_repository api',
|
||||
});
|
||||
|
||||
const azureAuth = ScmAuth.forAzure(mockAuthApi);
|
||||
|
||||
@@ -162,7 +162,7 @@ export class ScmAuth implements ScmAuthApi {
|
||||
*
|
||||
* If the additional `repoWrite` permission is requested, these scopes are added:
|
||||
*
|
||||
* `write_repository`
|
||||
* `write_repository api`
|
||||
*/
|
||||
static forGitlab(
|
||||
gitlabAuthApi: OAuthApi,
|
||||
@@ -173,7 +173,7 @@ export class ScmAuth implements ScmAuthApi {
|
||||
const host = options?.host ?? 'gitlab.com';
|
||||
return new ScmAuth('gitlab', gitlabAuthApi, host, {
|
||||
default: ['read_user', 'read_api', 'read_repository'],
|
||||
repoWrite: ['write_repository'],
|
||||
repoWrite: ['write_repository api'],
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user