• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

sync-repo: Docker Registry Synchronizer

原作者: [db:作者] 来自: 网络 收藏 邀请

开源软件名称:

sync-repo

开源软件地址:

https://gitee.com/AliyunContainerService/sync-repo

开源软件介绍:

Docker Registry Synchronizer

This helper project will synchronize Docker image from popular public Docker Registry services to your own registry.

  • Support gcr.io, quay.io and Docker Hub
  • Support public source image from above registry services only
  • Sync the tagged images from given repo updated within 15 days (default)

Prequesite

pip install dockerpip install python-dateutilpip install requests[security]

Editing image lists

Edit the images.txt of the image repositories for syncing

quay.io/coreos/prometheus-operator=registry.cn-hangzhou.aliyuncs.com/coreos_containers/prometheus-operatorgcr.io/google_containers/pause-amd64

Each line will be one repo definition

source_repo=target_repo Sync the source repo to specific target repo

or

source_repo Sync the source repo to default target repo, which is using default registry, namespace and the same name of the source repo.

In case to sync private repos of aliyun registry cross regions, you have to configure your aliyun cli before you get start, pls refer to aliyun-cli

registry.cn-hangzhou.aliyuncs.com/eric-dev/debug=registry.ap-southeast-1.aliyuncs.com/eric-dev/debug

Usage

Help

python sync_images.py -h|--help

Synchronize images from the configuraiton files, by default "images.txt"

python sync_images.py

Other optional arguments

-f|--file <image_list_file>-r|--registry <host:port> Default "registry.cn-hangzhou.aliyuncs.com"-n|--namespace <namespace> Default "google_containers"-d|--days <days> Default 15

Remove out-of-date images

You can run the following command to remove the images created more than 30 days (720h) ago:

docker image prune -a --force --filter "until=720h"

鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
热门推荐
热门话题
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap