title | description | author | ms.author | ms.service | ms.topic | ms.date | ms.custom |
---|---|---|---|---|---|---|---|
Share outside your org (Bicep) - Azure Data Share quickstart |
Learn how to share data with customers and partners using Azure Data Share and Bicep. |
schaffererin |
v-eschaffer |
data-share |
quickstart |
04/04/2022 |
subject-armqs, devx-track-azurepowershell, mode-arm |
Learn how to set up a new Azure Data Share from an Azure storage account using Bicep, and start sharing your data with customers and partners outside of your Azure organization. For a list of the supported data stores, see Supported data stores in Azure Data Share.
[!INCLUDE About Bicep]
If you don't have an Azure subscription, create a free account before you begin.
The Bicep file used in this quickstart is from Azure Quickstart Templates.
:::code language="bicep" source="~/quickstart-templates/quickstarts/microsoft.datashare/data-share-share-storage-account/main.bicep":::
The following resources are defined in the Bicep file:
- Microsoft.Storage/storageAccounts:
- Microsoft.Storage/storageAccounts/blobServices/containers
- Microsoft.DataShare/accounts
- Microsoft.DataShare/accounts/shares
- Microsoft.Storage/storageAccounts/providers/roleAssignments
- Microsoft.DataShare/accounts/shares/dataSets
- Microsoft.DataShare/accounts/shares/invitations
- Microsoft.DataShare/accounts/shares/synchronizationSettings
-
Save the Bicep file as main.bicep to your local computer.
-
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 --parameters projectName=<project-name> invitationEmail=<invitation-email>
New-AzResourceGroup -Name exampleRG -Location eastus New-AzResourceGroupDeployment -ResourceGroupName exampleRG -TemplateFile ./main.bicep -projectName "<project-name>" -invitationEmail "<invitation-email>"
[!NOTE] Replace <project-name> with a project name. The project name will be used to generate resource names. Replace <invitation-email> with an email address for receiving data share invitations.
When the deployment finishes, you should see a message indicating the deployment succeeded.
Use the Azure portal, Azure CLI, or Azure PowerShell to list the deployed resources in the resource group.
az resource list --resource-group exampleRG
Get-AzResource -ResourceGroupName exampleRG
When no longer needed, use the Azure portal, Azure CLI, or Azure PowerShell to delete the resource group and its resources.
az group delete --name exampleRG
Remove-AzResourceGroup -Name exampleRG
In this quickstart, you learned how to create an Azure data share and invite recipients. To learn more about how a data consumer can accept and receive a data share, continue to the accept and receive data tutorial.