![](/img/trans.png)
[英]Finding the correct network interface for VirtualBox instance spun up by docker-machine on OSX
[英]docker-machine virtualbox image locations on OSX
我在OSX(Mac Book)上使用docker-machine,它將圖像放在~/.docker/machine
。 我的驅動器幾乎已滿,我想將圖像移動到另一個驅動器。 如果有安裝選項或方法為.docker
和子目錄指定不同的位置,那將是很好的。
有沒有人沒有這么簡單的方法?
這可以使用MACHINE_STORAGE_PATH
環境變量或指定-s, --storage-path
:
$ export MACHINE_STORAGE_PATH=/Volumes/Drobo/machine
$ mkdir $MACHINE_STORAGE_PATH
$ docker-machine create test -d virtualbox
Creating CA: /Volumes/Drobo/machine/certs/ca.pem
Creating client certificate: /Volumes/Drobo/machine/certs/cert.pem
Image cache does not exist, creating it at /Volumes/Drobo/machine/cache...
No default boot2docker iso found locally, downloading the latest release...
Downloading https://github.com/boot2docker/boot2docker/releases/download/v1.8.1/boot2docker.iso to /Volumes/Drobo/machine/cache/boot2docker.iso...
Creating VirtualBox VM...
Creating SSH key...
Starting VirtualBox VM...
Starting VM...
To see how to connect Docker to this machine, run: docker-machine env test
$
$ ls -l /Volumes/Drobo/machine/machines/
total 0
drwx------ 13 brianz staff 442 Aug 28 16:37 test
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.