이 PowerShell 스크립트는 기존 데이터 공유에 Blob 데이터 세트를 추가합니다.
샘플 스크립트
# Set variables with your own values
$resourceGroupName = "<Resource group name>"
$dataShareAccountName = "<Data share account name>"
$dataShareName = "<Data share name>"
$blobDatasetName = "<Dataset name>"
$blobContainer = "<Blob container name>"
$blobFilePath = "<Blob file path>"
$storageAccountResourceId = "<Storage account resource id>"
#Add a blob dataset to the datashare
New-AzDataShareDataSet -ResourceGroupName $resourceGroupName -AccountName $dataShareAccountName -ShareName $dataShareName -Name $blobDataSetName -StorageAccountResourceId $storageAccountResourceId -FilePath $blobFilePath
스크립트 설명
이 스크립트는 다음 명령을 사용합니다.
| 명령 | 주의 |
|---|---|
| New-AzDataShareDataSet | 데이터 세트를 데이터 공유에 추가합니다. |
관련 콘텐츠
Azure PowerShell에 대한 자세한 내용은 Azure PowerShell 설명서를 참조하세요.
기타 Azure Data Share PowerShell 스크립트 샘플은 Azure Data Share PowerShell 샘플에 있습니다.