How can I permanently change Docker’s default pull/download directory?

0
5
Asked By CoolSpoon22 On

I'm trying to figure out how to permanently change the default pull or download directory for Docker, as everything currently goes to my /var/lib/docker directory. Is it possible to modify this setting using a .json file? For reference, my setup includes a 250GB NVMe drive for the main system and a 1TB HDD for my home directory.

2 Answers

Answered By DockerNinja101 On

You need to edit the daemon.json file to change the default directory. Look for the `data-root` option and point it to your preferred directory. Check the Docker docs for the specifics!

Answered By TechieGuru88 On

You might want to keep Docker's directory on the SSD for better performance. Moving it to an HDD could slow things down quite a bit. Check out the Docker documentation for more details on this.

GamerDude99 -

I actually have an SSD too, but I only mount it when I want to game. It used to be my third mount point at /home/usr/Games.

StorageWhiz77 -

Using Docker on an HDD isn't the end of the world, just slower! It's good for backups or less demanding tasks.

Related Questions

LEAVE A REPLY

Please enter your comment!
Please enter your name here

This site uses Akismet to reduce spam. Learn how your comment data is processed.