Commit Graph

65 Commits

Author SHA1 Message Date
b5335d2b04 Add log reading to the journald log driver
If a logdriver doesn't register a callback function to validate log
options, it won't be usable.  Fix the journald driver by adding a dummy
validator.

Teach the client and the daemon's "logs" logic that the server can also
supply "logs" data via the "journald" driver.  Update documentation and
tests that depend on error messages.

Add support for reading log data from the systemd journal to the
journald log driver.  The internal logic uses a goroutine to scan the
journal for matching entries after any specified cutoff time, formats
the messages from those entries as JSONLog messages, and stuffs the
results down a pipe whose reading end we hand back to the caller.

If we are missing any of the 'linux', 'cgo', or 'journald' build tags,
however, we don't implement a reader, so the 'logs' endpoint will still
return an error.

Make the necessary changes to the build setup to ensure that support for
reading container logs from the systemd journal is built.

Rename the Jmap member of the journald logdriver's struct to "vars" to
make it non-public, and to make it easier to tell that it's just there
to hold additional variable values that we want journald to record along
with log data that we're sending to it.

In the client, don't assume that we know which logdrivers the server
implements, and remove the check that looks at the server.  It's
redundant because the server already knows, and the check also makes
using older clients with newer servers (which may have new logdrivers in
them) unnecessarily hard.

When we try to "logs" and have to report that the container's logdriver
doesn't support reading, send the error message through the
might-be-a-multiplexer so that clients which are expecting multiplexed
data will be able to properly display the error, instead of tripping
over the data and printing a less helpful "Unrecognized input header"
error.

Signed-off-by: Nalin Dahyabhai <nalin@redhat.com> (github: nalind)
Upstream-commit: a821292ec8
Component: cli
2017-06-02 00:07:08 +00:00
8d0688201f Make daemon to start with no userlandproxy by default
This PR makes a user visible behavior change with userland
proxy disabled by default and rely on hairpin NAT to be enabled
by default. This may not work in older (unsupported) kernels
where the user will be forced to enable userlandproxy if needed.

      - Updated the Docs
      - Changed the integration-cli to start with userlandproxy
	desiabled by default.

Signed-off-by: Jana Radhakrishnan <mrjana@docker.com>
Upstream-commit: 3dff6170d6
Component: cli
2017-06-02 00:07:08 +00:00
016d3c3aa6 Add STOPSIGNAL instruction to dockerfiles.
This way, images creators can set the exit signal their programs use.

Signed-off-by: David Calavera <david.calavera@gmail.com>
Upstream-commit: f5b80326a1
Component: cli
2017-06-02 00:07:08 +00:00
6cdd6e3a6b update docker volume man pages
- added --help option
- fixed several formatting problems

Also added --help to volume inspect reference page.

Signed-off-by: Harald Albers <github@albersweb.de>
Upstream-commit: e8447c157d
Component: cli
2017-06-02 00:07:08 +00:00
0d8d6d57ac Add missing ps placeholder to the docs.
Signed-off-by: David Calavera <david.calavera@gmail.com>
Upstream-commit: 54a47bdcaa
Component: cli
2017-06-02 00:07:08 +00:00
5b7698a1f6 Fix usage for docker volume inspect and docker volume rm
For both commands, volume is _not_ optional. Several volumes may
be specified.
Both commands now use the same name (VOLUME) for the command argument.

Signed-off-by: Harald Albers <github@albersweb.de>
Upstream-commit: 849b5b6d67
Component: cli
2017-06-02 00:07:08 +00:00
dc9efd3901 Typo in cp.md
Closes #16124

Signed-off-by: Doug Davis <dug@us.ibm.com>
Upstream-commit: 56b46dca76
Component: cli
2017-06-02 00:07:08 +00:00
f264c481a4 Fix minor typo in docs
Signed-off-by: Harald Albers <github@albersweb.de>
Upstream-commit: 2edd24ea80
Component: cli
2017-06-02 00:07:08 +00:00
af60232055 add --insecure-registry warning to online docs
Signed-off-by: Sally O'Malley <somalley@redhat.com>
Upstream-commit: 5d85be4a3c
Component: cli
2017-06-02 00:07:08 +00:00
d3348772c2 Warning message for lvm devmapper running on top of loopback devices
Signed-off-by: Shishir Mahajan <shishir.mahajan@redhat.com>
Upstream-commit: d5394a0d5f
Component: cli
2017-06-02 00:07:07 +00:00
f286f8afde Add 'ancestor' ps filter for image
Makes it possible to filter containers by image, using
--filter=ancestor=busybox and get all the container running busybox
image and image based on busybox (to the bottom).

