Unable to connect Azure CLI from corporate network & unable to deploy code to appservice RRS feed

  • Question

  • I am unable to connect Azure CLI from our corporate network. I am trying to deploy Java SpringBoot application onto App Service through mvn. However, Azure CLI on our desktop is not connecting (timing out). Can you please advice on how to overcome this?

    We also have a ReactJS application that we are trying to deploy onto App Service through VSCode. We are getting errors here as well - "client 'xxxx' with object id 'xxx-xx-xxx-xx'  does not have authorization to perform action 'Microsoft.web.serverfarms.read' over scope '/subscriptions/xxxx-xxx-xxxx-xxx/resourceGroups/appsvc_linux_centralus/providers/Microsoft.Web/serverfarms/appsvc_linux_centralus' or the scope is invalid. if access was recently granted, please refresh your credentials". 

    Kindly assist

    Tuesday, November 5, 2019 11:17 AM


All replies

  • I think your first issue is explained here: https://github.com/Azure/azure-xplat-cli/wiki/Supporting-Corporate-Proxy

    The second issue seems like you dont have permissions to read. Can you please confirm what RBAC role you have over the Resource Group or at Subscription level? 



    Tuesday, November 5, 2019 2:36 PM
  • Thanks Rahber

    First query -- the solution in the link is dated 2014. Has there been any other solutions subsequently from Azure?

    Second query -- the role is "User"  -- does't have permissions to register applications. Is this the issue here?

    Tuesday, November 5, 2019 3:16 PM
  • What version of the CLI are you running? As long as you can access https://portal.azure.com, then the CLI should work from az login.

    As far as RBAC, I agree with Rahber, that your credentials may not have access to either the resources you're trying to access. Your account should have at least 'Contributor' role access so I suggest touching basis with your subscription admin.

    Thanks in advance, Ryan

    Tuesday, November 5, 2019 6:47 PM
  • Hi Ryan

    Thanks for responding

    I am using CLI v 2.0.75. This is almost latest

    I am able to access portal and also am able to access CLI from browser.

    Can I deploy files from my local file system to Azure App Service using Browser CLI? How do I navigate local file system?

    RBAC -- I do have Contributor access to my ID. My role is defined as "User" and I see that "Users can register applications" is set to No. I understand that this means I cannot create Service Principal. Not sure if this is linked to the error I am getting

    Wednesday, November 6, 2019 9:56 AM
  • Hi Suresh,

    You can use az webapp up or az webapp deployment source config-local-git to get your local code deployed up into Azure using the CLI. You also have options in deployment center via the portal.

    Registering applications is related to enabling Azure Active Directory on your app. That shouldn't prevent you from deploying your code. As long as you have Contributor on the resource you should be able to deploy. You can see the list of RBAC roles here.

    Thanks in advance, Ryan

    Wednesday, November 6, 2019 6:01 PM
  • Thanks. This was a proxy issue which was resolved after including HTTP_PROXY and HTTPS_PROXY information
    Tuesday, November 19, 2019 8:42 AM