Skip to content

Conversation

@tiborvass
Copy link
Collaborator

@tiborvass tiborvass commented May 11, 2017

Imports the man/ folder from moby/moby, preserving history.

Reuses main Dockerfile to generate man pages

Removes the use of glide, and uses vndr instead.

947efe9 is the merge commit that imports the history
019a052 is the commit that makes the relevant changes to make it work.

Run make -f docker.Makefile manpages to test

Shishir Mahajan and others added 30 commits May 10, 2017 18:15
Signed-off-by: Shishir Mahajan <shishir.mahajan@redhat.com>
Instead of just showing the number of containers this patch will
show the number of running, paused and stopped containers as well.

Signed-off-by: Kim Eik <kim@heldig.org>
(cherry picked from commit a9804ab1cb117a132cbf460067d55f5146d50956)
Signed-off-by: Lei Jitang <leijitang@huawei.com>
Remove the experimental docs for user namespaces and add similar content
to the `docker daemon` command documentation.

Docker-DCO-1.1-Signed-off-by: Phil Estes <estesp@linux.vnet.ibm.com> (github: estesp)
Signed-off-by: Chun Chen <ramichen@tencent.com>
Signed-off-by: David Calavera <david.calavera@gmail.com>
…ice size on daemon restart

Signed-off-by: Shishir Mahajan <shishir.mahajan@redhat.com>
Signed-off-by: Tibor Vass <tibor@docker.com>
Signed-off-by: Alessandro Boch <aboch@docker.com>
docker's network disconnect api now supports `Force` option which can be
used to force cleanup an endpoint from any host in the cluster.

Signed-off-by: Madhu Venugopal <madhu@docker.com>
Fixes issue #19089

Signed-off-by: Wen Cheng Ma <wenchma@cn.ibm.com>
Signed-off-by: Madhu Venugopal <madhu@docker.com>
Signed-off-by: Ryan Belgrave <rmb1993@gmail.com>
Read configuration after flags making this the priority:

1- Apply configuration from file.
2- Apply configuration from flags.

Reload configuration when a signal is received, USR2 in Linux:

- Reload router if the debug configuration changes.
- Reload daemon labels.
- Reload cluster discovery.

Signed-off-by: David Calavera <david.calavera@gmail.com>
* If user doesn't specify the subnets to create a network, it will pick
  subnets from inside preferred pool. This PR aims to inspect these subnets info

* Add integration tests for docker inspect the subnets.

* docker-py project is already synchronized.

* jenkins checks depend on docker/docker-py#888

Fixes issue #18626

Signed-off-by: Wen Cheng Ma <wenchma@cn.ibm.com>
It is possible to invoke `docker ps -f status=dead`, but the
documentation for docker-ps does not mention `dead` as a valid option.
This commit fixes that.

Signed-off-by: Kareem Khazem <karkhaz@karkhaz.com>
This makes it so when calling `docker run --rm`, or `docker rm -v`, only
volumes specified without a name, e.g. `docker run -v /foo` instead of
`docker run -v awesome:/foo` are removed.

Note that all volumes are named, some are named by the user, some get a
generated name. This is specifically about how the volume was specified
on `run`, assuming that if the user specified it with a name they expect
it to persist after the container is cleaned up.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Signed-off-by: Brian Goff <cpuguy83@gmail.com>
We cannot rely on the tar command for this type of operation because tar
versions, flags, and functionality can very from distro to distro.
Since this is in the container execution path it is not safe to have
this as a dependency from dockers POV where the user cannot change the
fact that docker is adding these pre and post mount commands.

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
Signed-off-by: Bryan Boreham <bjboreham@gmail.com>
Fixes issue #18410

Signed-off-by: Wen Cheng Ma <wenchma@cn.ibm.com>
Signed-off-by: Wen Cheng Ma <wenchma@cn.ibm.com>
Signed-off-by: Vincent Woo <me@vincentwoo.com>
Signed-off-by: David Calavera <david.calavera@gmail.com>
In new content addressable model, image no longer
have virtual size column, it is now 'size'. So we
need to update related docs about them.

Signed-off-by: Kai Qiang Wu(Kennan) <wkqwu@cn.ibm.com>
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Also adds internal network tests for bridge network

Signed-off-by: Chun Chen <ramichen@tencent.com>
In the NAME section: "confg.json" -> "config.json"

Signed-off-by: Tom X. Tobin <tomxtobin@tomxtobin.com>
The at sign (`@`) was being referred to in the documentation as an
ampersand (`&`).

Signed-off-by: Tom X. Tobin <tomxtobin@tomxtobin.com>
Signed-off-by: Evan Allrich <evan@unguku.com>
It is difficult to gather information about docker volumes command
without a parent man page.

This man page attempts to explain docker volumes and then references
the command man pages.

