OS下Docker挂载路径报错:does not exist: /host_mnt

系统:Mac OS 13.0.1 (22A400)
Docker版本:4.21.1 (114176)

使用命令:

docker run -it --rm --name XXXX --mount type=bind,source=#Home/Documents/fonts/,target=/home/fonts XXXXX

报错内容为:docker: Error response from daemon: invalid mount config for type "bind": bind source path does not exist: /host_mnt/Users/abc/Documents/fonts.

解决方法:
删除“source=#Home/Documents/fonts/”中的“Documents/fonts/”,mac中似乎只能挂载整个路径

你可能感兴趣的:(docker,容器,运维)