Commit Graph

953 Commits

Author SHA1 Message Date
dbb2daa29d Merge pull request #10197 from vbatts/vbatts-dm_cookie_support
devicemapper: API for cookie support
Upstream-commit: c81fb7fa4a41dfdc21eb37dade0eb71bd1dfa855
Component: engine
2015-01-27 11:44:03 -08:00
c4558ad58c Merge pull request #10305 from jlhawn/use_tarsum_v1
Always store images with tarsum.v1 checksum added
Upstream-commit: bfa0dc47da2d9e6399fa32bda72a7074224c815d
Component: engine
2015-01-26 14:42:07 -08:00
299d22c2cc pkg/archive: remove tar autodetection log line
Signed-off-by: Cristian Staretu <cristian.staretu@gmail.com>
Upstream-commit: a5cc1c556dcd6dfe5c1aed4bec95aaff6ddfad61
Component: engine
2015-01-24 08:43:03 +02:00
cc58d5c62d Always store images with tarsum.v1 checksum added
Updates `image.StoreImage()` to always ensure that images
that are installed in Docker have a tarsum.v1 checksum.

Docker-DCO-1.1-Signed-off-by: Josh Hawn <josh.hawn@docker.com> (github: jlhawn)
Upstream-commit: ba3bad66f92da057dba2a43ff9a512cf7ad72375
Component: engine
2015-01-23 11:30:27 -08:00
ce792ad046 Not doing extra assertion for io.Closer
Signed-off-by: Ian Babrou <ibobrik@gmail.com>
Upstream-commit: 4d10b32380793ce5e324a429ce2db60125aae205
Component: engine
2015-01-22 10:36:20 +03:00
dcea23baf1 Merge pull request #10231 from estesp/move-iptables-check
Move iptables check out of runtime init() to separate function
Upstream-commit: f3aed2a2974bba4fdca947227d877bcc2c7d540b
Component: engine
2015-01-21 10:46:40 -08:00
b793c28c03 Remove publisher if no one is listening
Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
Upstream-commit: 217a2bd1b62788e53fd38810b30672db58a4efc5
Component: engine
2015-01-20 20:21:47 -08:00
045cd9fe99 Add pubsub package to handle robust publisher
Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
Upstream-commit: 2f46b7601a3f5e11359b79624d73075b69778fbb
Component: engine
2015-01-20 20:21:46 -08:00
42697702c5 Move iptables check out of runtime init() to separate function
Due to the iptables package being `init`ed at start of the docker
runtime, this means the iptables --wait command listing all rules
is run, no matter if the command is simply "docker -h".  It makes
more sense to both locate the iptables command and check for the
wait flag support at the time iptables is actually used, as it
may not be used at all if certain network support is off/configured
differently.

Docker-DCO-1.1-Signed-off-by: Phil Estes <estesp@linux.vnet.ibm.com> (github: estesp)
Upstream-commit: 5e8285b08120f674b12a34c3f146216f6854a173
Component: engine
2015-01-20 21:04:22 -05:00
f11f701e04 Merge pull request #10222 from vbatts/vbatts-dm_flag_and_output
dm flag and output
Upstream-commit: 9b2afa04f8ab491d56614835de09eb0880250309
Component: engine
2015-01-20 18:45:43 -05:00
ca9b7e2a12 Merge pull request #10193 from vbatts/vbatts-dm_logging
devmapper: initialize log levels
Upstream-commit: fa7af79885f43bdbd0d13b6c8e1bdbab7b2cc722
Component: engine
2015-01-20 14:06:01 -05:00
3757727dfa devicemapper: define device-mapper log levels
Signed-off-by: Vincent Batts <vbatts@redhat.com>
Upstream-commit: a687e8d86ba07ebb42d988b6e13102569b60e673
Component: engine
2015-01-20 13:31:12 -05:00
dbf7d610b8 Merge pull request #10005 from estesp/fix-localhost-nameserver-cleanup
Clean up localhost resolv logic and add IPv6 support to regexp
Upstream-commit: e9d3e237e5cffef0dfcd4949c31959cd25863f3f
Component: engine
2015-01-20 10:30:06 -08:00
b85d65e0eb devicemapper: API for checking cookie support
Signed-off-by: Vincent Batts <vbatts@redhat.com>
Upstream-commit: cb81ed34a52420528281ccaa99e16c472f4f533a
Component: engine
2015-01-19 20:35:20 -05:00
5e93ebec1e Clean up localhost resolv logic and add IPv6 support to regexp
Addresses #5811

This cleans up an error in the logic which removes localhost resolvers
from the host resolv.conf at container creation start time. Specifically
when the determination is made if any nameservers are left after
removing localhost resolvers, it was using a string match on the word
"nameserver", which could have been anywhere (including commented out)
leading to incorrect situations where no nameservers were left but the
default ones were not added.

This also adds some complexity to the regular expressions for finding
nameservers in general, as well as matching on localhost resolvers due
to the recent addition of IPv6 support.  Because of IPv6 support now
available in the Docker daemon, the resolvconf code is now aware of
IPv6 enable/disable state and uses that for both filter/cleaning of
nameservers as well as adding default Google DNS (IPv4 only vs. IPv4
and IPv6 if IPv6 enabled).  For all these changes, tests have been
added/strengthened to test these additional capabilities.

Docker-DCO-1.1-Signed-off-by: Phil Estes <estesp@linux.vnet.ibm.com> (github: estesp)
Upstream-commit: 93d51e5e971e001d80e9ffa863439f2d72215b5a
Component: engine
2015-01-19 19:35:55 -05:00
279519e07d devicemapper: debug output specifics
moar information for the information gods

Signed-off-by: Vincent Batts <vbatts@redhat.com>
Upstream-commit: 4cfe9df0a9c206c368a90f460fea8fab197265d9
Component: engine
2015-01-19 17:21:10 -05:00
2622e003cc devicemapper: define the fallback flag
DM_UDEV_DISABLE_LIBRARY_FALLBACK is disabled by most applications today
when using device-mapper, and ensuring that device-mapper is in sync
with udev. This flag instructs devicemapper to not fallback to creating
the device nodes itself. In the case of udev sync not being supported,
devicemapper will attempt to create the devices in a timely manner,
regardless of udev.

Signed-off-by: Vincent Batts <vbatts@redhat.com>
Upstream-commit: dbb642b7fbdf42d3b401d610403ba58ebbde38d7
Component: engine
2015-01-19 17:06:53 -05:00
b3b9656da1 devicemapper: dm_udev_get_sync_support
expose an api to call dm_udev_get_sync_support/dm_udev_set_sync_support

Signed-off-by: Vincent Batts <vbatts@redhat.com>
Upstream-commit: 9c3380039e15f11fc07741edd4cbc0c7e5c490aa
Component: engine
2015-01-19 15:15:51 -05:00
c13d2851b8 Add Tarsum Calculation during v2 Pull operation
While the v2 pull operation is writing the body of the layer blob to disk
it now computes the tarsum checksum of the archive before extracting it to
the backend storage driver. If the checksum does not match that from the
image manifest an error is raised.

Also adds more debug logging to the pull operation and fixes existing test
cases which were failing. Adds a reverse lookup constructor to the tarsum
package so that you can get a tarsum object using a checksum label.

Docker-DCO-1.1-Signed-off-by: Josh Hawn <josh.hawn@docker.com> (github: jlhawn)
Upstream-commit: 213e3d116642431adbe634d39740eddc5a81e063
Component: engine
2015-01-15 14:05:05 -08:00
dea4567bd2 correct the flag comments
Signed-off-by: Qiang Huang <h.huangqiang@huawei.com>
Upstream-commit: 00bd7b4c414061d71d7f94b5850cbe132da623f0
Component: engine
2015-01-13 15:40:24 +08:00
6a864dec5f Merge pull request #10029 from soulshake/add-cecilia-payne-gaposchkin
Add Cecilia Payne-Gaposchkin to names generator.
Upstream-commit: 9b0072a7e63f560614fb9ba1b454b444cf4fe13e
Component: engine
2015-01-12 17:31:19 -08:00
aa2236d495 Add Cecilia Payne-Gaposchkin to the names generator.
Signed-off-by: AJ Bowen <aj@gandi.net>
Upstream-commit: 41178adb7e4e3df27c99c462b069dc9c196af2c3
Component: engine
2015-01-12 16:24:15 -08:00
502d87f39d fix issue with goimport
Signed-off-by: Victor Vieux <vieux@docker.com>
Upstream-commit: b70632ec532d4a948e227a646f8286d7c439cb4f
Component: engine
2015-01-12 22:52:19 +00:00
8015360eaf update copyrights to 2015
Signed-off-by: Victor Vieux <vieux@docker.com>
Upstream-commit: e5869b2b0bdf85d15813c714565fd49943c3d754
Component: engine
2015-01-12 22:47:36 +00:00
e142c94642 Add Laura Poitras to the names generator.
http://www.wired.com/2014/10/laura-poitras-crypto-tools-made-snowden-film-possible/

Signed-off-by: AJ Bowen <aj@gandi.net>
Upstream-commit: 883d1415355244b2a2710d0860e5019bc697839b
Component: engine
2015-01-12 09:35:12 -08:00
78ad19e428 Add Aaron Swartz to the names generator.
https://en.wikiquote.org/wiki/Aaron_Swartz

