docker images are stored in root user thus consuming my disk space

Hi my server is configured such that the free space for root user in it is very less. However the user created(suppose user1) has lot of space.
The docker images which are getting created by docker are saved in the root user thus consuming space and making my jobs to fail.How can i make docker images use user1?

Do i need to restart the registry in anyway?

  • Can I export a container with data and everything to spawn a complete copy on another computer?
  • Docker instance port Management
  • deploy war file on tomcat docker container
  • ASP.NET Core 1.0 EF7 System.Data.SqlClient not found
  • “docker images” command doesn't show correct size
  • I can't figure out this sequel pro and docker issue
  • I am unable to understand how to use docker groups and -G tag for this purpose.

    Can i mention something in dockerfile and make images up using user1 ?

  • How to add private registry certs to Docker Machine
  • Docker | How to build and deploy war file in jboss container hosted in Docker
  • Why don't docker use the host OS for all purposes
  • How is the ID from the docker info generated and how stable is it?
  • Dynamic DNS Resolution with HAProxy and Docker
  • How to enable SCM polling with the Jenkins Pipeline plugin
  • 2 Solutions collect form web for “docker images are stored in root user thus consuming my disk space”

    Checkout the -g option on the daemon process. Can be used to locate the docker home on an alternative disk volume.

    Explained in the following documentation links:

    Linked /var to /user1/var.

    The mounts and the volumes stay the same.

    I did this:

    `telinit 1 
    cp -pR /var /user1/var 
    mv /var /var.old 
    ln -s /user1/var /var 
    telinit 2` 
    Docker will be the best open platform for developers and sysadmins to build, ship, and run distributed applications.