question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

az login WSL 2 Ubuntu 18.04 does not open browser

See original GitHub issue

Describe the bug When running command az login web browser won’t open. Running on verbose mode

az login --verbose
Detect no GUI is available, so fall back to device code
To sign in, use a web browser to open the page https://microsoft.com/devicelogin and enter the code GFHKIOWYA to authenticate.

To Reproduce Run az login on WSL 2 Ubuntu 18.04

Expected behavior Default browser opens on AZ login page.

Environment summary Windows 10 Pro 2004

WSL 2 Ubuntu 18.04

uname -a
Linux MY-COMPUTER 4.19.104-microsoft-standard #1 SMP Wed Feb 19 06:37:35 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux
az --version
azure-cli                         2.10.0

command-modules-nspkg              2.0.3
core                              2.10.0
nspkg                              3.0.4
telemetry                          1.0.4

Python location '/opt/az/bin/python3'
Extensions directory '/home/nico/.azure/cliextensions'

Python (Linux) 3.6.10 (default, Jul 31 2020, 08:33:11)
[GCC 7.5.0]

Additional context Running

powershell.exe -Command 'Start-Process https://github.com/Azure/azure-cli/issues'

opens successfully the browser on the Azure CLI issues page.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Reactions:1
  • Comments:13 (5 by maintainers)

github_iconTop GitHub Comments

7reactions
jiaslicommented, Aug 27, 2020

Let me reopen it and put it into our roadmap.

5reactions
schundu9commented, Dec 1, 2020

Just use below - its Display issue DISPLAY=:0 az login

Read more comments on GitHub >

github_iconTop Results From Across the Web

az aks browse doesn't open browser automatically on WSL ...
It doesn't automatically open the browser from WSL2 like it does in macOS and Linux. So you have to CTRL + Click the...
Read more >
az aks browse doesn't open browser automatically on ... - MSDN
It doesn't automatically open the browser from WSL2 like it does in macOS and Linux. So you have to CTRL + Click the...
Read more >
Has az login stopped working in Ubuntu 20.04? - Stack Overflow
I run az login from my terminal (Ubuntu 20.04) and I am shown a browser window. I login to my Azure account. The...
Read more >
Managing Azure with AZ CLI and Windows Subsystem for Linux
1) To setup WSL on Windows 10, run as admin: · 2) From the Microsoft App Store, Install Ubuntu. · 3) Run the...
Read more >
Ubuntu: Enterprise Open Source and Linux
Ubuntu is the modern, open source operating system on Linux for the enterprise server, desktop, cloud, and IoT.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found