Change Docker Default Location

By March 11, 2018Docker

The most recent method to change the default data directory location is edit
[raw] /lib/systemd/system/docker.service
[/raw]

Replace the ExecStart value with the following:
[raw] ExecStart=/usr/bin/dockerd –graph=”/mnt/blockstorage/” -H fd://
[/raw]

Replace graph=”” with the location of your new storage.

or

Edit [raw]/etc/docker/daemon.json[/raw] [raw] {
“graph”: “/mnt/blockstorage”
}
[/raw]

 

Leave a Reply