Signed-off-by: Dan Walsh <dwalsh@redhat.com>
Signed-off-by: Aidan Hobson Sayers <aidanhs@cantab.net>
mapk0y and others added 9 commits May 10, 2017 18:17
Signed-off-by: mapk0y <mapk0y@gmail.com>
Docker-DCO-1.1-Signed-off-by: Josh Hawn <josh.hawn@docker.com> (github: jlhawn)
Signed-off-by: Akihiro Suda <suda.akihiro@lab.ntt.co.jp>
Signed-off-by: Antonio Murdaca <runcom@redhat.com>
This does some minor fix-ups in the CLI reference
for "history", and copies the formattting section to
the man-pages.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Signed-off-by: David Sheets <dsheets@docker.com>
Instead of forcing users to manually configure a block device to use
with devmapper, this gives the user the option to let the devmapper
driver configure a device for them.

Adds several new options to the devmapper storage-opts:

- dm.directlvm_device="" - path to the block device to configure for
  direct-lvm
- dm.thinp_percent=95 - sets the percentage of space to use for
  storage from the passed in block device
- dm.thinp_metapercent=1 - sets the percentage of space to for metadata
  storage from the passed in block device
- dm.thinp_autoextend_threshold=80 - sets the threshold for when `lvm`
  should automatically extend the thin pool as a percentage of the total
  storage space
- dm.thinp_autoextend_percent=20 - sets the percentage to increase the
  thin pool by when an autoextend is triggered.

