Skip to content

Commit a070d68

Browse files
committed
Cloud Shell Detection
1 parent 45499ff commit a070d68

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

msal/application.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -112,6 +112,10 @@ def _preferred_browser():
112112
return None
113113

114114

115+
def _is_running_in_cloud_shell():
116+
return os.environ.get("AZUREPS_HOST_ENVIRONMENT", "").startswith("cloud-shell")
117+
118+
115119
class _ClientWithCcsRoutingInfo(Client):
116120

117121
def initiate_auth_code_flow(self, **kwargs):

0 commit comments

Comments
 (0)