docker - 卷 myvol 指定不存在的驱动程序 azurefile
问题描述
Net 核心应用程序,我正在尝试挂载 azure 文件共享。下面是我的 docker-compose 文件。
version: "3.9"
services:
mountvolume:
container_name: mountvolume
build:
context: .
dockerfile: ./Dockerfile
ports:
- "8080:80"
volumes:
- myvol:/Files/
volumes:
myvol:
driver: azurefile
driver_opts:
accountname: mystorageaccount28628
accountkey: 2em0XONHCmgEE9m81Q/O0rTSGXf9giw==
share: "acishare"
remotepath: "aci/logs"
我在其中一个存储帐户中手动创建了名为 acishare 的 FileShare。我已经给出了与上面相同的存储帐户的帐户名和密钥。我尝试 docker-compose up 并得到以下错误
ERROR: Volume myvol specifies nonexistent driver azure file
有人可以帮我解决这个错误。同样在上面的卷部分中,我有字段 share 和 remotepath 所以 share 表示文件共享名称,但远程路径到底是什么意思?有人可以帮我弄清楚。任何帮助,将不胜感激。谢谢
解决方案
我目前有同样的问题,经过一些研究,似乎 docker 的 azure 文件驱动程序插件已被删除。不过,docker 文档 ( https://docs.docker.com/cloud/aci-integration/ )中仍然提到了它,但驱动程序拼写为azure_file。azure 文件插件的 Github 项目已被放弃https://github.com/Azure/azurefile-dockervolumedriver。
据我了解 MS Azure 文档,现在只有在 azure 中部署容器时才能进行集成(https://docs.microsoft.com/en-us/azure/container-instances/container-instances-volume-天蓝色文件)。
推荐阅读
- google-sheets - 从 Google 表格中的 m³ 计算 m² 价格
- python - 如果脚本停止执行,如何创建excel文件
- javascript - Chrome 开发工具的性能面板中的文档和文档框架计数是多少?
- javascript - PHP 中的条件格式 JavaScript
- javascript - 出现某些情况时显示警报错误消息
- android - 为什么android从编译转向实现
- python-3.x - Jinja 中的 For 循环无法再次使用或如何移动 First
- git - SSH 是有状态的还是无状态的?
- python - 如何在 Python 中平滑概率分布图?
- numpy - 调用 polyfit 时将 for 循环移动到 numpy 单个表达式中