Commit b63969e9 authored by Dmitriy Rudko's avatar Dmitriy Rudko 💬
Browse files

fix: [Bug #12645959] Fix auth logic for Partition services communication to use MSI

parent c4c7e96c
Pipeline #78173 failed with stages
in 14 minutes and 25 seconds
......@@ -55,12 +55,12 @@ export class AzureDataEcosystemServices extends AbstractDataEcosystemCore {
}
public static async getPartitionConfiguration(dataPartitionID: string): Promise<any> {
const credentials = AzureCredentials.getCredential()
const access_token = credentials.getToken(AzureConfig.SP_APP_RESOURCE_ID)
const options = {
headers: {
'Accept': 'application/json',
'Authorization': 'Bearer ' + (await AzureCredentials.getAzureServicePrincipalAccessToken(
AzureConfig.SP_CLIENT_ID, AzureConfig.SP_CLIENT_SECRET,
AzureConfig.SP_TENANT_ID, AzureConfig.SP_APP_RESOURCE_ID)).access_token,
'Authorization': `Bearer ${access_token}`,
'Content-Type': 'application/json'
},
url: AzureConfig.DES_SERVICE_HOST_PARTITION + '/api/partition/v1/partitions/' + dataPartitionID
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment