zoukankan      html  css  js  c++  java
  • 搭建私有Docker镜像仓库

    安装Docker

    yum install docker -y

    配置阿里镜像加速网址

    sudo tee /etc/docker/daemon.json << EOF
    {
      "registry-mirrors": ["https://xxx.mirror.aliyuncs.com"],
      "insecure-registries": ["192.168.1.9:5000"]
    }
    EOF
    
    # xxx是自己阿里厂库的私有地址

    启动Docker

    systemctl start docker 
    systemctl enable docker

    使用register搭建docker私有仓库

    docker pull registry:latest
    docker run -d -v /registry:/var/lib/registry -p 5000:5000 --restart=always --privileged=true --name registry registry:latest

    测试是否搭建成功

    网址:http://192.168.1.9:5000/v2/
    查看厂库中的镜像:http://192.168.1.9:5000/v2/_catalog

    上传一个镜像到仓库

    docker pull busybox
    docker tag busybox 192.168.1.9:5000/busybox:latest
    docker push 192.168.1.9:5000/busybox:latest
  • 相关阅读:
    90. 子集 II 回溯算法
    47. 全排列 II 回溯算法
    40. 组合总和 II
    39. 组合总和 回溯
    NLP 第八课 语言技术-文本与LDA主题模型
    36. 有效的数独
    31. 下一个排列
    HDU 4527
    HDU 4521
    HDU 5191
  • 原文地址:https://www.cnblogs.com/chusiyong/p/12860001.html
Copyright © 2011-2022 走看看