Docker-DCO-1.1-Signed-off-by: Jessica Frazelle <jess@docker.com> (github: jfrazelle)
Upstream-commit: 5b8c8b1819d0f2dcbe7d708b1ae8f579a73401bd
Component: engine
2015-01-09 22:25:53 -08:00
8404235dd8 Merge pull request #9648 from estesp/9202-update-resolvconf
Update container resolv.conf when host network changes /etc/resolv.conf
Upstream-commit: 92af1f014520b4f75a6220478b01ed6a02ca5bfb
Component: engine
2015-01-08 14:06:55 -08:00
ae1406d798 Update container resolv.conf when host network changes /etc/resolv.conf
Only modifies non-running containers resolv.conf bind mount, and only if
the container has an unmodified resolv.conf compared to its contents at
container start time (so we don't overwrite manual/automated changes
within the container runtime). For containers which are running when
the host resolv.conf changes, the update will only be applied to the
container version of resolv.conf when the container is "bounced" down
and back up (e.g. stop/start or restart)

Docker-DCO-1.1-Signed-off-by: Phil Estes <estesp@linux.vnet.ibm.com> (github: estesp)
Upstream-commit: 63a7ccdd2372d87f56f7a86da07c72ea51332c2a
Component: engine
2015-01-08 14:15:13 -05:00
b060268a74 Merge pull request #8748 from duglin/Issue8330
Have .dockerignore support Dockerfile/.dockerignore
Upstream-commit: 6d780139c4b7960b482a5f4fbf043adb6673864b
Component: engine
2015-01-06 13:47:42 -08:00
1a4a1b2193 Have .dockerignore support Dockerfile/.dockerignore
If .dockerignore mentions either then the client will send them to the
daemon but the daemon will erase them after the Dockerfile has been parsed
to simulate them never being sent in the first place.

an events test kept failing for me so I tried to fix that too

Closes #8330

Signed-off-by: Doug Davis <dug@us.ibm.com>
Upstream-commit: 6d801a3caa54ad7ef574bc426aa1ffc412c5af82
Component: engine
2015-01-06 10:57:48 -08:00
985e3e60ac Merge pull request #8941 from agonzalezro/log-duplicates
Log when truncindex.Get returns >1 container
Upstream-commit: 84dc197b087dc63280cdae50795a36434a84fa6f
Component: engine
2015-01-06 10:41:19 -08:00
319270793a Handle bad options better
* Do not log bad options error message twice, e.g.:

    $ docker run --pouet
    flag provided but not defined: --pouet
    See 'docker run --help'.
    2014/11/05 21:41:23 flag provided but not defined: --pouet

  With this patch just the first two lines will be produced.

* Print 'docker' just once when run without a command, e.g.:

    $ docker --hel
    flag provided but not defined: --hel
    See 'docker docker --help'.

Signed-off-by: Michal Minar <miminar@redhat.com>
Upstream-commit: 1d09fc22ca14b0b83bdc81cba06d3d7ac886a3e6
Component: engine
2015-01-06 13:44:27 +01:00
639170852f refactor redundant code around calls to cmd.Parse
Signed-off-by: Tibor Vass <teabee89@gmail.com>
Upstream-commit: 41be2f73c7ce2cbb5450ee8bb35bf7235125ca63
Component: engine
2015-01-06 13:41:16 +01:00
bb1bfae794 Remove TestUsage, since Usage will no longer be shown on failure to parse
Docker-DCO-1.1-Signed-off-by: Dan Walsh <dwalsh@redhat.com> (github: rhatdan)
Upstream-commit: 4dc962d09a05b5422c692f4762a32c24cb506e6b
Component: engine
2015-01-06 13:40:14 +01:00
f82eddabc6 --help option and help command should print to stdout not stderr
--help and help are successful commands so output should not go to error.

    QE teams have requested this change, also users doing docker help | less
    or docker run --help | less would expect this to work.

    Usage statement should only be printed when the user asks for it.
    Errors should print error message and then suggest the docker COMMAND --help
    command to see usage information.

    The current behaviour causes the user to have to search for the error message
    and sometimes scrolls right off the screen.  For example a error on a
    "docker run" command is very difficult to diagnose.

    Finally erros should always exit with a non 0 exit code, if the user
    makes a CLI error.

