You are planning to deploy a containerized application to Azure Container Instances (ACI). The container requires access to a persistent volume hosted on an Azure File Share. You decide to use the Azure CLI to provision the resources and deploy the container. Which sequence of steps should you perform to create the storage resources and deploy the container with the mounted volume?
- 1Run the `az storage account create` command to provision a new storage account.
- 2Run the `az storage account keys list` command to retrieve the access keys for the storage account.
- 3Run the `az storage share create` command, passing the storage account name and access key, to create the file share.
- 4Run the `az container create` command, specifying the volume mount parameters, including the file share name, storage account name, and storage account key.
Cevap
To deploy a container to Azure Container Instances with a mounted Azure File Share, you must first create the storage account, retrieve its access keys, create the file share within the storage account using those keys, and finally deploy the container group using the `az container create` command with the appropriate volume mount parameters.
The correct sequence starts with provisioning the physical storage account. Next, the access keys must be retrieved because they are required to authorize the creation of the file share and the subsequent mount operation. Once the keys are available, the file share is created. Finally, the container group is created using the container deployment command, which references the storage account, key, and share to mount the volume to the container.
Adım Adım Çözüm
Anahtar Kavram
Mounting an Azure File Share as a persistent volume in Azure Container Instances