ADF Cross-Tenant Link to Azure Devops doesn't persist

Patrick Dornian 0 Reputation points
2023-03-16T15:55:15.1633333+00:00

Hi,

My workplace has two tenants, and we have an ADF instance in one that is connected to a git controlled Azure DevOps repo in another. Whenever I connect to the data factory via the web studio, I get the error

"Invalid Git configuration. You need to gain access to the repository before you can publish any changes. Details: Incorrect account name for the given tenant."

I am not prompted to login to the other tenant to resolve the cross-tenant authentication to the DevOps repository. I definitely DO have access to the repositiory via my account in the other tenant. I can disconnect the repository in ADF and reconnect it via the documentation here:

https://learn.microsoft.com/en-us/azure/data-factory/cross-tenant-connections-to-azure-devops

at which point I'm reconnected and a garbage empty commit is added to the main branch.

User's image

I can then work as normal, but as soon as I ever have to reload the ADF studio, the connection breaks and I have to disconnect and reconnect the repo again.

We have one other cross tenant user who doesn't seem to have this issue so it might just be something on my end, but clearing all cookies and login credentials hasn't got me anywhere and I'm unable to find anyone else who has the same error in any online discussions.

For one brief happy moment for about 10 minutes, one day into troubleshooting this, I did seem to be able to get credential prompts from the other tenant upon going to https://adf.azure.com/ when logging in via a different machine, and it worked as expected. Then it stopped, and it's been a day since then. I have no idea why it suddenly started working for a brief amount of time and then broke immediately again, at which point I haven't had any success.

Has anyone seen this before, and any ideas for resolving it?

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

1 answer

Sort by: Most helpful
  1. AnnuKumari-MSFT 30,361 Reputation points Microsoft Employee
    2023-03-20T08:57:12.8033333+00:00

    @Patrick Dornian ,

    Welcome to Microsoft Q&A platform and thanks for posting your question here.

    As I understand your query, you are trying to set up GIT repo within ADF workspace which are in different tenants and you are facing this error: "Invalid Git configuration. You need to gain access to the repository before you can publish any changes. Details: Incorrect account name for the given tenant." Please correct me if my understanding is wrong.

    • Could you please use a different browser or a private/incognito mode to see if the issue persists.
    • Additionally, make sure that you have the necessary permissions to access the repository in the other tenant.
    • Make sure you select "Default Directory" instead of "Microsoft Account" while logging in the ADO organization while setting up the GIT repository for ADF. If you have created your ADO account using Microsoft directory, then

    Additional helpful resources:

    https://www.reddit.com/r/AZURE/comments/sbru6f/data_factory_cant_connect_to_azure_devops_repo/

    https://stackoverflow.com/questions/61683672/you-need-to-gain-access-to-the-repository-before-you-can-publish-any-changes-de

    https://learn.microsoft.com/en-us/azure/data-factory/cross-tenant-connections-to-azure-devops

    If none of these suggestions resolve the issue, I would recommend you to raise a support ticket so that you could be provided further assistance in troubleshooting the issue.


    Hope it helps. Kindly accept the answer by clicking on Accept answer button.