Docker-DCO-1.1-Signed-off-by: Dan Walsh <dwalsh@redhat.com> (github: rhatdan)
Upstream-commit: a2b529ead21e6ab9eafcb1b1d2437c725c43a06a
Component: engine
2015-01-06 13:40:14 +01:00
986d8f11d2 add ability to publish range of ports
Closes #8899
Signed-off-by: Srini Brahmaroutu <srbrahma@us.ibm.com>
Upstream-commit: 2338a9cf5a1ba5576b92e49065335a9c9251ade0
Component: engine
2015-01-02 23:21:26 +00:00
7ce3e89154 Add descriptions for bell, lumiere, morse, nobel, ptolemy, and wright
Signed-off-by: Andrew "Tianon" Page <admwiggin@gmail.com>
Upstream-commit: 587286bbaafa604078b4d72643c6a855a33e5aa1
Component: engine
2014-12-26 16:53:40 -07:00
4b22c19880 Switch names-generator arrays to be long-form
This way, we can embed the link/description lines directly in the array itself, conflicts between PRs to this section are minimized, new PRs are easier to review, and it's a lot easier to notice when people are missing a link/description (like the few that currently are).

Signed-off-by: Andrew "Tianon" Page <admwiggin@gmail.com>
Upstream-commit: ed21031353ee188e2837a3030b3fbda88e1ce614
Component: engine
2014-12-26 16:44:47 -07:00
13e3da74e0 Merge pull request #9813 from nurkiewicz/banach
Stefan Banach in names-generator
Upstream-commit: b98c352e4f7ada1a381746c8fff4feed959881d9
Component: engine
2014-12-26 09:37:16 -08:00
d937286ca7 Fix names-generator comment about name generation
Signed-off-by: Ankush Agarwal <ankushagarwal11@gmail.com>
Upstream-commit: 6df1eff85e5614dfc1b09e1ff5c4e9cadb0dde0f
Component: engine
2014-12-25 22:54:38 -08:00
40cc868918 Stefan Banach in names-generator
Signed-off-by: Tomasz Nurkiewicz <nurkiewicz@gmail.com>
Upstream-commit: 6e96dcec3c524dc05b7d72aa0aab4fd734c03a7d
Component: engine
2014-12-26 00:06:56 +01:00
4b105a7583 Create tests for pkg/iptables
Docker-DCO-1.1-Signed-off-by: Ian Bishop <ianbishop@pace7.com> (github: porjo)
Upstream-commit: 0da92633b4161ed1f8babe5ec4a9fe98257d34b5
Component: engine
2014-12-21 12:57:32 +10:00
ae55b92633 Create DOCKER forward chain on driver init
Docker-DCO-1.1-Signed-off-by: Ian Bishop <ianbishop@pace7.com> (github: porjo)
Upstream-commit: 2865373894f1532fa725481e8f04db4a5d7a0aa8
Component: engine
2014-12-21 12:57:32 +10:00
c720d69487 Move per-container forward rules to DOCKER chain
Docker-DCO-1.1-Signed-off-by: Ian Bishop <ianbishop@pace7.com> (github: porjo)
Upstream-commit: cc89b30d35edc02fc598a0b26fe7a1ed002238e4
Component: engine
2014-12-21 12:57:32 +10:00
913aff3176 pkg/units: fix size_test.go compilation
Signed-off-by: Cristian Staretu <cristian.staretu@gmail.com>
Upstream-commit: e59aad9cd387bf20dc0f4664afdd5c55b394cb5b
Component: engine
2014-12-19 18:38:12 +02:00
ad1b9f394b Merge pull request #9746 from unclejack/graphdb_fix
pkg/graphdb: use transactions for transactions
Upstream-commit: f7a449f92b88ca2a3db2fb33abade8c25a19c390
Component: engine
2014-12-19 11:11:59 -05:00
e2e02c60dd pkg/graphdb: use transactions for transactions
Signed-off-by: Cristian Staretu <cristian.staretu@gmail.com>
Upstream-commit: e9f37a011872fa89669dc105df27e1c6e16124b6
Component: engine
2014-12-19 13:57:21 +02:00
c7d1f45ca3 Merge pull request #9233 from inatatsu/fix-pkg-units-size-for-gccgo
Fix to avoid a compile error due to float to int truncation with GCCGO
Upstream-commit: 2acb856dff848bd69c5e971f6352854a26362164
Component: engine
2014-12-18 18:33:01 -08:00
5cdc9005f7 pkg/tarsum: delete the logging code
Signed-off-by: Cristian Staretu <cristian.staretu@gmail.com>
Upstream-commit: e7c0587d541cd9f224df622b2f97c918e68cfb05
Component: engine
2014-12-18 23:38:26 +02:00
9c05f0eaf9 Refactor to optimize storage driver ApplyDiff()
To avoid an expensive call to archive.ChangesDirs() which walks two directory
trees and compares every entry, archive.ApplyLayer() has been extended to
also return the size of the layer changes.

Docker-DCO-1.1-Signed-off-by: Josh Hawn <josh.hawn@docker.com> (github: jlhawn)
Upstream-commit: 35a22c9e12c05e2a0a205964702ced78ea39d7a1
Component: engine
2014-12-17 21:54:23 -08:00