Skip to content

Commit a93e40a

Browse files
Victor Vieuxvieux
authored andcommitted
Merge pull request moby#2812 from dotcloud/bump_v0.6.7
Bump v0.6.7
2 parents 6d42040 + 53f1bf0 commit a93e40a

File tree

124 files changed

+7987
-3772
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

124 files changed

+7987
-3772
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,3 +18,4 @@ bundles/
1818
.hg/
1919
.git/
2020
vendor/pkg/
21+
pyenv

AUTHORS

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@ Daniel Nordberg <dnordberg@gmail.com>
4444
Daniel Robinson <gottagetmac@gmail.com>
4545
Daniel Von Fange <daniel@leancoder.com>
4646
Daniel YC Lin <dlin.tw@gmail.com>
47+
Darren Coxall <darren@darrencoxall.com>
4748
David Calavera <david.calavera@gmail.com>
4849
David Sissitka <me@dsissitka.com>
4950
Deni Bertovic <deni@kset.org>
@@ -94,6 +95,7 @@ Jonathan Rudenberg <jonathan@titanous.com>
9495
Joost Cassee <joost@cassee.net>
9596
Jordan Arentsen <blissdev@gmail.com>
9697
Joseph Anthony Pasquale Holsten <joseph@josephholsten.com>
98+
Josh Poimboeuf <jpoimboe@redhat.com>
9799
Julien Barbier <write0@gmail.com>
98100
Jérôme Petazzoni <jerome.petazzoni@dotcloud.com>
99101
Karan Lyons <karan@karanlyons.com>
@@ -119,6 +121,7 @@ Marko Mikulicic <mmikulicic@gmail.com>
119121
Markus Fix <lispmeister@gmail.com>
120122
Martin Redmond <martin@tinychat.com>
121123
Matt Apperson <me@mattapperson.com>
124+
Mathieu Le Marec - Pasquet <kiorky@cryptelium.net>
122125
Matt Bachmann <bachmann.matt@gmail.com>
123126
Matthew Mueller <mattmuelle@gmail.com>
124127
Maxim Treskin <zerthurd@gmail.com>
@@ -165,6 +168,7 @@ Sridatta Thatipamala <sthatipamala@gmail.com>
165168
Sridhar Ratnakumar <sridharr@activestate.com>
166169
Steeve Morin <steeve.morin@gmail.com>
167170
Stefan Praszalowicz <stefan@greplin.com>
171+
Sven Dowideit <SvenDowideit@home.org.au>
168172
Thatcher Peskens <thatcher@dotcloud.com>
169173
Thermionix <bond711@gmail.com>
170174
Thijs Terlouw <thijsterlouw@gmail.com>

CHANGELOG.md

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,43 @@
11
# Changelog
22

3+
## 0.6.7 (2013-11-21)
4+
5+
#### Runtime
6+
7+
* Improved stability, fixes some race conditons
8+
* Skip the volumes mounted when deleting the volumes of container.
9+
* Fix layer size computation: handle hard links correctly
10+
* Use the work Path for docker cp CONTAINER:PATH
11+
* Fix tmp dir never cleanup
12+
* Speedup docker ps
13+
* More informative error message on name collisions
14+
* Fix nameserver regex
15+
* Always return long id's
16+
* Fix container restart race condition
17+
* Keep published ports on docker stop;docker start
18+
* Fix container networking on Fedora
19+
* Correctly express "any address" to iptables
20+
* Fix network setup when reconnecting to ghost container
21+
* Prevent deletion if image is used by a running container
22+
* Lock around read operations in graph
23+
24+
#### RemoteAPI
25+
26+
* Return full ID on docker rmi
27+
28+
#### Client
29+
30+
+ Add -tree option to images
31+
+ Offline image transfer
32+
* Exit with status 2 on usage error and display usage on stderr
33+
* Do not forward SIGCHLD to container
34+
* Use string timestamp for docker events -since
35+
36+
#### Other
37+
38+
* Update to go 1.2rc5
39+
+ Add /etc/default/docker support to upstart
40+
341
## 0.6.6 (2013-11-06)
442

543
#### Runtime

CONTRIBUTING.md

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,14 @@
11
# Contributing to Docker
22

