Forum Discussion
Azure File Share : Unable to mount Azure file share when executing docker-compose
I am trying to set up a container service locally that mounts an Azure file share as its extended storage. However, I am encountering an error despite verifying the keys and storage name. Here is the error message I am receiving.
[error]
Error response from daemon: failed to populate volume: error while mounting volume '/mnt/cloudstor/ipfs-docker_ipfs-azure': VolumeDriver.Mount: mount failed: exit status 32
output="mount error(13): Permission denied\nRefer to the mount.cifs(8) manual page (e.g. man mount.cifs)\nmount error(13): Permission denied\nRefer to the mount.cifs(8) manual page (e.g. man mount.cifs)\nmount: mounting //fileshare.file.core.windows.net/ipfs-share on /mnt/cloudstor/ipfs-docker_ipfs-azure failed: Permission denied\n
- balasubramanimIron Contributor
Please try these steps.
- Verify Details: Ensure correct storage account name, key, and file share name.
- Install CIFS Support (Linux):
sudo apt-get install cifs-utils - Set Directory Permissions:
sudo mkdir -p /mnt/cloudstor/ipfs-docker_ipfs-azure
sudo chmod 777 /mnt/cloudstor/ipfs-docker_ipfs-azure - Check Docker Compose Config: Ensure correct volume setup in docker-compose.yml:
driver_opts:
share_name: ipfs-share
storage_account_name: <name>
storage_account_key: <key> - Use SMB Version 3.0:
-o vers=3.0,username=<name>,password=<key>,dir_mode=0777,file_mode=0777
Reference URL:
https://learn.microsoft.com/en-us/azure/aks/azure-csi-files-storage-provision
https://learn.microsoft.com/en-us/azure/container-instances/container-instances-volume-azure-files