zoukankan      html  css  js  c++  java
  • ubuntu 16.04 跑 docker

    Ubuntu 的软件源配置文件是 /etc/apt/sources.list

    换国内的,不然会疯。下面是清华大学滴:

    # 默认注释了源码镜像以提高 apt update 速度,如有需要可自行取消注释
    deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial main restricted universe multiverse
    # deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial main restricted universe multiverse
    deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-updates main restricted universe multiverse
    # deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-updates main restricted universe multiverse
    deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-backports main restricted universe multiverse
    # deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-backports main restricted universe multiverse
    deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-security main restricted universe multiverse
    # deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-security main restricted universe multiverse

    然后reboot一下服务器。

    $ sudo apt-get update
    
    $ sudo apt-get install 
        apt-transport-https 
        ca-certificates 
        curl 
        software-properties-common
    
    $ curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
    
    $ sudo apt-key fingerprint 0EBFCD88
    
    $ sudo add-apt-repository 
       "deb [arch=amd64] https://download.docker.com/linux/ubuntu 
       $(lsb_release -cs) 
       stable"
    
    $ sudo apt-get update
    
    $ sudo apt-get install docker-ce

    然后配置个docker加速器

    curl -sSL https://get.daocloud.io/daotools/set_mirror.sh | sh -s http://xxxxxxxxx.m.daocloud.io

    然后根据提示,重新启动一下docker服务,输入docker info,就可以看到docker的情况啦~

  • 相关阅读:
    OpenERP实施记录(12):付款处理
    OpenERP实施记录(10):采购补货
    OpenERP实施记录(9):销售一批电脑
    从一个action地址获取信息
    在线杀毒 (最大文件大小64MB)
    WIN7启动WIFI
    Lazy Load, 延迟加载图片的 jQuery 插件【备忘】
    Android 汉字转拼音之JNI篇
    Android Studio 解决方法No JVM installation found. Please install a 64-bit JDK.
    Unity3D移植到自己的Android程序
  • 原文地址:https://www.cnblogs.com/vincentzhou/p/8969900.html
Copyright © 2011-2022 走看看