az pipelines ignores default organization when running commands from a local ADO git folder
See original GitHub issueDescribe the bug When running az cli devops commands from an ADO git folder the az cli devops defaults are ignored.
To Reproduce Azure Cli Version: 2.0.73
Azure-Devops extension version: 0.13.0
Steps to reproduce the behaviour:
- Clone an ADO Repo (it’s important that’s an ADO repo, with other GIT providers the bug doesn’t happen)
- Navigate to the cloned folder (important, you have to be in the cloned folder)
- Login with
az devops login
and provide a token (my token has all the scopes) - Set defaults, like :
az devops configure --defaults organization=https://dev.azure.com/contoso project=ContosoWebApp
- Run a command without providing the --organization switch:
az pipelines pool list
ERROR:
The requested resource requires user authentication: https://*****@dev.azure.com/*****/azure platform team/_git/azure platform team/vsts/info
Note: the ***** is just to keep my stuff private.
Expected behavior The normal run of the command
Additional context
- Running the command outside the Git Folder works perfectly.
- Running the command inside the cloned Git folder of another provider (like GitHub etc…) works perfectly
- To make it work inside the Git Folder I have to explicitly provide the --organization switch
Issue Analytics
- State:
- Created 4 years ago
- Comments:10 (3 by maintainers)
Top Results From Across the Web
Run Git commands in a script - Azure Pipelines - Microsoft Learn
Within Project Settings, select Repositories. Select the repository you want to run Git commands on. Select Security to edit your repository ...
Read more >How To Run Self-Hosted Azure DevOps Build/Release Agents
Step 1. Navigate to the Organization Settings and select Agent pools from the Pipeline section. pipelines. Step 2. Select the Default agent pool ......
Read more >Terraform on Azure Pipelines Best Practices - Julie Ng
Here are 5 Best Practices to get you started on the right foot. As an engineer in the Azure Customer Experience (CXP) organization,...
Read more >Automating infrastructure deployments in the Cloud with ...
Select Azure service connection from the drop-down. This task will run the terraform apply command to deploy the resources. By default, it will ......
Read more >git-svn Documentation - Git
Once tracking a Subversion repository (with any of the above methods), the Git repository can be updated from Subversion by the fetch command...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@geverghe could you also add the note to the Getting Started Guide. This was where I first learned about setting default config
Great work! thank you for listening 😃