• <sup id="mk476"></sup>
    <dl id="mk476"></dl>
  • <progress id="mk476"><tr id="mk476"></tr></progress>
    <div id="mk476"><tr id="mk476"></tr></div>
    <sup id="mk476"><ins id="mk476"></ins></sup>
  • <progress id="mk476"></progress>
    <div id="mk476"></div>
    <div id="mk476"><tr id="mk476"></tr></div>
  • <div id="mk476"></div>
    <dl id="mk476"><s id="mk476"></s></dl><dl id="mk476"></dl><div id="mk476"></div>
  • <div id="mk476"></div>
    <dl id="mk476"><ins id="mk476"></ins></dl>

    Docker国内镜像source

    现在使用docker的镜像大多基于几种基本Linux系统。虽然我不需要在容器李安装很多东西,但经常需要一些必要的工具,而基础镜像里并不包含,比如vim, ifconfig, curl等。考虑下载速度,最后修改镜像的source为国内地址。现在收集一些docker的基础镜像中国镜像?#30784;?/p>

    Github: https://github.com/Ryan-Miao/docker-china-source

    docker hub国内镜像

    下载docker image?#37096;?#20197;走国内镜像。

    /etc/docker/daemon.json

    { 
    "registry-mirrors": ["https://registry.docker-cn.com", "http://hub-mirror.c.163.com","https://docker.mirrors.ustc.edu.cn"] 
    }

    alpine

    Alpine Linux is a security-oriented, lightweight Linux distribution based on musl libc and busybox.

    特点是轻量,小,现在docker推荐的base镜像系统,绝大多数公共docker镜像都有alpine版本。

    新建repositories

    https://mirrors.aliyun.com/alpine/v3.6/main/
    
    https://mirrors.aliyun.com/alpine/v3.6/community/

    现在制作一个lua解析容器:

    Dockerfile

    FROM alpine
    
    COPY repositories /etc/apk/repositories
    RUN apk update && apk add vim curl net-tools lua

    centos6

    有时候还是想继续用centos6.

    wget http://mirrors.aliyun.com/repo/Centos-6.repo

    Dockerfile

    FROM centos:6
    MAINTAINER Ryan Miao
    WORKDIR /tmp
    COPY Centos-6.repo /etc/yum.repos.d/CentOS-Base.repo
    RUN yum clean all && yum makecache
    RUN yum install -y  vim git net-tools curl wget 

    debian

    Debian是社区类Linux的典范,是迄今为止最遵循GNU规范的Linux系统, 包括Debian和Ubuntu等.

    很多镜像选择debian作为基础镜像,比如nginx

    新建sources.list

    deb http://mirrors.aliyun.com/debian/ stretch main non-free contrib
    deb-src http://mirrors.aliyun.com/debian/ stretch main non-free contrib
    deb http://mirrors.aliyun.com/debian-security stretch/updates main
    deb-src http://mirrors.aliyun.com/debian-security stretch/updates main
    deb http://mirrors.aliyun.com/debian/ stretch-updates main non-free contrib
    deb-src http://mirrors.aliyun.com/debian/ stretch-updates main non-free contrib
    deb http://mirrors.aliyun.com/debian/ stretch-backports main non-free contrib
    deb-src http://mirrors.aliyun.com/debian/ stretch-backports main non-free contrib
    
    deb http://mirrors.163.com/debian/ stretch main non-free contrib
    deb http://mirrors.163.com/debian/ stretch-updates main non-free contrib
    deb http://mirrors.163.com/debian/ stretch-backports main non-free contrib
    deb-src http://mirrors.163.com/debian/ stretch main non-free contrib
    deb-src http://mirrors.163.com/debian/ stretch-updates main non-free contrib
    deb-src http://mirrors.163.com/debian/ stretch-backports main non-free contrib
    deb http://mirrors.163.com/debian-security/ stretch/updates main non-free contrib
    deb-src http://mirrors.163.com/debian-security/ stretch/updates main non-free contrib

    Dockerfile

    FROM nginx:1.15.10
    MAINTAINER Ryan Miao <[email protected]>
    
    
    COPY sources.list   /etc/apt/sources.list
    RUN apt-get update 
    RUN apt-get install -y net-tools procps curl wget vim telnet cron
    
    posted @ 2019-04-12 11:31 Ryan.Miao 阅读(...) 评论(...) 编辑 收藏
    江苏11选5软件 期开什么特码 河南十一选五杀号秘籍 河南22选5走势图奇偶 安徽十一选五预测号码今天 广西快乐十分直播吧 中国竞彩网模拟 新疆时时彩未出号 河南快赢481视频在线直播 河南快赢481走势图百度乐彩 北京赛车pk10图片 北京十一选五结果 全国彩票网 湖南彩票自由论坛 8十1中三红球有没有钱 新疆11选5全方位走势