0f43c3eb05
Refactor utility MkBuildContext to the more generic archive.Generate
...
This facilitates refactoring commands.go.
Docker-DCO-1.1-Signed-off-by: Solomon Hykes <solomon@docker.com > (github: shykes)
Upstream-commit: 9b56da78e0b1e4e1da9b2bacc44a22143745a2b0
Component: engine
2014-02-15 14:52:08 -08:00
e12f62e6df
Properly close archives
...
All archive that are created from somewhere generally have to be closed, because
at some point there is a file or a pipe or something that backs them. So, we
make archive.Archive a ReadCloser. However, code consuming archives does not
typically close them so we add an archive.ArchiveReader and use that when we're
only reading.
We then change all the Tar/Archive places to create ReadClosers, and to properly
close them everywhere.
As an added bonus we can use ReadCloserWrapper rather than EofReader in several places,
which is good as EofReader doesn't always work right. For instance, many compression
schemes like gzip knows it is EOF before having read the EOF from the stream, so the
EofCloser never sees an EOF.
Docker-DCO-1.1-Signed-off-by: Alexander Larsson <alexl@redhat.com > (github: alexlarsson)
Upstream-commit: f198ee525ad6862dce3940e08c72e0a092380a7b
Component: engine
2014-02-14 13:46:17 +01:00
972ffb5ee2
Merge pull request #4073 from crosbymichael/fix-docker-cp-close
...
Ensure docker cp stream is closed properly
Upstream-commit: c6edac9a1a33835e7ab0ea3173877f9731ec45a5
Component: engine
2014-02-13 14:12:53 +02:00
e378922981
Move the canonical run configuration objects to a sub-package
...
* Config is now runconfig.Config
* HostConfig is now runconfig.HostConfig
* MergeConfig is now runconfig.Merge
* CompareConfig is now runconfig.Compare
* ParseRun is now runconfig.Parse
* ContainerConfigFromJob is now runconfig.ContainerConfigFromJob
* ContainerHostConfigFromJob is now runconfig.ContainerHostConfigFromJob
This facilitates refactoring commands.go and shrinks the core.
Docker-DCO-1.1-Signed-off-by: Solomon Hykes <solomon@docker.com > (github: shykes)
Upstream-commit: 6393c38339e11b4a099a460ecf46bb5cafc4283b
Component: engine
2014-02-11 20:18:46 -08:00
9ed97b673b
Move even more stuff into dockerversion
...
Also, use it in all the places. :)
Docker-DCO-1.1-Signed-off-by: Andrew Page <admwiggin@gmail.com > (github: tianon)
Upstream-commit: da04f49b383c02ee28c32f948048b9e9a402bb4f
Component: engine
2014-02-11 17:26:54 -07:00
a0e7d3fc71
Ensure docker cp stream is closes properly
...
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com > (github: crosbymichael)
Upstream-commit: 35821ad78f4ad2b20cf839ecc5a73b44c568c5eb
Component: engine
2014-02-11 06:21:53 -08:00
02fa3704fe
Do not ping registry from the cli
...
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com > (github: crosbymichael)
Upstream-commit: e2eace9715253b5254d1596f3ee91e2f61127929
Component: engine
2014-02-05 16:49:43 -08:00
386288ab8c
Fix comparing binds and volume ids from other containers
...
Currently comparing volume ids for binds and other containers are broken
Fixes #3749
Fixes #3885
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com > (github: crosbymichael)
Upstream-commit: 720c5774e9a9cd510320a142848832f7cd314da7
Component: engine
2014-02-03 13:18:10 -08:00
47dc263009
Merge pull request #3872 from crosbymichael/network-driver
...
Remove networking out of core and into a driver
Upstream-commit: 819c2e3ecaaa1f82401fe76bae1715183426c3cf
Component: engine
2014-01-31 17:22:37 -08:00
140db53b4e
Move serveapi to api/api.go
...
Remove api import from server.go
Rename initapi to init server
Docker-DCO-1.1-Signed-off-by: Victor Vieux <victor.vieux@docker.com > (github: vieux)
Upstream-commit: 9eea7f28f0c64d43ef2a9987999a29774fa1476b
Component: engine
2014-01-31 23:06:00 +00:00
0b250038dd
Update core calls to network drivers
...
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com > (github: crosbymichael)
Upstream-commit: c712e74b45005e0f38297d254fb606aa18606d11
Component: engine
2014-01-31 12:04:44 -08:00
32d36c4ba5
merge master
...
Docker-DCO-1.1-Signed-off-by: Victor Vieux <victor.vieux@docker.com > (github: vieux)
Upstream-commit: b881a6c3c2e73f2fd342975239331004f0b59e12
Component: engine
2014-01-31 19:00:06 +00:00
236fdd833b
merge master
...
Docker-DCO-1.1-Signed-off-by: Victor Vieux <victor.vieux@docker.com > (github: vieux)
Upstream-commit: 51d280f944eab386ecd67acd6a1878de7b45c8d6
Component: engine
2014-01-31 18:43:34 +00:00
4ca789745b
Merge pull request #3829 from vieux/fix_api_regression
...
Fix ID -> Id api
Upstream-commit: 643c7dc25df4759c1894ba2ff3aa71fe11a06ea4
Component: engine
2014-01-31 10:38:57 -08:00
9365dcaac9
add setSubEnv and getSubEnv
...
Docker-DCO-1.1-Signed-off-by: Victor Vieux <victor.vieux@docker.com > (github: vieux)
Upstream-commit: 8fbdb7b59eba078bf24546686e005cc86a60e493
Component: engine
2014-01-31 04:01:46 +00:00
b237b19a08
job.error\* now return engine.StatusErr
...
Docker-DCO-1.1-Signed-off-by: Victor Vieux <victor.vieux@docker.com > (github: vieux)
Upstream-commit: 24086fa75dff1ebb56dfb8fbf2c80fdfd5be0e8a
Component: engine
2014-01-31 04:01:46 +00:00
f6edb78234
use exists
...
Docker-DCO-1.1-Signed-off-by: Victor Vieux <victor.vieux@docker.com > (github: vieux)
Upstream-commit: 1498cd4e0540c73546a4847948f7d6a75b596178
Component: engine
2014-01-31 02:21:59 +00:00
c57257cc3c
changed default value of getenvint to 0. fix tests
...
Docker-DCO-1.1-Signed-off-by: Victor Vieux <victor.vieux@docker.com > (github: vieux)
Upstream-commit: 28b5ae8cc4492f7b3cc2eb2b30b0f41713822b25
Component: engine
2014-01-31 02:06:08 +00:00
d1401083fb
remove TestAllocateTCPPortLocalhost faillure in tests
...
Docker-DCO-1.1-Signed-off-by: Victor Vieux <victor.vieux@docker.com > (github: vieux)
Upstream-commit: 8e619e13ca3906e849944a4b015b676b93c9f145
Component: engine
2014-01-30 21:53:32 +00:00
deac379ef5
refactor all *FromJob functions
...
Docker-DCO-1.1-Signed-off-by: Victor Vieux <victor.vieux@docker.com > (github: vieux)
Upstream-commit: 9261511aa509423432f4e22f6235719deadc0969
Component: engine
2014-01-30 20:45:32 +00:00
c7071fbcda
fix convertion issues
...
Docker-DCO-1.1-Signed-off-by: Victor Vieux <victor.vieux@docker.com > (github: vieux)
Upstream-commit: 187646127fa80a5ba39a53619b410eb2a13f0ffd
Component: engine
2014-01-30 00:56:42 +00:00
af8535454e
fix ID -> Id api
...
Docker-DCO-1.1-Signed-off-by: Victor Vieux <victor.vieux@docker.com > (github: vieux)
Upstream-commit: 54072dbbd6260a9d8a7249cae0bd17513f15c3fc
Component: engine
2014-01-29 20:31:49 +00:00
3fc86028ff
move api to it's own package
...
Docker-DCO-1.1-Signed-off-by: Victor Vieux <victor.vieux@docker.com > (github: vieux)
Upstream-commit: f556cd4186dfdb5e96b2e58b5caf9edbe7e2d7df
Component: engine
2014-01-29 19:26:54 +00:00
3f744f45d9
add setSubEnv and getSubEnv
...
Docker-DCO-1.1-Signed-off-by: Victor Vieux <victor.vieux@docker.com > (github: vieux)
Upstream-commit: 7b7f7e443637d8303f03316ee437012b71936c12
Component: engine
2014-01-29 18:53:43 +00:00
edaa89a4ad
job.error\* now return engine.StatusErr
...
Docker-DCO-1.1-Signed-off-by: Victor Vieux <victor.vieux@docker.com > (github: vieux)
Upstream-commit: 55d7aa1b49a49a27d77cd4011d921e340ec99f9f
Component: engine
2014-01-29 18:52:55 +00:00
87c7be2925
Merge pull request #3808 from alexlarsson/execdriver-get-pids-for-container
...
execdriver: Make GetPidsForContainer() a driver call
Upstream-commit: c00cb1aca15c4dea4198c4e488a986fa6ad9636c
Component: engine
2014-01-29 10:38:10 -08:00
2a8b1349cd
move warnings to the job
...
Docker-DCO-1.1-Signed-off-by: Victor Vieux <victor.vieux@docker.com > (github: vieux)
Upstream-commit: abd64a2b00a57dda2f24326fc49b7ca10e950dff
Component: engine
2014-01-29 01:17:55 +00:00
4f8cce969a
remove enableCors from the config and move it as a job arg
...
Docker-DCO-1.1-Signed-off-by: Victor Vieux <victor.vieux@docker.com > (github: vieux)
Upstream-commit: d41844ed2d946fc963f9977991233b5d9daf86fd
Component: engine
2014-01-29 00:20:51 +00:00
61ba43da9f
Merge pull request #3105 from philips/add-socket-activation
...
Add socket activation
Upstream-commit: 2723133a69a292abaa021afff98de127bda57b4e
Component: engine
2014-01-28 11:38:25 -08:00
4729a480ab
execdriver: Make GetPidsForContainer() a driver call
...
The current implementation is lxc specific.
Docker-DCO-1.1-Signed-off-by: Alexander Larsson <alexl@redhat.com > (github: alexlarsson)
Upstream-commit: 335bc39c9a5abfdbd07914ae1b8667a9d8590a6e
Component: engine
2014-01-28 16:21:49 +01:00
b941fc82f6
Fix unclear error message when deleting container
...
I was getting the following error:
```
$ bundles/0.7.6-dev/binary/docker-0.7.6-dev run -rm -v=/var/run:/foo base echo hi
hi
2014/01/28 14:24:46 Error: container_delete: No such id: run
```
This commit makes the true origin of the error clearer. Issue #3806 is
tracking the cause of the error.
Docker-DCO-1.1-Signed-off-by: Peter Waller <p@pwaller.net > (github: pwaller)
Upstream-commit: 70c1781e073287a0b012ce94ea1b233fd6628dfa
Component: engine
2014-01-28 14:28:13 +00:00
b82cbc2144
chore(*): go fmt
...
I noticed that travis was failing, go fmt to make it happy.
Docker-DCO-1.1-Signed-off-by: Brandon Philips <brandon.philips@coreos.com > (github: philips)
Upstream-commit: 1603039a7150e0510853efc9a9733ef64508dbb0
Component: engine
2014-01-27 17:18:09 -08:00
843c8c74fb
Move listenfd to utility package
...
Docker-DCO-1.1-Signed-off-by: Brandon Philips <brandon.philips@coreos.com > (github: philips)
Upstream-commit: 566fb31c889cfa05c617f44e6c99d44578d643a5
Component: engine
2014-01-27 17:18:09 -08:00
93246312a1
server: add socket activation
...
This adds the ability to socket activate docker by passing in
`-H fd://*` along with examples systemd configuration files.
The fastest way to test this is to run:
```
/usr/lib/systemd/systemd-activate -l 127.0.0.1:2001 /usr/bin/docker -d -H 'fd://*'
docker -H tcp://127.0.0.1:2001 ps
```
Docker-DCO-1.1-Signed-off-by: Brandon Philips <brandon.philips@coreos.com > (github: philips)
Upstream-commit: 87fb2c973d8f9a8a1868ab0c2da504095d04715b
Component: engine
2014-01-27 17:17:07 -08:00
e2920619d5
Release the push lock at the end
...
Docker-DCO-1.1-Signed-off-by: Abel Muiño <amuino@gmail.com > (github: amuino)
Upstream-commit: 77a34920b24901da82f9e22138ef21ffc665d678
Component: engine
2014-01-27 16:22:59 +01:00
70553c6361
move auth to a job
...
Docker-DCO-1.1-Signed-off-by: Victor Vieux <victor.vieux@docker.com > (github: vieux)
Upstream-commit: 1f8b1bb84e65cfd84f938eb01e1a48c33fce5a27
Component: engine
2014-01-24 16:51:02 -08:00
b7a9dba025
Move containers to a job
...
Docker-DCO-1.1-Signed-off-by: Victor Vieux <victor.vieux@docker.com > (github: vieux)
Upstream-commit: 5ea2986ce5cfce1b86fdc92610dbc6d670691168
Component: engine
2014-01-24 16:07:42 -08:00
29cb397f3d
push job
...
Docker-DCO-1.1-Signed-off-by: Victor Vieux <victor.vieux@docker.com > (github: vieux)
Upstream-commit: e8ee18fa2993bd47069ba582889b0c83a68f3d43
Component: engine
2014-01-24 15:34:08 -08:00
043779a4ab
move events to job
...
Docker-DCO-1.1-Signed-off-by: Victor Vieux <victor.vieux@docker.com > (github: vieux)
Upstream-commit: 5cc6312bfc4e511784693d02b9bb8e8d9d1c04b0
Component: engine
2014-01-24 15:28:17 -08:00
650f0e4bf5
merge 2 jobs, no more buffer
...
Docker-DCO-1.1-Signed-off-by: Victor Vieux <victor.vieux@docker.com > (github: vieux)
Upstream-commit: 5fd8aa02bae6602bfe6bff541be1e1dc5c1e0fb8
Component: engine
2014-01-24 15:13:30 -08:00
f3fc21caa0
update attach to use the new job
...
Docker-DCO-1.1-Signed-off-by: Victor Vieux <victor.vieux@docker.com > (github: vieux)
Upstream-commit: a7e9baaf89ae86dba4f93fb76a436e4c86249e4c
Component: engine
2014-01-24 15:11:38 -08:00
760e8be989
move inspect to 2 jobs
...
Docker-DCO-1.1-Signed-off-by: Victor Vieux <victor.vieux@docker.com > (github: vieux)
Upstream-commit: 134435a79c06bd178aa6f687fcabeb2caced485a
Component: engine
2014-01-24 15:11:38 -08:00
0c66a1deba
remove buffer
...
Docker-DCO-1.1-Signed-off-by: Victor Vieux <victor.vieux@docker.com > (github: vieux)
Upstream-commit: 177f6588824de5a489f0b31a2cf053c3cdf0bb0e
Component: engine
2014-01-24 14:57:18 -08:00
4dfa12a504
Move docker rmi to a job
...
Docker-DCO-1.1-Signed-off-by: Victor Vieux <victor.vieux@docker.com > (github: vieux)
Upstream-commit: 564e6bc7802b606d829a498eee0c2bb8ce4032e1
Component: engine
2014-01-24 14:55:11 -08:00
336aee840a
remove useless flush method
...
Docker-DCO-1.1-Signed-off-by: Victor Vieux <victor.vieux@docker.com > (github: vieux)
Upstream-commit: 35641f0ec7ecae16f88ba9affe0aeea0ae864874
Component: engine
2014-01-24 14:46:31 -08:00
0b480b0b5d
fix flush
...
Docker-DCO-1.1-Signed-off-by: Victor Vieux <victor.vieux@docker.com > (github: vieux)
Upstream-commit: 90e9a2d85a6c981b137df0c22c31d6f32f4b6f66
Component: engine
2014-01-24 14:46:31 -08:00
10c689f549
move pull and import to a job
...
Docker-DCO-1.1-Signed-off-by: Victor Vieux <victor.vieux@docker.com > (github: vieux)
Upstream-commit: 9dcbdbc4b1addb67c0fdcadab1c8f98f30e58b4c
Component: engine
2014-01-24 14:46:31 -08:00
2491610f84
move build to a job
...
Docker-DCO-1.1-Signed-off-by: Victor Vieux <victor.vieux@docker.com > (github: vieux)
Upstream-commit: 415379e45dadb32385771ceae701d8b9f204f2b8
Component: engine
2014-01-23 16:08:05 -08:00
04f201ccfb
Add a --signal option to the kill command to specify a signal.
...
Docker-DCO-1.1-Signed-off-by: Paul Lietar <paul@lietar.net > (github: plietar)
Upstream-commit: 1f75a0bf435fe9a0f118b027e0387ba41e201c66
Component: engine
2014-01-22 06:10:52 +00:00
354af1c70c
Merge branch 'add_missing_attributes' of https://github.com/rogaha/docker into rogaha-add_missing_attributes
...
Conflicts:
api.go
Docker-DCO-1.1-Signed-off-by: Victor Vieux <victor.vieux@docker.com > (github: vieux)
Upstream-commit: 4c1879f919689cd884848f3c2269df942a5788cf
Component: engine
2014-01-21 18:01:19 -08:00