How to block Azure AI Studio from being deployed by a user

Paco Bernabé 5 Reputation points
2024-02-14T09:30:33.38+00:00

Hi all, In my current project, the client doesn't want users to deploy Azure AI Studio. I have tried to block it via policy by blocking the deployment of the following: ""type": "Microsoft.CognitiveServices/accounts"". Why that type? I first deployed Azure AI Studio myself (Yes, I know it's in public preview), then I exported the template, and that's the only type that I saw in the template (Microsoft.CognitiveServices/accounts). The problem here is that, if I use that policy, it will also block other Cognitive Services. My question is, is there a way of blocking Azure AI Studio, without blocking the deployment of other services? Thank you!

Azure AI services
Azure AI services
A group of Azure services, SDKs, and APIs designed to make apps more intelligent, engaging, and discoverable.
3,271 questions
0 comments No comments
{count} votes

2 answers

Sort by: Most helpful
  1. Paco Bernabé 5 Reputation points
    2024-02-14T14:41:15.76+00:00

    Thank you @Abrar Adil S and @romungi-MSFT , putting together the type Microsoft.MachinelearningServices/workspaces and the kind Hub did the trick. With that policy I'm able to block Azure AI Studio, and the Machine Learning workspaces and the Cognitive services are not impacted.

        "policyRule": {
          "if": {
            "allOf": [
              {
                "field": "type",
                "equals": "Microsoft.MachineLearningServices/workspaces"
              },
              {
                "field": "kind",
                "equals": "Hub"
              }
            ]
          },
    
    
    1 person found this answer helpful.
    0 comments No comments

  2. Abrar Adil S 246 Reputation points
    2024-02-14T09:46:40.8333333+00:00

    Hello @Paco Bernabé The type which you have specified ("type": "Microsoft.CognitiveServices/accounts") is for other Cognitive Services such as Custom Vision, Computer Vision, Language Service, Translator, Content Moderator, Content Safety etc.

    For the Azure AI Studio, the "type: "Microsoft.MachineLearningServices/workspaces"

    Please use the below Policy to Deny the creation of the Azure AI Studio.

    {
      "mode": "All",
      "policyRule": {
        "if": {
          "allOf": [
            {
              "field": "type",
              "equals": "Microsoft.MachineLearningServices/workspaces"
            }
          ]
        },
        "then": {
          "effect": "deny"
        }
      }
    }
    
    

    Screenshot: User's image

    Please let me know if the problem persists, and I will be happy to offer further assistance. If the provided solution has helped in resolving the issue, please consider accepting it by clicking on the "Accept answer" button.


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.