在线时间:8:00-16:00
迪恩网络APP
随时随地掌握行业动态
扫描二维码
关注迪恩网络微信公众号
开源软件名称:sync-repo开源软件地址:https://gitee.com/AliyunContainerService/sync-repo开源软件介绍:Docker Registry SynchronizerThis helper project will synchronize Docker image from popular public Docker Registry services to your own registry.
Prequesitepip install dockerpip install python-dateutilpip install requests[security] Editing image listsEdit 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
or
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 UsageHelp 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 imagesYou can run the following command to remove the images created more than 30 days (720h) ago: docker image prune -a --force --filter "until=720h" |
请发表评论