How to install the latest version of Docker on CentOS 7

前端 未结 2 1420
傲寒
傲寒 2021-01-22 00:22

I am trying to have a modern docker.io version 1.5+ installed on a CentOS 7 64bit system.

The default docker.io that comes with the yum servers is 1.3.2, and this versio

相关标签:
2条回答
  • 2021-01-22 00:44

    Please see the official user guide on installing the latest version of Docker on CentOS

    At the very start it says: "While using a package is the recommended way of installing Docker, the above package might not be the current release version. If you need the latest version, you can install the binary directly."

    This tells you how to do that: https://docs.docker.com/installation/binaries/

    Basically:

    • check your dependencies
    • download the binary: wget https://get.docker.com/builds/Linux/x86_64/docker-latest -O docker
    • run the daemon: sudo ./docker -d &

    Now you're good to go.

    0 讨论(0)
  • 2021-01-22 00:51

    Here is what I did:

    1. Add a repo to yum using this command

    sudo vi /etc/yum.repos.d/cbs.repo

    and with this contents:

    [virt7-testing]
    name=virt7-testing
    baseurl=http://cbs.centos.org/repos/virt7-testing/x86_64/os/
    enabled=1
    gpgcheck=0
    
    1. Start yum using Applications -> System Tools -> Software

    2. Search for Docker

    3. Note that docker 1.5.x is available for install.

    4. If Docker 1.3.2 is installed, uninstall it by unchecking it and clicking apply.

    5. Click the check box next to Docker 1.5.x and click apply.

    6. Test that the install was successful by running docker --version from command line.
    0 讨论(0)
提交回复
热议问题