github.com/jandre/docker@v1.7.0/docs/installation/gentoolinux.md (about) 1 <!--[metadata]> 2 +++ 3 title = "Installation on Gentoo" 4 description = "Installation instructions for Docker on Gentoo." 5 keywords = ["gentoo linux, virtualization, docker, documentation, installation"] 6 [menu.main] 7 parent = "smn_linux" 8 +++ 9 <![end-metadata]--> 10 11 # Gentoo 12 13 Installing Docker on Gentoo Linux can be accomplished using one of two ways: the **official** way and the `docker-overlay` way. 14 15 Official project page of [Gentoo Docker](https://wiki.gentoo.org/wiki/Project:Docker) team. 16 17 ## Official way 18 The first and recommended way if you are looking for a stable 19 experience is to use the official `app-emulation/docker` package directly 20 from the tree. 21 22 If any issues arise from this ebuild including, missing kernel 23 configuration flags or dependencies, open a bug 24 on the Gentoo [Bugzilla](https://bugs.gentoo.org) assigned to `docker AT gentoo DOT org` 25 or join and ask in the official 26 [IRC](http://webchat.freenode.net?channels=%23gentoo-containers&uio=d4) channel on the Freenode network. 27 28 ## docker-overlay way 29 30 If you're looking for a `-bin` ebuild, a live ebuild, or a bleeding edge 31 ebuild, use the provided overlay, [docker-overlay](https://github.com/tianon/docker-overlay) 32 which can be added using `app-portage/layman`. The most accurate and 33 up-to-date documentation for properly installing and using the overlay 34 can be found in the [overlay](https://github.com/tianon/docker-overlay/blob/master/README.md#using-this-overlay). 35 36 If any issues arise from this ebuild or the resulting binary, including 37 and especially missing kernel configuration flags or dependencies, 38 open an [issue](https://github.com/tianon/docker-overlay/issues) on 39 the `docker-overlay` repository or ping `tianon` directly in the `#docker` 40 IRC channel on the Freenode network. 41 42 ## Installation 43 44 ### Available USE flags 45 46 | USE Flag | Default | Description | 47 | ------------- |:-------:|:------------| 48 | aufs | |Enables dependencies for the "aufs" graph driver, including necessary kernel flags.| 49 | btrfs | |Enables dependencies for the "btrfs" graph driver, including necessary kernel flags.| 50 | contrib | Yes |Install additional contributed scripts and components.| 51 | device-mapper | Yes |Enables dependencies for the "devicemapper" graph driver, including necessary kernel flags.| 52 | doc | |Add extra documentation (API, Javadoc, etc). It is recommended to enable per package instead of globally.| 53 | lxc | |Enables dependencies for the "lxc" execution driver.| 54 | vim-syntax | |Pulls in related vim syntax scripts.| 55 | zsh-completion| |Enable zsh completion support.| 56 57 USE flags are described in detail on [tianon's 58 blog](https://tianon.github.io/post/2014/05/17/docker-on-gentoo.html). 59 60 The package should properly pull in all the necessary dependencies and 61 prompt for all necessary kernel options. 62 63 $ sudo emerge -av app-emulation/docker 64 65 >Note: Sometimes there is a disparity between the latest versions 66 >in the official **Gentoo tree** and the **docker-overlay**. 67 >Please be patient, and the latest version should propagate shortly. 68 69 ## Starting Docker 70 71 Ensure that you are running a kernel that includes all the necessary 72 modules and configuration (and optionally for device-mapper 73 and AUFS or Btrfs, depending on the storage driver you've decided to use). 74 75 To use Docker, the `docker` daemon must be running as **root**. 76 To use Docker as a **non-root** user, add yourself to the **docker** 77 group by running the following command: 78 79 $ sudo usermod -a -G docker user 80 81 ### OpenRC 82 83 To start the `docker` daemon: 84 85 $ sudo /etc/init.d/docker start 86 87 To start on system boot: 88 89 $ sudo rc-update add docker default 90 91 ### systemd 92 93 To start the `docker` daemon: 94 95 $ sudo systemctl start docker 96 97 To start on system boot: 98 99 $ sudo systemctl enable docker 100 101 If you need to add an HTTP Proxy, set a different directory or partition for the 102 Docker runtime files, or make other customizations, read our systemd article to 103 learn how to [customize your systemd Docker daemon options](/articles/systemd/). 104 105 ## Uninstallation 106 107 To uninstall the Docker package: 108 109 $ sudo emerge -cav app-emulation/docker 110 111 To uninstall the Docker package and dependencies that are no longer needed: 112 113 $ sudo emerge -C app-emulation/docker 114 115 The above commands will not remove images, containers, volumes, or user created 116 configuration files on your host. If you wish to delete all images, containers, 117 and volumes run the following command: 118 119 $ rm -rf /var/lib/docker 120 121 You must delete the user created configuration files manually.