当前位置: 首页 > news >正文

【docker镜像加速器配置】

提示:本文原创作品,良心制作,干货为主,简洁清晰,一看就会

文章目录

    • 前言
    • 方式一
    • 方式二
    • 方式三

前言

本文章专门用来收录docker的镜像加速器,总有一款你能用

方式一

root@docker:~# vim /etc/docker/daemon.json{"registry-mirrors":["https://a88uijg4.mirror.aliyuncs.com","https://docker.lmirror.top","https://docker.m.daocloud.io","https://hub.uuuadc.top","https://docker.anyhub.us.kg","https://dockerhub.jobcher.com","https://dockerhub.icu","https://docker.ckyl.me","https://docker.awsl9527.cn","https://docker.laoex.link"]}root@docker:~# systemctl daemon-reloadroot@docker:~# systemctl restart dockerroot@docker:~# docker pull nginx:1.24 #测试拉取1.24: Pulling from library/nginx 04e7578caeaa: Pull complete 57a1056ea484: Pull complete 6989106bacf0: Pull complete c00d1142b331: Pull complete cb49393af980: Pull complete 5ac1ebd8aebe: Pull complete Digest: sha256:f6daac2445b0ce70e64d77442ccf62839f3f1b4c24bf6746a857eff014e798c8 Status: Downloaded newer imagefornginx:1.24 docker.io/library/nginx:1.24

方式二

"exec-opts": ["native.cgroupdriver=systemd"] 配置Cgroup驱动程序
Cgroup驱动程序用于限制分配给进程的资源,官方建议配置容器运行时和kubelet使用systemd(systemd是Linux系统第一个初始进程)作为容器的控制组(Cgroup),以此使系统更稳定

root@docker:~# vim /etc/docker/daemon.json{"registry-mirrors":["https://docker.mirrors.ustc.edu.cn","https://docker.m.daocloud.io","http://hub-mirrors.c.163.com"],"max-concurrent-downloads":10,"log-driver":"json-file","log-level":"warn","data-root":"/var/lib/docker","exec-opts":["native.cgroupdriver=systemd"]}root@docker:~# systemctl daemon-reloadroot@docker:~# systemctl restart dockerroot@docker:~# docker pull nginx #测试拉取Using default tag: latest latest: Pulling from library/nginx 5435b2dcdf5c: Pull complete 054715a6bffa: Pull complete 88d1d984b765: Pull complete 4a038fd18db1: Pull complete 84e114c2bb36: Pull complete 7b5d674621c2: Pull complete 448ea5cac5d5: Pull complete Digest: sha256:7f0adca1fc6c29c8dc49a2e90037a10ba20dc266baaed0988e9fb4d0d8b85ba0 Status: Downloaded newer imagefornginx:latest docker.io/library/nginx:latest

方式三

root@docker:~# vim /etc/docker/daemon.json{"registry-mirrors":["https://docker.1panel.live","http://hub-mirror.c.163.com","https://mirror.baidubce.com","https://mirror.ccs.tencentyun.com"]}

注:
文中若有疏漏,欢迎大家指正赐教。
本文为100%原创,转载请务必标注原创作者,尊重劳动成果。
求赞、求关注、求评论!你的支持是我更新的最大动力,评论区等你~

http://www.jsqmd.com/news/862085/

相关文章:

  • Spring AI Alibaba 1.x 系列【55】Interrupts 中断机制:静态中断源码分析
  • 升学赠礼推荐开封汴绣绣品
  • 2026年局域网考试系统选型对比:优考试助力政企信创与内网安全
  • 【RK3588-AI-004】RK3588 AI专属依赖环境预装(Python、OpenCV、基础编译工具)
  • 3分钟掌握gmpublisher:Garry‘s Mod工坊发布的终极解决方案
  • 数分-MySQL基础01
  • Allen-Bradley 280D-F12Z-10B-CR启动控制模块
  • Go语言并发编程:sync包深度解析与实践
  • 升官发财送开封汴绣礼品推荐
  • 【Linux驱动开发】第10天:设备树零基础入门——DTS/DTB/DTC全解+编译流程
  • AI论文软件的实战手册:什么程度算学术不端?
  • Aeneas终极指南:3步搞定音频文本自动对齐,准确率超95%
  • 【Linux驱动开发】第11天:设备树(Device Tree)超详细全解:从诞生背景到工作原理
  • 如何构建更接近真实交通的自动驾驶仿真世界:数字孪生、风险重构与物理感知全栈实践
  • 编译和链接+预处理
  • 从塑料感→博物馆级质感,Midjourney材质进阶全路径:Chaos=0.3+Texture Boost+--style raw三重锁频技术,限时公开
  • ElevenLabs高棉文语音私有化部署终极方案(含Docker+Khmer IPA音素映射表),仅限前200位技术负责人获取
  • 为什么这款文档转换工具能同时实现高效与精准?揭秘Marker的核心优势
  • 2026.5.12【芯片设计面试经验分享】上海车载芯片设计公司
  • 079.自监督学习预训练:在无标签数据上预训练YOLO骨干网络
  • ElevenLabs挪威文语音API调用全链路拆解,从HTTP头配置到SSML韵律标记实战,零基础30分钟上线商用级语音
  • rk3588/rk3576使用rkllm推理大模型,提供OpenAI服务
  • VCG Mesh平滑整形
  • AI赋能光伏电站智能运维:边缘计算网关如何成为运维中枢?
  • AI 的持续学习:从会话中提取可复用知识
  • 一文搞懂 Linux 驱动并发与竞争(学习笔记)
  • 2026年工业胶粘材料国产化趋势白皮书:PI 金手指胶带的高温性能与应用突破
  • 深入拆解 MySQL InnoDB 隔离级别:从 MVCC 到临键锁
  • Go语言内存管理:从tcmalloc到GC优化
  • 2026年AI写作辅助网站实测排行,哪款真正适合写论文?