upgrading.rst 1.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273
  1. :title: Upgrading
  2. :description: These instructions are for upgrading Docker
  3. :keywords: Docker, Docker documentation, upgrading docker, upgrade
  4. .. _upgrading:
  5. Upgrading
  6. =========
  7. The technique for upgrading ``docker`` to a newer version depends on
  8. how you installed ``docker``.
  9. .. versionadded:: 0.5.3
  10. You may wish to add a ``docker`` group to your system to avoid using sudo with ``docker``. (see :ref:`dockergroup`)
  11. After ``apt-get``
  12. -----------------
  13. If you installed Docker using ``apt-get`` or Vagrant, then you should
  14. use ``apt-get`` to upgrade.
  15. .. versionadded:: 0.6
  16. Add Docker repository information to your system first.
  17. .. code-block:: bash
  18. # Add the Docker repository key to your local keychain
  19. sudo sh -c "curl https://get.docker.io/gpg | apt-key add -"
  20. # Add the Docker repository to your apt sources list.
  21. sudo sh -c "echo deb https://get.docker.io/ubuntu docker main > /etc/apt/sources.list.d/docker.list"
  22. # update your sources list
  23. sudo apt-get update
  24. # install the latest
  25. sudo apt-get install lxc-docker
  26. After manual installation
  27. -------------------------
  28. If you installed the Docker :ref:`binaries` then follow these steps:
  29. .. code-block:: bash
  30. # kill the running docker daemon
  31. killall docker
  32. .. code-block:: bash
  33. # get the latest binary
  34. wget http://get.docker.io/builds/Linux/x86_64/docker-latest -O docker
  35. # make it executable
  36. chmod +x docker
  37. Start docker in daemon mode (``-d``) and disconnect, running the
  38. daemon in the background (``&``). Starting as ``./docker`` guarantees
  39. to run the version in your current directory rather than a version
  40. which might reside in your path.
  41. .. code-block:: bash
  42. # start the new version
  43. sudo ./docker -d &
  44. Alternatively you can replace the docker binary in ``/usr/local/bin``.