docker - 无法在 Windows 容器上挂载文件
问题描述
当我尝试在 docker-compose.yml 文件上安装配置文件时:
version: '3.4'
services:
myService:
...
volumes:
- c:\DOCKER_DATA\myService.config:c:\MyService.exe.config
我得到:
无法为服务 myService 创建容器:无效的卷规范:'c:\DOCKER_DATA\myService.config:c:\myService.exe.config:rw':“bind”类型的装载配置无效:源路径必须是目录
解决方案
目前,此处发布的 Windows 容器不支持此功能。
推荐阅读
- c# - 在我的业务逻辑中使用 LINQ,但出现错误
- javascript - Javascript - 如何删除类中的事件侦听器?
- python - Python - 批量读取非常大的文本文件时的无限循环
- arduino - 在此日期之前,是否有适用于 Arduino 或 Raspberry pi 的 Google 帮助?
- django - Django - 如何检查查询集的所有属性?
- powerbi - 计算 Power BI 中两个筛选器之间的差异
- ios - 如何在 SwiftUI 中从 json API 生成固定数量的视图?
- mysql - 在 Bash 脚本文件中编写存储过程
- recursion - 努力建立递归直觉
- android - 使用 Android 设备构建 ionic cordova