diff --git a/.env.example b/.env.example index 9e8e1932cd0..a3835e093d3 100644 --- a/.env.example +++ b/.env.example @@ -112,6 +112,7 @@ RETHINKDB_SSL='false' # GITHUB_CLIENT_SECRET='key_GITHUB_CLIENT_SECRET' # GITLAB_CLIENT_ID='key_GITLAB_CLIENT_ID' # GITLAB_CLIENT_SECRET='key_GITLAB_CLIENT_SECRET' +# GITLAB_SERVER_URL='https://gitlab.com' # HUBSPOT_API_KEY='' # HUBSPOT_SALES_PIPELINE_ACTIVE_STAGES='' # HUBSPOT_SALES_PIPELINE_ID='' diff --git a/scripts/toolboxSrc/primeIntegrations.ts b/scripts/toolboxSrc/primeIntegrations.ts index e56a06c18e3..e441c1a59ae 100644 --- a/scripts/toolboxSrc/primeIntegrations.ts +++ b/scripts/toolboxSrc/primeIntegrations.ts @@ -8,7 +8,7 @@ const upsertGlobalIntegrationProvidersFromEnv = async () => { authStrategy: 'oauth2', scope: 'global', teamId: 'aGhostTeam', - serverBaseUrl: 'https://gitlab.com', + serverBaseUrl: process.env.GITLAB_SERVER_URL, clientId: process.env.GITLAB_CLIENT_ID, clientSecret: process.env.GITLAB_CLIENT_SECRET }, @@ -34,7 +34,7 @@ const upsertGlobalIntegrationProvidersFromEnv = async () => { } ] as const - const validProviders = providers.filter(({clientId, clientSecret}) => clientId && clientSecret) + const validProviders = providers.filter(({clientId, clientSecret, serverBaseUrl}) => clientId && clientSecret && serverBaseUrl) await Promise.all( validProviders.map((provider) => { return upsertIntegrationProvider(provider)