Score:1

How to use a POSIX-compliant volume in Azure Container Instances

ua flag

Some Docker images like postgres and gitlab/gitlab-ce require the ability to set permissions and ownerships on files and directories, however this does not appear to be supported on Azure Container Instances (see here, here, here) due to the file shares being mounted as CIFS (SMB) and the underlying file system appearing to be NTFS.

Is there any way to mount an Azure file share or blob storage to my container with POSIX permissions and ownership support?

We use Terraform to deploy our infrastructure to Azure, so examples in HCL would be greatly appreciated.

I am not looking for alternatives such as Azure VMs, Azure PostgreSQL Server or Marketplace offerings.

John Hanley avatar
cn flag
ACI does not support your requirement for POSIX file system support at this time.
Simao Gomes Viana avatar
ua flag
@JohnHanley I'm aware of that, my question is whether there is a concrete way to circumvent it, for example by manually mounting a share or image file or using some kind of proxy FUSE filesystem inside the container. There might already be a halfway elegant solution out there which is what I'm aiming for here.
Simao Gomes Viana avatar
ua flag
There is no way. It's impossible. AKS doesn't do this either.
Score:0
cn flag

If you have not yet solved this you can use NFS to access data in storage account

Azure Files allows access through NFS and offers POSIX compliance

https://docs.microsoft.com/en-us/azure/storage/files/files-nfs-protocol

You can also have a look at other NFS access solutions in Azure

https://docs.microsoft.com/en-us/azure/storage/common/nfs-comparison

Then you can see here for instructions to mount this in Azure Container Instance

Simao Gomes Viana avatar
ua flag
As of my last conversation with Microsoft Support, they have confirmed to me that the documentation is incorrect and that NFS shares are not supported in Azure Containers. Furthermore, the instructions you have linked are not tested and do not actually work because ACI does not allow mounting volumes inside the container.
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.