zoukankan      html  css  js  c++  java
  • Docker和Docker-compose安装教程以及docker-elk,docker-storm安装教程

    此安装教程仅供我自己安装配置时查看,其他的人不可以偷看!!!

    安装Docker

    1. Update package information, ensure that APT works with the https method, and that CA certificates are installed.

    sudo apt-get update
    sudo apt-get install apt-transport-https ca-certificates
    

    2. Add the new GPG key.

    sudo apt-key adv --keyserver hkp://p80.pool.sks-keyservers.net:80 --recv-keys 58118E89F3A912897C070ADBF76221572C52609D
    

    3. Open the /etc/apt/sources.list.d/docker.list file in your favorite editor.If the file doesn’t exist, create it.Remove any existing entries.Add an entry for your Ubuntu operating system.

    deb https://apt.dockerproject.org/repo ubuntu-precise main
    deb https://apt.dockerproject.org/repo ubuntu-trusty main
    deb https://apt.dockerproject.org/repo ubuntu-xenial main
    

    On Ubuntu Precise 12.04 (LTS)

    On Ubuntu Trusty 14.04 (LTS)

    On Ubuntu Xenial 16.04 (LTS)

    上面的deb要和下面的版本分别对应。

    4. Save and close the /etc/apt/sources.list.d/docker.list file.Update the APT package index.Purge the old repo if it exists.Verify that APT is pulling from the right repository.

    sudo apt-get update
    sudo apt-get purge lxc-docker
    apt-cache policy docker-engine
    

    5. Update your package manager.Install the recommended packages.(仅Ubuntu Xenial 16.04 (LTS)和Ubuntu Trusty 14.04 (LTS),12.04不做讨论,自己去docker官网看)

    sudo apt-get update
    sudo apt-get install linux-image-extra-$(uname -r) linux-image-extra-virtual
    

    6. Update your APT package index.Install Docker.

    sudo apt-get update
    sudo apt-get install docker-engine
    

    7. Start the docker daemon.

    sudo service docker start
    

      

    安装Docker-Compose(需要先安装docker)

    1. Go to the Compose repository release page on GitHub.

    2. Follow the instructions from the release page and run the curl command, which the release page specifies, in your terminal.

    【“Permission denied”  Run sudo -i, then the two commands below, then exit.】

    3. An example command illustrating the format,Apply executable permissions to the binary.Test the installation.

    curl -L https://github.com/docker/compose/releases/download/1.8.1/docker-compose-`uname -s`-`uname -m` > /usr/local/bin/docker-compose
    chmod +x /usr/local/bin/docker-compose
    docker-compose --version

    Alternative install options

    Install using pip

    pip version 6.0 or greater is required

    pip install docker-compose
    

    Install as a container

    curl -L https://github.com/docker/compose/releases/download/1.8.0/run.sh > /usr/local/bin/docker-compose
    chmod +x /usr/local/bin/docker-compose
    

      

  • 相关阅读:
    数据结构总结(UPDATING......)
    课件例题4.11,4.12
    Luogu P1525 关押罪犯
    Luogu P1540 机器翻译
    Luogu P1313 计算系数
    Luogu P1311 选择客栈
    Luogu P1519 穿越栅栏 Overfencing
    Luogu P2863 [USACO06JAN]牛的舞会The Cow Prom
    Tarjan学习笔记
    Luogu P3393 逃离僵尸岛
  • 原文地址:https://www.cnblogs.com/cutd/p/5953417.html
Copyright © 2011-2022 走看看