diff --git a/Vagrantfile b/Vagrantfile index 6bfc77dc23..884cb40a9b 100644 --- a/Vagrantfile +++ b/Vagrantfile @@ -25,7 +25,7 @@ def v10(config) # Assign this VM to a bridged network, allowing you to connect directly to a # network using the host's network device. This makes the VM appear as another # physical device on your network. - # config.vm.network :bridged + #config.vm.network :bridged # Forward a port from the guest to the host, which allows for outside # computers to access the VM, whereas host only networking does not. @@ -37,7 +37,7 @@ def v10(config) # Share an additional folder to the guest VM. The first argument is # an identifier, the second is the path on the guest to mount the # folder, and the third is the path on the host to the actual folder. - config.vm.share_folder "v-data", "~/docker", "~/docker" + config.vm.share_folder "v-data", "~/docker", File.dirname(__FILE__) # Enable provisioning with Puppet stand alone. Puppet manifests # are contained in a directory path relative to this Vagrantfile. @@ -119,10 +119,11 @@ end aws.keypair_name = ENV["AWS_KEYPAIR_NAME"] aws.ssh_private_key_path = ENV["AWS_SSH_PRIVKEY"] aws.region = "us-east-1" - aws.ami = "ami-1c1e8075" - aws.ssh_username = "vagrant" + aws.ami = "ami-ae9806c7" + aws.ssh_username = "ubuntu" aws.instance_type = "t1.micro" end + config.vm.provider :rackspace do |rs| config.vm.box = "dummy" config.vm.box_url = "https://github.com/mitchellh/vagrant-rackspace/raw/master/dummy.box" @@ -133,6 +134,7 @@ end rs.flavor = /512MB/ rs.image = /Ubuntu/ end + config.vm.provider :virtualbox do |vb| config.vm.box = "quantal64_3.5.0-25" config.vm.box_url = "http://get.docker.io/vbox/ubuntu/12.10/quantal64_3.5.0-25.box" diff --git a/commands.go b/commands.go index 3806323879..c769568536 100644 --- a/commands.go +++ b/commands.go @@ -43,7 +43,7 @@ func (srv *Server) Help() string { {"logs", "Fetch the logs of a container"}, {"port", "Lookup the public-facing port which is NAT-ed to PRIVATE_PORT"}, {"ps", "List containers"}, - {"pull", "Pull an image or a repository to the docker registry server"}, + {"pull", "Pull an image or a repository from the docker registry server"}, {"push", "Push an image or a repository to the docker registry server"}, {"restart", "Restart a running container"}, {"rm", "Remove a container"}, diff --git a/docs/Makefile b/docs/Makefile index 55e4ad6eb5..d7602ae826 100644 --- a/docs/Makefile +++ b/docs/Makefile @@ -49,6 +49,8 @@ docs: cp sources/index.html $(BUILDDIR)/html/ cp sources/gettingstarted.html $(BUILDDIR)/html/ cp sources/dotcloud.yml $(BUILDDIR)/html/ + cp sources/CNAME $(BUILDDIR)/html/ + cp sources/.nojekyll $(BUILDDIR)/html/ @echo @echo "Build finished. The HTML pages are in $(BUILDDIR)/html." diff --git a/docs/sources/.nojekyll b/docs/sources/.nojekyll new file mode 100644 index 0000000000..e69de29bb2 diff --git a/docs/sources/CNAME b/docs/sources/CNAME new file mode 100644 index 0000000000..243e482261 --- /dev/null +++ b/docs/sources/CNAME @@ -0,0 +1 @@ +docker.io diff --git a/docs/sources/documentation/commandline/basecommands.rst b/docs/sources/documentation/commandline/basecommands.rst index 180ad413a8..b065985059 100644 --- a/docs/sources/documentation/commandline/basecommands.rst +++ b/docs/sources/documentation/commandline/basecommands.rst @@ -13,11 +13,11 @@ Running an interactive shell .. code-block:: bash # Download a base image - docker import base + docker pull base # Run an interactive shell in the base image, # allocate a tty, attach stdin and stdout - docker run -a -i -t base /bin/bash + docker run -i -t base /bin/bash Starting a long-running worker process @@ -26,10 +26,10 @@ Starting a long-running worker process .. code-block:: bash # Run docker in daemon mode - (docker -d || echo "Docker daemon already running") & + (sudo docker -d || echo "Docker daemon already running") & # Start a very useful long-running process - JOB=$(docker run base /bin/sh -c "while true; do echo Hello world!; sleep 1; done") + JOB=$(docker run -d base /bin/sh -c "while true; do echo Hello world; sleep 1; done") # Collect the output of the job so far docker logs $JOB @@ -51,7 +51,7 @@ Expose a service on a TCP port .. code-block:: bash # Expose port 4444 of this container, and tell netcat to listen on it - JOB=$(docker run -p 4444 base /bin/nc -l -p 4444) + JOB=$(docker run -d -p 4444 base /bin/nc -l -p 4444) # Which public port is NATed to my container? PORT=$(docker port $JOB 4444) diff --git a/docs/sources/documentation/examples/python_web_app.rst b/docs/sources/documentation/examples/python_web_app.rst index 5b0ac30b63..922af29345 100644 --- a/docs/sources/documentation/examples/python_web_app.rst +++ b/docs/sources/documentation/examples/python_web_app.rst @@ -12,9 +12,9 @@ The goal of this example is to show you how you can author your own docker image .. code-block:: bash - $ docker import shykes/pybuilder + $ docker pull shykes/pybuilder -We are importing the "shykes/pybuilder" docker image +We are downloading the "shykes/pybuilder" docker image .. code-block:: bash diff --git a/docs/sources/documentation/installation/macos.rst b/docs/sources/documentation/installation/macos.rst index f7c1b65c1d..09eca22b92 100644 --- a/docs/sources/documentation/installation/macos.rst +++ b/docs/sources/documentation/installation/macos.rst @@ -2,7 +2,7 @@ Mac OS X and other linux ======================== - Please note the only 'official' installation is using the :ref:`ubuntu_linux` installation path. This version + Please note this is a community contributed installation path. The only 'official' installation is using the :ref:`ubuntu_linux` installation path. This version may be out of date because it depends on some binaries to be updated and published diff --git a/docs/sources/documentation/installation/windows.rst b/docs/sources/documentation/installation/windows.rst index 7c0b15be4b..6091d6bac1 100644 --- a/docs/sources/documentation/installation/windows.rst +++ b/docs/sources/documentation/installation/windows.rst @@ -6,7 +6,7 @@ Windows ========= - Please note the only 'official' installation is using the :ref:`ubuntu_linux` installation path. This version + Please note this is a community contributed installation path. The only 'official' installation is using the :ref:`ubuntu_linux` installation path. This version may be out of date because it depends on some binaries to be updated and published @@ -156,7 +156,7 @@ You are now ready for the docker’s “hello world” example. Run .. code-block:: bash - docker run -a busybox echo hello world + docker run busybox echo hello world .. image:: images/win/run_04.gif :alt: run docker diff --git a/docs/sources/static_files/lego_docker.jpg b/docs/sources/static_files/lego_docker.jpg index 77e68cb865..b3039a2cb5 100644 Binary files a/docs/sources/static_files/lego_docker.jpg and b/docs/sources/static_files/lego_docker.jpg differ diff --git a/puppet/modules/docker/manifests/init.pp b/puppet/modules/docker/manifests/init.pp index b6b8aecd1c..843cd021f1 100644 --- a/puppet/modules/docker/manifests/init.pp +++ b/puppet/modules/docker/manifests/init.pp @@ -1,12 +1,26 @@ class virtualbox { Package { ensure => "installed" } + user { "vagrant": + name => "vagrant", + ensure => present, + comment => "Vagrant User", + shell => "/bin/bash", + home => "/home/vagrant", + } + + file { "/home/vagrant": + mode => 644, + require => User["vagrant"], + } + # remove some files from the base vagrant image because they're old file { "/home/vagrant/docker-master": ensure => absent, recurse => true, force => true, purge => true, + require => File["/home/vagrant"], } file { "/usr/local/bin/dockerd": ensure => absent, @@ -23,9 +37,33 @@ class virtualbox { } class ec2 { + user { "vagrant": + name => "ubuntu", + ensure => present, + comment => "Vagrant User", + shell => "/bin/bash", + home => "/home/ubuntu", + } + file { "/home/vagrant": + ensure => link, + target => "/home/ubuntu", + require => User["vagrant"], + } } class rax { + user { "vagrant": + name => "ubuntu", + ensure => present, + comment => "Vagrant User", + shell => "/bin/bash", + home => "/home/ubuntu", + } + file { "/home/vagrant": + ensure => link, + target => "/home/ubuntu", + require => User["vagrant"], + } } class docker { @@ -49,43 +87,17 @@ class docker { $rax_version = inline_template("<%= %x{/usr/bin/xenstore-read vm-data/provider_data/provider} %>") if ($ec2_version) { - include ec2 + $vagrant_user = "ubuntu" + include ec2 } elsif ($rax_version) { + $vagrant_user = "vagrant" include rax } else { # virtualbox is the vagrant default, so it should be safe to assume + $vagrant_user = "vagrant" include virtualbox } - user { "vagrant": - ensure => present, - comment => "Vagrant User", - shell => "/bin/bash", - home => "/home/vagrant", - groups => [ - "sudo", - "vagrant", - "ubuntu", - ], - require => [ - Group["sudo"], - Group["vagrant"], - Group["ubuntu"], - ], - } - - group { "ubuntu": - ensure => present, - } - - group { "vagrant": - ensure => present, - } - - group { "sudo": - ensure => present, - } - file { "/usr/local/bin": ensure => directory, owner => root, @@ -112,16 +124,10 @@ class docker { require => Exec["copy-docker-bin"], } - file { "/home/vagrant": - ensure => directory, - mode => 644, - require => User["vagrant"], - } - file { "/home/vagrant/.profile": mode => 644, - owner => "vagrant", - group => "vagrant", + owner => $vagrant_user, + group => "ubuntu", content => template("docker/profile"), require => File["/home/vagrant"], }