def _open(self, name, mode='rb'): """ Return the AzureStorageFile. """ from django.core.files.base import ContentFile contents = self._get_service().get_blob_to_bytes( container_name=self.container, blob_name=name ) return ContentFile(contents)