2014-04-15 20:53:12 -04:00
|
|
|
page_title: Installation on Gentoo
|
2014-05-27 13:08:19 -04:00
|
|
|
page_description: Installation instructions for Docker on Gentoo.
|
2014-04-15 20:53:12 -04:00
|
|
|
page_keywords: gentoo linux, virtualization, docker, documentation, installation
|
|
|
|
|
|
|
|
# Gentoo
|
|
|
|
|
|
|
|
Installing Docker on Gentoo Linux can be accomplished using one of two
|
2014-04-23 16:48:28 -04:00
|
|
|
methods. The first and best way if you're looking for a stable
|
2014-04-15 20:53:12 -04:00
|
|
|
experience is to use the official app-emulation/docker package directly
|
|
|
|
in the portage tree.
|
|
|
|
|
2014-05-27 13:08:19 -04:00
|
|
|
If you're looking for a `-bin` ebuild, a live ebuild, or bleeding edge
|
|
|
|
ebuild changes/fixes, the second installation method is to use the
|
|
|
|
overlay provided at
|
2014-04-15 20:53:12 -04:00
|
|
|
[https://github.com/tianon/docker-overlay](https://github.com/tianon/docker-overlay)
|
2014-05-27 13:08:19 -04:00
|
|
|
which can be added using `app-portage/layman`. The most accurate and
|
|
|
|
up-to-date documentation for properly installing and using the overlay
|
|
|
|
can be found in [the overlay
|
2014-04-15 20:53:12 -04:00
|
|
|
README](https://github.com/tianon/docker-overlay/blob/master/README.md#using-this-overlay).
|
|
|
|
|
|
|
|
Note that sometimes there is a disparity between the latest version and
|
2014-04-23 16:48:28 -04:00
|
|
|
what's in the overlay, and between the latest version in the overlay and
|
|
|
|
what's in the portage tree. Please be patient, and the latest version
|
2014-04-15 20:53:12 -04:00
|
|
|
should propagate shortly.
|
|
|
|
|
|
|
|
## Installation
|
|
|
|
|
|
|
|
The package should properly pull in all the necessary dependencies and
|
|
|
|
prompt for all necessary kernel options. The ebuilds for 0.7+ include
|
|
|
|
use flags to pull in the proper dependencies of the major storage
|
|
|
|
drivers, with the "device-mapper" use flag being enabled by default,
|
|
|
|
since that is the simplest installation path.
|
|
|
|
|
2014-05-01 10:13:34 -04:00
|
|
|
$ sudo emerge -av app-emulation/docker
|
2014-04-15 20:53:12 -04:00
|
|
|
|
|
|
|
If any issues arise from this ebuild or the resulting binary, including
|
|
|
|
and especially missing kernel configuration flags and/or dependencies,
|
2014-04-23 16:48:28 -04:00
|
|
|
[open an issue on the docker-overlay repository](
|
|
|
|
https://github.com/tianon/docker-overlay/issues) or ping
|
|
|
|
tianon directly in the #docker IRC channel on the freenode network.
|
2014-04-15 20:53:12 -04:00
|
|
|
|
|
|
|
## Starting Docker
|
|
|
|
|
|
|
|
Ensure that you are running a kernel that includes all the necessary
|
|
|
|
modules and/or configuration for LXC (and optionally for device-mapper
|
2014-04-23 16:48:28 -04:00
|
|
|
and/or AUFS, depending on the storage driver you`ve decided to use).
|
2014-04-15 20:53:12 -04:00
|
|
|
|
|
|
|
### OpenRC
|
|
|
|
|
|
|
|
To start the docker daemon:
|
|
|
|
|
2014-05-01 10:13:34 -04:00
|
|
|
$ sudo /etc/init.d/docker start
|
2014-04-15 20:53:12 -04:00
|
|
|
|
|
|
|
To start on system boot:
|
|
|
|
|
2014-05-01 10:13:34 -04:00
|
|
|
$ sudo rc-update add docker default
|
2014-04-15 20:53:12 -04:00
|
|
|
|
|
|
|
### systemd
|
|
|
|
|
|
|
|
To start the docker daemon:
|
|
|
|
|
2014-05-01 10:13:34 -04:00
|
|
|
$ sudo systemctl start docker.service
|
2014-04-15 20:53:12 -04:00
|
|
|
|
|
|
|
To start on system boot:
|
|
|
|
|
2014-05-01 10:13:34 -04:00
|
|
|
$ sudo systemctl enable docker.service
|