Cannot perform this action when created function app

Aliyya Amru 70 Reputation points
2024-03-04T06:58:26.2033333+00:00

Hello, I learn about "Create a Custom Skill for Azure AI Search" https://microsoftlearning.github.io/mslearn-knowledge-mining/Instructions/Exercises/02-search-skills.html#create-an-azure-function-for-a-custom-skill.

I've made my azure multi services, and create a search solution and everything is fine. But, when i try to create Azure Function for a custom skill, there's error in my resource group "You cannot perform this action without all of the following permissions (microsoft.web/serverfarms/write, microsoft.web/sites/write)" like this picture bellow. can anyone tell me what kind of this error and how to solve it? thanks.

error message

Azure Functions
Azure Functions
An Azure service that provides an event-driven serverless compute platform.
4,891 questions
Azure AI Search
Azure AI Search
An Azure search service with built-in artificial intelligence capabilities that enrich information to help identify and explore relevant content at scale.
949 questions
0 comments No comments
{count} votes

Accepted answer
  1. JananiRamesh-MSFT 26,546 Reputation points
    2024-03-04T09:02:08.8633333+00:00

    @Aliyya Amru Thanks for reaching out. It seems that you’re encountering a permissions issue while trying to create an Azure Function for a custom skill. The error message indicates that you don’t have the necessary permissions for certain actions related to Microsoft.Web/serverfarms and Microsoft.Web/sites.

    To resolve this issue, you can either grant yourself the necessary permissions or by asking your Azure administrator to grant you the necessary permissions.

    To grant yourself the necessary permissions, you can follow these steps:

    1. Navigate to the resource group where you want to create the Azure Function.
    2. Click on the "Access control (IAM)" tab.
    3. Click on the "+ Add" button and select "Add role assignment".
    4. In the "Add role assignment" pane, select the "Contributor" role and enter your username or email address in the "Select" field.
    5. Click on the "Save" button to grant yourself the Contributor role.

    Once you have the necessary permissions, you should be able to create an Azure Function for your custom skill without any issues.

    do let me know incase of further queries, I would be happy to assist you.


0 additional answers

Sort by: Most helpful

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.