Signed-off-by: Vincent Demeester <vincent@sbr.pm>
Upstream-commit: 67f663c7bf
Component: cli
2017-06-02 00:07:07 +00:00
2b021a1765 Update filtering chapters on ps/images references
Signed-off-by: Vincent Demeester <vincent@sbr.pm>
Upstream-commit: 898614f30a
Component: cli
2017-06-02 00:07:07 +00:00
ccd9b5c29e Builder counts from 1
Signed-off-by: John Howard <jhoward@microsoft.com>
Upstream-commit: 6d275805ad
Component: cli
2017-06-02 00:07:07 +00:00
fb53625655 Add volume API/CLI
Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Upstream-commit: 1f10226bfd
Component: cli
2017-06-02 00:07:07 +00:00
53111401ba adding message option to the import subcommand
Signed-off-by: Taylor Jones <monitorjbl@gmail.com>
Upstream-commit: f4060b1f65
Component: cli
2017-06-02 00:07:07 +00:00
74c0fd37cc Add unless-stopped restart policy
Fixes #11008

Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: df39b0146b
Component: cli
2017-06-02 00:07:07 +00:00
1386a1809c Add support for kernel memory limit
Signed-off-by: Qiang Huang <h.huangqiang@huawei.com>
Upstream-commit: 5731775665
Component: cli
2017-06-02 00:07:06 +00:00
3376746a0c add weight to daemon page so it renders in order
Signed-off-by: Morgan Bauer <mbauer@us.ibm.com>
Upstream-commit: 4ddb2c2a8d
Component: cli
2017-06-02 00:07:06 +00:00
05097b2cf9 Updated test to check for exec --privileged side-effects
Also improving documentation for same feature as part of
docker/docker#14113 docs review.

Signed-off-by: Tim Dettrick <t.dettrick@uq.edu.au>
Upstream-commit: e577c15cec
Component: cli
2017-06-02 00:07:05 +00:00
229ae40481 Revert "Revert "Add docker exec run a command in privileged mode""
This reverts commit 40b71adee390e9c06471b89ed845132b4ec80177.

Original commit (for which this is effectively a rebased version) is
72a500e9e5929b038816d8bd18d462a19e571c99 and was provided by Lei Jitang
<leijitang@huawei.com>.

Signed-off-by: Tim Dettrick <t.dettrick@uq.edu.au>
Upstream-commit: d0fa83e285
Component: cli
2017-06-02 00:07:05 +00:00
913a4fa94d Fix #8048 : make docker images repository:tag work
Make command like "docker images ubuntu:14.04" work and filter out the
image with the given tag.

Closes #8048.

Signed-off-by: Vincent Demeester <vincent@sbr.pm>
Upstream-commit: a395c4af01
Component: cli
2017-06-02 00:07:05 +00:00
32fd4e2f42 Remove -h flag from completion and daemon reference
All docker subcommands support `-h` as an alias for `--help`
unless they have `-h` aliased to something else like `docker run`,
which uses `-h` for `--hostname`.

`-h` is not included in the help messages of the commands, though.

It ist visible in
* reference: only in `docker daemon` reference,
  see output of `grep -Rse --help=false docs`
* man pages: only in `docker` man page
  see output of `grep -RF '**-h**' man`

For consistency reasons, this commit removes `-h` as an alias for
`--help` from the reference page, man page and the bash completion.

Signed-off-by: Harald Albers <github@albersweb.de>
Upstream-commit: 91300d7db0
Component: cli
2017-06-02 00:07:05 +00:00
cca08cfd4e - Remove references to sudo in basics.md; see sudo instructions top of file
- Removing references to Boot2Docker replacing with Docker Machine
- Removing sudo warnings in instances where appropriate (no sudo in file)
- Updating with comments

