By accessing the website and accepting the Cookie Policy, you agree to use the cookies provided by the Site in accordance with to analyze traffic, remember your preferences, and optimize your experience.
Docker Compose on Windows 掛 Volume 路徑問題
2020-07-09 20:10:11    365    0    0
emengweb

在Windows系统疯狂的无法正常挂载本地映射,尝试许久终于找到解决方法。(路径必须使用/c(盘符)/绝对路径,相对路径会导致docker出错)

解法

  1. 打開 Docker Desktop 設定,找到 Shared Drives
  2. 勾選你 docker-compose.yml 檔案所在的硬碟 -> Apply
  3. 在 docker-compose.yml 的資料夾下,新增 .env 檔案
    COMPOSE_CONVERT_WINDOWS_PATHS=1
  4. 重新執行 docker-compose up -d

上一篇: Docker保存修改后的镜像

下一篇: nohup命令提示无法执行的解决方法 nohup: command not found

365 人读过
文档导航