You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 11 Next »


Docker 설치 공식 가이드 for CentOS


OS 요구 사항

  • To install Docker CE, you need a maintained version of CentOS 7. Archived versions aren’t supported or tested.

    The centos-extras repository must be enabled. This repository is enabled by default, but if you have disabled it, you need to re-enable it.

    The overlay2 storage driver is recommended.

    출처


    Docker Engine - Community

    • For Docker Engine - Community, only some configurations are tested, and your operating system’s kernel may not support every storage driver. In general, the following configurations work on recent versions of the Linux distribution:
    Linux distributionRecommended storage driversAlternative drivers
    Docker Engine - Community on Ubuntuoverlay2 or aufs (for Ubuntu 14.04 running on kernel 3.13)overlay¹, devicemapper², zfs, vfs
    Docker Engine - Community on Debianoverlay2 (Debian Stretch), aufs or devicemapper(older versions)overlay¹, vfs
    Docker Engine - Community on CentOSoverlay2overlay¹, devicemapper², zfs, vfs
    Docker Engine - Community on Fedoraoverlay2overlay¹, devicemapper², zfs, vfs

    Supported backing filesystems

    • With regard to Docker, the backing filesystem is the filesystem where /var/lib/docker/ is located. Some storage drivers only work with specific backing filesystems.
    Storage driverSupported backing filesystems
    overlay2, overlayxfs with ftype=1, ext4
    aufsxfs, ext4
    devicemapperdirect-lvm
    btrfsbtrfs
    zfszfs
    vfsany filesystem


Uninstall old versions

  • $ sudo yum remove docker \
                      docker-client \
                      docker-client-latest \
                      docker-common \
                      docker-latest \
                      docker-latest-logrotate \
                      docker-logrotate \
                      docker-engine

Docker CE 설치

  1. 저장소를 설정하고 설치하는 방법 : 가장 일반적인 방법으로 설치 및 업그레이드 작업을 쉽게하기 위해
  2. 수동으로 설치 : PM 패키지를 다운로드하여 수동으로 설치 하고 업그레이드를 완전히 수동으로 관리 (for not Internet)
  3. 자동화된 스크립트로 설치 : 테스트 및 개발 환경에서 사용하여 Docker를 설치


저장소를 설정하고 설치하는 방법

  • 필수 패키지 설치

    • $ sudo yum install -y yum-utils \
        device-mapper-persistent-data \
        lvm2
  • Stable repository 설정

    $ sudo yum-config-manager \
        --add-repo \
        https://download.docker.com/linux/centos/docker-ce.repo

Docker CE 설치

  • 최신 버전설치

    $ sudo yum install docker-ce docker-ce-cli containerd.io
  • 특정 버전설치

    $ yum list docker-ce --showduplicates | sort -r
    
    docker-ce.x86_64  3:18.09.1-3.el7                     docker-ce-stable
    docker-ce.x86_64  3:18.09.0-3.el7                     docker-ce-stable
    docker-ce.x86_64  18.06.1.ce-3.el7                    docker-ce-stable
    docker-ce.x86_64  18.06.0.ce-3.el7                    docker-ce-stable
    
    
    $ sudo yum install docker-ce-<VERSION_STRING> docker-ce-cli-<VERSION_STRING> containerd.io









  • No labels