Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

az interactive in Azure Cloud Shell: authentication problem? #5421

Closed
yokawasa opened this issue Jan 28, 2018 · 4 comments · Fixed by #5442
Closed

az interactive in Azure Cloud Shell: authentication problem? #5421

yokawasa opened this issue Jan 28, 2018 · 4 comments · Fixed by #5442
Assignees
Labels
Auth bug This issue requires a change to an existing behavior in the product in order to be resolved. Cloud Shell Interactive az interactive P1
Milestone

Comments

@yokawasa
Copy link


Environment summary

  • Browser: Chrome Version 63.0.3239.132 (Official Build) (64-bit)
  • Azure Cloud Shell

In intractive mode of Azure Cloud Shell, I got the following message for any commands I execute,

yoichi@Azure:~$ az interactive
az>> vm list
Please run 'az login' to setup account.

So I tried to login by typing 'az login', however I got the message below. Then I closed the browser, opened the Azure Cloud Shell, and tried again but I got the same message.

az>> login
Azure Cloud Shell automatically authenticates the user account it was initially launched under, as a result 'az login' is disabled.
az>
@tjprescott tjprescott added Account az login/account Interactive az interactive question The issue doesn't require a change to the product in order to be resolved. Most issues start as that bug This issue requires a change to an existing behavior in the product in order to be resolved. P1 and removed question The issue doesn't require a change to the product in order to be resolved. Most issues start as that labels Jan 29, 2018
@tjprescott
Copy link
Member

tjprescott commented Jan 29, 2018

@yokawasa thank you for the report. I have reproduced the issue and we will address this in an upcoming release.

@williexu
Copy link
Contributor

williexu commented Feb 1, 2018

We cache the account info of a user upon az login.
The problem is that interactive looks into a different folder for this cached information and thus would require another login from interactive mode to get this information.
Unfortunately, a second login is not possible in cloudshell. A workaround until our next release would be to copy over the contents of ".azure" into ".azure-shell".
#5442 will make interactive mode look at the .azure for this info.

@tjprescott
Copy link
Member

tjprescott commented Feb 2, 2018

@williexu what is the specific bash command you executed in the shell? That's all anyone needs to know :)

@williexu
Copy link
Contributor

williexu commented Feb 2, 2018

Good point. Run cp -a .azure/. .azure-shell after starting up cloudshell.

@haroldrandom haroldrandom added Auth bug This issue requires a change to an existing behavior in the product in order to be resolved. Cloud Shell Interactive az interactive P1 labels Oct 25, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Auth bug This issue requires a change to an existing behavior in the product in order to be resolved. Cloud Shell Interactive az interactive P1
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants