Dina
Did you try to use the Variable Group to pass the Secret value dynamically?
You may also try the below suggestion,
"secretName": "[if(equals(variables('Environment'), 'prod'), variables('SecretName'), 'AzureDataLakeStorageGen2Test')]"
How to add "secretName" parameter for Azure Data Lake Storage Gen2 linked service in Azure Data Factory?
I have an Azure Data Lake Storage Gen2 linked service in the dev data factory environment and also in the prod environment. Below is the json of the dev linked service. The problem I have is that the secretName in the prod environment is different "AzureKeyvaultTestProd" than the one in the dev and I can not override this parameter in the release pipeline. The arm-template-definition.json is also below. How to override the secretName for the prod environment in the release pipeline?
"Microsoft.DataFactory/factories/linkedServices": {
"*": {
"properties": {
"typeProperties": {
"accountName": "=",
"username": "=",
"userName": "=",
"accessKeyId": "=",
"endpoint": "=",
"servicePrincipalId": "=",
"userId": "=",
"host": "=",
"clientId": "=",
"clusterUserName": "=",
"clusterSshUserName": "=",
"hostSubscriptionId": "=",
"clusterResourceGroup": "=",
"subscriptionId": "=",
"resourceGroupName": "=",
"tenant": "=",
"dataLakeStoreUri": "=",
"baseUrl": "=",
"database": "=",
"serviceEndpoint": "=",
"batchUri": "=",
"poolName": "=",
"databaseName": "=",
"systemNumber": "=",
"server": "=",
"url": "=",
"functionAppUrl": "=",
"environmentUrl": "=",
"aadResourceId": "=",
"sasUri": "|:-sasUri:secureString",
"sasToken": "|",
"connectionString": "|:-connectionString:secureString",
"hostKeyFingerprint": "=",
"domain": "-",
"workspaceResourceId": "-",
"clusterId": "-",
"existingClusterId": "-",
"secretName":"-"
}
}
},
"Odbc": {
"properties": {
"typeProperties": {
"userName": "=",
"connectionString": {
"secretName": "="
}
}
}
}
},
{
"name": "AzureDataLakeStorageGen2Test",
"properties": {
"annotations": [],
"type": "AzureBlobFS",
"typeProperties": {
"url": "https://test.dfs.core.net",
"accountKey": {
"type": "AzureKeyVaultSecret",
"store": {
"referenceName": "AzureKeyVaultTest",
"type": "LinkedServiceReference"
},
"secretName": "AzureDataLakeStorageGen2Test"
}
},
"connectVia": {
"referenceName": "TEST",
"type": "IntegrationRuntimeReference"
}
}
}
2 answers
Sort by: Most helpful
-
QuantumCache 20,261 Reputation points
2024-02-26T23:55:36.3566667+00:00 -
Dina 0 Reputation points
2024-02-27T09:08:51.38+00:00 Can I add this ?: "AzureDataLakeStorageGen2Test", "properties": { "typeProperties": { "accountKey": { "secretName": "-" } } },