Signed-off-by: Mary Anthony <mary@docker.com>
Upstream-commit: 8bd8ac0170
Component: cli
2017-06-02 00:07:04 +00:00
a19c3b4886 Docker stats: display Block IO stats
Signed-off-by: Zhang Wei <zhangwei555@huawei.com>
Upstream-commit: 2b4f09abe4
Component: cli
2017-06-02 00:07:04 +00:00
bbec853a6b Multiple fixes to 'docker stats' output:
* Add space between values in docker stats output for easier parsing

  Old output could not be parsed easily because there were columns
  that did not have any separator. Also values that are together
  without any space is difficult to read even for humans.

* Update unit.HumanSize comment to match what the does actually does

Signed-off-by: Otto Kekäläinen <otto@seravo.fi>
Upstream-commit: ab0de17526
Component: cli
2017-06-02 00:07:04 +00:00
d9d9241080 Copy edits for typos
Signed-off-by: Ed Costello <epc@epcostello.com>
Upstream-commit: 67f43a0a8b
Component: cli
2017-06-02 00:07:04 +00:00
f1e06e2bd3 daemon.md: do fix placement of exec driver heading
Options for zfs storage driver were incorrectly placed
under 'exec driver options' header. Move the header to
the correct place.

Now, this is the second time I am fixing this. First time
it was commit 68efb27, but the following commit 9af7afb
screwed it up again, so the header appears twice now.

Get rid of the the wrong one.

Cc: David Calavera <david.calavera@gmail.com>
Signed-off-by: Kir Kolyshkin <kir@openvz.org>
Upstream-commit: 7480a999ca
Component: cli
2017-06-02 00:07:04 +00:00
9150f65bd7 Remove references to boot2docker replace with docker-machine
- boot2docker is deprecated in the 1.8.0
- docker-machine replaces it
- this fixes #14563
- Updating with thaJetzah comments

Signed-off-by: Mary Anthony <mary@docker.com>
Upstream-commit: b775ca48e0
Component: cli
2017-06-02 00:07:04 +00:00
29d9d04015 Add missing documentation to cli/import.md
PR #11907 added support for import using file (path), but it missed
the update of cli/import.md. This fixes that.

Signed-off-by: Vincent Demeester <vincent@sbr.pm>
Upstream-commit: 32d52f1244
Component: cli
2017-06-02 00:07:03 +00:00
6faa369765 Fix typo in JSON config example, in the CLI documetation
Signed-off-by: Michał Czeraszkiewicz <czerasz.hosting@gmail.com>
Upstream-commit: d0b639feb0
Component: cli
2017-06-02 00:07:03 +00:00
88f42b2275 Rename to flags and environment variables to content trust
Update help line to allow 90 characters instead of 80

The trust flag pushes out the help description column wider, requiring more room to display help messages.

Signed-off-by: Derek McGowan <derek@mcgstyle.net> (github: dmcgowan)
Upstream-commit: 57094eec6e
Component: cli
2017-06-02 00:07:03 +00:00
692c177a60 Add cmdline docs for signing and verification flows
Signed-off-by: Nathan McCauley <nathan.mccauley@docker.com>
Upstream-commit: 53d11aa48e
Component: cli
2017-06-02 00:07:03 +00:00
4869d3d87d Document that load supports compressed tarballs.
As per
ecdbf86884/pkg/archive/archive.go (L96)

Signed-off-by: Andy Rothfusz <github@developersupport.net>
Upstream-commit: e52d8f2291
Component: cli
2017-06-02 00:07:03 +00:00
61b854bffc Update docs to use the new docker daemon command
Signed-off-by: Tibor Vass <tibor@docker.com>
Upstream-commit: a79a020ed7
Component: cli
2017-06-02 00:07:03 +00:00
a0ea158993 Fixing dangling link in docs/reference/commandline/run.md
Signed-off-by: Mohammed Aaqib Ansari <maaquib@gmail.com>
Upstream-commit: 2bf81f0efb
Component: cli
2017-06-02 00:07:03 +00:00
Lei
2d2192c579 Add ulimit to docker build.
Signed-off-by: Lei Jitang <leijitang@huawei.com>
Upstream-commit: f793c1b50c
Component: cli
2017-06-02 00:07:02 +00:00
Lei
a6c3628cea Docs: update the devicemapper default basesize from 10G to 100G
Signed-off-by: Lei Jitang <leijitang@huawei.com>
Upstream-commit: ba3e24187c
Component: cli
2017-06-02 00:07:02 +00:00
0bcbde5ebd Split reader interface from logger interface
Implement new reader interface on jsonfile.
Moves jsonlog decoding from daemon to jsonfile logger.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Upstream-commit: c9cf4a479a
Component: cli
2017-06-02 00:07:02 +00:00
7317401756 ps --format: Add config.js doc, fix gofmt, add integration tests
Re-add the docs from @calavera's PR to the moved cli cmd reference docs.
Fix gofmt and vet issues from carried commits
Add integration test for using format with --no-trunc and multi-names
Fix custom_test map order dependency on expected value check
Add docs to reference/commandline/ps.md
Remove "-F" flag option from original carried PR content

