diff --git a/workspaces/azure-devops/.changeset/modern-pigs-cheer.md b/workspaces/azure-devops/.changeset/modern-pigs-cheer.md new file mode 100644 index 0000000000..f869d94bfa --- /dev/null +++ b/workspaces/azure-devops/.changeset/modern-pigs-cheer.md @@ -0,0 +1,5 @@ +--- +'@backstage-community/plugin-azure-devops': patch +--- + +Updated permissions section in `README` to remove legacy backend references and to make the instructions more clear diff --git a/workspaces/azure-devops/plugins/azure-devops/README.md b/workspaces/azure-devops/plugins/azure-devops/README.md index 6160464938..6a5bb527e4 100644 --- a/workspaces/azure-devops/plugins/azure-devops/README.md +++ b/workspaces/azure-devops/plugins/azure-devops/README.md @@ -322,33 +322,16 @@ To get the README component working you'll need to do the following two steps: ## Permission Framework -Azure DevOps plugin supports the permission framework for PRs, GitTags, Pipelines and Readme features. +Azure DevOps plugin supports the permission framework for PRs, GitTags, Pipelines and Readme features. To use these permissions you'll need to add the `@backstage-community/plugin-azure-devops-common` to the same location as your [Permission Policy](https://backstage.io/docs/permissions/writing-a-policy). This example assumes that your Permission Policy lives in your `packages/backend`: ```bash # From your Backstage root directory yarn --cwd packages/backend add @backstage-community/plugin-azure-devops-common ``` -New Backend you can skip the below and proceed with [permission configuration](#configure-permission) - -To enable permissions for the legacy backend system in `packages/backend/src/plugins/azure-devops.ts` add the following. - -```diff -export default async function createPlugin( - env: PluginEnvironment, -): Promise { - return createRouter({ - logger: env.logger, - config: env.config, - reader: env.reader, -+ permissions: env.permissions, - }); -} -``` - ### Configure Permission -To apply the permission rules add the following in `packages/backend/src/plugins/permissions.ts`. +To apply the permission rules add the following in to your [Permission Policy](https://backstage.io/docs/permissions/writing-a-policy). > Note: the following is just an example of how you might want to setup permissions, as an Adopter you can configure this to fit your needs. Also all the permissions are Resource Permissions as they work with an Entity with the exception of `azureDevOpsPullRequestDashboardReadPermission`.