permission-node: improve service-to-service error url

Signed-off-by: Vincenzo Scamporlino <vincenzos@spotify.com>
This commit is contained in:
Vincenzo Scamporlino
2023-02-27 15:52:53 +01:00
parent 10cb6b8e8f
commit 37e9215c79
3 changed files with 8 additions and 3 deletions
+5
View File
@@ -0,0 +1,5 @@
---
'@backstage/plugin-permission-node': patch
---
Improve Service-to-service url error
@@ -70,7 +70,7 @@ describe('ServerPermissionClient', () => {
tokenManager: ServerTokenManager.noop(),
}),
).toThrow(
'Backend-to-backend authentication must be configured before enabling permissions. Read more here https://backstage.io/docs/tutorials/backend-to-backend-auth',
'Service-to-service authentication must be configured before enabling permissions. Read more here https://backstage.io/docs/auth/service-to-service-auth',
);
});
@@ -33,7 +33,7 @@ import {
/**
* A thin wrapper around
* {@link @backstage/plugin-permission-common#PermissionClient} that allows all
* backend-to-backend requests.
* service-to-service requests.
* @public
*/
export class ServerPermissionClient implements PermissionEvaluator {
@@ -58,7 +58,7 @@ export class ServerPermissionClient implements PermissionEvaluator {
(tokenManager as any).isInsecureServerTokenManager
) {
throw new Error(
'Backend-to-backend authentication must be configured before enabling permissions. Read more here https://backstage.io/docs/tutorials/backend-to-backend-auth',
'Service-to-service authentication must be configured before enabling permissions. Read more here https://backstage.io/docs/auth/service-to-service-auth',
);
}