diff --git a/packages/backend/src/plugins/plugins_helper/googleAuthResolver.ts b/packages/backend/src/plugins/plugins_helper/googleAuthResolver.ts index 6c7f9b0..58fe66d 100644 --- a/packages/backend/src/plugins/plugins_helper/googleAuthResolver.ts +++ b/packages/backend/src/plugins/plugins_helper/googleAuthResolver.ts @@ -2,12 +2,9 @@ import { stringifyEntityRef, DEFAULT_NAMESPACE, } from '@backstage/catalog-model'; -import dotenv from 'dotenv'; import { OAuthResult } from '@backstage/plugin-auth-backend'; import { SignInInfo, AuthResolverContext } from '@backstage/plugin-auth-node'; -dotenv.config(); - export const resolverResult = async ( profile_input: SignInInfo, ctx: AuthResolverContext, @@ -25,7 +22,7 @@ export const resolverResult = async ( const [localPart, domain] = profile.email.split('@'); - if (domain !== process.env.EMAIL_DOMAIN) { + if (domain !== 'code.berlin') { throw new Error(`Login failed due to incorrect email domain.`); }