3-
Want to hack on Docker? Awesome! Here are instructions to get you started. They are probably not perfect, please let us know if anything feels
4-
wrong or incomplete.
3+
Want to hack on Docker? Awesome! Here are instructions to get you
4+
started. They are probably not perfect, please let us know if anything
5+
feels wrong or incomplete.
56

67
## Build Environment
78

8-
For instructions on setting up your development environment, please see our dedicated [dev environment setup docs](http://docs.docker.io/en/latest/contributing/devenvironment/).
9+
For instructions on setting up your development environment, please
10+
see our dedicated [dev environment setup
11+
docs](http://docs.docker.io/en/latest/contributing/devenvironment/).
912

1013
## Contribution guidelines
1114

Dockerfile

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ run apt-get install -y -q mercurial
3636
run apt-get install -y -q build-essential libsqlite3-dev
3737

3838
# Install Go
39-
run curl -s https://go.googlecode.com/files/go1.2rc3.src.tar.gz | tar -v -C /usr/local -xz
39+
run curl -s https://go.googlecode.com/files/go1.2rc5.src.tar.gz | tar -v -C /usr/local -xz
4040
env PATH /usr/local/go/bin:/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/sbin:/bin:/sbin
4141
env GOPATH /go:/go/src/github.com/dotcloud/docker/vendor
4242
run cd /usr/local/go/src && ./make.bash && go install -ldflags '-w -linkmode external -extldflags "-static -Wl,--unresolved-symbols=ignore-in-shared-libs"' -tags netgo -a std
@@ -46,10 +46,9 @@ run apt-get install -y -q ruby1.9.3 rubygems libffi-dev
4646
run gem install --no-rdoc --no-ri fpm
4747
run apt-get install -y -q reprepro dpkg-sig
4848

49-
# Install s3cmd 1.0.1 (earlier versions don't support env variables in the config)
5049
run apt-get install -y -q python-pip
51-
run pip install s3cmd
52-
run pip install python-magic
50+
run pip install s3cmd==1.1.0-beta3
51+
run pip install python-magic==0.4.6
5352
run /bin/echo -e '[default]\naccess_key=$AWS_ACCESS_KEY\nsecret_key=$AWS_SECRET_KEY\n' > /.s3cfg
5453

5554
# Runtime dependencies

NOTICE

Lines changed: 6 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -8,35 +8,12 @@ by Keith Rarick, licensed under the MIT License.
88

99
The following is courtesy of our legal counsel:
1010

11-
Transfers of Docker shall be in accordance with applicable export
12-
controls of any country and all other applicable legal requirements.
13-
Docker shall not be distributed or downloaded to or in Cuba, Iran,
14-
North Korea, Sudan or Syria and shall not be distributed or downloaded
15-
to any person on the Denied Persons List administered by the U.S.
16-
Department of Commerce.
1711

18-
What does that mean?
19-
Here is a further explanation from our legal counsel:
12+
Use and transfer of Docker may be subject to certain restrictions by the
13+
United States and other governments.
14+
It is your responsibility to ensure that your use and/or transfer does not
15+
violate applicable laws.
2016

21-
Like all software products that utilize cryptography, the export and
22-
use of Docker is subject to the U.S. Commerce Department's Export
23-
Administration Regulations (EAR) because it uses or contains
24-
cryptography (see
25-
http://www.bis.doc.gov/index.php/policy-guidance/encryption). Certain
26-
free and open source software projects have a lightweight set of
27-
requirements, which can generally be met by providing email notice to
28-
the appropriate U.S. government agencies that their source code is
29-
available on a publicly available repository and making the
30-
appropriate statements in the README.
17+
For more information, please see http://www.bis.doc.gov
3118

32-
The restrictions of the EAR apply to certain denied locations
33-
(currently Iran, Sudan, Syria, North Korea, or Cuba) and those
34-
individuals on the Denied Persons List, which is available here:
35-
http://www.bis.doc.gov/index.php/policy-guidance/lists-of-parties-of-concern/denied-persons-list.
36-
If you are incorporating Docker into a new open source project, the
37-
EAR restrictions apply to your incorporation of Docker into your
38-
project in the same manner as other cryptography-enabled projects,
39-
such as OpenSSL, almost all Linux distributions, etc.
40-
41-
For more information, see http://www.apache.org/dev/crypto.html and/or
42-
seek legal counsel.
19+
See also http://www.apache.org/dev/crypto.html and/or seek legal counsel.

README.md

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -193,10 +193,9 @@ wrong or incomplete.
193193
*Brought to you courtesy of our legal counsel. For more context,
194194
please see the Notice document.*
195195

196-
Transfers of Docker shall be in accordance with applicable export controls
197-
of any country and all other applicable legal requirements. Without limiting the
198-
foregoing, Docker shall not be distributed or downloaded to any individual or
199-
location if such distribution or download would violate the applicable US
200-
government export regulations.
196+
Use and transfer of Docker may be subject to certain restrictions by the
197+
United States and other governments.
198+
It is your responsibility to ensure that your use and/or transfer does not
199+
violate applicable laws.
201200

202201
For more information, please see http://www.bis.doc.gov

VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
0.6.6
1+
0.6.7-dev

Vagrantfile

Lines changed: 119 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -4,65 +4,135 @@
44
BOX_NAME = ENV['BOX_NAME'] || "ubuntu"
55
BOX_URI = ENV['BOX_URI'] || "http://files.vagrantup.com/precise64.box"
66
VF_BOX_URI = ENV['BOX_URI'] || "http://files.vagrantup.com/precise64_vmware_fusion.box"
7+
AWS_BOX_URI = ENV['BOX_URI'] || "https://github.com/mitchellh/vagrant-aws/raw/master/dummy.box"
78
AWS_REGION = ENV['AWS_REGION'] || "us-east-1"
8-
AWS_AMI = ENV['AWS_AMI'] || "ami-d0f89fb9"
9+
AWS_AMI = ENV['AWS_AMI'] || "ami-69f5a900"
10+
AWS_INSTANCE_TYPE = ENV['AWS_INSTANCE_TYPE'] || 't1.micro'
11+
912
FORWARD_DOCKER_PORTS = ENV['FORWARD_DOCKER_PORTS']
1013

14+
SSH_PRIVKEY_PATH = ENV["SSH_PRIVKEY_PATH"]
15+
16+
# A script to upgrade from the 12.04 kernel to the raring backport kernel (3.8)
17+
# and install docker.
18+
$script = <<SCRIPT
19+
# The username to add to the docker group will be passed as the first argument
20+
# to the script. If nothing is passed, default to "vagrant".
21+
user="$1"
22+
if [ -z "$user" ]; then
23+
user=vagrant
24+
fi
25+
26+
# Adding an apt gpg key is idempotent.
27+
wget -q -O - https://get.docker.io/gpg | apt-key add -
28+
29+
# Creating the docker.list file is idempotent, but it may overrite desired
30+
# settings if it already exists. This could be solved with md5sum but it
31+
# doesn't seem worth it.
32+
echo 'deb http://get.docker.io/ubuntu docker main' > \
33+
/etc/apt/sources.list.d/docker.list
34+
35+
# Update remote package metadata. 'apt-get update' is idempotent.
36+
apt-get update -q
37+
38+
# Install docker. 'apt-get install' is idempotent.
39+
apt-get install -q -y lxc-docker
40+
41+
usermod -a -G docker "$user"
42+
43+
tmp=`mktemp -q` && {
44+
# Only install the backport kernel, don't bother upgrade if the backport is
45+
# already installed. We want parse the output of apt so we need to save it
46+
# with 'tee'. NOTE: The installation of the kernel will trigger dkms to
47+
# install vboxguest if needed.
48+
apt-get install -q -y --no-upgrade linux-image-generic-lts-raring | \
49+
tee "$tmp"
50+
51+
# Parse the number of installed packages from the output
52+
NUM_INST=`awk '$2 == "upgraded," && $4 == "newly" { print $3 }' "$tmp"`
53+
rm "$tmp"
54+
}
55+
56+
# If the number of installed packages is greater than 0, we want to reboot (the
57+
# backport kernel was installed but is not running).
58+
if [ "$NUM_INST" -gt 0 ];
59+
then
60+
echo "Rebooting down to activate new kernel."
61+
echo "/vagrant will not be mounted. Use 'vagrant halt' followed by"
62+
echo "'vagrant up' to ensure /vagrant is mounted."
63+
shutdown -r now
64+
fi
65+
SCRIPT
66+
67+
# We need to install the virtualbox guest additions *before* we do the normal
68+
# docker installation. As such this script is prepended to the common docker
69+
# install script above. This allows the install of the backport kernel to
70+
# trigger dkms to build the virtualbox guest module install.
71+
$vbox_script = <<VBOX_SCRIPT + $script
72+
# Install the VirtualBox guest additions if they aren't already installed.
73+
if [ ! -d /opt/VBoxGuestAdditions-4.3.2/ ]; then
74+
# Update remote package metadata. 'apt-get update' is idempotent.
75+
apt-get update -q
76+
77+
# Kernel Headers and dkms are required to build the vbox guest kernel
78+
# modules.
79+
apt-get install -q -y linux-headers-generic-lts-raring dkms
80+
81+
echo 'Downloading VBox Guest Additions...'
82+
wget -cq http://dlc.sun.com.edgesuite.net/virtualbox/4.3.2/VBoxGuestAdditions_4.3.2.iso
83+
84+
mount -o loop,ro /home/vagrant/VBoxGuestAdditions_4.3.2.iso /mnt
85+
/mnt/VBoxLinuxAdditions.run --nox11
86+
umount /mnt
87+
fi
88+
VBOX_SCRIPT
89+
1190
Vagrant::Config.run do |config|
1291
# Setup virtual machine box. This VM configuration code is always executed.
1392
config.vm.box = BOX_NAME
1493
config.vm.box_url = BOX_URI
1594

16-
config.ssh.forward_agent = true
17-
18-
# Provision docker and new kernel if deployment was not done.
19-
# It is assumed Vagrant can successfully launch the provider instance.
20-
if Dir.glob("#{File.dirname(__FILE__)}/.vagrant/machines/default/*/id").empty?
21-
# Add lxc-docker package
22-
pkg_cmd = "wget -q -O - https://get.docker.io/gpg | apt-key add -;" \
23-
"echo deb http://get.docker.io/ubuntu docker main > /etc/apt/sources.list.d/docker.list;" \
24-
"apt-get update -qq; apt-get install -q -y --force-yes lxc-docker; "
25-
# Add Ubuntu raring backported kernel
26-
pkg_cmd << "apt-get update -qq; apt-get install -q -y linux-image-generic-lts-raring; "
27-
# Add guest additions if local vbox VM. As virtualbox is the default provider,
28-
# it is assumed it won't be explicitly stated.
29-
if ENV["VAGRANT_DEFAULT_PROVIDER"].nil? && ARGV.none? { |arg| arg.downcase.start_with?("--provider") }
30-
pkg_cmd << "apt-get install -q -y linux-headers-generic-lts-raring dkms; " \
31-
"echo 'Downloading VBox Guest Additions...'; " \
32-
"wget -q http://dlc.sun.com.edgesuite.net/virtualbox/4.2.12/VBoxGuestAdditions_4.2.12.iso; "
33-
# Prepare the VM to add guest additions after reboot
34-
pkg_cmd << "echo -e 'mount -o loop,ro /home/vagrant/VBoxGuestAdditions_4.2.12.iso /mnt\n" \
35-
"echo yes | /mnt/VBoxLinuxAdditions.run\numount /mnt\n" \
36-
"rm /root/guest_additions.sh; ' > /root/guest_additions.sh; " \
37-
"chmod 700 /root/guest_additions.sh; " \
38-
"sed -i -E 's#^exit 0#[ -x /root/guest_additions.sh ] \\&\\& /root/guest_additions.sh#' /etc/rc.local; " \
39-
"echo 'Installation of VBox Guest Additions is proceeding in the background.'; " \
40-
"echo '\"vagrant reload\" can be used in about 2 minutes to activate the new guest additions.'; "
41-
end
42-
# Add vagrant user to the docker group
43-
pkg_cmd << "usermod -a -G docker vagrant; "
44-
# Activate new kernel
45-
pkg_cmd << "shutdown -r +1; "
46-
config.vm.provision :shell, :inline => pkg_cmd
95+
# Use the specified private key path if it is specified and not empty.
96+
if SSH_PRIVKEY_PATH
97+
config.ssh.private_key_path = SSH_PRIVKEY_PATH
4798
end
48-
end
4999

100+
config.ssh.forward_agent = true
101+
end
50102

51103
# Providers were added on Vagrant >= 1.1.0
104+
#
105+
# NOTE: The vagrant "vm.provision" appends its arguments to a list and executes
106+
# them in order. If you invoke "vm.provision :shell, :inline => $script"
107+
# twice then vagrant will run the script two times. Unfortunately when you use
108+
# providers and the override argument to set up provisioners (like the vbox
109+
# guest extensions) they 1) don't replace the other provisioners (they append
110+
# to the end of the list) and 2) you can't control the order the provisioners
111+
# are executed (you can only append to the list). If you want the virtualbox
112+
# only script to run before the other script, you have to jump through a lot of
113+
# hoops.
114+
#
115+
# Here is my only repeatable solution: make one script that is common ($script)
116+
# and another script that is the virtual box guest *prepended* to the common
117+
# script. Only ever use "vm.provision" *one time* per provider. That means
118+
# every single provider has an override, and every single one configures
119+
# "vm.provision". Much saddness, but such is life.
52120
Vagrant::VERSION >= "1.1.0" and Vagrant.configure("2") do |config|
53121
config.vm.provider :aws do |aws, override|
54-
aws.access_key_id = ENV["AWS_ACCESS_KEY_ID"]
55-
aws.secret_access_key = ENV["AWS_SECRET_ACCESS_KEY"]
122+
username = "ubuntu"
123+
override.vm.box_url = AWS_BOX_URI
124+
override.vm.provision :shell, :inline => $script, :args => username
125+
aws.access_key_id = ENV["AWS_ACCESS_KEY"]
126+
aws.secret_access_key = ENV["AWS_SECRET_KEY"]
56127
aws.keypair_name = ENV["AWS_KEYPAIR_NAME"]
57-
override.ssh.private_key_path = ENV["AWS_SSH_PRIVKEY"]
58-
override.ssh.username = "ubuntu"
128+
override.ssh.username = username
59129
aws.region = AWS_REGION
60130
aws.ami = AWS_AMI
61-
aws.instance_type = "t1.micro"
131+
aws.instance_type = AWS_INSTANCE_TYPE
62132
end
63133

64-
config.vm.provider :rackspace do |rs|
65-
config.ssh.private_key_path = ENV["RS_PRIVATE_KEY"]
134+
config.vm.provider :rackspace do |rs, override|
135+
override.vm.provision :shell, :inline => $script
66136
rs.username = ENV["RS_USERNAME"]
67137
rs.api_key = ENV["RS_API_KEY"]
68138
rs.public_key_path = ENV["RS_PUBLIC_KEY"]
@@ -71,20 +141,25 @@ Vagrant::VERSION >= "1.1.0" and Vagrant.configure("2") do |config|
71141
end
72142

73143
config.vm.provider :vmware_fusion do |f, override|
74-
override.vm.box = BOX_NAME
75144
override.vm.box_url = VF_BOX_URI
76145
override.vm.synced_folder ".", "/vagrant", disabled: true
146+
override.vm.provision :shell, :inline => $script
77147
f.vmx["displayName"] = "docker"
78148
end
79149

80-
config.vm.provider :virtualbox do |vb|
81-
config.vm.box = BOX_NAME
82-
config.vm.box_url = BOX_URI
150+
config.vm.provider :virtualbox do |vb, override|
151+
override.vm.provision :shell, :inline => $vbox_script
83152
vb.customize ["modifyvm", :id, "--natdnshostresolver1", "on"]
84153
vb.customize ["modifyvm", :id, "--natdnsproxy1", "on"]
85154
end
86155
end
87156

157+
# If this is a version 1 config, virtualbox is the only option. A version 2
158+
# config would have already been set in the above provider section.
159+
Vagrant::VERSION < "1.1.0" and Vagrant::Config.run do |config|
160+
config.vm.provision :shell, :inline => $vbox_script
161+
end
162+
88163
if !FORWARD_DOCKER_PORTS.nil?
89164
Vagrant::VERSION < "1.1.0" and Vagrant::Config.run do |config|
90165
(49000..49900).each do |port|

0 commit comments

Comments
 (0)