Alexander Larsson
c138801073
Container: Inject into the mount, not the rwPath
...
For device-mapper setups we can't just push the file into the rwPath.
2013-09-30 17:35:01 -06:00
Alexander Larsson
b0626f403b
Implement container.ExportRW() on device-mapper
2013-09-30 17:34:59 -06:00
Alexander Larsson
fda6ff9c27
Make TarFilter more useful
...
There are a few changes:
* Callers can specify if they want recursive behaviour or not
* All file listings to tar are sent on stdin, to handle long lists better
* We can pass in a list of filenames which will be created as empty
files in the tarball
This is exactly what we want for the creation of layer tarballs given
a container fs, a set of files to add and a set of whiteout files to create.
2013-09-30 17:34:59 -06:00
Alexander Larsson
1c5dc26a7c
Implement docker diff for device-mapper
...
To do diffing we just compare file metadata, so this relies
on things like size and mtime/ctime to catch any changes.
Its *possible* to trick this by updating a file without
changing the size and setting back the mtime/ctime, but
that seems pretty unlikely to happen in reality, and lets
us avoid comparing the actual file data.
2013-09-30 17:34:59 -06:00
Alexander Larsson
a9ec1dbc9b
Image: Deactivate image device when unmounting container
...
There is no need to keep all the device-mapper devices active, we
can just activate them on demand if needed.
2013-09-30 17:34:59 -06:00
Alexander Larsson
e368c8bb01
Image: Add runtime and container id args to Mount()
...
We will later need the runtime to get access to the VolumeSet
singleton, and the container id to have a name for the volume
for the container
2013-09-30 17:34:58 -06:00
Victor Vieux
bcce3cbdd1
Merge pull request #1995 from dotcloud/fix_attach_2
...
Fix the attach behavior with -i
2013-09-30 03:29:19 -07:00
Guillaume J. Charmes
537149829a
Fix the attach behavior with -i
2013-09-27 11:10:55 -07:00
Michael Crosby
723de87681
Move run -rm to the cli only
2013-09-26 14:52:37 -07:00
Michael Crosby
db869ecce5
Merge pull request #1589 from unclejack/479-add_rm_support_to_docker_run
...
Add -rm to docker run for removing a container on exit
2013-09-27 11:45:32 -07:00
unclejack
22e7e107ad
automatically remove container via -rm
...
add AutoRemove to HostConfig
add -rm flag to docker run
add TestRunAutoRemove to test -rm
docs: add -rm to commandline/command/run
add hostConfig to container monitor
make monitor destroy the container via -rm
This adds support for automatically removing a container after it
exits. The removal of the container is handled on the server side.
2013-09-27 17:43:12 +03:00
Alexander Larsson
c1c74cb0b1
Container: Always create a new session for the container
...
We never want the container to be in the same process group as the
daemon, as then the container will receive signals sent to the
process group of the container.
2013-09-24 14:57:29 +02:00
Victor Vieux
2fafe1efce
Merge pull request #1948 from dotcloud/fix_attach
...
Fix attach issue
2013-09-23 02:15:51 -07:00
Michael Crosby
23cf3c7a33
Merge pull request #1934 from dotcloud/host-permissions
...
Only copy files and change permissions with non bindmount
2013-09-22 09:40:52 -07:00
Guillaume J. Charmes
e97364ecd7
Improve detach unit tests
2013-09-20 13:36:19 -07:00
Guillaume J. Charmes
2bd089dadb
Fix attach issue
2013-09-20 11:31:00 -07:00
Michael Crosby
b45e280ee8
Only copy files and change permissions with non bindmount
2013-09-19 20:35:05 -07:00
Guillaume J. Charmes
68074fce68
Merge pull request #1886 from dotcloud/multi-volumes-from
...
* Runtime: Allow multiple volumes-from
2013-09-19 12:01:12 -07:00
Michael Crosby
45b50730e3
Merge pull request #1849 from dotcloud/better_handle_hostConfig
...
Improved hostConfig reload
2013-09-16 10:48:53 -07:00
Michael Crosby
b79bd4e864
Allow multiple volumes-from
2013-09-14 20:09:15 +00:00
Michael Crosby
b986fd00e0
Merge pull request #1846 from dotcloud/fix_return_error
...
Fix wrong return error
2013-09-13 09:44:38 -07:00
Brian Olsen
9cfbaecfe5
Transfer uid and gid to volume. Fixes #1737 .
2013-09-11 03:17:42 +02:00
Victor Vieux
f482432a76
improved hostConfig reload
2013-09-10 22:13:15 +00:00
Victor Vieux
44d0f941f2
fix wrong return error
2013-09-10 17:16:59 +00:00
Victor Vieux
27ca0c225a
Merge branch '1582_fix_volume_content' of https://github.com/griff/docker into griff-1582_fix_volume_content
2013-09-10 16:52:46 +00:00
Michael Crosby
e89396809f
Merge pull request #1735 from dotcloud/1301-support-domainname
...
Add domain name support
2013-09-09 17:21:11 -07:00
Victor Vieux
4f2e59f94a
bind mount /etc/hosts and /etc/hostname
2013-09-09 20:29:57 +00:00
Victor Vieux
0a436e03b8
add domainname support
2013-09-09 20:29:06 +00:00
shin-
2ea52dddec
Merge branch 'better_api_ports' of git://github.com/shin-/docker into shin--better_api_ports
2013-09-04 22:25:01 +02:00
Brian Olsen
7a9c711832
Copies content from image to volumne if non-empty. Fixes #1582 .
2013-08-30 22:02:05 +02:00
Brian Olsen
6756e786ac
Just fixing gofmt issues in other people's code.
2013-08-30 22:02:05 +02:00
Victor Vieux
eee6d3dae9
add TEST env var during tests and silenced parserun during tests
2013-08-29 22:55:29 +00:00
shin-
98018df078
More descriptive, easier to process container portmappings information in the API
2013-08-28 00:20:35 +02:00
Michael Crosby
c2b273df5d
Merge pull request #1611 from pysqz/master
...
Make sure 'Ghost' container is available with allocated IP
2013-08-27 11:30:00 -07:00
pysqz
cc18a9c650
Also reuse forwarding ports
2013-08-28 03:14:21 +08:00
Michael Crosby
551092f9c0
Add lxc-conf flag to allow custom lxc options
2013-08-22 16:05:21 +00:00
pysqz
2f6ce27fde
Make sure 'Ghost' container is available with allocated IP
2013-08-21 22:37:58 +08:00
Victor Vieux
b21f898620
assume ip_forwarding = 1 by default
2013-08-19 12:34:30 +00:00
Marco Hennings
687d27ab57
Add an option to set the working directory.
...
This makes it possible to simply wrap a command inside a container. This makes
it easier to use a container as an unified build environment.
Examples:
~/workspace/docker
$ docker run -v `pwd`:`pwd` -w `pwd` -i -t ubuntu ls
AUTHORS Makefile archive.go changes.go docker
[...]
docker run -v `pwd`:`pwd` -w `pwd` -i -t ubuntu pwd
/home/marco/workspace/docker
2013-08-18 19:34:01 +02:00
Michael Crosby
15bc2240ac
Merge pull request #1505 from dotcloud/improve_events
...
Add image name in /events
2013-08-14 15:40:36 -07:00
Guillaume J. Charmes
631c449183
Merge pull request #1496 from xdissent/1351-volumes-from-before-volumes
...
* Runtime: Apply volumes-from before creating volumes
2013-08-14 15:10:41 -07:00
Jérôme Petazzoni
280901e5fb
add -insecure flag and relevant tests
2013-08-13 16:20:22 -07:00
Victor Vieux
703905d7ec
ensure the use oh IDs and add image's name in /events
2013-08-12 11:50:03 +00:00
Greg Thornton
57b49efc98
Skip existing volumes in volumes-from
...
Removes the error when a container already has a volume that would otherwise
be created by `Config.VolumesFrom`. Allows restarting containers with a
`Config.VolumesFrom` set.
2013-08-10 06:37:57 +00:00
Greg Thornton
3bd73a9633
Apply volumes-from before creating volumes
...
Copies the volumes from the container specified in `Config.VolumesFrom` before
creating volumes from `Config.Volumes`. Skips any preexisting volumes when
processing `Config.Volumes`. Fixes #1351
2013-08-10 04:55:23 +00:00
Colin Rice
10190be5d7
Add warning when net.ipv4.ip_forwarding = 0
...
Added warnings to api.go, container.go, commands.go, and runtime.go
Also updated APIInfo to return whether IPv4Forwarding is enabled
2013-08-07 18:28:39 -04:00
Michael Crosby
d94b186080
Strip leading forward slash from resource
2013-08-06 16:09:54 +00:00
Michael Crosby
5b8cfbe15c
Add cp command and copy api endpoint
...
The cp command and copy api endpoint allows users
to copy files and or folders from a containers filesystem.
Closes #382
2013-08-06 16:09:54 +00:00
Guillaume J. Charmes
f6fa353dd8
Merge pull request #1267 from sridatta/new-clean-init
...
* Runtime: Fix to "Inject dockerinit at /.dockerinit"
2013-08-05 13:23:22 -07:00
Guillaume J. Charmes
29de2432ea
Merge pull request #1350 from ndarilek/1348-add-hostname-to-environment
...
Runtime: add hostname to environment
2013-08-02 13:58:43 -07:00