Defaults are taken from
[here](https://docs.docker.com/engine/userguide/storagedriver/device-mapper-driver/#/configure-direct-lvm-mode-for-production)

The only option that is required is `dm.directlvm_device` for docker to
set everything up.

Changes to these settings are not currently supported and will error
out.
Future work could support allowing changes to these values.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
This is synonymous with `docker run --cidfile=FILE` and writes the digest of
the newly built image to the named file. This is intended to be used by build
systems which want to avoid tagging (perhaps because they are in CI or
otherwise want to avoid fixed names which can clash) by enabling e.g. Makefile
constructs like:

    image.id: Dockerfile
    	docker build --iidfile=image.id .

    do-some-more-stuff: image.id
    	do-stuff-with <image.id

Currently the only way to achieve this is to use `docker build -q` and capture
the stdout, but at the expense of losing the build output.

In non-silent mode (without `-q`) with API >= v1.29 the caller will now see a
`JSONMessage` with the `Aux` field containing a `types.BuildResult` in the
output stream for each image/layer produced during the build, with the final
one being the end product.  Having all of the intermediate images might be
interesting in some cases.

In silent mode (with `-q`) there is no change, on success the only output will
be the resulting image digest as it was previosuly.

There was no wrapper to just output an Aux section without enclosing it in a
Progress, so add one here.

Added some tests to integration cli tests.

Signed-off-by: Ian Campbell <ian.campbell@docker.com>
Signed-off-by: Tibor Vass <tibor@docker.com>
@andrewhsu
Copy link
Contributor

LGTM

stuff works:

$ make -f docker.Makefile manpages
$ ls man/man*
man/man1:
docker-attach.1             docker-exec.1               docker-node-rm.1            docker-service-update.1
docker-build.1              docker-export.1             docker-node-update.1        docker-service.1
docker-checkpoint-create.1  docker-history.1            docker-node.1               docker-stack-deploy.1
docker-checkpoint-ls.1      docker-image-build.1        docker-pause.1              docker-stack-ls.1
docker-checkpoint-rm.1      docker-image-history.1      docker-plugin-create.1      docker-stack-ps.1
docker-checkpoint.1         docker-image-import.1       docker-plugin-disable.1     docker-stack-rm.1
docker-commit.1             docker-image-inspect.1      docker-plugin-enable.1      docker-stack-services.1
docker-container-attach.1   docker-image-load.1         docker-plugin-inspect.1     docker-stack.1
docker-container-commit.1   docker-image-ls.1           docker-plugin-install.1     docker-start.1
docker-container-cp.1       docker-image-prune.1        docker-plugin-ls.1          docker-stats.1
docker-container-create.1   docker-image-pull.1         docker-plugin-push.1        docker-stop.1
docker-container-diff.1     docker-image-push.1         docker-plugin-rm.1          docker-swarm-init.1
docker-container-exec.1     docker-image-rm.1           docker-plugin-set.1         docker-swarm-join-token.1
docker-container-export.1   docker-image-save.1         docker-plugin-upgrade.1     docker-swarm-join.1
docker-container-inspect.1  docker-image-tag.1          docker-plugin.1             docker-swarm-leave.1
docker-container-kill.1     docker-image.1              docker-port.1               docker-swarm-unlock-key.1
docker-container-logs.1     docker-images.1             docker-ps.1                 docker-swarm-unlock.1
docker-container-ls.1       docker-import.1             docker-pull.1               docker-swarm-update.1
docker-container-pause.1    docker-info.1               docker-push.1               docker-swarm.1
docker-container-port.1     docker-inspect.1            docker-rename.1             docker-system-df.1
docker-container-prune.1    docker-kill.1               docker-restart.1            docker-system-events.1
docker-container-rename.1   docker-load.1               docker-rm.1                 docker-system-info.1
docker-container-restart.1  docker-login.1              docker-rmi.1                docker-system-prune.1
docker-container-rm.1       docker-logout.1             docker-run.1                docker-system.1
docker-container-run.1      docker-logs.1               docker-save.1               docker-tag.1
docker-container-start.1    docker-network-connect.1    docker-search.1             docker-top.1
docker-container-stats.1    docker-network-create.1     docker-secret-create.1      docker-unpause.1
docker-container-stop.1     docker-network-disconnect.1 docker-secret-inspect.1     docker-update.1
docker-container-top.1      docker-network-inspect.1    docker-secret-ls.1          docker-version.1
docker-container-unpause.1  docker-network-ls.1         docker-secret-rm.1          docker-volume-create.1
docker-container-update.1   docker-network-prune.1      docker-secret.1             docker-volume-inspect.1
docker-container-wait.1     docker-network-rm.1         docker-service-create.1     docker-volume-ls.1
docker-container.1          docker-network.1            docker-service-inspect.1    docker-volume-prune.1
docker-cp.1                 docker-node-demote.1        docker-service-logs.1       docker-volume-rm.1
docker-create.1             docker-node-inspect.1       docker-service-ls.1         docker-volume.1
docker-deploy.1             docker-node-ls.1            docker-service-ps.1         docker-wait.1
docker-diff.1               docker-node-promote.1       docker-service-rm.1         docker.1
docker-events.1             docker-node-ps.1            docker-service-scale.1

man/man5:
Dockerfile.5         docker-config-json.5

man/man8:
dockerd.8

@tiborvass tiborvass force-pushed the import_man branch 4 times, most recently from 9c1657c to f44743c Compare May 11, 2017 05:14
Removes the use of glide, and uses vndr instead.

Signed-off-by: Tibor Vass <tibor@docker.com>
.PHONY: test
test:
@go test -tags daemon -v $(shell go list ./... | grep -v /vendor/)
@go test -tags daemon -v $(shell go list ./... | grep -vE '/vendor/|github.com/docker/cli/man$$')
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is it necessary to exclude the man directory from testing?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Because of missing packages, that are included only after the vendor-on-the-fly part of generate.sh

"Deadline": "2m",
"Sort": ["linter", "severity", "path"],
"Exclude": ["cli/compose/schema/bindata.go"],
"Exclude": ["cli/compose/schema/bindata.go", "man/generate.go"],
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is this necessary? I don't think we should exclude it from linting

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Because packages are missing when linting.

## Generate man pages from go source and markdown
.PHONY: manpages
manpages:
@man/generate.sh
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This doesn't need to be .PHONY, this is one of the rare cases when a Makefile is actually appropriate.

I believe something like this would be correct:

man/man*: man/
    @man/generate.sh

manpages: man/man*

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you use wildcards in Makefile rules like that? I didn't think so, you would need $(wildcard man/man*), I think.

But be careful: this:

foo bar: baz
     make-foo-and-bar baz

Does not cause make-foo-and-bar baz to run once whenever baz changes. It will be run once for foo and once for bar. That is unlikely to be what you wanted, at least judging from the lack of parameters to man/generate.sh in your example (if it had been passed $@ then it might be correct).

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess this would be easier to do if we wrote the man pages to man/dist/ then the target would be just that string without the need for wildcards.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not entirely sure how make deals with targets or dependencies which are directories rather then files, but if that sort of thing works (I guess it just stats and uses the mtime just like for a file), sure.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, I think that's how it works. I did it for vendor (in this Makefile) and it seems to work so far.


grep -v '^#' man/vendor.tmp | while read dep; do
vndr $(echo "$dep" | cut -d' ' -f1)
done
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There has to be a better way to do this.

Why not keep this as a separate Dockerfile? Now that we have ARG in FROM I think we can have a single file.

@vdemeester
Copy link
Collaborator

@tiborvass needs a rebase 👼

@tiborvass tiborvass closed this Jun 1, 2017
nobiit pushed a commit to nobidev/docker-cli that referenced this pull request Nov 19, 2025
nobiit pushed a commit to nobidev/docker-cli that referenced this pull request Nov 19, 2025
Do not terminate on missing build-ids
Upstream-commit: 8457a25900698f1bdef844c22fb19900de1a5bc7
Component: packaging
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.