当前位置:首页 > linux运维

使用自定义docker加速地址下载镜像

14324472931年前 (2024-11-17)linux运维1685

1.例如加速地址为:

https://docker.m.daocloud.io

2.配置docker加速地址

cat > /etc/docker/daemon.json <<EOF
> {"registry-mirrors": ["https://docker.m.daocloud.io"]}
> EOF

3.重启docker让加速地址生效

systemctl  daemon-reload 
systemctl  start  docker.service

4.使用加速地址下载docker

docker pull docker.m.daocloud.io/hello-world   #拉取镜像
docker tag docker.m.daocloud.io/hello-world hello-world   #拉取镜像自定义文件名

5.可以使用该开源项目搭建docker加速项目:https://github.com/jonssonyan/cf-workers-proxy

扫描二维码推送至手机访问。

版权声明:本文由爱开发博客发布,如需转载请注明出处。

本文链接:https://www.lovekf.cn/?id=36

分享给朋友:

“使用自定义docker加速地址下载镜像” 的相关文章

自建dns服务器

自建dns服务器:项目来源:AdguardTeam/AdGuardHome: Network-wide ads & trackers blocking DNS server (github.com)我建立的DNS:1.15.64.27:53特点:本dns服务器主要解决的是DNS污染问题,顺便…

自建内网穿透服务器-基于Docker的FRP内网穿透部署

创建配置文件# 创建存放目录 sudo mkdir /etc/frp # 创建frps.ini文件 vim /etc/frp/frps.tomlfrps.toml文件配置内容[common] # 监听端口 bind_port&nb…

openvpn服务端一键搭建

需求: 搭建openvpn目的是安全访问内网和匿名访问其他网站,确保隐私信息不会泄露。 搭建方法: 1.复制以下脚本命名为“openvpn-install.sh”,在ssh中执行。 ```bash#!/bin/bash shellcheck disable=SC1091,SC2164,SC…

aria2配置文件和bt-tracker定期更新脚本

# # https://github.com/P3TERX/aria2.conf # File name:aria2.conf # Description: Awesome Aria2 configuration file # Version: 2021.09.15 # # Copyright (c…

nginx 和frp共存端口转发规则

```bash server { listen 80; listen [::]:80; server_name *.lovekf.cn; location / { proxy_pass http://127.0.0.1:81; proxy_redirect http://$host/ http:/…

linux基线配置脚本(自己更具需求书写,并不适合所有人)

支持内容:1.检查更新系统时间。 ```bash#!/bin/bash 更新系统时间(假设你有NTP服务或者可以访问互联网时间服务器)echo “Updating system time using NTP…”sudo timedatectl set-ntp true 检查是否成功设置…

发表评论

访客

◎欢迎参与讨论,请在这里发表您的看法和观点。