Docker-DCO-1.1-Signed-off-by: Phil Estes <estesp@linux.vnet.ibm.com> (github: estesp)
Upstream-commit: 5f2fd60890
Component: cli
2017-06-02 00:07:02 +00:00
d41bceaee4 docs: Updated for docker cp and its API changes
Documented changes to API to enable new `docker cp` behavior.

Added documentation on `docker cp` usage and behavior.

Docker-DCO-1.1-Signed-off-by: Josh Hawn <josh.hawn@docker.com> (github: jlhawn)
Upstream-commit: 7e6f0aaece
Component: cli
2017-06-02 00:07:02 +00:00
1591eec643 Update documentation according to opts updates
Signed-off-by: Vincent Demeester <vincent@sbr.pm>
Upstream-commit: bbabc8172c
Component: cli
2017-06-02 00:07:02 +00:00
a40aa70084 add support for maximum log size, and max number of log files
Signed-off-by: wlan0 <sidharthamn@gmail.com>
Upstream-commit: 7dac74d442
Component: cli
2017-06-02 00:07:01 +00:00
6dbeaaf4d7 Docs: fix commandline doc create.md and run.md
Signed-off-by: Qiang Huang <h.huangqiang@huawei.com>
Upstream-commit: 30dbdd7943
Component: cli
2017-06-02 00:07:01 +00:00
b93f7135a0 Adds documentation for additional groups.
Signed-off-by: Mrunal Patel <mrunalp@gmail.com>
Upstream-commit: 7301088482
Component: cli
2017-06-02 00:07:01 +00:00
0d5c36bb7c add --format flag to docker version
Signed-off-by: Patrick Hemmer <patrick.hemmer@gmail.com>
Upstream-commit: 90f2c9cf90
Component: cli
2017-06-02 00:07:01 +00:00
88ba0fa858 Add the memory swappiness tuning option to docker.
Memory swappiness option takes 0-100, and helps to tune swappiness
behavior per container.
For example, When a lower value of swappiness is chosen
the container will see minimum major faults. When no value is
specified for memory-swappiness in docker UI, it is inherited from
parent cgroup. (generally 60 unless it is changed).

Signed-off-by: Raghavendra K T <raghavendra.kt@linux.vnet.ibm.com>
Upstream-commit: b553af956f
Component: cli
2017-06-02 00:07:01 +00:00
d25588047e Align 'docker commit' docs with the code
It was missing some variants and 'maintainer' isn't actually supported.
Also sorted the list of allowed cmds in the code just to make it easier
to diff with the docs.

Signed-off-by: Doug Davis <dug@us.ibm.com>
Upstream-commit: c88c5588bf
Component: cli
2017-06-02 00:07:01 +00:00
2f100155de Add support for DOCKER_CONFIG/--config to specific config file dir
Carry #11675

Aside from what #11675 says, to me a key usecase for this is to support
more than one Docker cli running at the same time but each may have its
own set of config files.

Signed-off-by: Doug Davis <dug@us.ibm.com>
Upstream-commit: 408d7deaf7
Component: cli
2017-06-02 00:07:01 +00:00
07e7c8577e Clarify that nproc is not for per container
Fix ulimit nproc spec in daemon

Signed-off-by: Harry Zhang <harryzhang@zju.edu.cn>
Upstream-commit: db7a29716e
Component: cli
2017-06-02 00:07:01 +00:00
57bfdb01b7 Revert "Fix implicit DeviceMapper selection"
This reverts commit 0a376291b2213699f986a7bca1cc8c4f4ed00f8d.

Signed-off-by: David Calavera <david.calavera@gmail.com>
Upstream-commit: 083daaeb2b
Component: cli
2017-06-02 00:07:00 +00:00