Share via


Quickstart: Media Services account Bicep

Media Services logo v3


Warning

Azure Media Services will be retired June 30th, 2024. For more information, see the AMS Retirement Guide.

This article shows you how to use Bicep to create a media services account.

Introduction

Bicep is a domain-specific language (DSL) that uses declarative syntax to deploy Azure resources. It provides concise syntax, reliable type safety, and support for code reuse. Bicep offers the best authoring experience for your infrastructure-as-code solutions in Azure.

Prerequisites

If you don't have an Azure subscription, create a free account before you begin.

If you have never deployed a Bicep file before, it is helpful to read about Bicep files and go through the quickstart.

Review the Bicep file

The Bicep file used in this quickstart is from Azure Quickstart Templates.

The following Azure resources are defined in the Bicep file:

Deploy the Bicep file

  1. Save the Bicep file as main.bicep to your local computer.

  2. Deploy the Bicep file using either Azure CLI or Azure PowerShell.

    az group create --name exampleRG --location eastus
    az deployment group create --resource-group exampleRG --template-file main.bicep
    

    When the deployment finishes, you should see a message indicating the deployment succeeded.

Review deployed resources

Use the Azure portal, Azure CLI, or Azure PowerShell to list the deployed resources in the resource group.

az resource list --resource-group exampleRG

Clean up resources

When it's no longer needed, delete the resource group, which also deletes the resources in the resource group.

az group delete --name exampleRG

Get help and support

You can contact Media Services with questions or follow our updates by one of the following methods: