2014-04-15 06:01:25 +00:00
|
|
|
|
page_title: About Docker
|
2014-05-18 18:52:41 +02:00
|
|
|
|
page_description: Introduction to Docker.
|
2014-04-15 06:01:25 +00:00
|
|
|
|
page_keywords: docker, introduction, documentation, about, technology, understanding, Dockerfile
|
|
|
|
|
|
|
|
|
|
# About Docker
|
|
|
|
|
|
2014-05-18 18:52:41 +02:00
|
|
|
|
**Develop, Ship and Run Any Application, Anywhere**
|
2014-04-15 06:01:25 +00:00
|
|
|
|
|
2014-06-23 18:35:15 +00:00
|
|
|
|
[**Docker**](https://www.docker.com) is a platform for developers and sysadmins
|
2014-06-06 07:50:04 +10:00
|
|
|
|
to develop, ship, and run applications. Docker lets you quickly assemble
|
|
|
|
|
applications from components and eliminates the friction that can come when
|
|
|
|
|
shipping code. Docker lets you get your code tested and deployed into production
|
|
|
|
|
as fast as possible.
|
2014-05-18 18:52:41 +02:00
|
|
|
|
|
2014-06-04 13:17:21 -07:00
|
|
|
|
Docker consists of:
|
2014-05-18 18:52:41 +02:00
|
|
|
|
|
2014-06-04 13:17:21 -07:00
|
|
|
|
* The Docker Engine - our lightweight and powerful open source container
|
|
|
|
|
virtualization technology combined with a work flow for building
|
|
|
|
|
and containerizing your applications.
|
2014-06-14 23:13:55 +02:00
|
|
|
|
* [Docker Hub](https://hub.docker.com) - our SaaS service for
|
2014-06-04 13:17:21 -07:00
|
|
|
|
sharing and managing your application stacks.
|
2014-05-18 18:52:41 +02:00
|
|
|
|
|
|
|
|
|
## Why Docker?
|
|
|
|
|
|
2014-07-02 16:33:13 -07:00
|
|
|
|
*Faster delivery of your applications*
|
|
|
|
|
|
|
|
|
|
* We want your environment to work better. Docker containers,
|
2014-06-04 13:17:21 -07:00
|
|
|
|
and the work flow that comes with them, help your developers,
|
|
|
|
|
sysadmins, QA folks, and release engineers work together to get your code
|
|
|
|
|
into production and make it useful. We've created a standard
|
|
|
|
|
container format that lets developers care about their applications
|
|
|
|
|
inside containers while sysadmins and operators can work on running the
|
2014-06-06 07:50:04 +10:00
|
|
|
|
container in your deployment. This separation of duties streamlines and
|
|
|
|
|
simplifies the management and deployment of code.
|
2014-07-02 16:33:13 -07:00
|
|
|
|
* We make it easy to build new containers, enable rapid iteration of
|
2014-06-04 13:17:21 -07:00
|
|
|
|
your applications, and increase the visibility of changes. This
|
2014-05-23 18:29:50 +10:00
|
|
|
|
helps everyone in your organization understand how an application works
|
|
|
|
|
and how it is built.
|
2014-07-02 16:33:13 -07:00
|
|
|
|
* Docker containers are lightweight and fast! Containers have
|
2014-06-04 13:17:21 -07:00
|
|
|
|
sub-second launch times, reducing the cycle
|
|
|
|
|
time of development, testing, and deployment.
|
2014-05-18 18:52:41 +02:00
|
|
|
|
|
2014-07-02 16:33:13 -07:00
|
|
|
|
*Deploy and scale more easily*
|
|
|
|
|
|
|
|
|
|
* Docker containers run (almost) everywhere. You can deploy
|
2014-05-18 18:52:41 +02:00
|
|
|
|
containers on desktops, physical servers, virtual machines, into
|
2014-06-04 13:17:21 -07:00
|
|
|
|
data centers, and up to public and private clouds.
|
2014-07-02 16:33:13 -07:00
|
|
|
|
* Since Docker runs on so many platforms, it's easy to move your
|
2014-06-05 16:55:32 -07:00
|
|
|
|
applications around. You can easily move an application from a
|
2014-05-18 18:52:41 +02:00
|
|
|
|
testing environment into the cloud and back whenever you need.
|
2014-07-02 16:33:13 -07:00
|
|
|
|
* Docker's lightweight containers also make scaling up and
|
2014-06-06 07:50:04 +10:00
|
|
|
|
down fast and easy. You can quickly launch more containers when
|
|
|
|
|
needed and then shut them down easily when they're no longer needed.
|
2014-05-18 18:52:41 +02:00
|
|
|
|
|
2014-07-02 16:33:13 -07:00
|
|
|
|
*Get higher density and run more workloads*
|
|
|
|
|
|
|
|
|
|
* Docker containers don't need a hypervisor, so you can pack more of
|
2014-05-18 18:52:41 +02:00
|
|
|
|
them onto your hosts. This means you get more value out of every
|
2014-06-04 13:17:21 -07:00
|
|
|
|
server and can potentially reduce what you spend on equipment and
|
|
|
|
|
licenses.
|
2014-05-18 18:52:41 +02:00
|
|
|
|
|
2014-07-02 16:33:13 -07:00
|
|
|
|
*Faster deployment makes for easier management*
|
|
|
|
|
|
|
|
|
|
* As Docker speeds up your work flow, it gets easier to make lots
|
2014-06-04 13:17:21 -07:00
|
|
|
|
of small changes instead of huge, big bang updates. Smaller
|
|
|
|
|
changes mean reduced risk and more uptime.
|
2014-04-15 06:01:25 +00:00
|
|
|
|
|
|
|
|
|
## About this guide
|
|
|
|
|
|
2014-07-02 16:33:13 -07:00
|
|
|
|
The [Understanding Docker section](introduction/understanding-docker.md) will help you:
|
2014-04-15 06:01:25 +00:00
|
|
|
|
|
2014-06-04 13:17:21 -07:00
|
|
|
|
- See how Docker works at a high level
|
|
|
|
|
- Understand the architecture of Docker
|
2014-05-18 18:52:41 +02:00
|
|
|
|
- Discover Docker's features;
|
2014-06-04 13:17:21 -07:00
|
|
|
|
- See how Docker compares to virtual machines
|
|
|
|
|
- See some common use cases.
|
2014-04-15 06:01:25 +00:00
|
|
|
|
|
2014-05-22 07:05:19 +10:00
|
|
|
|
### Installation Guides
|
2014-04-15 06:01:25 +00:00
|
|
|
|
|
2014-07-02 16:33:13 -07:00
|
|
|
|
The [installation section](/installation/#installation) will show you how to install
|
|
|
|
|
Docker on a variety of platforms.
|
2014-04-15 06:01:25 +00:00
|
|
|
|
|
|
|
|
|
|
2014-05-22 07:05:19 +10:00
|
|
|
|
### Docker User Guide
|
|
|
|
|
|
2014-08-27 18:34:19 -07:00
|
|
|
|
To learn about Docker in more detail and to answer questions about usage and
|
|
|
|
|
implementation, check out the [Docker User Guide](/userguide/).
|
|
|
|
|
|
|
|
|
|
## Release Notes
|
|
|
|
|
|
|
|
|
|
**Version 1.2.0**
|
|
|
|
|
|
|
|
|
|
This version fixes a number of bugs and issues and adds new functions and other
|
|
|
|
|
improvements. These include:
|
|
|
|
|
|
|
|
|
|
*New restart policies*
|
|
|
|
|
|
|
|
|
|
We added a `--restart flag` to `docker run` to specify a restart policy for your
|
|
|
|
|
container. Currently, there are three policies available:
|
|
|
|
|
|
2014-08-28 17:29:09 -07:00
|
|
|
|
* `no` – Do not restart the container if it dies. (default)
|
|
|
|
|
* `on-failure` – Restart the container if it exits with a non-zero exit code.
|
2014-08-27 18:34:19 -07:00
|
|
|
|
This can also accept an optional maximum restart count (e.g. `on-failure:5`).
|
2014-08-28 17:29:09 -07:00
|
|
|
|
* `always` – Always restart the container no matter what exit code is returned.
|
2014-08-27 18:34:19 -07:00
|
|
|
|
This deprecates the `--restart` flag on the Docker daemon.
|
|
|
|
|
|
|
|
|
|
*New flags for `docker run`: `--cap-add` and `–-cap-drop`*
|
|
|
|
|
|
|
|
|
|
In previous releases, Docker containers could either be given complete capabilities or
|
|
|
|
|
they could all follow a whitelist of allowed capabilities while dropping all others.
|
|
|
|
|
Further, using `--privileged` would grant all capabilities inside a container, rather than
|
|
|
|
|
applying a whitelist. This was not recommended for production use because it’s really
|
|
|
|
|
unsafe; it’s as if you were directly in the host.
|
|
|
|
|
|
2014-08-28 17:29:09 -07:00
|
|
|
|
This release introduces two new flags for `docker run`, `--cap-add` and `--cap-drop`, that
|
|
|
|
|
give you fine-grain control over the specific capabilities you want grant to a particular
|
2014-08-27 18:34:19 -07:00
|
|
|
|
container.
|
|
|
|
|
|
|
|
|
|
*New `-–device` flag for `docker run`*
|
|
|
|
|
|
2014-08-28 17:29:09 -07:00
|
|
|
|
Previously, you could only use devices inside your containers by bind mounting them (with
|
2014-08-27 18:34:19 -07:00
|
|
|
|
`-v`) in a `--privileged` container. With this release, we introduce the `--device flag`
|
|
|
|
|
to `docker run` which lets you use a device without requiring a privileged container.
|
|
|
|
|
|
|
|
|
|
*Writable `/etc/hosts`, `/etc/hostname` and `/etc/resolv.conf`*
|
|
|
|
|
|
|
|
|
|
You can now edit `/etc/hosts`, `/etc/hostname` and `/etc/resolve.conf` in a running
|
2014-08-28 17:29:09 -07:00
|
|
|
|
container. This is useful if you need to install BIND or other services that might
|
2014-08-27 18:34:19 -07:00
|
|
|
|
override one of those files.
|
|
|
|
|
|
2014-08-28 17:29:09 -07:00
|
|
|
|
Note, however, that changes to these files are not saved when running `docker build` and
|
|
|
|
|
so will not be preserved in the resulting image. The changes will only “stick” in a
|
|
|
|
|
running container.
|
2014-08-27 18:34:19 -07:00
|
|
|
|
|
|
|
|
|
*Docker proxy in a separate process*
|
|
|
|
|
|
|
|
|
|
The Docker userland proxy that routes outbound traffic to your containers now has its own
|
|
|
|
|
separate process (one process per connection). This greatly reduces the load on the
|
|
|
|
|
daemon, which increases stability and efficiency.
|
|
|
|
|
|
2014-08-28 17:29:09 -07:00
|
|
|
|
*Other improvements & changes*
|
2014-08-27 18:34:19 -07:00
|
|
|
|
|
2014-08-28 17:29:09 -07:00
|
|
|
|
* When using `docker rm -f`, Docker now kills the container (instead of stopping it)
|
|
|
|
|
before removing it . If you intend to stop the container cleanly, you can use `docker
|
|
|
|
|
stop`.
|
2014-08-27 18:34:19 -07:00
|
|
|
|
|
|
|
|
|
* Added support for IPv6 addresses in `--dns`
|
|
|
|
|
|
|
|
|
|
* Added search capability in private registries
|
2014-07-02 16:33:13 -07:00
|
|
|
|
|