devmapper: use proper DM_UDEV_DISABLE_*_FLAG when creating the thin-pool

Otherwise udev can unecessarily execute various rules (and issue
scanning IO, etc) against the thin-pool -- which can never be a
top-level device.

Docker-DCO-1.1-Signed-off-by: Mike Snitzer <snitzer@redhat.com> (github: snitm)
devmapper: Add option for specifying an lvm2 created thin-pool device

Ideally lvm2 would be used to create/manage the thin-pool volume that is
then handed to docker to exclusively create/manage the thin and thin
snapshot volumes needed for it's containers.  Managing the thin-pool
outside of docker makes for the most feature-rich method of having
docker utilize device mapper thin provisioning as the backing storage
for docker's containers.  lvm2-based thin-pool management feature
highlights include: automatic or interactive thin-pool resize support,
dynamically change thin-pool features, automatic thinp metadata checking
when lvm2 activates the thin-pool, etc.

Docker will not activate/deactivate the specified thin-pool device but
it will exclusively manage/create thin and thin snapshot volumes in it.

Docker will not take ownership of the specified thin-pool device unless
it has 0 data blocks used and a transaction id of 0.  This should help
guard against using a thin-pool that is already in use.

Also fix typos in setupBaseImage() relative to the thin volume type of
the base image.

Docker-DCO-1.1-Signed-off-by: Mike Snitzer <snitzer@redhat.com> (github: snitm)
devmapper: disable discards by default if dm.thinpooldev was specified

User may still enable discards by setting dm.blkdiscard=true

Docker-DCO-1.1-Signed-off-by: Mike Snitzer <snitzer@redhat.com> (github: snitm)
Allow for custom debootstrap wrappers like qemu-debootstrap in contrib/mkimage/debootstrap

Signed-off-by: Andrew Page <admwiggin@gmail.com>
overlayfs: more helpful output when not supported

based on https://github.com/docker/docker/pull/7619#discussion_r20385086

Signed-off-by: Vincent Batts <vbatts@hashbangbash.com>
overlayfs: add --storage-driver doc

Signed-off-by: Vincent Batts <vbatts@redhat.com>
Fix for #8777

Now filter name is trimmed and lowercased before evaluation for case
insensitive and whitespace trimemd check.

Signed-off-by: Oh Jinkyun <tintypemolly@gmail.com>
Allow developers to build docker with debuginfo included

If you execute

DEBUG=-g hack/make.sh dynbinary

Docker will be build with the debug info making it easier to use
cgdb or lightide to debug.

Docker-DCO-1.1-Signed-off-by: Dan Walsh <dwalsh@redhat.com> (github: rhatdan)
events filtering

Signed-off-by: Victor Vieux <vieux@docker.com>
docs nits

Signed-off-by: Victor Vieux <vieux@docker.com>
Use termios via CGO

Signed-off-by: Yohei Ueda <yohei@jp.ibm.com>
build: add pull flag to force image pulling

Signed-off-by: Cristian Staretu <cristian.staretu@gmail.com>
pkg/devicemapper: clarify TaskCreate and createTask

* Rename and expose createTask() to TaskCreateNamed()
* add comments

Signed-off-by: Vincent Batts <vbatts@redhat.com>
Merge pull request #9188 from somaopensource/8777-fix

Fix for #8777 (continuing PR #9061)
Cleanup exec API docs and available params

Adds pertitent information about what is expected in the json payload
and comments out unsupported (exec) features in runConfig.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
devmapper: remove unnecessary else branch in getPoolName()

Docker-DCO-1.1-Signed-off-by: Mike Snitzer <snitzer@redhat.com> (github: snitm)
Merge pull request #9223 from vbatts/vbatts-overlay_notfound

overlayfs: more helpful output when not supported
Add missing unit testcase for new IsSet() func in mflag

Forgot to add this when I did PR #9259

Signed-off-by: Doug Davis <dug@us.ibm.com>
zsh: correctly parse available subcommands

A lot of flags have been added on the output of `docker help`. Use a
more robust method to extract the list of available subcommands by
spotting the `Command:` line and the next blank line.

Signed-off-by: Vincent Bernat <vincent@bernat.im>
Fixed typo in documentation.