an [abandoned] attempt to slice out the docker/docker/pkg package
Find a file
Alexander Larsson 83de20deb7 libcontainer: Use pivot_root instead of chroot
Instead of keeping all the old mounts in the container namespace and
just using subtree as root we pivot_root so that the actual root in
the namespace is the root we want, and then we unmount the previous
mounts.

This has multiple advantages:

* The namespace mount tree is smaller (in the kernel)
* If you break out of the chroot you could previously access the host
  filesystem. Now the host filesystem is fully invisible to the namespace.
* We get rid of all unrelated mounts from the parent namespace, which means
  we don't hog these. This is important if we later switch to MS_PRIVATE instead
  of MS_SLAVE as otherwise these mounts would be impossible to unmount from the
  parent namespace.

Docker-DCO-1.1-Signed-off-by: Alexander Larsson <alexl@redhat.com> (github: alexlarsson)
2014-03-04 12:44:08 +01:00
cgroups Fix cgroups swap issue when it is not supported 2014-02-25 19:45:57 -08:00
collections Remove std sort and use custom sort for performances 2014-01-26 14:01:38 -08:00
graphdb runtime: Fix unique constraint error checks 2014-03-03 15:10:52 +01:00
iptables iptables: use dest_addr and dest_port for public port FORWARD rule 2014-02-04 11:32:50 -06:00
libcontainer libcontainer: Use pivot_root instead of chroot 2014-03-04 12:44:08 +01:00
listenbuffer Change name to listenbuffer 2014-02-15 21:10:37 -08:00
mflag add warning for deprecatd flags 2014-03-03 19:57:05 +00:00
mount Merge pull request #3841 from alexlarsson/separate-base-fs 2014-01-31 11:49:14 -08:00
namesgenerator Fix misspelled Hawkings -> Hawking, Archimede -> Archimedes, Euclide -> Euclid 2014-01-09 10:02:55 -05:00
netlink Merge pull request #4011 from crosbymichael/add-netlink-functions 2014-02-18 19:37:52 -05:00
opts pkg/opts: a collection of custom value parsers implementing flag.Value 2014-02-11 19:59:52 -08:00
proxy Remove verbose logging for non errors 2014-02-17 13:31:13 -08:00
sysinfo remove ip_forward warning 2014-01-28 13:27:56 -06:00
system Fix cross compile for make cross 2014-02-25 15:19:13 -08:00
systemd pkg: systemd: add initial MAINTAINERS 2014-02-06 12:04:35 -08:00
term Move utility package 'term' to pkg/term 2013-12-23 23:42:37 +00:00
user Use type switch instead of reflection 2014-01-31 20:15:24 -07:00
version add version pkg 2014-02-25 21:08:38 +00:00
README.md Add README to pkg 2013-12-23 23:12:19 +00:00

pkg/ is a collection of utility packages used by the Docker project without being specific to its internals.

Utility packages are kept separate from the docker core codebase to keep it as small and concise as possible. If some utilities grow larger and their APIs stabilize, they may be moved to their own repository under the Docker organization, to facilitate re-use by other projects. However that is not the priority.

The directory pkg is named after the same directory in the camlistore project. Since Brad is a core Go maintainer, we thought it made sense to copy his methods for organizing Go code :) Thanks Brad!

Because utility packages are small and neatly separated from the rest of the codebase, they are a good place to start for aspiring maintainers and contributors. Get in touch if you want to help maintain them!