Cannot Publish Function App From Visual Studio

Ryan Ruenroeng 30 Reputation points
2023-04-18T21:32:45.78+00:00

Hi there, I don't understand why I'm unable to create a Function App using the Visual Studio wizard: User's image

The documentation didn't at first tell me that I needed to add resource providers to my subscription in order for my Function App to be able to have Azure Storage and whatever services Microsoft.Web is providing. I'm not hitting this wall, but without any kind of error message to explain to me why I cannot create this app. Best, Ryan

Azure Functions
Azure Functions
An Azure service that provides an event-driven serverless compute platform.
5,003 questions
{count} votes

2 answers

Sort by: Most helpful
  1. VenkateshDodda-MSFT 20,781 Reputation points Microsoft Employee
    2023-04-20T07:09:48.6+00:00

    @Ryan Ruenroeng Thanks for your follow-up questions on this.

    I have tried to reproduce the same behavior in my own subscription by creating a user with Reader permission at subscription level and Contributor permission at Resource group level when we tried to deploy the function app from visual studio the Create option in publish profile is greyed out.

    • If you have Contributor permission at Resource group level, and if you want to create a function app (irrespective of SKU like consumption, elastic premium or dedicated app service plan) you need to have the permissions Webplan contributor and also Storage Account contributor` along with Contributor access on resource group.
      User's image
    • Since you have the contributor access at resource group level, you can ignore the Reader permission to that specific user at subscription level.
    • If you have Contributor permission at subscription level, you can create the function app directly.
    • If you want to limit the specific user to create a function app at subscription level or at resource group level you can limit the permissions by creating a custom role including permissions (Microsoft.Web/serverfarms/Write,Microsoft.Web/serverfarms/Write etc.,) by referring to the Resource Provider Operations Documentation
    • Regarding the documentation change I would request you to raise a feedback request on the same documentation by click the feedback this page option at the bottom of the documentation as shown below
      User's image

    Feel free to reach back to me if you have any further questions on this.

    1 person found this answer helpful.

  2. Ken Duoba 0 Reputation points
    2024-08-06T22:59:28.69+00:00

    I've had a similar issues when using the publishing wizard in VS. In my case, I just had to create the resource group manually via the Azure Portal beforehand rather than using the "New..." option. It did manage to create a new the storage account though. Looks a lot like a bug in the Wizard to me...

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.