zoukankan      html  css  js  c++  java
  • Centos7搭建docker仓库

    一:安装启动registry

      1.1:环境准备

        yum install -y python-devel libevent-devel python-pip gcc xz-devel

        pip install docker-registry

      1.2:server端

        [root@k8s-01 ~]# docker pull registry(西游记)

    [root@k8s-01 ~]# docker pull registry
    Using default tag: latest
    Trying to pull repository docker.io/library/registry ... 
    latest: Pulling from docker.io/library/registry
    c87736221ed0: Pull complete 
    1cc8e0bb44df: Pull complete 
    54d33bcb37f5: Pull complete 
    e8afc091c171: Pull complete 
    b4541f6d3db6: Pull complete 
    

       1.3:浏览器打开http://10.8.8.31:5000/v2/_catalog   

        {"repositories":[]}表示现在仓库中,没有镜像images

      1.3:启动registry

        默认情况下,会将仓库存放于容器的 /tmp/registry 目录下,如果容器被删除,则数据也会丢失,所以我们可以通过 -v 参数来将镜像文件存放在本地的指定路径:

    docker run -itd -v /data/registry:/var/lib/registry -p 5000:5000 --restart=always --name registry registry:latest
    

       1.4:

    感谢:

    https://blog.csdn.net/yejinxiong001/article/details/81944820

    https://www.cnblogs.com/purpleraintear/p/6010657.html

    TLS认证:

    https://www.cnblogs.com/zhaojiankai/p/7813969.html

  • 相关阅读:
    Spring配置多个数据源
    虚拟机内存结构
    Java中sleep,wait,yield,join的区别
    Java的四种引用方式
    Java 中的泛型详解-Java编程思想
    Java RTTI和反射
    linux 分析java 线程状态
    小容量的byteBuffer 读取大文本
    @Conditional 原理
    替换字符串占位符
  • 原文地址:https://www.cnblogs.com/jackyzm/p/10565680.html
Copyright © 2011-2022 走看看