Unable to Override the ManagedEndpoint resource ID in the Data Factoty CI / CD pipeline

Ian Henry 231 Reputation points
2021-05-07T11:24:03.763+00:00

After adding a ManagedPrivateEndpoint the CI/CD pipeline fails when I try and override the endpoint linked resource id to reflect the resource name in production environment.

Trying to override the value in the DevOps in the override template parameters part of Azure resource group deployment Task in a classic release pipeline. Get this error :

InvalidResourceRequest: Invalid resource request. Resource type: 'ManagedPrivateEndpoint', Resource name: 'AzureDataLakeStorage1' 'Error: Invalid payload'.
Check out the troubleshooting guide to see if your issue is addressed: https://learn.microsoft.com/en-us/azure/devops/pipelines/tasks/deploy/azure-resource-group-deployment?view=azure-devops#troubleshooting
Task failed while creating or updating the template deployment.

Azure Data Factory
Azure Data Factory
An Azure service for ingesting, preparing, and transforming data at scale.
11,030 questions
{count} votes

Accepted answer
  1. Ian Henry 231 Reputation points
    2021-05-11T10:10:47.31+00:00

    Thanks Martin, for you help. I managed to get this working. It is possible to override the resourceId in the release pipeline so the resource is different in each environment. But you only get 1 shot at that.

    If you need to change it thereafter you need to delete the private endpoint and start the process over.

    I can kinda see why .... but its not idempotent! :)

    1 person found this answer helpful.

3 additional answers

Sort by: Most helpful
  1. MartinJaffer-MSFT 26,196 Reputation points
    2021-05-10T23:54:35.09+00:00

    I heard back, @Ian Henry .

    To override the resource id of the target stored .. its in the property: privateLinkResourceId and put the appropriate groupId

    1 person found this answer helpful.
    0 comments No comments

  2. vaik 1 Reputation point
    2021-11-21T16:52:05.577+00:00

    @MartinJaffer-MSFT

    I tried setting groupId='blob' and also I tried deleting MPEs before deployment but still Im getting same error.

    151256-image.png


  3. Sharma, Rahul 1 Reputation point
    2022-03-02T16:30:58.407+00:00

    @MartinJaffer-MSFT I have a situation

    I have 2 data factories, one for dev and other for testing.

    I have created a managed private endpoint in dev data factory that points to azure sql (pointing to dev sql server and db) eg: az_mpe_dev

    I have created a managed private endpoint in test data factory that points to azure sql (pointing to testsql server and db) eg: az_mpe_test

    Now when I use azure pipeline to deploy dev adf to test, I get the following error:
    ManagedPrivateEndpointInvalidPayload: Managed private endpoint 'az_mpe_dev' is invalid.

    In the templateparameter.json
    its:

                "az_mpe_dev_properties_privateLinkResourceId": {  
    		"value": "/subscriptions/abc/resourceGroups/rg-dev/providers/Microsoft.Sql/servers/sqlserver-dev  
    	},  
    	"az_mpe_dev_properties_groupId": {  
    		"value": "sqlServer"  
    	},  
    	"az_mpe_dev_properties_ipAddress": {  
    		"value": null  
    	},  
    	az_mpe_dev_properties_resourceId": {  
    		"value": "/subscriptions/abc/resourceGroups/vnet-b4549a5weqwee-UKSouth-243-rg/providers/Microsoft.Network/privateEndpoints/az-df-dev.az_mpe_de"  
    	}  
    

    Now when I override the template parameters with test values I get the above error.

    How should I resolve this ?

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.