mirror of
https://gitee.com/SuperManito/LinuxMirrors
synced 2026-01-22 22:45:47 +08:00
1 line
257 KiB
JSON
1 line
257 KiB
JSON
{"config":{"lang":["en","zh"],"separator":"[\\s\\-,:!=\\[\\]()\"/]+|(?!\\b)(?=[A-Z][a-z])|\\.(?!\\d)|&[lg]t;","pipeline":["stemmer"],"fields":{"title":{"boost":1000.0},"text":{"boost":1.0},"tags":{"boost":1000000.0}}},"docs":[{"location":"","title":"\u4e00\u952e\u811a\u672c\u4f7f\u6362\u6e90\u66f4\u7b80\u5355","text":"GNU/Linux \u66f4\u6362\u7cfb\u7edf\u8f6f\u4ef6\u6e90\u811a\u672c\u53ca Docker \u5b89\u88c5\u4e0e\u6362\u6e90\u811a\u672c \u4e00\u952e\u811a\u672c\u4f7f\u6362\u6e90\u66f4\u7b80\u5355 GNU/Linux Docker <ul> <li> <p> \u8f7b\u677e\u4f7f\u7528</p> <p>\u53ea\u9700\u8981\u4e00\u884c\u547d\u4ee4\u5c31\u80fd\u76f4\u63a5\u8fd0\u884c\uff0c\u96f6\u6280\u672f\u95e8\u69db\uff0c\u65e0\u9700\u5b89\u88c5\u4efb\u4f55\u4f9d\u8d56 \u6587\u6863\u96c6\u6210\u4e86 AI \u641c\u7d22\u4e0e\u804a\u5929\uff0c\u63d0\u4f9b\u5404\u79cd\u4f7f\u7528\u573a\u666f\u7684\u89e3\u51b3\u65b9\u6848</p> </li> <li> <p> \u7cfb\u7edf\u652f\u6301\u5e7f\u6cdb</p> <p>\u5df2\u9002\u914d\u9ad8\u8fbe <code>26+</code> \u64cd\u4f5c\u7cfb\u7edf\uff0c\u6db5\u76d6\u5404\u7c7b\u7248\u672c\uff0c\u7cbe\u51c6\u8bc6\u522b\u7cfb\u7edf\u7c7b\u578b \u811a\u672c\u517c\u5bb9\u6027\u9ad8\uff0c\u4e0d\u652f\u6301\u7684\u7cfb\u7edf\u4f1a\u6709\u76f8\u5e94\u63d0\u793a\u5e76\u65e0\u64cd\u4f5c\u8df3\u51fa</p> </li> <li> <p> \u591a\u5143\u8f6f\u4ef6\u6e90\u9002\u914d</p> <p>\u6df1\u5165\u8003\u5bdf\u4e86\u56fd\u5185\u955c\u50cf\u7ad9\u7684\u7cfb\u7edf\u9002\u914d\u60c5\u51b5\uff0c\u4e13\u4e3a\u4e2d\u56fd\u7528\u6237\u6253\u9020 \u8fd8\u63d0\u4f9b\u5168\u7f51\u641c\u96c6\u7684\u56fd\u5185\u6559\u80b2\u7f51\u548c\u6d77\u5916\u955c\u50cf\u7ad9\u4f9b\u7528\u6237\u9009\u62e9</p> </li> <li> <p> \u5feb\uff0c\u4e14\u9ad8\u6548</p> <p>\u6700\u5feb\u4ec5\u9700 10 \u79d2\u5373\u53ef\u5b8c\u6210\u8f6f\u4ef6\u6e90\u7684\u66f4\u6362\uff0c\u9ad8\u6548\u8fd0\u7ef4\uff0c\u8282\u7701\u5927\u91cf\u65f6\u95f4\u6210\u672c \u9879\u76ee\u7ecf\u8fc7\u6570\u5e74\u7684\u8fed\u4ee3\u4e0e\u4f18\u5316\uff0c\u811a\u672c\u6027\u80fd\u5353\u8d8a\u8fd0\u884c\u7a33\u5b9a\uff0c\u573a\u666f\u5224\u65ad\u5b8c\u5584</p> </li> <li> <p> \u5168\u7403\u7f51\u7edc\uff0c\u8c03\u7528\u65e0\u5fe7</p> <p>\u672c\u7f51\u7ad9\u63d0\u4f9b\u5168\u7403\u8fb9\u7f18\u7f51\u7edc\u52a0\u901f\uff0c\u4e0d\u60e7\u5404\u79cd\u7f51\u7edc\u73af\u5883\uff0c\u56fd\u5185\u8f7b\u677e\u8bbf\u95ee \u540c\u65f6\u63d0\u4f9b\u4e86\u591a\u4e2a\u5907\u7528\u5730\u5740\u4ee5\u786e\u4fdd\u9879\u76ee\u811a\u672c\u59cb\u7ec8\u53ef\u7528\uff0c\u771f\u6b63\u505a\u5230\u4f7f\u7528\u65e0\u5fe7</p> </li> <li> <p> \u529f\u80fd\u5f3a\u5927\uff0c\u65e0\u4e0e\u4f26\u6bd4</p> <p>\u811a\u672c\u901a\u8fc7\u65b9\u5411\u952e\u4ea4\u4e92\u9010\u6b65\u5f15\u5bfc\u7528\u6237\u9009\u62e9\u8f6f\u4ef6\u6e90\u914d\u7f6e\uff0c\u4f7f\u6362\u6e90\u66f4\u7b80\u5355 \u6b64\u5916\u811a\u672c\u63d0\u4f9b\u4e86\u4e30\u5bcc\u7684\u547d\u4ee4\u9009\u9879\uff0c\u652f\u6301 CI/CD \u96c6\u6210\u4e0e\u81ea\u52a8\u5316\u8fd0\u7ef4</p> </li> <li> <p> \u9ad8\u5ea6\u53ef\u5b9a\u5236</p> <p>\u811a\u672c\u547d\u4ee4\u9009\u9879\u9075\u5faa\u6b63\u5f0f\u5e94\u7528\u7a0b\u5e8f\u89c4\u8303\u8bbe\u8ba1\uff0c\u80fd\u591f\u6ee1\u8db3\u5404\u79cd\u9ad8\u7ea7\u9700\u6c42 \u4ee3\u7801\u7ed3\u6784\u6e05\u6670\uff0c\u6613\u4e8e\u9605\u8bfb\u548c\u4fee\u6539\uff0c\u652f\u6301\u514b\u9686\u540e\u5b9a\u5236\uff0c\u652f\u6301\u591a\u8bed\u8a00\u6253\u5370</p> </li> <li> <p> \u81ea\u7531\uff0c\u5f00\u6e90</p> <p>\u9879\u76ee\u5df2\u8bbe\u7acb MIT \u5f00\u6e90\u8bb8\u53ef\u534f\u8bae\uff0c\u811a\u672c\u4ee3\u7801\u5b8c\u5168\u5f00\u6e90\u4e14\u514d\u8d39\u4f7f\u7528 \u8bf7\u5c0a\u91cd\u4f5c\u8005\u7684\u77e5\u8bc6\u6210\u679c\uff0c\u4f20\u64ad\u65f6\u8bf7\u5728\u663e\u8457\u4f4d\u7f6e\u6807\u6ce8\u6765\u6e90\u6216\u9879\u76ee\u5730\u5740</p> </li> </ul> \u64cd\u4f5c\u7cfb\u7edf \u9002\u914d\u7248\u672c Debian 8\uff5e13 Ubuntu 14\uff5e25 Kali Linux all Linux Mint 17\uff5e22 / LMDE 2\uff5e7 Deepin\uff08\u6df1\u5ea6\uff09 all Zorin OS all Armbian all Proxmox VE all Raspberry Pi OS all Red Hat Enterprise Linux 7\uff5e10 Fedora 30\uff5e43 CentOS 7\uff5e8 / Stream 8\uff5e10 Rocky Linux 8\uff5e10 AlmaLinux 8\uff5e10 Oracle Linux 8\uff5e10 openEuler\uff08\u5f00\u6e90\u6b27\u62c9\uff09 20\uff5e25 OpenCloudOS\uff08\u9e25\u6816\uff09 8.6\uff5e9 / Stream 23 openKylin\uff08\u5f00\u653e\u9e92\u9e9f\uff09 all Anolis OS\uff08\u9f99\u8725\uff09 8 / 23 openSUSE Leap 15 ~ 16 / Tumbleweed Arch Linux all Manjaro all EndeavourOS all Alpine Linux v3 / edge Gentoo all NixOS 19\uff5e25 <p>\u5f00 \u59cb \u4f7f \u7528 \u8f6f\u4ef6\u6e90\u5217\u8868</p>"},{"location":"other/","title":"Docker \u5b89\u88c5\u4e0e\u6362\u6e90\u811a\u672c","text":""},{"location":"other/#\u4e00\u952e\u6267\u884c\u547d\u4ee4","title":"\u4e00\u952e\u6267\u884c\u547d\u4ee4","text":"\u5b89\u88c5\u4ec5\u66f4\u6362\u955c\u50cf\u52a0\u901f\u5668 \u5b98\u7f51\uff08\u63a8\u8350\uff09 GitHub Gitee \u7801\u4e91 (\u955c\u50cf\u4ed3\u5e93) GitCode (\u955c\u50cf\u4ed3\u5e93) jsDelivr (CDN) \u817e\u8baf\u4e91 EO (CDN) <pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh)\n</code></pre> <pre><code>bash <(curl -sSL https://raw.githubusercontent.com/SuperManito/LinuxMirrors/main/DockerInstallation.sh)\n</code></pre> <pre><code>bash <(curl -sSL https://gitee.com/SuperManito/LinuxMirrors/raw/main/DockerInstallation.sh)\n</code></pre> <p>\u5b9e\u65f6\u540c\u6b65\u3001\u65e0\u5ef6\u8fdf\uff0c\u56fd\u5185\u7f51\u7edc\u73af\u5883\u4e0b\u63a8\u8350\u4f7f\u7528</p> <pre><code>bash <(curl -sSL https://raw.gitcode.com/SuperManito/LinuxMirrors/raw/main/DockerInstallation.sh)\n</code></pre> <p>\u540c\u6b65\u5b58\u57281\u5c0f\u65f6\u5ef6\u8fdf</p> <pre><code>bash <(curl -sSL https://cdn.jsdelivr.net/gh/SuperManito/LinuxMirrors@main/DockerInstallation.sh)\n</code></pre> <pre><code>bash <(curl -sSL https://edgeone.linuxmirrors.cn/docker.sh)\n</code></pre> <p>\u4e0d\u5efa\u8bae\u5728\u56fd\u5185\u7f51\u7edc\u73af\u5883\u4e0b\u4f7f\u7528</p> <p>\u96c6\u6210\u5b89\u88c5 <code>Docker Engine</code> \u548c <code>Docker Compose</code>\uff0c\u652f\u6301\u9009\u62e9\u6216\u66f4\u6362\u8f6f\u4ef6\u6e90\uff08Docker \u8f6f\u4ef6\u4ed3\u5e93\uff09\u4ee5\u53ca\u955c\u50cf\u4ed3\u5e93\u3001\u5b89\u88c5\u6307\u5b9a\u7248\u672c\u3001\u91cd\u88c5\u7b49\u529f\u80fd\uff0c\u652f\u6301 ARM \u67b6\u6784</p> <p>\u811a\u672c\u53c2\u8003\u5b98\u65b9\u6587\u6863\u4f7f\u7528\u7cfb\u7edf\u5305\u7ba1\u7406\u5de5\u5177\u8fdb\u884c\u5b89\u88c5\uff0c\u4e0d\u5b58\u5728\u517c\u5bb9\u6027\u3001\u5b89\u5168\u6027\u7b49\u95ee\u9898\uff0c\u53ef\u5b89\u88c5\u7684\u7248\u672c\u7531 Docker CE \u4ed3\u5e93\u51b3\u5b9a</p> \u5b98\u7f51\uff08\u63a8\u8350\uff09 GitHub Gitee \u7801\u4e91 (\u955c\u50cf\u4ed3\u5e93) GitCode (\u955c\u50cf\u4ed3\u5e93) jsDelivr (CDN) \u817e\u8baf\u4e91 EO (CDN) <pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --only-registry\n</code></pre> <pre><code>bash <(curl -sSL https://raw.githubusercontent.com/SuperManito/LinuxMirrors/main/DockerInstallation.sh) --only-registry\n</code></pre> <pre><code>bash <(curl -sSL https://gitee.com/SuperManito/LinuxMirrors/raw/main/DockerInstallation.sh) --only-registry\n</code></pre> <p>\u5b9e\u65f6\u540c\u6b65\u3001\u65e0\u5ef6\u8fdf\uff0c\u56fd\u5185\u7f51\u7edc\u73af\u5883\u4e0b\u63a8\u8350\u4f7f\u7528</p> <pre><code>bash <(curl -sSL https://raw.gitcode.com/SuperManito/LinuxMirrors/raw/main/DockerInstallation.sh) --only-registry\n</code></pre> <p>\u540c\u6b65\u5b58\u57281\u5c0f\u65f6\u5ef6\u8fdf</p> <pre><code>bash <(curl -sSL https://cdn.jsdelivr.net/gh/SuperManito/LinuxMirrors@main/DockerInstallation.sh) --only-registry\n</code></pre> <pre><code>bash <(curl -sSL https://edgeone.linuxmirrors.cn/docker.sh) --only-registry\n</code></pre> <p>\u4e0d\u5efa\u8bae\u5728\u56fd\u5185\u7f51\u7edc\u73af\u5883\u4e0b\u4f7f\u7528</p> <ul> <li> <p> \u5b8c\u5168\u66ff\u4ee3\u5b98\u65b9\u5b89\u88c5\u811a\u672c</p> <p>\u4e0e get.docker.com \u903b\u8f91\u4e00\u81f4\uff0c\u878d\u5408\u4e86\u672c\u9879\u76ee\u6362\u6e90\u67b6\u6784\u4ee5\u53ca\u7279\u6027</p> </li> <li> <p> \u652f\u6301\u56fd\u4ea7\u884d\u751f\u64cd\u4f5c\u7cfb\u7edf</p> <p>\u517c\u5bb9\u5927\u91cf\u4e0d\u53d7\u5b98\u65b9\u5b89\u88c5\u811a\u672c\u652f\u6301\u7684\u884d\u751f\u64cd\u4f5c\u7cfb\u7edf </p> </li> <li> <p> \u529f\u80fd\u5f3a\u5927\u3001\u65e0\u4e0e\u4f26\u6bd4</p> <p>\u5168\u7f51\u6700\u5b9e\u7528\u7684\u5f00\u6e90\u8fd0\u7ef4\u811a\u672c\u4e4b\u4e00\uff0c\u6027\u80fd\u5353\u8d8a</p> </li> <li> <p> \u7cbe\u5999\u7edd\u4f26\u7684\u4ea4\u4e92\u8bbe\u8ba1</p> <p>\u6613\u4e8e\u7406\u89e3\u548c\u4f7f\u7528\u7684\u4ea4\u4e92\u5f0f\u547d\u4ee4\u884c\u754c\u9762\uff0c\u9065\u9065\u9886\u5148</p> </li> </ul> <p>\u2728 \u7ecf\u8fc7\u4e86\u6570\u5e74\u7684\u6280\u672f\u6c89\u6dc0\u4e0e\u751f\u4ea7\u73af\u5883\u68c0\u9a8c\uff0c\u5e7f\u53d7\u793e\u533a\u597d\u8bc4\uff0c\u6df1\u5f97\u5f00\u53d1\u8005\u559c\u7231\uff0c\u5927\u5382\u90fd\u5728\u4f7f\u7528</p> <p></p> <p>Docker Compose \u4e0d\u518d\u9700\u8981\u72ec\u7acb\u5b89\u88c5</p> <p>Docker Compose \u81ea V2 \u7248\u672c\u8d77\u5f00\u59cb\u4f5c\u4e3a Docker CLI\uff08\u547d\u4ee4\u884c\uff09\u7684\u4e00\u90e8\u5206\uff0c\u811a\u672c\u9ed8\u8ba4\u96c6\u6210\u5b89\u88c5\u8be5\u63d2\u4ef6\uff0c\u8bf7\u4f7f\u7528 <code>docker compose</code> \u547d\u4ee4\u66ff\u4ee3 <code>docker-compose</code></p> <p>\u8f6f\u4ef6\u6e90\u8bf4\u660e</p> <ul> <li> <p>Docker CE \u8f6f\u4ef6\u4ed3\u5e93</p> <p>Docker CE \u5168\u79f0 Docker Community Edition\uff08Docker \u793e\u533a\u7248\uff09\uff0c\u662f Docker Engine \u7684\u522b\u79f0\uff0c\u8be5\u4ed3\u5e93\u7528\u4e8e\u4e0b\u8f7d\u5e76\u5b89\u88c5 Docker \u76f8\u5173\u8f6f\u4ef6\u5305</p> </li> <li> <p>Docker Registry \u955c\u50cf\u4ed3\u5e93</p> <p>\u7528\u4e8e\u63a7\u5236\u62c9\u53d6\u955c\u50cf\u7684\u9ed8\u8ba4\u6765\u6e90\u5b58\u50a8\u4ed3\u5e93\uff0c\u53c8\u79f0\u955c\u50cf\u52a0\u901f\u5668\uff0c\u9ed8\u8ba4\u4e3a\u5b98\u65b9\u5bb9\u5668\u955c\u50cf\u4ed3\u5e93 Docker Hub </p> </li> </ul> <p>\u7531\u4e8e\u4e00\u4e9b\u4e0d\u53ef\u6297\u529b\u7684\u56e0\u7d20\uff0c\u56fd\u5185\u7f51\u7edc\u73af\u5883\u4e0b\u76ee\u524d\u65e0\u6cd5\u8bbf\u95ee Docker Hub \u56e0\u6b64\u4e0d\u80fd\u6b63\u5e38\u62c9\u53d6\u955c\u50cf\uff0c\u5efa\u8bae\u4f7f\u7528\u4e0b\u65b9\u63d0\u5230\u7684\u56fd\u5185\u53ef\u7528\u955c\u50cf\u4ed3\u5e93\u6e90</p> <p>\u6ce8\uff1a\u811a\u672c\u5185\u7684\u6307\u5b9a Web \u534f\u8bae\u4ea4\u4e92\u4ec5\u7528\u4e8e\u63a7\u5236 <code>Docker CE</code> \u8f6f\u4ef6\u6e90\uff0c<code>Docker Registry</code> \u5f3a\u5236\u4f7f\u7528 <code>HTTPS</code> \u534f\u8bae</p> <p>\u5185\u7f6e\u7684\u955c\u50cf\u4ed3\u5e93\u6e90</p> <p> \u56fd\u5185\u53ef\u7528 \u7ad9\u70b9\u540d\u79f0 \u5730\u5740 \u8bf4\u660e \u6beb\u79d2\u955c\u50cf docker.1ms.run \u4f01\u4e1a\u955c\u50cf\u7ad9\uff0cCDN\u667a\u80fd\u5206\u53d1\u901f\u5ea6\u6781\u5feb\uff0c\u652f\u6301\u4ed8\u8d39\u5b9a\u5236\uff0c\u63a8\u8350\u4f7f\u7528 Docker Proxy dockerproxy.net \u7531 ghproxy \u521b\u5efa\uff0c\u53ef\u7528\u6027\u9ad8\u4f46\u901f\u5ea6\u5f88\u6162\uff0c\u652f\u6301\u4f01\u4e1a\u955c\u50cf\u4ed8\u8d39\u52a0\u901f DaoCloud \u9053\u5ba2 docker.m.daocloud.io \u8001\u724c\u4f01\u4e1a\u955c\u50cf\u7ad9\uff0c\u53ef\u7528\u6027\u9ad8\u4e14\u901f\u5ea6\u5feb\uff0c\u73b0\u4e3a\u767d\u540d\u5355\u6a21\u5f0f 1Panel \u955c\u50cf docker.1panel.live \u4f01\u4e1a\u4ea7\u54c1\u81ea\u7528\u955c\u50cf <p>\u672c\u5f00\u6e90\u9879\u76ee\u4e0d\u9002\u5408\u91c7\u96c6\u4e2a\u4eba\u81ea\u5efa\u7684\u955c\u50cf\u52a0\u901f\u5668\uff0c\u5982\u6709\u9700\u8981\u53ef\u642d\u914d\u547d\u4ee4\u9009\u9879\u81ea\u884c\u4f7f\u7528</p> <p>\u5176\u5b83</p> \u7ad9\u70b9\u540d\u79f0 \u5730\u5740 \u7ad9\u70b9\u540d\u79f0 \u5730\u5740 \u963f\u91cc\u4e91\uff08\u676d\u5dde\uff09 registry.cn-hangzhou.aliyuncs.com \u963f\u91cc\u4e91\uff08\u65e5\u672c-\u4e1c\u4eac\uff09 registry.ap-northeast-1.aliyuncs.com \u963f\u91cc\u4e91\uff08\u4e0a\u6d77\uff09 registry.cn-shanghai.aliyuncs.com \u963f\u91cc\u4e91\uff08\u65b0\u52a0\u5761\uff09 registry.ap-southeast-1.aliyuncs.com \u963f\u91cc\u4e91\uff08\u9752\u5c9b\uff09 registry.cn-qingdao.aliyuncs.com \u963f\u91cc\u4e91\uff08\u9a6c\u6765\u897f\u4e9a-\u5409\u9686\u5761\uff09 registry.ap-southeast-3.aliyuncs.com \u963f\u91cc\u4e91\uff08\u5317\u4eac\uff09 registry.cn-beijing.aliyuncs.com \u963f\u91cc\u4e91\uff08\u5370\u5ea6\u5c3c\u897f\u4e9a-\u96c5\u52a0\u8fbe\uff09 registry.ap-southeast-5.aliyuncs.com \u963f\u91cc\u4e91\uff08\u5f20\u5bb6\u53e3\uff09 registry.cn-zhangjiakou.aliyuncs.com \u963f\u91cc\u4e91\uff08\u5fb7\u56fd-\u6cd5\u5170\u514b\u798f\uff09 registry.eu-central-1.aliyuncs.com \u963f\u91cc\u4e91\uff08\u547c\u548c\u6d69\u7279\uff09 registry.cn-huhehaote.aliyuncs.com \u963f\u91cc\u4e91\uff08\u82f1\u56fd-\u4f26\u6566\uff09 registry.eu-west-1.aliyuncs.com \u963f\u91cc\u4e91\uff08\u4e4c\u5170\u5bdf\u5e03\uff09 registry.cn-wulanchabu.aliyuncs.com \u963f\u91cc\u4e91\uff08\u7f8e\u56fd\u897f\u90e8-\u7845\u8c37\uff09 registry.us-west-1.aliyuncs.com \u963f\u91cc\u4e91\uff08\u6df1\u5733\uff09 registry.cn-shenzhen.aliyuncs.com \u963f\u91cc\u4e91\uff08\u7f8e\u56fd\u4e1c\u90e8-\u5f17\u5409\u5c3c\u4e9a\uff09 registry.us-east-1.aliyuncs.com \u963f\u91cc\u4e91\uff08\u6cb3\u6e90\uff09 registry.cn-heyuan.aliyuncs.com \u963f\u91cc\u4e91\uff08\u963f\u8054\u914b-\u8fea\u62dc\uff09 registry.me-east-1.aliyuncs.com \u963f\u91cc\u4e91\uff08\u5e7f\u5dde\uff09 registry.cn-guangzhou.aliyuncs.com \u8c37\u6b4c\u4e91\uff08\u5317\u7f8e\uff09 gcr.io \u963f\u91cc\u4e91\uff08\u6210\u90fd\uff09 registry.cn-chengdu.aliyuncs.com \u8c37\u6b4c\u4e91\uff08\u4e9a\u6d32\uff09 asia.gcr.io \u963f\u91cc\u4e91\uff08\u9999\u6e2f\uff09 registry.cn-hongkong.aliyuncs.com \u8c37\u6b4c\u4e91\uff08\u6b27\u6d32\uff09 eu.gcr.io \u817e\u8baf\u4e91 mirror.ccs.tencentyun.com Docker Hub registry.hub.docker.com <p>\u6ce8\uff1a\u56fd\u5185\u4e91\u8ba1\u7b97\u4f01\u4e1a\u7684\u955c\u50cf\u4ed3\u5e93\u6e90\u4ec5\u9488\u5bf9\u5176\u4e1a\u52a1\uff0c\u5883\u5185\u5b9e\u4f8b\u53ef\u80fd\u4ecd\u65e0\u6cd5\u8bbf\u95ee Docker Hub</p>"},{"location":"other/#\u547d\u4ee4\u9009\u9879\u9ad8\u7ea7\u7528\u6cd5","title":"\u547d\u4ee4\u9009\u9879\uff08\u9ad8\u7ea7\u7528\u6cd5\uff09","text":"bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --help \u547d\u4ee4\u9009\u9879(\u540d\u79f0/\u542b\u4e49/\u503c)\uff1a --source \u6307\u5b9a Docker CE \u8f6f\u4ef6\u6e90\u5730\u5740(\u57df\u540d\u6216IP) \u5730\u5740 --source-registry \u6307\u5b9a Docker \u955c\u50cf\u4ed3\u5e93\u5730\u5740(\u57df\u540d\u6216IP) \u5730\u5740 --branch \u6307\u5b9a Docker CE \u8f6f\u4ef6\u6e90\u4ed3\u5e93(\u8def\u5f84) \u4ed3\u5e93\u540d --branch-version \u6307\u5b9a Docker CE \u8f6f\u4ef6\u6e90\u4ed3\u5e93\u7248\u672c \u7248\u672c\u53f7 --designated-version \u6307\u5b9a Docker Engine \u5b89\u88c5\u7248\u672c \u7248\u672c\u53f7 --codename \u6307\u5b9a Debian \u7cfb\u64cd\u4f5c\u7cfb\u7edf\u7684\u7248\u672c\u4ee3\u53f7 \u4ee3\u53f7\u540d\u79f0 --protocol \u6307\u5b9a Docker CE \u8f6f\u4ef6\u6e90\u7684 Web \u534f\u8bae http \u6216 https --use-intranet-source \u662f\u5426\u4f18\u5148\u4f7f\u7528\u5185\u7f51 Docker CE \u8f6f\u4ef6\u6e90\u5730\u5740 true \u6216 false --install-latest \u662f\u5426\u5b89\u88c5\u6700\u65b0\u7248\u672c\u7684 Docker Engine true \u6216 false --close-firewall \u662f\u5426\u5173\u95ed\u9632\u706b\u5899 true \u6216 false --clean-screen \u662f\u5426\u5728\u8fd0\u884c\u524d\u6e05\u9664\u5c4f\u5e55\u4e0a\u7684\u6240\u6709\u5185\u5bb9 true \u6216 false --lang \u6307\u5b9a\u811a\u672c\u8f93\u51fa\u7684\u8bed\u8a00 \u8bed\u8a00 --only-registry \u4ec5\u66f4\u6362\u955c\u50cf\u4ed3\u5e93\u6a21\u5f0f \u65e0 --ignore-backup-tips \u5ffd\u7565\u8986\u76d6\u5907\u4efd\u63d0\u793a \u65e0 --pure-mode \u7eaf\u51c0\u6a21\u5f0f\uff0c\u7cbe\u7b80\u6253\u5370\u5185\u5bb9 \u65e0 --help \u67e5\u770b\u5e2e\u52a9\u83dc\u5355 \u65e0 \u540d\u79f0 \u542b\u4e49 \u9009\u9879\u503c <code>--source</code> \u6307\u5b9a <code>Docker CE</code> \u6e90\u5730\u5740(\u57df\u540d\u6216IP) <code>\u5730\u5740</code> <code>--source-registry</code> \u6307\u5b9a <code>Docker</code> \u955c\u50cf\u4ed3\u5e93\u5730\u5740(\u57df\u540d\u6216IP) <code>\u5730\u5740\uff08\u591a\u4e2a\u7528\u82f1\u6587\u9017\u53f7\u5206\u5272\uff09</code> <code>--branch</code> \u6307\u5b9a <code>Docker CE</code> \u8f6f\u4ef6\u6e90\u4ed3\u5e93(\u8def\u5f84) <code>\u4ed3\u5e93\u540d\uff08\u8be6\u89c1\u4e0b\u65b9\u6587\u6863\uff09</code> <code>--branch-version</code> \u6307\u5b9a <code>Docker CE</code> \u8f6f\u4ef6\u6e90\u4ed3\u5e93\u7248\u672c <code>\u7248\u672c\u53f7\uff08\u8be6\u89c1\u4e0b\u65b9\u6587\u6863\uff09</code> <code>--designated-version</code> \u6307\u5b9a <code>Docker Engine</code> \u5b89\u88c5\u7248\u672c <code>\u7248\u672c\u53f7\uff08\u8be6\u89c1\u4e0b\u65b9\u6587\u6863\uff09</code> <code>--codename</code> \u6307\u5b9a <code>Debian</code> \u7cfb\u64cd\u4f5c\u7cfb\u7edf\u7684\u7248\u672c\u4ee3\u53f7 <code>\u4ee3\u53f7\u540d\u79f0</code> <code>--protocol</code> \u6307\u5b9a <code>Docker CE</code> \u6e90\u7684 Web \u534f\u8bae <code>http</code> \u6216 <code>https</code> <code>--use-intranet-source</code> \u662f\u5426\u4f18\u5148\u4f7f\u7528\u5185\u7f51 <code>Docker CE</code> \u8f6f\u4ef6\u6e90\u5730\u5740 <code>true</code> \u6216 <code>false</code> <code>--install-latest</code> \u662f\u5426\u5b89\u88c5\u6700\u65b0\u7248\u672c\u7684 <code>Docker Engine</code> <code>true</code> \u6216 <code>false</code> <code>--close-firewall</code> \u662f\u5426\u5173\u95ed\u9632\u706b\u5899 <code>true</code> \u6216 <code>false</code> <code>--clean-screen</code> \u662f\u5426\u5728\u8fd0\u884c\u524d\u6e05\u9664\u5c4f\u5e55\u4e0a\u7684\u6240\u6709\u5185\u5bb9 <code>true</code> \u6216 <code>false</code> <code>--lang</code> \u6307\u5b9a\u811a\u672c\u8f93\u51fa\u7684\u8bed\u8a00 <code>\u8bed\u8a00ID\uff08\u8be6\u89c1\u4e0b\u65b9\u6587\u6863\uff09</code> <code>--only-registry</code> \u4ec5\u66f4\u6362\u955c\u50cf\u4ed3\u5e93\u6a21\u5f0f \u65e0 <code>--ignore-backup-tips</code> \u5ffd\u7565\u8986\u76d6\u5907\u4efd\u63d0\u793a\uff08\u5373\u4e0d\u8986\u76d6\u5907\u4efd\uff09 \u65e0 <code>--pure-mode</code> \u7eaf\u51c0\u6a21\u5f0f\uff0c\u7cbe\u7b80\u6253\u5370\u5185\u5bb9 \u65e0 <code>--help</code> \u67e5\u770b\u5e2e\u52a9\u83dc\u5355 \u65e0 <p>\u8f6f\u4ef6\u6e90\u5b8c\u6574\u683c\u5f0f <code><WEB\u534f\u8bae>://<\u8f6f\u4ef6\u6e90\u5730\u5740(\u57df\u540d\u6216IP)>/<\u8f6f\u4ef6\u6e90\u4ed3\u5e93(\u8def\u5f84)></code></p>"},{"location":"other/#\u6307\u5b9a\u955c\u50cf\u4ed3\u5e93\u5730\u5740","title":"\u6307\u5b9a\u955c\u50cf\u4ed3\u5e93\u5730\u5740","text":"<pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --source-registry registry.example.com\n</code></pre> <p>\u53ef\u4ee5\u540c\u65f6\u6307\u5b9a\u591a\u4e2a\u5730\u5740\uff0c\u9700\u4f7f\u7528\u82f1\u6587\u9017\u53f7\u8fdb\u884c\u5206\u5272</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) \\\n --source-registry \"registry-1.example.com,registry-2.example.com\"\n</code></pre>"},{"location":"other/#\u4ec5\u66f4\u6362\u955c\u50cf\u4ed3\u5e93","title":"\u4ec5\u66f4\u6362\u955c\u50cf\u4ed3\u5e93","text":"\u4f7f\u7528\u811a\u672c\u4e00\u952e\u66ff\u6362\u624b\u52a8\u66ff\u6362 <p>\u4ec5\u66f4\u6362\u955c\u50cf\u52a0\u901f\u5668\uff0c\u5f53\u68c0\u6d4b\u5230\u672a\u5b89\u88c5 Docker \u65f6\u4f1a\u62a5\u9519\u8df3\u51fa</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --only-registry\n</code></pre> <p>\u61d2\u4eba\u4e00\u952e\u547d\u4ee4\uff08\u4f7f\u7528\u591a\u4e2a\u5730\u5740\uff09</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) \\\n --only-registry \\\n --source-registry \"docker.1ms.run,docker.1panel.live,docker.m.daocloud.io\"\n</code></pre> <p>\u9009\u9879\u503c\u53ef\u4ee5\u6307\u5b9a\u591a\u4e2a\u5730\u5740\uff0c\u9700\u4f7f\u7528\u82f1\u6587\u9017\u53f7\u8fdb\u884c\u5206\u5272</p> <ul> <li> <p>\u5b89\u88c5 <code>jq</code> \u8f6f\u4ef6\u5305</p> Debian \u7cfb / openKylinRedHat \u7cfb / openEuler / OpenCloudOS / Anolis OS <pre><code>apt-get install -y jq\n</code></pre> <p><code>Debian</code> <code>Ubuntu</code> <code>Kali</code> <code>Linux Mint</code> <code>Deepin</code> <code>Zorin OS</code> <code>Armbian</code> <code>Proxmox VE</code> <code>Raspberry Pi OS</code> <code>openKylin</code></p> <p>\u65b0\u88c5\u7cfb\u7edf\u9700\u8981\u5148\u6267\u884c\u4e00\u904d\u66f4\u65b0 <code>apt-get update</code></p> <pre><code>dnf install -y jq || yum install -y jq\n</code></pre> <p><code>Red Hat Enterprise Linux</code> <code>CentOS</code> <code>Rocky Linux</code> <code>AlmaLinux</code> <code>Fedora</code> <code>openEuler</code> <code>OpenCloudOS</code> <code>Anolis OS</code></p> </li> <li> <p>\u6307\u5b9a\u955c\u50cf\u4ed3\u5e93\u5730\u5740</p> <p>\u8bf7\u624b\u52a8\u66ff\u6362 <code><example.registry.com></code> \u4e3a\u955c\u50cf\u4ed3\u5e93\u5730\u5740\u540e\u5728\u6267\u884c\uff0c\u8be6\u89c1\u4e0a\u65b9 \u201c\u9879\u76ee\u5185\u7f6e\u7684\u955c\u50cf\u4ed3\u5e93\u6e90\u201d \u8868\u683c\u4e2d\u7684\u5730\u5740\u5217</p> <p><pre><code>SOURCE_REGISTRY='\"https://<example.registry.com>\"'\n</code></pre> \u8fd8\u53ef\u4ee5\u6307\u5b9a\u591a\u4e2a\u955c\u50cf\u4ed3\u5e93\uff0c\u5982 <code>SOURCE_REGISTRY='\"https://example.registry.com\",\"https://test.registry.com\"'</code>\uff0c\u6ce8\u610f\u7528\u82f1\u6587\u9017\u53f7\u5206\u5272</p> </li> <li> <p>\u66ff\u6362\u955c\u50cf\u4ed3\u5e93\u5730\u5740</p> <pre><code>[ -s \"/etc/docker/daemon.json\" ] || echo \"{}\" >/etc/docker/daemon.json\njq '.[\"registry-mirrors\"] = ['\"${SOURCE_REGISTRY}\"']' /etc/docker/daemon.json >/etc/docker/daemon.json.tmp && mv /etc/docker/daemon.json.tmp\n</code></pre> </li> <li> <p>\u91cd\u542f Docker \u670d\u52a1</p> <pre><code>systemctl daemon-reload\n[[ $(systemctl is-active docker) == \"active\" ]] && systemctl restart docker || systemctl enable --now docker\n</code></pre> </li> </ul>"},{"location":"other/#\u6307\u5b9a-docker-ce-\u8f6f\u4ef6\u6e90\u5730\u5740","title":"\u6307\u5b9a Docker CE \u8f6f\u4ef6\u6e90\u5730\u5740","text":"<pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --source mirror.example.com/docker-ce\n</code></pre> <p>\u6ce8\u610f\u8be5\u5730\u5740\u8def\u5f84\u9700\u8981\u5305\u542b\u955c\u50cf\u7ad9\u7684 Docker CE \u8f6f\u4ef6\u6e90\u4ed3\u5e93\u8def\u5f84\u5373 <code>docker-ce</code></p>"},{"location":"other/#\u6307\u5b9a-docker-ce-\u8f6f\u4ef6\u6e90\u4ed3\u5e93","title":"\u6307\u5b9a Docker CE \u8f6f\u4ef6\u6e90\u4ed3\u5e93","text":"<p>\u811a\u672c\u9ed8\u8ba4\u4f1a\u81ea\u52a8\u5224\u65ad\u4e00\u822c\u65e0\u9700\u6307\u5b9a\uff0c\u9664\u975e\u4f60\u6709\u7279\u6b8a\u9700\u6c42</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --branch centos\n</code></pre> <p>\u4ed3\u5e93\u540d\u662f\u56fa\u5b9a\u7684\uff0c\u76ee\u524d\u53ea\u6709 <code>centos</code> <code>debian</code> <code>fedora</code> <code>raspbian</code> <code>rhel</code> <code>sles</code> <code>static</code> <code>ubuntu</code> \u8fd9\u51e0\u4e2a \u5177\u4f53\u8be6\u89c1 \u5b98\u65b9\u5b89\u88c5\u6587\u6863 \u548c Docker CE \u5b98\u65b9\u4ed3\u5e93</p> \u8fd8\u53ef\u4ee5\u6307\u5b9a\u4ed3\u5e93\u7248\u672c\u53f7<pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) \\\n --branch centos \\\n --branch-version 9\n</code></pre> <p>\u53ef\u4ee5\u4f7f\u7528\u8be5\u9009\u9879\u6765\u63a7\u5236\u5b89\u88c5\u8f6f\u4ef6\u5305\u7684\u517c\u5bb9\u6027\uff08\u4ec5\u9002\u7528\u4e8e\u7ea2\u5e3d\u7cfb\u64cd\u4f5c\u7cfb\u7edf\uff09\uff0c\u5177\u4f53\u8be6\u89c1\u5bf9\u5e94\u4ed3\u5e93\u76ee\u5f55\u4e2d\u4ee3\u8868\u7248\u672c\u53f7\u7684\u8def\u5f84\u540d\u79f0\uff08\u6b63\u6574\u6570\uff09\u3002</p>"},{"location":"other/#\u6307\u5b9a-docker-engine-\u5b89\u88c5\u7248\u672c","title":"\u6307\u5b9a Docker Engine \u5b89\u88c5\u7248\u672c","text":"<p>\u6307\u5b9a\u5b89\u88c5\u7248\u672c\u65f6\u4f1a\u5ffd\u7565 <code>\u662f\u5426\u5b89\u88c5\u6700\u65b0\u7248\u672c</code> \u7684\u547d\u4ee4\u9009\u9879\uff0c\u683c\u5f0f\u4e3a <code>\u4e3b\u7248\u672c.\u6b21\u7248\u672c.\u8865\u4e01\u7248\u672c</code>\uff0c\u4f8b\u5982 <code>28.4.1</code>\u3002</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --designated-version 28.0.0\n</code></pre> <p>\u5982\u679c\u6307\u5b9a\u7684\u7248\u672c\u4e0d\u5b58\u5728\u6216\u8005\u4e0d\u652f\u6301\u5f53\u524d\u7cfb\u7edf\uff0c\u5c4a\u65f6\u811a\u672c\u4f1a\u62a5\u9519\u8df3\u51fa</p> \u67e5\u770b\u7248\u672c\u5217\u8868\u7684\u65b9\u6cd5 Debian \u7cfbRedHat \u7cfb / openEuler / OpenCloudOS / Anolis OS <pre><code>apt-cache madison docker-ce | awk '{print $3}' | grep -Eo \"[0-9][0-9].[0-9]{1,2}.[0-9]{1,2}\" | sort -t '.' -k1,1nr -k2,2nr -k3,3nr\n</code></pre> <p><code>Debian</code> <code>Ubuntu</code> <code>Kali</code> <code>Linux Mint</code> <code>Deepin</code> <code>Zorin OS</code> <code>Armbian</code> <code>Proxmox VE</code> <code>Raspberry Pi OS</code></p> <pre><code>dnf list docker-ce --showduplicates | sort -r | awk '{print $2}' | grep -Eo \"[0-9][0-9].[0-9]{1,2}.[0-9]{1,2}\" | sort -t '.' -k1,1nr -k2,2nr -k3,3nr\n</code></pre> <p><code>Red Hat Enterprise Linux</code> <code>CentOS</code> <code>Rocky Linux</code> <code>AlmaLinux</code> <code>Fedora</code> <code>openEuler</code> <code>OpenCloudOS</code> <code>Anolis OS</code></p> <p>\u672a\u51fa\u73b0\u5728\u8be5\u5217\u8868\u4e2d\u7684\u7248\u672c\u5219\u4e0d\u652f\u6301\u901a\u8fc7\u672c\u811a\u672c\u5b89\u88c5\uff0c\u5982\u679c\u83b7\u53d6\u4e0d\u5230\u7248\u672c\u5217\u8868\u8bf4\u660e\u4f60\u5f53\u524d\u7684\u7cfb\u7edf\u73af\u5883\u8fd8\u6ca1\u6709\u6b63\u786e\u914d\u7f6e Docker CE \u8f6f\u4ef6\u6e90\uff08\u8fd0\u884c\u811a\u672c\u65f6\u4e0d\u5b58\u5728\u8be5\u95ee\u9898\uff09</p>"},{"location":"other/#\u56fd\u9645\u5316i18n","title":"\u56fd\u9645\u5316\uff08I18n\uff09","text":"<p>\u811a\u672c\u63d0\u4f9b\u591a\u8bed\u8a00\u652f\u6301\uff0c\u5f53\u524d\u5185\u7f6e <code>\u7b80\u4f53\u4e2d\u6587</code>\u3001<code>\u7e41\u9ad4\u4e2d\u6587</code>\u3001<code>English</code> \u5171\u4e09\u79cd\u663e\u793a\u8bed\u8a00\uff0c\u9ed8\u8ba4\u4e3a <code>\u7b80\u4f53\u4e2d\u6587</code></p>"},{"location":"other/#\u6307\u5b9a\u8bed\u8a00","title":"\u6307\u5b9a\u8bed\u8a00","text":"<pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --lang xxx\n</code></pre> \u7c7b\u578b \u503c \u7b80\u4f53\u4e2d\u6587 <code>zh-hans</code> <code>zh-cn</code> <code>zh</code> \u7e41\u9ad4\u4e2d\u6587 <code>zh-hant</code> <code>zh-tw</code> <code>zh-hk</code> English <code>en</code> <code>en-us</code> <p>\u4e5f\u53ef\u4ee5\u76f4\u63a5\u4f5c\u4e3a\u547d\u4ee4\u9009\u9879\u4f7f\u7528</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --en\n</code></pre> <p><code>--en</code> <code>--en-us</code> <code>--zh</code> <code>--zh-cn</code> <code>--zh-hans</code> <code>--zh-hant</code></p>"},{"location":"other/#\u901a\u8fc7\u4ea4\u4e92\u8fdb\u884c\u9009\u62e9","title":"\u901a\u8fc7\u4ea4\u4e92\u8fdb\u884c\u9009\u62e9","text":"<pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --lang auto\n</code></pre>"},{"location":"other/#\u65e0\u4eba\u503c\u5b88\u81ea\u52a8\u5316","title":"\u65e0\u4eba\u503c\u5b88\uff08\u81ea\u52a8\u5316\uff09","text":"<p>\u4e0d\u901a\u8fc7\u4ea4\u4e92\u5b8c\u6210\u5b89\u88c5\u64cd\u4f5c\uff0c\u81f3\u5c11\u9700\u8981\u4f7f\u7528\u5982\u4e0b\u547d\u4ee4\u9009\u9879\u6765\u5b9e\u73b0\uff0c\u5efa\u8bae\u719f\u6089\u540e\u518d\u4f7f\u7528</p> \u53c2\u8003\u547d\u4ee4<pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) \\\n --source mirror.example.com/docker-ce \\\n --source-registry registry.hub.docker.com \\\n --protocol http \\\n --use-intranet-source false \\\n --install-latest true \\\n --close-firewall true \\\n --ignore-backup-tips\n</code></pre> <p>\u5982\u679c\u62a5\u9519 <code>\u547d\u4ee4\u9009\u9879\u65e0\u6548</code> \u90a3\u4e48\u8bf7\u68c0\u67e5\u9009\u9879\u5408\u6cd5\u6027\u4ee5\u53ca\u7a7a\u683c\u5b57\u7b26\u7f16\u7801\uff0c\u5728\u793a\u4f8b\u4e2d\u4e00\u884c\u5199\u4e00\u4e2a\u9009\u9879\u662f\u4e3a\u4e86\u63d0\u9ad8\u547d\u4ee4\u7684\u53ef\u8bfb\u6027</p>"},{"location":"other/#\u7eaf\u51c0\u6a21\u5f0f","title":"\u7eaf\u51c0\u6a21\u5f0f","text":"<p>\u63a8\u51fa\u8be5\u529f\u80fd\u662f\u4e3a\u4e86\u4fbf\u4e8e\u5f00\u53d1\u4ee5\u53ca\u8fd0\u7ef4\u4eba\u5458\u4f7f\u7528\uff0c\u542f\u7528\u540e\u4f1a\u7cbe\u7b80\u811a\u672c\u5185\u5bb9\u8f93\u51fa\uff0c\u5efa\u8bae\u642d\u914d\u5176\u5b83\u547d\u4ee4\u9009\u9879\u65e0\u4ea4\u4e92\u4f7f\u7528</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --pure-mode\n</code></pre> <p>\u6eda\u52a8\u8f93\u51fa\u7684\u547d\u4ee4\u65e5\u5fd7\u53ef\u80fd\u5b58\u5728\u65e0\u6cd5\u9884\u6599\u7684\u663e\u793a\u95ee\u9898\uff0c\u4e0d\u8fc7\u76ee\u524d\u6682\u672a\u53d1\u73b0\u5f02\u5e38</p>"},{"location":"other/#\u5e38\u89c1\u95ee\u9898","title":"\u5e38\u89c1\u95ee\u9898","text":""},{"location":"other/#\u5173\u4e8e\u670d\u52a1\u62a5\u9519\u65e0\u6cd5\u542f\u52a8","title":"\u5173\u4e8e\u670d\u52a1\u62a5\u9519\u65e0\u6cd5\u542f\u52a8","text":"<p>\u975e\u65b0\u88c5\u73af\u5883\u53ef\u80fd\u4f1a\u5728\u8fd0\u884c\u811a\u672c\u540e\u9047\u5230 <code>Docker</code> \u670d\u52a1\u65e0\u6cd5\u542f\u52a8\u7684\u60c5\u51b5\uff0c\u5efa\u8bae\u91cd\u65b0\u5b89\u88c5\u6765\u89e3\u51b3\uff0c\u5378\u8f7d\u4e0d\u4f1a\u5220\u9664\u672c\u5730\u955c\u50cf\u548c\u5bb9\u5668\u6570\u636e</p> <p>\u5378\u8f7d\u547d\u4ee4\u5982\u4e0b\uff1a</p> Debian \u7cfbRedHat \u7cfb / openEuler / OpenCloudOS / Anolis OS <pre><code>apt-get remove -y docker* containerd.io runc && apt-get autoremove\n</code></pre> <p><code>Debian</code> <code>Ubuntu</code> <code>Kali</code> <code>Linux Mint</code> <code>Deepin</code> <code>Zorin OS</code> <code>Armbian</code> <code>Proxmox VE</code> <code>Raspberry Pi OS</code></p> <pre><code>yum remove -y docker* containerd.io podman* runc\n</code></pre> <p><code>Red Hat Enterprise Linux</code> <code>CentOS</code> <code>Rocky Linux</code> <code>AlmaLinux</code> <code>Fedora</code> <code>openEuler</code> <code>OpenCloudOS</code> <code>Anolis OS</code></p> <p>\u5378\u8f7d\u5b8c\u6210\u540e\u91cd\u65b0\u6267\u884c\u811a\u672c\u5b89\u88c5\u5373\u53ef</p>"},{"location":"other/#\u5173\u4e8e\u4e0d\u652f\u6301\u7684\u64cd\u4f5c\u7cfb\u7edf","title":"\u5173\u4e8e\u4e0d\u652f\u6301\u7684\u64cd\u4f5c\u7cfb\u7edf","text":"<p>\u5982\u679c\u63d0\u793a\u4e0d\u652f\u6301\u90a3\u4e48\u8bf7\u4f7f\u7528\u7cfb\u7edf\u81ea\u5e26\u7684\u5305\u7ba1\u7406\u5de5\u5177\u8fdb\u884c\u5b89\u88c5\u3002\u56e0\u4e3a\u8fd9\u4e9b\u8f6f\u4ef6\u5305\u7531 Linux \u53d1\u884c\u7248\u7684\u8f6f\u4ef6\u5305\u7ef4\u62a4\u8005\u6784\u5efa\u548c\u7ef4\u62a4\uff0c\u53ef\u80fd\u5b58\u5728\u914d\u7f6e\u5dee\u5f02\u6216\u7531\u4fee\u6539\u540e\u7684\u6e90\u4ee3\u7801\u6784\u5efa\u3002</p> <p>\u4e5f\u53ef\u4ee5\u4f7f\u7528 \u00a0 </p>"},{"location":"other/#\u7cbe\u7b80\u7248lite","title":"\u7cbe\u7b80\u7248\uff08Lite\uff09","text":"<p>\u9879\u76ee\u989d\u5916\u63d0\u4f9b\u4e00\u4e2a\u7cbe\u7b80\u7248\u672c\uff0c\u662f\u4e3b\u811a\u672c\u7684\u590d\u5236\uff0c\u9762\u5411\u4f01\u4e1a\u4ea7\u54c1\u3001\u5927\u578b\u5f00\u6e90\u793e\u533a\u9879\u76ee\u4f7f\u7528\uff0c\u5177\u6709\u4ee5\u4e0b\u7279\u6027\uff1a</p> <ul> <li>\u5355\u4e00\u663e\u793a\u8bed\u8a00 <code>English</code>\uff0c\u65e0 I18n \u56fd\u9645\u5316\u529f\u80fd</li> <li>\u9ed8\u8ba4\u4f7f\u7528\u5b98\u65b9\u6e90\uff0c\u53bb\u9664\u4e86\u4ea4\u4e92\u9009\u62e9\u5185\u7f6e\u8f6f\u4ef6\u6e90\u529f\u80fd</li> <li>\u53bb\u9664\u4e86\u65e0\u5173\u7684\u6253\u5370\u5185\u5bb9</li> <li>\u4fdd\u7559\u6838\u5fc3\u903b\u8f91\u4e0e\u547d\u4ee4\u9009\u9879\u8bbe\u8ba1</li> </ul> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker-lite.sh)\n</code></pre> <p>\u8bf7\u719f\u6089\u672c\u9879\u76ee\u540e\u518d\u4f7f\u7528\uff0c\u4e0d\u5efa\u8bae\u65b0\u624b\u7528\u6237\u4f7f\u7528</p>"},{"location":"other/#\u6700\u4f73\u5b9e\u8df5","title":"\u6700\u4f73\u5b9e\u8df5","text":"\u9002\u7528\u4e8e\u4f01\u4e1a\u4ea7\u54c1\u90e8\u7f72\u4ee5\u53ca CI/CD \u7b49\u81ea\u52a8\u5316\u8fd0\u7ef4\u573a\u666f\u7684\u4ee3\u7801\u793a\u4f8b\uff08\u5c55\u5f00\u67e5\u770b\uff09 <p>\u5982\u679c\u4f60\u4e0d\u60f3\u8ba9\u7528\u6237\u8fdb\u884c\u4efb\u4f55\u4ea4\u4e92\uff0c\u8bf7\u4f7f\u7528 <code>\u5b8c\u5168\u81ea\u52a8\u5316</code> \u793a\u4f8b</p>"},{"location":"other/#\u5b8c\u5168\u81ea\u52a8\u5316\u63a8\u8350","title":"\u5b8c\u5168\u81ea\u52a8\u5316\uff08\u63a8\u8350\uff09","text":"<pre><code># !/bin/bash\nfunction install_docker() {\n if command -v docker &>/dev/null; then\n return\n fi\n\n # script options\n local script_host=\"linuxmirrors.cn\" # official host (CDN), more host see official site\n local close_firewall=\"true\" # close firewalld service and selinux (redhat systems need)\n # mirrors options\n local source_docker_ce_address=\"mirrors.tencent.com/docker-ce\" # global high availability address\n local source_docker_ce_protocol=\"https\" # https or http\n local source_docker_registry_address=\"registry.hub.docker.com\"\n\n # judge network environment\n local region_code=\"$(curl -s ipinfo.io/country)\"\n if [[ \"${region_code}\" == \"CN\" ]]; then\n local source_intranet_address=\"\"\n # use intranet source if possible\n if [ -s \"/sys/class/dmi/id/sys_vendor\" ]; then\n local sys_vendor=\"$(cat /sys/class/dmi/id/sys_vendor)\"\n if [[ \"${sys_vendor}\" == *\"Alibaba\"* ]]; then\n source_intranet_address=\"mirrors.cloud.aliyuncs.com/docker-ce\"\n elif [[ \"${sys_vendor}\" == *\"Huawei\"* ]]; then\n source_intranet_address=\"mirrors.myhuaweicloud.com/docker-ce\"\n elif [[ \"${sys_vendor}\" == *\"Tencent\"* ]]; then\n source_intranet_address=\"mirrors.tencentyun.com/docker-ce\"\n elif [[ \"${sys_vendor}\" == *\"Inspur\"* ]]; then\n source_intranet_address=\"mirrors.ivolces.com/docker-ce\"\n fi\n else\n cat /etc/motd | grep \"Alibaba Cloud \" -q\n if [ $? -eq 0 ]; then\n source_intranet_address=\"mirrors.cloud.aliyuncs.com/docker-ce\"\n fi\n fi\n # check connectivity\n if [ -n \"${source_intranet_address}\" ]; then\n if ping -c1 -W1 \"${source_intranet_address%%/*}\" >/dev/null 2>&1; then\n source_docker_ce_address=\"${source_intranet_address}\"\n source_docker_ce_protocol=\"http\"\n fi\n fi\n # registry mirror (best choice for Chinese mainland)\n source_docker_registry_address=\"docker.1ms.run\"\n else\n # use official source\n source_docker_ce_address=\"download.docker.com\"\n source_docker_registry_address=\"registry.hub.docker.com\"\n fi\n\n # install docker engine\n bash <(curl -sSL https://${script_host}/docker-lite.sh) \\\n --source \"${source_docker_ce_address}\" \\\n --source-registry \"${source_docker_registry_address}\" \\\n --protocol \"${source_docker_ce_protocol}\" \\\n --close-firewall \"${close_firewall}\"\n}\n\ninstall_docker\n</code></pre>"},{"location":"other/#\u7b80\u6613\u65b9\u5f0f","title":"\u7b80\u6613\u65b9\u5f0f","text":"<pre><code># !/bin/bash\nfunction install_docker() {\n if command -v docker &>/dev/null; then\n return\n fi\n\n bash <(curl -sSL https://${script_host}/docker.sh) \\\n --install-latest true \\\n --ignore-backup-tips \\\n --lang auto\n\n if command -v docker &>/dev/null; then\n echo -e \"\\n# Docker installation successful.\\n# Please run this script again manually after installation.\"\n exit 0\n else\n echo -e \"\\n# Docker installation failed.\\n# Please check the error message above.\"\n exit 1\n fi\n}\n\ninstall_docker\n</code></pre> <p>\u6ce8\uff1a\u4e0d\u6307\u5b9a <code>Docker CE \u6e90</code> \u4ee5\u53ca <code>\u955c\u50cf\u4ed3\u5e93\u6e90</code> \u5219\u4f1a\u4ea4\u7531\u7528\u6237\u8fdb\u884c\u4ea4\u4e92\u9009\u62e9\uff0c\u5c4a\u65f6\u4f1a\u81ea\u52a8\u6e05\u5c4f <code>$ clear</code>\uff0c\u4ece\u800c\u5bfc\u81f4\u4f60\u811a\u672c\u7684\u8fd0\u884c\u65e5\u5fd7\u88ab\u6e05\u9664</p>"},{"location":"other/example1/","title":"Example1","text":"<pre><code># !/bin/bash\nfunction install_docker() {\n if command -v docker &>/dev/null; then\n return\n fi\n\n # script options\n local script_host=\"linuxmirrors.cn\" # official host (CDN), more host see official site\n local close_firewall=\"true\" # close firewalld service and selinux (redhat systems need)\n # mirrors options\n local source_docker_ce_address=\"mirrors.tencent.com/docker-ce\" # global high availability address\n local source_docker_ce_protocol=\"https\" # https or http\n local source_docker_registry_address=\"registry.hub.docker.com\"\n\n # judge network environment\n local region_code=\"$(curl -s ipinfo.io/country)\"\n if [[ \"${region_code}\" == \"CN\" ]]; then\n local source_intranet_address=\"\"\n # use intranet source if possible\n if [ -s \"/sys/class/dmi/id/sys_vendor\" ]; then\n local sys_vendor=\"$(cat /sys/class/dmi/id/sys_vendor)\"\n if [[ \"${sys_vendor}\" == *\"Alibaba\"* ]]; then\n source_intranet_address=\"mirrors.cloud.aliyuncs.com/docker-ce\"\n elif [[ \"${sys_vendor}\" == *\"Huawei\"* ]]; then\n source_intranet_address=\"mirrors.myhuaweicloud.com/docker-ce\"\n elif [[ \"${sys_vendor}\" == *\"Tencent\"* ]]; then\n source_intranet_address=\"mirrors.tencentyun.com/docker-ce\"\n elif [[ \"${sys_vendor}\" == *\"Inspur\"* ]]; then\n source_intranet_address=\"mirrors.ivolces.com/docker-ce\"\n fi\n else\n cat /etc/motd | grep \"Alibaba Cloud \" -q\n if [ $? -eq 0 ]; then\n source_intranet_address=\"mirrors.cloud.aliyuncs.com/docker-ce\"\n fi\n fi\n # check connectivity\n if [ -n \"${source_intranet_address}\" ]; then\n if ping -c1 -W1 \"${source_intranet_address%%/*}\" >/dev/null 2>&1; then\n source_docker_ce_address=\"${source_intranet_address}\"\n source_docker_ce_protocol=\"http\"\n fi\n fi\n # registry mirror (best choice for Chinese mainland)\n source_docker_registry_address=\"docker.1ms.run\"\n else\n # use official source\n source_docker_ce_address=\"download.docker.com\"\n source_docker_registry_address=\"registry.hub.docker.com\"\n fi\n\n # install docker engine\n bash <(curl -sSL https://${script_host}/docker-lite.sh) \\\n --source \"${source_docker_ce_address}\" \\\n --source-registry \"${source_docker_registry_address}\" \\\n --protocol \"${source_docker_ce_protocol}\" \\\n --close-firewall \"${close_firewall}\"\n}\n\ninstall_docker\n</code></pre>"},{"location":"other/example2/","title":"Example2","text":"<pre><code># !/bin/bash\nfunction install_docker() {\n if command -v docker &>/dev/null; then\n return\n fi\n\n bash <(curl -sSL https://${script_host}/docker.sh) \\\n --install-latest true \\\n --ignore-backup-tips \\\n --lang auto\n\n if command -v docker &>/dev/null; then\n echo -e \"\\n# Docker installation successful.\\n# Please run this script again manually after installation.\"\n exit 0\n else\n echo -e \"\\n# Docker installation failed.\\n# Please check the error message above.\"\n exit 1\n fi\n}\n\ninstall_docker\n</code></pre>"},{"location":"sponsor/","title":"\u8d5e\u52a9","text":""},{"location":"sponsor/#_1","title":"\u8d5e\u52a9","text":"\u6210\u4e3a\u8d5e\u52a9\u5546 <p>\u8bf7\u524d\u5f80\u4f5c\u8005\u7231\u53d1\u7535\u4e3b\u9875\u67e5\u770b\u8bf4\u660e\u5e76\u4e0e\u4f5c\u8005\u53d6\u5f97\u8054\u7cfb</p>"},{"location":"use/","title":"\u4f7f\u7528\u65b9\u6cd5","text":""},{"location":"use/#\u4e00\u952e\u6267\u884c\u547d\u4ee4","title":"\u4e00\u952e\u6267\u884c\u547d\u4ee4","text":"\u4e2d\u56fd\u5927\u9646 \u5883\u5916\u4ee5\u53ca\u6d77\u5916\u5730\u533a \u4e2d\u56fd\u5927\u9646\u6559\u80b2\u7f51 \u5b98\u7f51 (\u63a8\u8350) GitHub Gitee \u7801\u4e91 (\u955c\u50cf\u4ed3\u5e93) GitCode (\u955c\u50cf\u4ed3\u5e93) jsDelivr (CDN) \u817e\u8baf\u4e91 EO (CDN) <pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh)\n</code></pre> <pre><code>bash <(curl -sSL https://raw.githubusercontent.com/SuperManito/LinuxMirrors/main/ChangeMirrors.sh)\n</code></pre> <pre><code>bash <(curl -sSL https://gitee.com/SuperManito/LinuxMirrors/raw/main/ChangeMirrors.sh)\n</code></pre> <p>\u5b9e\u65f6\u540c\u6b65\u3001\u65e0\u5ef6\u8fdf\uff0c\u56fd\u5185\u7f51\u7edc\u73af\u5883\u4e0b\u63a8\u8350\u4f7f\u7528</p> <pre><code>bash <(curl -sSL https://raw.gitcode.com/SuperManito/LinuxMirrors/raw/main/ChangeMirrors.sh)\n</code></pre> <p>\u540c\u6b65\u5b58\u57281\u5c0f\u65f6\u5ef6\u8fdf</p> <pre><code>bash <(curl -sSL https://cdn.jsdelivr.net/gh/SuperManito/LinuxMirrors@main/ChangeMirrors.sh)\n</code></pre> <pre><code>bash <(curl -sSL https://edgeone.linuxmirrors.cn/main.sh)\n</code></pre> <p>\u4e0d\u5efa\u8bae\u5728\u56fd\u5185\u7f51\u7edc\u73af\u5883\u4e0b\u4f7f\u7528</p> \u5b98\u7f51 (\u63a8\u8350) GitHub Gitee \u7801\u4e91 (\u955c\u50cf\u4ed3\u5e93) GitCode (\u955c\u50cf\u4ed3\u5e93) jsDelivr (CDN) \u817e\u8baf\u4e91 EO (CDN) <pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --abroad\n</code></pre> <pre><code>bash <(curl -sSL https://raw.githubusercontent.com/SuperManito/LinuxMirrors/main/ChangeMirrors.sh) --abroad\n</code></pre> <pre><code>bash <(curl -sSL https://gitee.com/SuperManito/LinuxMirrors/raw/main/ChangeMirrors.sh) --abroad\n</code></pre> <p>\u5b9e\u65f6\u540c\u6b65\u3001\u65e0\u5ef6\u8fdf\uff0c\u56fd\u5185\u7f51\u7edc\u73af\u5883\u4e0b\u63a8\u8350\u4f7f\u7528</p> <pre><code>bash <(curl -sSL https://raw.gitcode.com/SuperManito/LinuxMirrors/raw/main/ChangeMirrors.sh) --abroad\n</code></pre> <p>\u540c\u6b65\u5b58\u57281\u5c0f\u65f6\u5ef6\u8fdf</p> <pre><code>bash <(curl -sSL https://cdn.jsdelivr.net/gh/SuperManito/LinuxMirrors@main/ChangeMirrors.sh) --abroad\n</code></pre> <pre><code>bash <(curl -sSL https://edgeone.linuxmirrors.cn/main.sh) --abroad\n</code></pre> <p>\u4e0d\u5efa\u8bae\u5728\u56fd\u5185\u7f51\u7edc\u73af\u5883\u4e0b\u4f7f\u7528</p> \u5b98\u7f51 (\u63a8\u8350) GitHub Gitee \u7801\u4e91 (\u955c\u50cf\u4ed3\u5e93) GitCode (\u955c\u50cf\u4ed3\u5e93) jsDelivr (CDN) \u817e\u8baf\u4e91 EO (CDN) <pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --edu\n</code></pre> <pre><code>bash <(curl -sSL https://raw.githubusercontent.com/SuperManito/LinuxMirrors/main/ChangeMirrors.sh) --edu\n</code></pre> <pre><code>bash <(curl -sSL https://gitee.com/SuperManito/LinuxMirrors/raw/main/ChangeMirrors.sh) --edu\n</code></pre> <p>\u5b9e\u65f6\u540c\u6b65\u3001\u65e0\u5ef6\u8fdf\uff0c\u56fd\u5185\u7f51\u7edc\u73af\u5883\u4e0b\u63a8\u8350\u4f7f\u7528</p> <pre><code>bash <(curl -sSL https://raw.gitcode.com/SuperManito/LinuxMirrors/raw/main/ChangeMirrors.sh) --edu\n</code></pre> <p>\u540c\u6b65\u5b58\u57281\u5c0f\u65f6\u5ef6\u8fdf</p> <pre><code>bash <(curl -sSL https://cdn.jsdelivr.net/gh/SuperManito/LinuxMirrors@main/ChangeMirrors.sh) --edu\n</code></pre> <pre><code>bash <(curl -sSL https://edgeone.linuxmirrors.cn/main.sh) --edu\n</code></pre> <p>\u4e0d\u5efa\u8bae\u5728\u56fd\u5185\u7f51\u7edc\u73af\u5883\u4e0b\u4f7f\u7528</p> <p>\u4f7f\u7528\u5e2e\u52a9</p> <p>\u9009\u9879\u5361\u5206\u522b\u4ee3\u8868\u811a\u672c\u5185\u7f6e\u8f6f\u4ef6\u6e90\uff08\u955c\u50cf\u7ad9\uff09\u7c7b\u578b\u548c\u83b7\u53d6\u811a\u672c\u9014\u5f84\uff0c\u8bf7\u5728\u4f7f\u7528\u524d\u68c0\u67e5\u76ee\u6807\u955c\u50cf\u7ad9\u662f\u5426\u652f\u6301\u4f60\u6240\u4f7f\u7528\u7684\u64cd\u4f5c\u7cfb\u7edf\uff0c\u53ef\u4ee5\u5728\u8f6f\u4ef6\u6e90\u5217\u8868\u4e2d\u67e5\u770b\u3002 \u9ed8\u8ba4\u81ea\u52a8\u5907\u4efd\u539f\u6709\u8f6f\u4ef6\u6e90\u5185\u5bb9\uff0c\u5982\u9700\u4e86\u89e3\u66f4\u591a\u8bf7\u7ffb\u9605\u4e0b\u65b9\u6587\u6863\u3002\u82e5\u4f7f\u7528\u8fc7\u7a0b\u4e2d\u7684\u67d0\u4e9b\u9009\u9879\u4ee4\u4f60\u7591\u60d1\u4e0d\u89e3\uff0c\u90a3\u4e48\u5728\u9009\u62e9\u8f6f\u4ef6\u6e90\u540e\u4e00\u8def\u56de\u8f66\u5373\u662f\u6700\u4f73\u5b9e\u8df5\u3002</p> <p>\u652f\u6301\u5728\u7cfb\u7edf\u539f\u6709\u8f6f\u4ef6\u6e90\u635f\u574f\u3001\u7f3a\u5931\u3001\u65e0\u6548\u7b49\u5f02\u5e38\u73af\u5883\u4e0b\u4f7f\u7528\uff0c\u65e0\u9700\u989d\u5916\u5b89\u88c5\u4efb\u4f55\u4f9d\u8d56\u3002</p> <p>\u5173\u4e8e\u8f6f\u4ef6\u6e90\u7684\u9009\u62e9\uff08\u65b0\u7528\u6237\u5fc5\u8bfb\uff09</p> <p>\u5982\u679c\u4f60\u4e0d\u4e86\u89e3\u8fd9\u4e9b\u955c\u50cf\u7ad9\u90a3\u4e48\u5efa\u8bae\u4f7f\u7528 <code>\u963f\u91cc\u4e91 (\u517c\u5bb9\u6027\u9ad8\u3001\u53ef\u7528\u6027\u5f3a)</code> \u6216 <code>\u4e2d\u56fd\u79d1\u5b66\u6280\u672f\u5927\u5b66 (\u901f\u5ea6\u5feb)</code>\uff0c\u8bf7\u4e0d\u8981\u9677\u5165\u6d4b\u901f\u7126\u8651\uff0c\u5185\u7f6e\u7684\u8f6f\u4ef6\u6e90\u4e00\u822c\u4e0d\u4f1a\u6709\u592a\u5927\u7684\u5dee\u5f02\u3002 \u672c\u9879\u76ee\u811a\u672c\u662f\u4e00\u4e2a\u81ea\u52a8\u5316\u8fd0\u7ef4\u5de5\u5177\uff0c\u4e0d\u4f1a\u5bf9\u955c\u50cf\u7ad9\u8fdb\u884c\u4e3b\u89c2\u7684\u4f18\u52a3\u6392\u5e8f\u548c\u5b9a\u5236\u9002\u914d\uff0c\u7528\u6237\u7684\u9009\u62e9\u5e94\u8be5\u662f\u81ea\u7531\u7684\uff0c\u8fd9\u4e5f\u662f\u4e3a\u4e86\u5f00\u6e90\u8f6f\u4ef6\u7cbe\u795e\u80fd\u591f\u5f97\u5230\u66f4\u597d\u7684\u5ef6\u7eed\u3002</p> <ul> <li> <p> \u9700\u8981 <code>ROOT</code> \u6743\u9650</p> <p>\u8bf7\u4f7f\u7528 <code>root</code> \u8d26\u6237\u8fd0\u884c\u672c\u811a\u672c\uff0c\u5207\u6362\u547d\u4ee4\u4e3a <code>sudo -i</code> \u6216 <code>su root</code>\uff0c\u4e0d\u540c\u7cfb\u7edf\u4f7f\u7528\u7684\u547d\u4ee4\u4e0d\u540c\u3002\u53e6\u5916\u6ce8\u610f\u4e0d\u8981\u901a\u8fc7 <code>sudo</code> \u76f4\u63a5\u8fd0\u884c\u4e00\u952e\u547d\u4ee4\u4f8b\u5982 <code>sudo bash <(xxx)</code>\u3002</p> </li> <li> <p> \u5efa\u8bae\u4f7f\u7528\u73b0\u4ee3\u5316\u7684 <code>SSH</code> \u5ba2\u6237\u7aef\u5e94\u7528</p> <p>\u5982\u679c\u7cfb\u7edf\u547d\u4ee4\u884c\u754c\u9762\u7684\u4e2d\u6587\u663e\u793a\u4e71\u7801\uff0c\u5c06\u5bfc\u81f4\u65e0\u6cd5\u67e5\u770b\u4ea4\u4e92\u5185\u5bb9\uff0c\u6b64\u5916\u90e8\u5206\u7cfb\u7edf GUI \u56fe\u5f62\u754c\u9762\u7684\u7ec8\u7aef\u5e94\u7528\u53ef\u80fd\u5b58\u5728\u4e00\u4e9b\u65e0\u6cd5\u9884\u6599\u7684\u663e\u793a\u95ee\u9898\u3002\u90e8\u5206\u7cfb\u7edf\u4f1a\u81ea\u52a8\u5f00\u542f SSH \u670d\u52a1\uff0c\u5426\u5219\u8bf7\u53c2\u8003\u5f00\u542f\u65b9\u6cd5\u3002</p> </li> <li> <p> \u5982\u679c\u662f\u5728\u65b0\u88c5\u7cfb\u7edf\u4e0a\u9996\u6b21\u6267\u884c\u811a\u672c</p> <p>\u5f53\u524d\u4f9d\u8d56 <code>curl</code> \u6307\u4ee4\u83b7\u53d6\u811a\u672c\u5185\u5bb9\uff0c\u4f46\u90e8\u5206\u64cd\u4f5c\u7cfb\u7edf\u672a\u9884\u88c5\u6b64\u8f6f\u4ef6\u5305\uff0c\u5c06\u4f1a\u62a5\u9519 <code>Command not found</code>\uff0c\u5b89\u88c5\u65b9\u6cd5\u8be6\u89c1\u4e0b\u65b9 \u5173\u4e8e\u62a5\u9519 Command not found\u3002\u811a\u672c\u672c\u8eab\u4e0e <code>curl</code> <code>wget</code> \u6307\u4ee4\u65e0\u5173\uff0c\u4e0d\u4f1a\u4e0b\u8f7d\u4efb\u4f55\u5185\u5bb9\u3002</p> </li> <li> <p> \u811a\u672c\u8fd0\u884c\u671f\u95f4\u9700\u8981\u4ea4\u4e92\u9009\u62e9\u914d\u7f6e</p> <p>\u8bf7\u901a\u8fc7\u65b9\u5411\u952e UpDownLeftRight \u6216 WASD \u63a7\u5236\u9009\u9879\u5e76\u6309 Enter \u56de\u8f66\u952e\u786e\u8ba4\u3002\u5982\u679c\u53d1\u73b0\u4ea4\u4e92\u5f02\u5e38\u8bf7\u6539\u53d8\u7ec8\u7aef\u8f6f\u4ef6\u7684\u7a97\u53e3\u5927\u5c0f\u540e\u91cd\u8bd5\uff0c\u907f\u514d\u7a97\u53e3\u94fa\u6ee1\u5168\u5c4f\u3002</p> </li> </ul>"},{"location":"use/#\u5e38\u89c1\u95ee\u9898","title":"\u5e38\u89c1\u95ee\u9898","text":""},{"location":"use/#\u5173\u4e8e\u62a5\u9519-command-not-found","title":"\u5173\u4e8e\u62a5\u9519 Command not found","text":"<p>\u6b64\u62a5\u9519\u662f\u7531\u4e8e\u7cfb\u7edf\u6ca1\u6709\u5b89\u88c5 <code>curl</code> \u8f6f\u4ef6\u5305\u5bfc\u81f4\uff0c\u5b89\u88c5\u547d\u4ee4\u5982\u4e0b</p> Debian \u7cfb / openKylinRedHat \u7cfb / openEuler / OpenCloudOS / Anolis OSopenSUSEArch Linux / ManjaroAlpine LinuxGentooNixOS <pre><code>apt-get install -y curl\n</code></pre> <p><code>Debian</code> <code>Ubuntu</code> <code>Kali</code> <code>Linux Mint</code> <code>Deepin</code> <code>Zorin OS</code> <code>Armbian</code> <code>Proxmox VE</code> <code>Raspberry Pi OS</code> <code>openKylin</code></p> <p>\u65b0\u88c5\u7cfb\u7edf\u9700\u8981\u5148\u6267\u884c\u4e00\u904d\u66f4\u65b0 <code>apt-get update</code></p> <pre><code>dnf install -y curl || yum install -y curl\n</code></pre> <p><code>Red Hat Enterprise Linux</code> <code>CentOS</code> <code>Rocky Linux</code> <code>AlmaLinux</code> <code>Fedora</code> <code>openEuler</code> <code>OpenCloudOS</code> <code>Anolis OS</code></p> <pre><code>zypper install curl\n</code></pre> <pre><code>pacman -S curl\n</code></pre> <pre><code>apk --no-cache add -f curl bash ncurses\n</code></pre> <pre><code>emerge --ask curl\n</code></pre> <pre><code>nix-env -iA nixos.curl\n</code></pre> \u5b89\u88c5\u4e0d\u4e0a\uff1f\uff08\u70b9\u51fb\u5c55\u5f00\u67e5\u770b\u5176\u5b83\u89e3\u51b3\u65b9\u6cd5\uff09 <p>\u5047\u5982\u7cfb\u7edf\u539f\u6709\u8f6f\u4ef6\u6e90\u662f\u65e0\u6548\u7684\u5bfc\u81f4\u5b89\u88c5\u4e0d\u4e0a <code>curl</code> \u8f6f\u4ef6\u5305\uff0c\u90a3\u4e48\u5bf9\u4e8e Linux \u521d\u5b66\u8005\u6765\u8bf4\u53ef\u80fd\u4f1a\u6bd4\u8f83\u9ebb\u70e6\uff0c\u8fd9\u91cc\u63d0\u4f9b\u51e0\u4e2a\u5728\u7ebf\u83b7\u53d6\u811a\u672c\u7684\u5e94\u6025\u65b9\u6cd5</p> \u4f7f\u7528 Python \u4e0b\u8f7d\u4f7f\u7528 wget \u6307\u4ee4\u4e0b\u8f7d\u4f7f\u7528\u6d4f\u89c8\u5668\u4e0b\u8f7d <p>\u9002\u7528\u4e8e\u5927\u90e8\u5206\u64cd\u4f5c\u7cfb\u7edf\uff08<code>Alpine Linux</code> \u9664\u5916\uff09\uff0c<code>python3</code> \u8981\u662f\u4e0d\u5b58\u5728\u90a3\u5c31\u518d\u8bd5\u8bd5 <code>python</code> \u6307\u4ee4 <pre><code>python3 -c \"import urllib.request; urllib.request.urlretrieve('https://linuxmirrors.cn/main.sh', 'main.sh')\"\n</code></pre></p> <p>\u4e00\u822c\u6ca1\u6709\u9884\u88c5 <code>curl</code> \u8f6f\u4ef6\u5305\u7684\u7cfb\u7edf\u4e5f\u4e0d\u4f1a\u9884\u88c5 <code>wget</code> \u8f6f\u4ef6\u5305\uff0c\u6240\u4ee5\u5927\u6982\u7387\u8fd9\u4e2a\u65b9\u6cd5\u5e94\u8be5\u662f\u4e0d\u884c\u7684 <pre><code>wget https://linuxmirrors.cn/main.sh\n</code></pre></p> <p>\u5982\u679c\u53ef\u4ee5\u8bbf\u95ee\u7cfb\u7edf GUI \u56fe\u50cf\u754c\u9762\u548c\u684c\u9762\u7684\u8bdd\u90a3\u53ef\u4ee5\u76f4\u63a5\u5728\u6d4f\u89c8\u5668\u4e2d\u6253\u5f00\u94fe\u63a5\u4e0b\u8f7d\u811a\u672c\uff0c\u5f88\u591a\u7cfb\u7edf\u90fd\u4f1a\u9884\u88c5 Firefox \u706b\u72d0\u6d4f\u89c8\u5668</p> <p>\u4e4b\u540e\u518d\u6267\u884c\u811a\u672c\u5373\u53ef</p> \u4e2d\u56fd\u5927\u9646 \u5883\u5916\u4ee5\u53ca\u6d77\u5916\u5730\u533a \u4e2d\u56fd\u5927\u9646\u6559\u80b2\u7f51 <pre><code>bash main.sh\n</code></pre> <pre><code>bash main.sh --abroad\n</code></pre> <pre><code>bash main.sh --edu\n</code></pre> <p>\u5982\u679c\u4ee5\u4e0a\u65b9\u6cd5\u8bd5\u4e86\u90fd\u4e0d\u884c\uff0c\u90a3\u5c31\u590d\u5236\u6e90\u7801\u81f3\u672c\u5730\u65b0\u5efa\u4efb\u610f\u540d\u79f0\u7684 <code>.sh</code> \u811a\u672c\uff0c\u7c98\u8d34\u6e90\u7801\u5185\u5bb9\u540e\u901a\u8fc7 <code>bash</code> \u6307\u4ee4\u624b\u52a8\u6267\u884c\u3002</p>"},{"location":"use/#\u5907\u4efd\u539f\u6709\u8f6f\u4ef6\u6e90","title":"\u5907\u4efd\u539f\u6709\u8f6f\u4ef6\u6e90","text":"<p>\u811a\u672c\u4f1a\u81ea\u52a8\u5907\u4efd\u539f\u6709\u8f6f\u4ef6\u4ed3\u5e93\u914d\u7f6e\u6587\u4ef6\uff0c\u5907\u4efd\u8def\u5f84\u4e3a\u539f\u6709\u6587\u4ef6\u6216\u76ee\u5f55\u7684\u7edd\u5bf9\u8def\u5f84\u52a0\u4e0a <code>.bak</code> \u540e\u7f00\uff0c\u4f8b\u5982 <code>/etc/apt/sources.list => /etc/apt/sources.list.bak</code>\uff0c\u5f53\u68c0\u67e5\u5230\u5df2\u5b58\u5728\u5907\u4efd\u5185\u5bb9\u65f6\u4f1a\u8be2\u95ee\u662f\u5426\u8986\u76d6\u5907\u4efd\u3002</p>"},{"location":"use/#\u8fd8\u539f\u5df2\u5907\u4efd\u7684\u8f6f\u4ef6\u6e90","title":"\u8fd8\u539f\u5df2\u5907\u4efd\u7684\u8f6f\u4ef6\u6e90","text":"\u70b9\u51fb\u5c55\u5f00\u67e5\u770b Debian \u7cfb / openKylinRedHat \u7cfb / openEuler / OpenCloudOS / Anolis OSopenSUSEArch Linux / ManjaroAlpine LinuxGentooNixOS \u4f20\u7edf\u683c\u5f0fDEB822 \u683c\u5f0f <pre><code>cp -rf /etc/apt/sources.list.bak /etc/apt/sources.list\napt-get update\n</code></pre> <pre><code>system_name=\"$(lsb_release -is | tr '[:upper:]' '[:lower:]')\"\ncp -rf \"/etc/apt/sources.list.d/${system_name}.sources.bak\" \"/etc/apt/sources.list.d/${system_name}.sources\"\napt-get update\n</code></pre> <p><code>Debian</code> <code>Ubuntu</code> <code>Kali</code> <code>Linux Mint</code> <code>Deepin</code> <code>Zorin OS</code> <code>Armbian</code> <code>Proxmox VE</code> <code>Raspberry Pi OS</code> <code>openKylin</code></p> <pre><code>cp -rf /etc/yum.repos.d.bak /etc/yum.repos.d\nyum makecache\n</code></pre> <p><code>Red Hat Enterprise Linux</code> <code>CentOS</code> <code>Rocky Linux</code> <code>AlmaLinux</code> <code>Fedora</code> <code>openEuler</code> <code>OpenCloudOS</code> <code>Anolis OS</code></p> <pre><code>cp -rf /etc/zypp/repos.d.bak /etc/zypp/repos.d\nzypper ref\n</code></pre> <pre><code>cp -rf /etc/pacman.d/mirrorlist.bak /etc/pacman.d/mirrorlist\npacman -Sy\n</code></pre> <pre><code>cp -rf /etc/apk/repositories.bak /etc/apk/repositories\napk update -f\n</code></pre> <pre><code>cp -rf /etc/portage/make.conf.bak /etc/portage/make.conf\n[ -d /etc/portage/repos.conf ] && cp -rf /etc/portage/repos.conf/gentoo.conf.bak /etc/portage/repos.conf/gentoo.conf\nemerge --sync --quiet\n</code></pre> <pre><code>cp -rf /etc/nix/nix.conf.bak /etc/nix/nix.conf\n</code></pre>"},{"location":"use/#\u5173\u4e8e\u5f00\u542f-ssh-\u8fdc\u7a0b\u767b\u5f55\u7684\u65b9\u6cd5","title":"\u5173\u4e8e\u5f00\u542f SSH \u8fdc\u7a0b\u767b\u5f55\u7684\u65b9\u6cd5","text":"\u70b9\u51fb\u5c55\u5f00\u67e5\u770b <p>\u547d\u4ee4\u4ee5\u53ca\u914d\u7f6e\u6b65\u9aa4\u4ec5\u4f9b\u53c2\u8003\uff0c\u6ce8\u610f\u7075\u6d3b\u53d8\u901a</p> <ul> <li> <p>\u9a8c\u8bc1\u662f\u5426\u5df2\u5b89\u88c5 <code>SSH</code> \u670d\u52a1</p> <pre><code>ls /etc | grep ssh\n</code></pre> <p>\u5982\u679c\u6ca1\u6709\u8fd9\u4e2a\u6587\u4ef6\u5939\u8bf4\u660e\u7cfb\u7edf\u672a\u5b89\u88c5 <code>SSH</code> \u670d\u52a1\uff0c\u4f60\u9700\u8981\u901a\u8fc7\u5305\u7ba1\u7406\u5de5\u5177\u5b89\u88c5 <code>openssh-server</code> \u8f6f\u4ef6\u5305\uff0c\u5b89\u88c5\u547d\u4ee4\u5982\u4e0b\uff1a</p> Debian \u7cfb / openKylinRedHat \u7cfb / openEuler / OpenCloudOS / Anolis OSopenSUSEArch Linux / ManjaroAlpine LinuxGentoo <pre><code>apt-get install -y openssh-server\n</code></pre> <p><code>Debian</code> <code>Ubuntu</code> <code>Kali</code> <code>Linux Mint</code> <code>Deepin</code> <code>Zorin OS</code> <code>Armbian</code> <code>Proxmox VE</code> <code>Raspberry Pi OS</code> <code>openKylin</code></p> <p>\u65b0\u88c5\u7cfb\u7edf\u9700\u8981\u5148\u6267\u884c\u4e00\u904d\u66f4\u65b0 <code>apt-get update</code></p> <pre><code>dnf install -y openssh-server || yum install -y openssh-server\n</code></pre> <p><code>Red Hat Enterprise Linux</code> <code>CentOS</code> <code>Rocky Linux</code> <code>AlmaLinux</code> <code>Fedora</code> <code>openEuler</code> <code>OpenCloudOS</code> <code>Anolis OS</code></p> <pre><code>zypper install openssh-server\n</code></pre> <pre><code>pacman -S openssh\n</code></pre> <pre><code>apk --no-cache add -f openssh\n</code></pre> <pre><code>emerge --ask --changed-use --oneshot net-misc/openssh\n</code></pre> <p>\u4e0d\u540c\u7cfb\u7edf\u4e0a\u7684\u8f6f\u4ef6\u5305\u540d\u79f0\u6709\u6240\u5dee\u5f02\uff0c\u5982\u679c\u63d0\u793a\u627e\u4e0d\u5230\u8be5\u8f6f\u4ef6\u5305\u53ef\u5c1d\u8bd5\u4f7f\u7528\u901a\u914d\u7b26 <code>openssh*</code> \u8fdb\u884c\u5b89\u88c5</p> </li> <li> <p>\u914d\u7f6e <code>SSH</code> \u670d\u52a1</p> \u5141\u8bb8 root \u8d26\u6237\u767b\u5f55<pre><code>cat /etc/ssh/sshd_config | grep -Eq \"^[# ]?PermitRootLogin \" ; [ $? -eq 0 ] && sed -i 's/^[# ]\\?PermitRootLogin.*/PermitRootLogin yes/g' /etc/ssh/sshd_config || echo -e \"\\nPermitRootLogin yes\" >> /etc/ssh/sshd_config\n</code></pre> \u542f\u7528\u5bc6\u7801\u8ba4\u8bc1<pre><code>cat /etc/ssh/sshd_config | grep -Eq \"^[# ]?PasswordAuthentication \" ; [ $? -eq 0 ] && sed -i 's/^[# ]\\?PasswordAuthentication.*/PasswordAuthentication yes/g' /etc/ssh/sshd_config || echo -e \"\\nPasswordAuthentication yes\" >> /etc/ssh/sshd_config\n</code></pre> </li> <li> <p>\u542f\u52a8/\u91cd\u542f <code>SSH</code> \u670d\u52a1</p> <pre><code>for ssh_svc in sshd ssh; do systemctl restart \"${ssh_svc}\" 2>/dev/null && break ; systemctl enable --now \"${ssh_svc}\" 2>/dev/null && break ; done\n</code></pre> </li> </ul> <p>\u53cb\u60c5\u63d0\u793a\uff1a\u5982\u679c\u4f60\u6b63\u5728\u4f7f\u7528\u516c\u7f51\u670d\u52a1\u5668\uff0c\u5efa\u8bae\u5173\u95ed SSH \u5bc6\u7801\u8ba4\u8bc1\u65b9\u5f0f\u5e76\u8bbe\u7f6e\u5bc6\u94a5\u767b\u5f55\u3002</p>"},{"location":"use/#\u5173\u4e8e\u672a\u663e\u793a\u65b9\u5411\u952e\u4ea4\u4e92\u63a7\u5236\u754c\u9762","title":"\u5173\u4e8e\u672a\u663e\u793a\u65b9\u5411\u952e\u4ea4\u4e92\u63a7\u5236\u754c\u9762","text":"<p>\u5982\u679c\u53d1\u73b0\u4ea4\u4e92\u754c\u9762\u662f\u8f93\u5165\u800c\u4e0d\u662f\u65b0\u5f0f\u7684\u65b9\u5411\u952e\u63a7\u5236\uff0c\u90a3\u4e48\u8bf7\u81ea\u884c\u5b89\u88c5 <code>ncurses</code> \u6216 <code>nano</code> \u8f6f\u4ef6\u5305\uff0c\u65b0\u5f0f\u7684\u6309\u952e\u4ea4\u4e92\u4f9d\u8d56 <code>tput</code> \u6307\u4ee4\u5b9e\u73b0\u3002</p>"},{"location":"use/#\u5173\u4e8e\u672a\u542f\u7528\u7684\u8f6f\u4ef6\u6e90\u4ed3\u5e93","title":"\u5173\u4e8e\u672a\u542f\u7528\u7684\u8f6f\u4ef6\u6e90\u4ed3\u5e93","text":"<p>\u5f88\u591a\u7cfb\u7edf\u7684\u8f6f\u4ef6\u6e90\u4f1a\u542f\u7528\u591a\u4e2a\u8f6f\u4ef6\u4ed3\u5e93\u914d\u7f6e\uff0c\u811a\u672c\u9075\u5faa\u7cfb\u7edf\u9ed8\u8ba4\u8bbe\u7f6e\uff0c\u9ed8\u8ba4\u4e0d\u542f\u7528\u7684\u8f6f\u4ef6\u6e90\uff08\u4ed3\u5e93\uff09\u4e0d\u4f1a\u5728\u8fd0\u884c\u5b8c\u672c\u811a\u672c\u540e\u88ab\u542f\u7528\uff0c\u4f46\u662f\u5b83\u4eec\u4e5f\u968f\u811a\u672c\u66f4\u6362\u4e86\u76ee\u6807\u8f6f\u4ef6\u6e90\uff08\u955c\u50cf\u7ad9\uff09\u5730\u5740\uff0c\u5177\u4f53\u542f\u7528\u65b9\u6cd5\u5982\u4e0b\uff1a</p> Debian \u7cfb / openKylinRedHat \u7cfb / openEuler / OpenCloudOS / Anolis OSopenSUSE <p>\u9ed8\u8ba4\u7981\u7528\u4e86<code>deb-src</code>\u6e90\u7801\u4ed3\u5e93\u548c<code>proposed</code>\u9884\u53d1\u5e03\u8f6f\u4ef6\u6e90\uff0c\u82e5\u9700\u542f\u7528\u8bf7\u5c06 <code>/etc/apt/sources.list</code> \u6587\u4ef6\u4e2d\u76f8\u5173\u5185\u5bb9\u7684\u6240\u5728\u884c\u53d6\u6d88\u6ce8\u91ca</p> <p><code>Debian</code> <code>Ubuntu</code> <code>Kali</code> <code>Linux Mint</code> <code>Deepin</code> <code>Zorin OS</code> <code>Armbian</code> <code>Proxmox VE</code> <code>Raspberry Pi OS</code> <code>openKylin</code></p> <p>\u90e8\u5206\u4ed3\u5e93\u9ed8\u8ba4\u6ca1\u6709\u542f\u7528\uff0c\u82e5\u9700\u542f\u7528\u8bf7\u5c06 <code>/etc/yum.repos.d</code> \u76ee\u5f55\u4e0b\u76f8\u5173 repo \u6587\u4ef6\u4e2d\u7684 <code>enabled</code> \u503c\u4fee\u6539\u4e3a <code>1</code></p> <p><code>Red Hat Enterprise Linux</code> <code>CentOS</code> <code>Rocky Linux</code> <code>AlmaLinux</code> <code>Fedora</code> <code>openEuler</code> <code>OpenCloudOS</code> <code>Anolis OS</code></p> <p>\u90e8\u5206\u4ed3\u5e93\u9ed8\u8ba4\u6ca1\u6709\u542f\u7528\uff0c\u82e5\u9700\u542f\u7528\u8bf7\u5c06 <code>/etc/zypp/repos.d</code> \u76ee\u5f55\u4e0b\u76f8\u5173 repo \u6587\u4ef6\u4e2d\u7684 <code>enabled</code> \u503c\u4fee\u6539\u4e3a <code>1</code></p>"},{"location":"use/#\u5176\u5b83","title":"\u5176\u5b83","text":"\u5173\u4e8e\u8c03\u7528\u811a\u672c\u7684\u4e92\u8054\u7f51\u4f4d\u7f6e <p>\u9879\u76ee\u5229\u7528 GitHub Action \u5728\u6bcf\u6b21\u63d0\u4ea4\u540e\u81ea\u52a8\u62f7\u8d1d\u6e90\u7801\u5230\u6587\u6863\u76ee\u5f55\u4f5c\u4e3a\u7f51\u7ad9\u8d44\u6e90\u53d1\u5e03\uff0c\u7f51\u7ad9\u6258\u7ba1\u4e8e Netlify\uff0c\u51e0\u4e4e\u6ca1\u6709\u88ab\u52ab\u6301\u7684\u98ce\u9669\u8bf7\u653e\u5fc3\u4f7f\u7528\u3002</p> <p>\u5f53\u7136\u4f60\u4e5f\u53ef\u4ee5\u4f7f\u7528\u4ee3\u7801\u6258\u7ba1\u4ed3\u5e93\u7684\u539f\u59cb\u5730\u5740\u6765\u8c03\u7528\uff0c\u8fd9\u91cc\u53ea\u662f\u60f3\u544a\u8bc9\u4f60\u4e3a\u4ec0\u4e48\u4f1a\u6709\u51e0\u4e2a\u4e0d\u540c\u7684\u5730\u5740\uff0c\u9ed8\u8ba4\u7684\u5b98\u7f51\u5730\u5740\u66f4\u6613\u4e8e\u8bb0\u5fc6\u548c\u8bbf\u95ee\u3002</p> \u5173\u4e8e\u8f6f\u4ef6\u6e90\u4e0b\u8f7d\u901f\u5ea6\u95ee\u9898 <p>\u9996\u5148\uff0c\u5728\u8f6f\u4ef6\u6e90\u5217\u8868\u7684\u4f7f\u7528\u5e2e\u52a9\u5904\u6709\u5199\u4f7f\u7528\u63a8\u8350\uff0c\u8fd9\u662f\u6839\u636e\u4ee5\u5f80\u7ecf\u9a8c\u603b\u7ed3\u51fa\u6765\u7684\uff0c\u4f46\u603b\u6709\u7528\u6237\u5728\u7ea0\u7ed3\u8f6f\u4ef6\u6e90\u901f\u5ea6\u7684\u95ee\u9898\u3002</p> <p>\u8f6f\u4ef6\u6e90\uff08\u955c\u50cf\u7ad9\uff09\u7684\u7f51\u7edc\u5ef6\u8fdf\u5373 <code>Ping</code> \u4e0e\u4e0b\u8f7d\u901f\u5ea6\u6ca1\u6709\u592a\u5927\u7684\u5173\u8054\uff0c\u53cc\u65b9\u5730\u7406\u4f4d\u7f6e\u95f4\u9694\u7684\u8fdc\u8fd1\u4e0d\u4ee3\u8868\u5b9e\u9645\u4f53\u9a8c\uff0c\u6709\u4e9b\u955c\u50cf\u7ad9\u4e0b\u884c\u603b\u5e26\u5bbd\u5f88\u9ad8\u4f46\u5b9e\u9645\u6d4b\u901f\u5374\u5e76\u4e0d\u7406\u60f3\uff0c\u56e0\u4e3a\u8fd9\u4e0e\u955c\u50cf\u7ad9\u7684\u8d1f\u8f7d\u7b56\u7565\u6709\u5173\u3002</p> <p>\u7f51\u4e0a\u4e5f\u6709\u5f88\u591a\u57fa\u4e8e C\u3001Python \u7f16\u5199\u7684\u955c\u50cf\u7ad9\u6d4b\u901f\u5f00\u6e90\u811a\u672c\uff0c\u800c\u672c\u9879\u76ee\u811a\u672c\u57fa\u4e8e Bash Shell \u7f16\u5199\u4e14\u4e0d\u4f9d\u8d56\u4efb\u4f55\u7b2c\u4e09\u65b9\u5e93\uff0cBash \u662f Linux \u8fd0\u7ef4\u4e2d\u6700\u5e38\u7528\u7684\u811a\u672c\u8bed\u8a00\u5e76\u4e14\u7edd\u5927\u90e8\u5206\u53d1\u884c\u7248\u90fd\u4f1a\u9884\u88c5\uff0c\u8fd9\u610f\u5473\u7740\u7528\u6237\u4e0d\u9700\u8981\u5b89\u88c5\u4efb\u4f55\u73af\u5883\u5c31\u80fd\u76f4\u63a5\u8fd0\u884c\uff0c\u8fd9\u79cd\u4fbf\u5229\u6027\u662f\u5176\u5b83\u9ad8\u7ea7\u8bed\u8a00\u65e0\u6cd5\u66ff\u4ee3\u7684\uff0c\u4e0d\u8fc7\u76ee\u524d\u6765\u770b Bash \u811a\u672c\u53ef\u80fd\u4e0d\u592a\u5bb9\u6613\u5b9e\u73b0\u7cbe\u51c6\u6d4b\u901f\u7684\u529f\u80fd\uff0c\u4f7f\u7528\u5176\u5b83\u9ad8\u7ea7\u8bed\u8a00\u7f16\u5199\u6d4b\u901f\u529f\u80fd\u65e0\u7591\u662f\u9020\u8f6e\u5b50\u7684\u884c\u4e3a\u3002</p> \u5173\u4e8e\u8f6f\u4ef6\u6e90\u9009\u4f18 <p>\u5f88\u591a\u670b\u53cb\u53ef\u80fd\u90fd\u4f1a\u6709\u4e00\u4e2a\u7591\u95ee\uff1a\u201c\u65e2\u7136\u811a\u672c\u5df2\u7ecf\u5982\u6b64\u4fbf\u6377\u4e14\u5b9e\u73b0\u4e86\u9ad8\u5ea6\u81ea\u52a8\u5316\uff0c\u4e3a\u4ec0\u4e48\u4e0d\u80fd\u5b9e\u73b0\u8f6f\u4ef6\u6e90\u81ea\u52a8\u9009\u4f18\u5462\uff1f\u201d\uff0c\u4e0d\u662f\u505a\u4e0d\u5230\u800c\u662f\u4e0d\u80fd\u3002</p> <p>\u201c\u8f6f\u4ef6\u6e90\u9009\u4f18\u201d \u5728\u8fd9\u91cc\u6307\u7684\u662f\u811a\u672c\u6839\u636e\u5ba2\u6237\u7aef\u7684\u7f51\u7edc\u73af\u5883\u3001\u5730\u7406\u4f4d\u7f6e\u81ea\u52a8\u9009\u62e9\u4e00\u4e2a\u4f53\u9a8c\u6700\u4f73\u7684\u8f6f\u4ef6\u6e90\uff0c\u8fd9\u4e2a\u95ee\u9898\u8981\u4ece\u591a\u4e2a\u89d2\u5ea6\u6765\u8bba\u8bc1\uff1a</p> <ul> <li> <p>\u901f\u5ea6\u65b9\u9762</p> <p>\u5176\u5b9e\u4e0a\u9762\u5df2\u7ecf\u89e3\u91ca\u8fc7\u4e86\uff0c\u603b\u7ed3\u6765\u8bf4\u5c31\u662f\u8ffd\u6c42\u901f\u5ea6\u4e0d\u662f\u666e\u904d\u9700\u6c42\uff0c\u5bf9\u5927\u591a\u6570\u4eba\u6765\u8bf4\u662f\u65e0\u611f\u7684\u3001\u80fd\u7528\u5373\u53ef\uff0c\u51b5\u4e14\u73b0\u5728\u5f88\u591a Linux \u53d1\u884c\u7248\u4e0d\u9700\u8981\u6362\u6e90\u5c31\u6709\u4e0d\u9519\u7684\u901f\u5ea6\u3002</p> </li> <li> <p>\u5bf9\u4e8e\u955c\u50cf\u7ad9\u672c\u8eab</p> <p>\u4e3e\u4e2a\u6700\u7b80\u5355\u7684\u4f8b\u5b50\uff0c\u4ee5\u524d\u963f\u91cc\u4e91\u955c\u50cf\u7ad9\u56e0\u4e3a\u901f\u5ea6\u5feb\u3001\u53ef\u7528\u6027\u9ad8\u51e0\u4e4e\u88ab\u5f53\u6210\u9996\u9009\uff0c\u4f46\u662f\u968f\u7740\u7528\u6237\u8d8a\u6765\u8d8a\u591a\u5bfc\u81f4\u901f\u5ea6\u53d8\u7684\u539f\u6765\u8d8a\u6162\u751a\u81f3\u53ef\u80fd\u4e0d\u8db3 10 Mbps\u3002 \u957f\u6b64\u4ee5\u5f80\uff0c\u90a3\u4e9b\u7528\u6237\u591a\u7684\u955c\u50cf\u7ad9\u53ef\u80fd\u65e0\u6cd5\u627f\u53d7\u8fc7\u9ad8\u7684\u6d41\u91cf\u800c\u5bfc\u81f4\u4f53\u9a8c\u4e0b\u964d\uff0c\u7528\u6237\u5c11\u7684\u955c\u50cf\u7ad9\u53ef\u80fd\u4f1a\u6700\u7ec8\u8d70\u5411\u5173\u95ed\uff0c\u8fd9\u4e0d\u5229\u4e8e\u6574\u4e2a\u751f\u6001\u7684\u53d1\u5c55\u3002</p> </li> <li> <p>\u5f00\u53d1\u8005\u89d2\u5ea6</p> <p>\u672c\u9879\u76ee\u7ad9\u5728\u8fd0\u7ef4\u5de5\u5177\u7684\u89d2\u5ea6\u81f4\u529b\u4e8e\u5f00\u53d1\u4e00\u4e2a\u901a\u7528\u7684\u6362\u6e90\u811a\u672c\uff0c\u800c\u4e0d\u662f\u4e00\u4e2a\u89e3\u51b3\u8f6f\u4ef6\u6e90\u9700\u6c42\u7684\u5177\u4f53\u5316\u5de5\u5177\uff0c\u8981\u4f7f\u811a\u672c\u7684\u9ed8\u8ba4\u884c\u4e3a\u9002\u7528\u4e8e\u5927\u591a\u6570\u7528\u6237\u7fa4\u4f53\u3002\u4f5c\u4e3a\u8fd0\u7ef4\u5de5\u5177\u8981\u6709\u660e\u786e\u7684\u529f\u80fd\u5b9a\u4f4d\uff0c\u4f5c\u4e3a\u811a\u672c\u8981\u4ece\u6269\u5c55\u6027\u3001\u5b9e\u7528\u6027\u7b49\u591a\u4e2a\u65b9\u9762\u53bb\u8861\u91cf\u5229\u5f0a\uff0c\u8f6f\u4ef6\u6e90\u7684\u9009\u62e9\u6743\u5e94\u8be5\u5b8c\u5168\u4ea4\u7ed9\u7528\u6237\u3002</p> </li> </ul>"},{"location":"use/#\u547d\u4ee4\u9009\u9879\u9ad8\u7ea7\u7528\u6cd5","title":"\u547d\u4ee4\u9009\u9879\uff08\u9ad8\u7ea7\u7528\u6cd5\uff09","text":"bash <(curl -sSL https://linuxmirrors.cn/main.sh) --help \u547d\u4ee4\u9009\u9879(\u540d\u79f0/\u542b\u4e49/\u503c)\uff1a --abroad \u4f7f\u7528\u5883\u5916\u4ee5\u53ca\u6d77\u5916\u8f6f\u4ef6\u6e90 \u65e0 --edu \u4f7f\u7528\u4e2d\u56fd\u5927\u9646\u6559\u80b2\u7f51\u8f6f\u4ef6\u6e90 \u65e0 --source \u6307\u5b9a\u8f6f\u4ef6\u6e90\u5730\u5740(\u57df\u540d\u6216IP) \u5730\u5740 --source-epel \u6307\u5b9a EPEL \u9644\u52a0\u8f6f\u4ef6\u5305\u4ed3\u5e93\u7684\u8f6f\u4ef6\u6e90\u5730\u5740(\u57df\u540d\u6216IP) \u5730\u5740 --source-security \u6307\u5b9a Debian / Ubuntu \u7cfb\u7edf security \u4ed3\u5e93\u7684\u8f6f\u4ef6\u6e90\u5730\u5740(\u57df\u540d\u6216IP) \u5730\u5740 --source-vault \u6307\u5b9a CentOS / AlmaLinux \u7cfb\u7edf vault \u4ed3\u5e93\u7684\u8f6f\u4ef6\u6e90\u5730\u5740(\u57df\u540d\u6216IP) \u5730\u5740 --source-portage \u6307\u5b9a Gentoo \u7cfb\u7edf portage \u4ed3\u5e93\u7684\u8f6f\u4ef6\u6e90\u5730\u5740(\u57df\u540d\u6216IP) \u5730\u5740 --source-base-system \u6307\u5b9a Linux Mint / Raspberry Pi OS \u5e95\u5c42\u7cfb\u7edf\u7684\u8f6f\u4ef6\u6e90\u5730\u5740(\u57df\u540d\u6216IP) \u5730\u5740 --branch \u6307\u5b9a\u8f6f\u4ef6\u6e90\u4ed3\u5e93(\u8def\u5f84) \u4ed3\u5e93\u540d --branch-epel \u6307\u5b9a EPEL \u9644\u52a0\u8f6f\u4ef6\u5305\u4ed3\u5e93\u7684\u8f6f\u4ef6\u6e90\u4ed3\u5e93(\u8def\u5f84) \u4ed3\u5e93\u540d --branch-security \u6307\u5b9a Debian \u7cfb\u7edf security \u4ed3\u5e93\u7684\u8f6f\u4ef6\u6e90\u4ed3\u5e93(\u8def\u5f84) \u4ed3\u5e93\u540d --branch-vault \u6307\u5b9a CentOS / AlmaLinux \u7cfb\u7edf vault \u4ed3\u5e93\u7684\u8f6f\u4ef6\u6e90\u4ed3\u5e93(\u8def\u5f84) \u4ed3\u5e93\u540d --branch-portage \u6307\u5b9a Gentoo \u7cfb\u7edf portage \u4ed3\u5e93\u7684\u8f6f\u4ef6\u6e90\u4ed3\u5e93(\u8def\u5f84) \u4ed3\u5e93\u540d --branch-base-system \u6307\u5b9a Linux Mint / Raspberry Pi OS \u5e95\u5c42\u7cfb\u7edf\u7684\u8f6f\u4ef6\u6e90\u4ed3\u5e93(\u8def\u5f84) \u4ed3\u5e93\u540d --codename \u6307\u5b9a Debian \u7cfb / openKylin \u64cd\u4f5c\u7cfb\u7edf\u7684\u7248\u672c\u4ee3\u53f7 \u4ee3\u53f7\u540d\u79f0 --protocol \u6307\u5b9a Web \u534f\u8bae http \u6216 https --use-intranet-source \u662f\u5426\u4f18\u5148\u4f7f\u7528\u5185\u7f51\u8f6f\u4ef6\u6e90\u5730\u5740 true \u6216 false --use-official-source \u662f\u5426\u4f7f\u7528\u76ee\u6807\u64cd\u4f5c\u7cfb\u7edf\u7684\u5b98\u65b9\u8f6f\u4ef6\u6e90 true \u6216 false --use-official-source-epel \u662f\u5426\u4f7f\u7528 EPEL \u9644\u52a0\u8f6f\u4ef6\u5305\u7684\u5b98\u65b9\u8f6f\u4ef6\u6e90 true \u6216 false --install-epel \u662f\u5426\u5b89\u88c5 EPEL \u9644\u52a0\u8f6f\u4ef6\u5305 true \u6216 false --backup \u662f\u5426\u5907\u4efd\u539f\u6709\u8f6f\u4ef6\u6e90 true \u6216 false --upgrade-software \u662f\u5426\u66f4\u65b0\u8f6f\u4ef6\u5305 true \u6216 false --clean-cache \u662f\u5426\u5728\u66f4\u65b0\u8f6f\u4ef6\u5305\u540e\u6e05\u7406\u4e0b\u8f7d\u7f13\u5b58 true \u6216 false --clean-screen \u662f\u5426\u5728\u8fd0\u884c\u524d\u6e05\u9664\u5c4f\u5e55\u4e0a\u7684\u6240\u6709\u5185\u5bb9 true \u6216 false --lang \u6307\u5b9a\u811a\u672c\u8f93\u51fa\u7684\u8bed\u8a00 \u8bed\u8a00 --only-epel \u4ec5\u66f4\u6362 EPEL \u8f6f\u4ef6\u6e90\u6a21\u5f0f \u65e0 --ignore-backup-tips \u5ffd\u7565\u8986\u76d6\u5907\u4efd\u63d0\u793a \u65e0 --print-diff \u6253\u5370\u6e90\u6587\u4ef6\u4fee\u6539\u524d\u540e\u5dee\u5f02 \u65e0 --pure-mode \u7eaf\u51c0\u6a21\u5f0f\uff0c\u7cbe\u7b80\u6253\u5370\u5185\u5bb9 \u65e0 --help \u67e5\u770b\u5e2e\u52a9\u83dc\u5355 \u65e0 \u540d\u79f0 \u542b\u4e49 \u9009\u9879\u503c <code>--abroad</code> \u4f7f\u7528\u5883\u5916\u4ee5\u53ca\u6d77\u5916\u8f6f\u4ef6\u6e90 \u65e0 <code>--edu</code> \u4f7f\u7528\u4e2d\u56fd\u5927\u9646\u6559\u80b2\u7f51\u8f6f\u4ef6\u6e90 \u65e0 <code>--source</code> \u6307\u5b9a\u8f6f\u4ef6\u6e90\u5730\u5740\uff08\u57df\u540d\u6216IP\uff09 <code>\u5730\u5740</code> <code>--source-epel</code> \u6307\u5b9a EPEL \u9644\u52a0\u8f6f\u4ef6\u5305\u4ed3\u5e93\u7684\u8f6f\u4ef6\u6e90\u5730\u5740\uff08\u57df\u540d\u6216IP\uff09 <code>\u5730\u5740</code> <code>--source-security</code> \u6307\u5b9a Debian / Ubuntu \u7cfb\u7edf security \u4ed3\u5e93\u7684\u8f6f\u4ef6\u6e90\u5730\u5740\uff08\u57df\u540d\u6216IP\uff09 <code>\u5730\u5740</code> <code>--source-vault</code> \u6307\u5b9a CentOS / AlmaLinux \u7cfb\u7edf vault \u4ed3\u5e93\u7684\u8f6f\u4ef6\u6e90\u5730\u5740\uff08\u57df\u540d\u6216IP\uff09 <code>\u5730\u5740</code> <code>--source-portage</code> \u6307\u5b9a Gentoo \u7cfb\u7edf portage \u4ed3\u5e93\u7684\u8f6f\u4ef6\u6e90\u5730\u5740\uff08\u57df\u540d\u6216IP\uff09 <code>\u5730\u5740</code> <code>--source-base-system</code> \u6307\u5b9a Linux Mint / Raspberry Pi OS \u5e95\u5c42\u7cfb\u7edf\u7684\u8f6f\u4ef6\u6e90\u5730\u5740\uff08\u57df\u540d\u6216IP\uff09 <code>\u5730\u5740</code> <code>--branch</code> \u6307\u5b9a\u8f6f\u4ef6\u6e90\u4ed3\u5e93\uff08\u8def\u5f84\uff09 <code>\u4ed3\u5e93\u540d</code> <code>--branch-epel</code> \u6307\u5b9a EPEL \u9644\u52a0\u8f6f\u4ef6\u5305\u4ed3\u5e93\u7684\u8f6f\u4ef6\u6e90\u4ed3\u5e93\uff08\u8def\u5f84\uff09 <code>\u4ed3\u5e93\u540d</code> <code>--branch-security</code> \u6307\u5b9a Debian \u7cfb\u7edf security \u4ed3\u5e93\u7684\u8f6f\u4ef6\u6e90\u4ed3\u5e93\uff08\u8def\u5f84\uff09 <code>\u4ed3\u5e93\u540d</code> <code>--branch-vault</code> \u6307\u5b9a CentOS / AlmaLinux \u7cfb\u7edf vault \u4ed3\u5e93\u7684\u8f6f\u4ef6\u6e90\u4ed3\u5e93\uff08\u8def\u5f84\uff09 <code>\u4ed3\u5e93\u540d</code> <code>--branch-portage</code> \u6307\u5b9a Gentoo \u7cfb\u7edf portage \u4ed3\u5e93\u7684\u8f6f\u4ef6\u6e90\u4ed3\u5e93\uff08\u8def\u5f84\uff09 <code>\u4ed3\u5e93\u540d</code> <code>--branch-base-system</code> \u6307\u5b9a Linux Mint / Raspberry Pi OS \u5e95\u5c42\u7cfb\u7edf\u7684\u8f6f\u4ef6\u6e90\u4ed3\u5e93\uff08\u8def\u5f84\uff09 <code>\u4ed3\u5e93\u540d</code> <code>--codename</code> \u6307\u5b9a Debian \u7cfb / openKylin \u64cd\u4f5c\u7cfb\u7edf\u7684\u7248\u672c\u4ee3\u53f7 <code>\u4ee3\u53f7\u540d\u79f0</code> <code>--protocol</code> \u6307\u5b9a Web \u534f\u8bae <code>http</code> \u6216 <code>https</code> <code>--use-intranet-source</code> \u662f\u5426\u4f18\u5148\u4f7f\u7528\u5185\u7f51\u8f6f\u4ef6\u6e90\u5730\u5740 <code>true</code> \u6216 <code>false</code> <code>--use-official-source</code> \u662f\u5426\u4f7f\u7528\u76ee\u6807\u64cd\u4f5c\u7cfb\u7edf\u7684\u5b98\u65b9\u8f6f\u4ef6\u6e90 <code>true</code> \u6216 <code>false</code> <code>--use-official-source-epel</code> \u662f\u5426\u4f7f\u7528 EPEL \u9644\u52a0\u8f6f\u4ef6\u5305\u7684\u5b98\u65b9\u8f6f\u4ef6\u6e90 <code>true</code> \u6216 <code>false</code> <code>--install-epel</code> \u662f\u5426\u5b89\u88c5 EPEL \u9644\u52a0\u8f6f\u4ef6\u5305 <code>true</code> \u6216 <code>false</code> <code>--backup</code> \u662f\u5426\u5907\u4efd\u539f\u6709\u8f6f\u4ef6\u6e90 <code>true</code> \u6216 <code>false</code> <code>--upgrade-software</code> \u662f\u5426\u66f4\u65b0\u8f6f\u4ef6\u5305 <code>true</code> \u6216 <code>false</code> <code>--clean-cache</code> \u662f\u5426\u5728\u66f4\u65b0\u8f6f\u4ef6\u5305\u540e\u6e05\u7406\u4e0b\u8f7d\u7f13\u5b58 <code>true</code> \u6216 <code>false</code> <code>--clean-screen</code> \u662f\u5426\u5728\u8fd0\u884c\u524d\u6e05\u9664\u5c4f\u5e55\u4e0a\u7684\u6240\u6709\u5185\u5bb9 <code>true</code> \u6216 <code>false</code> <code>--lang</code> \u6307\u5b9a\u811a\u672c\u8f93\u51fa\u7684\u8bed\u8a00 <code>\u8bed\u8a00ID\uff08\u8be6\u89c1\u4e0b\u65b9\u6587\u6863\uff09</code> <code>--only-epel</code> \u4ec5\u66f4\u6362 EPEL \u8f6f\u4ef6\u6e90\u6a21\u5f0f \u65e0 <code>--ignore-backup-tips</code> \u5ffd\u7565\u8986\u76d6\u5907\u4efd\u63d0\u793a\uff08\u5373\u4e0d\u8986\u76d6\u5907\u4efd\uff09 \u65e0 <code>--print-diff</code> \u662f\u5426\u6253\u5370\u6e90\u6587\u4ef6\u4fee\u6539\u524d\u540e\u5dee\u5f02 \u65e0 <code>--pure-mode</code> \u7eaf\u51c0\u6a21\u5f0f\uff0c\u7cbe\u7b80\u6253\u5370\u5185\u5bb9 \u65e0 <code>--help</code> \u67e5\u770b\u5e2e\u52a9\u83dc\u5355 \u65e0 <p>\u8f6f\u4ef6\u6e90\u5b8c\u6574\u683c\u5f0f <code><WEB\u534f\u8bae>://<\u8f6f\u4ef6\u6e90\u5730\u5740(\u57df\u540d\u6216IP)>/<\u8f6f\u4ef6\u6e90\u4ed3\u5e93(\u8def\u5f84)></code></p> <p>\u4e0b\u9762\u662f\u4e00\u4e9b\u9ad8\u7ea7\u7528\u6cd5\u7684\u4e3e\u4f8b</p>"},{"location":"use/#\u6307\u5b9a\u8f6f\u4ef6\u6e90\u5730\u5740","title":"\u6307\u5b9a\u8f6f\u4ef6\u6e90\u5730\u5740","text":"<pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --source mirror.example.com\n</code></pre>"},{"location":"use/#\u6307\u5b9a\u8f6f\u4ef6\u6e90\u4ed3\u5e93\u76ee\u5f55","title":"\u6307\u5b9a\u8f6f\u4ef6\u6e90\u4ed3\u5e93\u76ee\u5f55","text":"<p>\u8fd9\u91cc\u63cf\u8ff0\u7684\u8f6f\u4ef6\u6e90\u4ed3\u5e93\u4e0e\u7cfb\u7edf\u8f6f\u4ef6\u4ed3\u5e93\u4e0d\u540c\uff0c\u6307\u7684\u662f\u8f6f\u4ef6\u6e90\uff08\u955c\u50cf\u7ad9\uff09\u5730\u5740\u540e\u9762\u7684\u8def\u5f84\u5373\u955c\u50cf\u7ad9\u7684\u4ed3\u5e93\u76ee\u5f55\uff0c\u867d\u7136\u540d\u4e49\u4e0a\u90fd\u662f\u4ed3\u5e93\u4f46\u662f\u975e\u5e38\u5bb9\u6613\u6df7\u6dc6</p> <p>\u4e3b\u8981\u4f7f\u7528\u573a\u666f\uff1a\u76ee\u6807\u955c\u50cf\u7ad9\u6709\u5bf9\u5e94\u7684\u7cfb\u7edf\u955c\u50cf\u4ed3\u5e93\u4f46\u662f\u4e0d\u7b26\u5408\u672c\u9879\u76ee\u811a\u672c\u5173\u4e8e\u8f6f\u4ef6\u6e90\u4ed3\u5e93\u8bbe\u7f6e\u7684\u9ed8\u8ba4\u89c4\u5219</p> \u9879\u76ee\u5bf9\u4e8e\u5404\u64cd\u4f5c\u7cfb\u7edf\u6240\u4f7f\u7528\u7684\u9ed8\u8ba4\u4ed3\u5e93\u540d\u79f0\uff08\u70b9\u51fb\u5c55\u5f00\u67e5\u770b\uff09 <p>\u9879\u76ee\u811a\u672c\u4e3a\u4e86\u9002\u914d\u5927\u7684\u73af\u5883\u4e0d\u4f1a\u9488\u5bf9\u67d0\u4e00\u955c\u50cf\u7ad9\u72ec\u7279\u7684\u4ed3\u5e93\u540d\u79f0\u800c\u5355\u72ec\u9002\u914d</p> SYSTEM NAMES Debian <code>debian</code> <code>debian-archive</code> Ubuntu <code>ubuntu</code> <code>ubuntu-ports</code> Kali Linux <code>kali</code> Linux Mint <code>linuxmint</code> <code>ubuntu</code> <code>ubuntu-ports</code> <code>debian</code> Deepin <code>deepin</code> Zorin OS <code>ubuntu</code> <code>ubuntu-ports</code> Armbian <code>armbian</code> Proxmox VE <code>proxmox</code> Raspberry Pi OS <code>raspberrypi</code> <code>raspbian</code> <code>debian</code> <code>debian-archive</code> Red Hat Enterprise Linux <code>centos</code> <code>centos-stream</code> <code>centos-altarch</code> <code>centos-vault</code> Fedora <code>fedora</code> <code>fedora-archive</code> CentOS <code>centos</code> <code>centos-stream</code> <code>centos-altarch</code> <code>centos-vault</code> Rocky Linux <code>rocky</code> AlmaLinux <code>almalinux</code> <code>almalinux-vault</code> Oracle Linux <code>centos-stream</code> openEuler <code>openeuler</code> OpenCloudOS <code>opencloudos</code> openKylin <code>openkylin</code> Anolis OS <code>anolis</code> openSUSE <code>opensuse</code> Arch Linux <code>archlinux</code> <code>archlinuxarm</code> Manjaro <code>manjaro</code> EndeavourOS <code>endeavouros</code> Alpine Linux <code>alpine</code> Gentoo <code>gentoo</code> <code>gentoo-portage</code> NixOS <code>nix-channels</code> <p>\u8bf7\u770b\u4e0b\u9762\u7684\u4f8b\u5b50</p> \u4f7f\u7528\u963f\u91cc\u4e91\u955c\u50cf\u7ad9\u7684 Rocky Linux \u8f6f\u4ef6\u6e90<pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) \\\n --source mirrors.aliyun.com \\\n --branch rockylinux\n</code></pre> <p>\u963f\u91cc\u4e91\u955c\u50cf\u7ad9\u7684 Rocky Linux \u4ed3\u5e93\u76ee\u5f55\u540d\u79f0\u4e3a <code>rockylinux</code>\uff0c\u4e0d\u7b26\u5408\u9ed8\u8ba4\u89c4\u5219 <code>rocky</code>\uff0c\u4f46\u662f\u53ef\u4ee5\u901a\u8fc7\u547d\u4ee4\u9009\u9879\u7ed5\u8fc7\u811a\u672c\u9ed8\u8ba4\u89c4\u5219\u6765\u5b9e\u73b0\u3002</p> <p>\u90e8\u5206\u7cfb\u7edf\u4f1a\u540c\u65f6\u914d\u7f6e\u591a\u4e2a\u4ed3\u5e93\u7684\u8f6f\u4ef6\u6e90\uff0c\u5177\u4f53\u8be6\u89c1\u547d\u4ee4\u9009\u9879</p> <p>\u7531\u4e8e\u8f6f\u4ef6\u6e90\u4ed3\u5e93\u4f5c\u7528\u5728\u8f6f\u4ef6\u6e90\u5730\u5740\u4e0a\u56e0\u6b64\u4e5f\u53ef\u4ee5\u4f7f\u7528\u591a\u7ea7\u8def\u5f84\uff0c\u4f8b\u5982 <code>--branch \"linux/debian\"</code> -> <code>https://mirrors.example.com/linux/debian</code></p>"},{"location":"use/#\u5355\u72ec\u66f4\u6362-epel-\u6e90","title":"\u5355\u72ec\u66f4\u6362 EPEL \u6e90","text":"<p>EPEL (Extra Packages for Enterprise Linux) \u662f\u7531 Fedora \u7ec4\u7ec7\u7ef4\u62a4\u7684\u4e00\u4e2a\u9644\u52a0\u8f6f\u4ef6\u5305\u4ed3\u5e93\uff0c\u5b83\u4e3b\u8981\u9002\u7528\u4e8e\u9664 Fedora \u64cd\u4f5c\u7cfb\u7edf\u4ee5\u5916\u7684\u7ea2\u5e3d\u7cfb Linux \u53d1\u884c\u7248\uff0c\u914d\u7f6e EPEL \u4ed3\u5e93\u5df2\u6210\u4e3a\u5e7f\u5927\u7528\u6237\u7684\u666e\u904d\u9700\u6c42\uff0c\u5efa\u8bae\u9ed8\u8ba4\u5b89\u88c5\u5b83</p> <p>\u6709\u4e9b\u65f6\u5019\u4f60\u4f1a\u53d1\u73b0\u60f3\u4f7f\u7528\u7684\u955c\u50cf\u7ad9\u6ca1\u6709 EPEL \u4ed3\u5e93\uff0c\u90a3\u4e48\u4f60\u53ef\u4ee5\u5728\u7b2c\u4e00\u6b21\u8fd0\u884c\u811a\u672c\u65f6\u4e0d\u5b89\u88c5\u6216\u66f4\u6362 EPEL \u6e90\u7136\u540e\u518d\u5355\u72ec\u6267\u884c\u4e0b\u9762\u7684\u547d\u4ee4</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --only-epel\n</code></pre> <p>\u5bf9\u4e8e\u5df2\u7ecf EOL \u7684 EPEL 7\uff0c\u6ce8\u610f\u9700\u8981\u4f7f\u7528 <code>archive</code> \u4ed3\u5e93\uff0c\u5883\u5916\u4ee5\u53ca\u6d77\u5916\u7f51\u7edc\u73af\u5883\u5efa\u8bae\u901a\u8fc7\u547d\u4ee4\u9009\u9879 <code>--use-official-source-epel true</code> \u4f7f\u7528\u5b98\u65b9\u6e90</p>"},{"location":"use/#\u6062\u590d\u4f7f\u7528\u5b98\u65b9\u6e90","title":"\u6062\u590d\u4f7f\u7528\u5b98\u65b9\u6e90","text":"<p>\u5f53\u4f60\u4e0d\u5c0f\u5fc3\u5220\u9664\u4e86\u5b98\u65b9\u6e90\u7684\u5907\u4efd\u65f6\u53ef\u4ee5\u4f7f\u7528\u6b64\u547d\u4ee4\u6765\u6062\u590d\uff0c\u4f7f\u7528\u6b64\u547d\u4ee4\u9009\u9879\u540e\u5c06\u8df3\u8fc7\u9009\u62e9\u8f6f\u4ef6\u6e90\u6b65\u9aa4</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --use-official-source true\n</code></pre> <p>\u90e8\u5206\u7cfb\u7edf\u4e0d\u5b58\u5728\u5b98\u65b9\u6e90\u4f8b\u5982 <code>Arch Linux</code>\uff0c\u5c4a\u65f6\u4f1a\u81ea\u52a8\u66f4\u6362\u6210\u517c\u5bb9\u6027\u8f83\u9ad8\u7684\u963f\u91cc\u4e91\u955c\u50cf\u7ad9</p>"},{"location":"use/#\u7279\u5b9a\u7cfb\u7edf\u7684\u4f7f\u7528\u793a\u4f8b","title":"\u7279\u5b9a\u7cfb\u7edf\u7684\u4f7f\u7528\u793a\u4f8b","text":""},{"location":"use/#\u5173\u4e8e-centos-\u505c\u670d\u95ee\u9898","title":"\u5173\u4e8e CentOS \u505c\u670d\u95ee\u9898","text":"<p>\u811a\u672c\u5bf9\u4e8e\u5df2\u7ecf EOL \u7684 CentOS 7/8\u3001CentOS Stream 8 \u8fdb\u884c\u4e86\u9002\u914d</p> <ul> <li> <p>\u56fd\u5185\u73af\u5883</p> <p>\u6b63\u5e38\u4f7f\u7528\u811a\u672c\uff0c\u6ca1\u6709\u989d\u5916\u64cd\u4f5c\uff0c\u56e0\u4e3a\u56fd\u5185\u5927\u90e8\u5206\u955c\u50cf\u7ad9\u90fd\u5df2\u540c\u6b65 <code>CentOS Vault</code> \u4ed3\u5e93</p> </li> <li> <p>\u5883\u5916\u4ee5\u53ca\u6d77\u5916\u73af\u5883</p> <p>\u5efa\u8bae\u4f7f\u7528 <code>\u817e\u8baf\u4e91</code> \u6216 <code>\u963f\u91cc\u4e91</code> \u955c\u50cf\u7ad9\uff0c\u6216\u8005\u901a\u8fc7 <code>--use-official-source true</code> \u547d\u4ee4\u9009\u9879\u4f7f\u7528\u5b98\u65b9\u6e90</p> </li> </ul> <p>\u53e6\u5916 EPEL 7 \u4e5f\u8fdb\u5165\u4e86 EOL\uff0c\u811a\u672c\u540c\u6837\u5bf9\u5176\u8fdb\u884c\u4e86\u9002\u914d</p>"},{"location":"use/#\u6307\u5b9a-gnulinux-debian-\u64cd\u4f5c\u7cfb\u7edf\u7684-security-\u6e90","title":"\u6307\u5b9a GNU/Linux Debian \u64cd\u4f5c\u7cfb\u7edf\u7684 Security \u6e90","text":"<p>\u5982\u679c\u4f60\u60f3\u5c3d\u53ef\u80fd\u63d0\u9ad8\u670d\u52a1\u5668\u7684\u5b89\u5168\u6027\u5219\u5efa\u8bae\u4f7f\u7528\u5b98\u65b9\u6e90\uff0c\u56e0\u4e3a\u955c\u50cf\u540c\u6b65\u5b58\u5728\u5ef6\u8fdf</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) \\\n --source-security security.debian.org \\\n --branch-security debian-security\n</code></pre>"},{"location":"use/#\u6307\u5b9a-debian-\u7cfb-linux-\u64cd\u4f5c\u7cfb\u7edf\u7684\u7248\u672c\u4ee3\u53f7","title":"\u6307\u5b9a Debian \u7cfb Linux \u64cd\u4f5c\u7cfb\u7edf\u7684\u7248\u672c\u4ee3\u53f7","text":"<p>\u5927\u591a\u6570\u60c5\u51b5\u4e0b\u81ea\u5b9a\u4e49\u7248\u672c\u4ee3\u53f7\u7528\u4e8e\u66f4\u6362\u7cfb\u7edf\u7248\u672c\uff0c\u8bf7\u770b\u4e0b\u9762\u7684\u4f8b\u5b50</p> \u5347\u7ea7 GNU/Linux Debian \u81f3 13 \"trixie\"\u5c06 GNU/Linux Debian \u7684\u7248\u672c\u5207\u6362\u5230\u6d4b\u8bd5\u5206\u652f <ul> <li> <p>\u66f4\u6362\u7248\u672c\u4ee3\u53f7</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) \\\n --codename trixie \\\n --upgrade-software false\n</code></pre> </li> <li> <p>\u7981\u7528 backports \u4ed3\u5e93</p> <pre><code>sed -i '/backports/s/^/# /' /etc/apt/sources.list\n</code></pre> </li> <li> <p>\u5347\u7ea7\u7cfb\u7edf</p> <pre><code>apt-get update\napt-get dist-upgrade\n</code></pre> </li> <li> <p>\u5728\u5347\u7ea7\u5b8c\u6210\u5e76\u91cd\u65b0\u5f15\u5bfc\u7cfb\u7edf\u540e\u6267\u884c\u4ee5\u4e0b\u6b65\u9aa4</p> <pre><code># \u6e05\u7a7a\u539f\u6709\u8f6f\u4ef6\u6e90\uff08\u5982\u6709\u975e\u7cfb\u7edf\u8f6f\u4ef6\u6e90\u5185\u5bb9\u8bf7\u5148\u81ea\u884c\u624b\u52a8\u5907\u4efd\uff09\nsed -i '1,$d' /etc/apt/sources.list\n# \u91cd\u65b0\u6267\u884c\u6362\u6e90\u811a\u672c\nbash <(curl -sSL https://linuxmirrors.cn/main.sh)\n</code></pre> </li> </ul> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) \\\n --codename testing \\\n --upgrade-software false\n</code></pre> \u82e5\u811a\u672c\u65e0\u6cd5\u5b9e\u73b0\u6307\u5b9a\u7248\u672c\u4ee3\u53f7\uff0c\u4f60\u4e5f\u53ef\u4ee5\u5728\u6267\u884c\u811a\u672c\u540e\u624b\u52a8\u66ff\u6362<pre><code>sed -i \"s/$(lsb_release -cs)/\u6307\u5b9a\u7248\u672c\u4ee3\u53f7/g\" /etc/apt/sources.list\n</code></pre>"},{"location":"use/#\u66f4\u6362-ubuntu-eol\u7248\u672c\u8f6f\u4ef6\u6e90","title":"\u66f4\u6362 Ubuntu EOL\u7248\u672c\u8f6f\u4ef6\u6e90","text":"<p>EOL \u4e3a\u751f\u547d\u5468\u671f\u7ed3\u675f\u7684\u7f29\u5199\uff08End Of Life\uff09\uff0cUbuntu \u8fed\u4ee3\u901f\u5ea6\u8f83\u5feb\u4e00\u822c\u975eLTS(\u957f\u671f\u652f\u6301)\u7248\u672c\u7684\u751f\u547d\u5468\u671f\u53ea\u67099\u4e2a\u6708\u3002\u5b98\u65b9\u4f1a\u5b9a\u671f\u4ece\u4e3b\u4ed3\u5e93\u79fb\u9664\u4e0d\u5728\u751f\u547d\u5468\u671f\u5185\u7684\u7248\u672c\u4ed3\u5e93\u76ee\u5f55\uff0c\u5c4a\u65f6\u53ef\u80fd\u5c31\u9700\u8981\u4f7f\u7528\u955c\u50cf\u7ad9\u7684 <code>Ubuntu Old Releases</code> \u4ed3\u5e93</p> <p>\u5177\u4f53\u7248\u672c\u652f\u6301\u60c5\u51b5\u8be6\u89c1\u5b98\u65b9 Wiki\uff0c\u5173\u4e8e <code>Ubuntu Old Releases</code> \u4ed3\u5e93\u7684\u652f\u6301\u60c5\u51b5\u8be6\u89c1\u5404\u955c\u50cf\u7ad9</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) \\\n --source mirrors.ustc.edu.cn \\\n --branch ubuntu-old-releases\n</code></pre>"},{"location":"use/#arch-linux-\u4f7f\u7528\u4e2d\u6587\u793e\u533a\u4ed3\u5e93","title":"Arch Linux \u4f7f\u7528\u4e2d\u6587\u793e\u533a\u4ed3\u5e93","text":"<p>\u672c\u9879\u76ee\u811a\u672c\u5f53\u524d\u4e0d\u652f\u6301\u8be5\u989d\u5916\u4ed3\u5e93\uff0c\u7531\u4e8e\u4f7f\u7528\u4eba\u6570\u8f83\u5c11\u7b49\u539f\u56e0\u6682\u4e0d\u8003\u8651\u9002\u914d\uff0c\u82e5\u60f3\u4f7f\u7528\u8bf7\u53c2\u8003\u4e0b\u65b9\u7684\u4e00\u952e\u914d\u7f6e\u547d\u4ee4</p> <pre><code>SOURCE=\"https://mirrors.aliyun.com/archlinuxcn\" # \u6307\u5b9a\u8f6f\u4ef6\u6e90\u5730\u5740\ngrep -q \"\\[archlinuxcn\\]\" /etc/pacman.conf || echo -e \"[archlinuxcn]\\nServer = ${SOURCE}/\\$arch\" >>/etc/pacman.conf # \u4e00\u952e\u914d\u7f6e\u547d\u4ee4\n</code></pre>"},{"location":"use/#\u56fd\u9645\u5316i18n","title":"\u56fd\u9645\u5316\uff08I18n\uff09","text":"<p>\u811a\u672c\u63d0\u4f9b\u591a\u8bed\u8a00\u652f\u6301\uff0c\u5f53\u524d\u5185\u7f6e <code>\u7b80\u4f53\u4e2d\u6587</code>\u3001<code>\u7e41\u9ad4\u4e2d\u6587</code>\u3001<code>English</code> \u5171\u4e09\u79cd\u663e\u793a\u8bed\u8a00\uff0c\u9ed8\u8ba4\u4e3a <code>\u7b80\u4f53\u4e2d\u6587</code></p>"},{"location":"use/#\u6307\u5b9a\u8bed\u8a00","title":"\u6307\u5b9a\u8bed\u8a00","text":"<pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --lang xxx\n</code></pre> \u7c7b\u578b \u503c \u7b80\u4f53\u4e2d\u6587 <code>zh-hans</code> <code>zh-cn</code> <code>zh</code> \u7e41\u9ad4\u4e2d\u6587 <code>zh-hant</code> <code>zh-tw</code> <code>zh-hk</code> English <code>en</code> <code>en-us</code> <p>\u4e5f\u53ef\u4ee5\u76f4\u63a5\u4f5c\u4e3a\u547d\u4ee4\u9009\u9879\u4f7f\u7528</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --en\n</code></pre> <p><code>--en</code> <code>--en-us</code> <code>--zh</code> <code>--zh-cn</code> <code>--zh-hans</code> <code>--zh-hant</code></p>"},{"location":"use/#\u901a\u8fc7\u4ea4\u4e92\u8fdb\u884c\u9009\u62e9","title":"\u901a\u8fc7\u4ea4\u4e92\u8fdb\u884c\u9009\u62e9","text":"<pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --lang auto\n</code></pre>"},{"location":"use/#\u65e0\u4eba\u503c\u5b88\u81ea\u52a8\u5316","title":"\u65e0\u4eba\u503c\u5b88\uff08\u81ea\u52a8\u5316\uff09","text":"<p>\u4e0d\u901a\u8fc7\u4ea4\u4e92\u5b8c\u6210\u6362\u6e90\u64cd\u4f5c\uff0c\u81f3\u5c11\u9700\u8981\u4f7f\u7528\u5982\u4e0b\u547d\u4ee4\u9009\u9879\u6765\u5b9e\u73b0\uff0c\u5efa\u8bae\u719f\u6089\u540e\u518d\u4f7f\u7528</p> \u53c2\u8003\u547d\u4ee4<pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) \\\n --source mirror.example.com \\\n --protocol http \\\n --use-intranet-source false \\\n --install-epel true \\\n --backup true \\\n --upgrade-software false \\\n --clean-cache false \\\n --ignore-backup-tips\n</code></pre> <p>\u5982\u679c\u62a5\u9519 <code>\u547d\u4ee4\u9009\u9879\u65e0\u6548</code> \u90a3\u4e48\u8bf7\u68c0\u67e5\u9009\u9879\u5408\u6cd5\u6027\u4ee5\u53ca\u7a7a\u683c\u5b57\u7b26\u7f16\u7801\uff0c\u5728\u793a\u4f8b\u4e2d\u4e00\u884c\u5199\u4e00\u4e2a\u9009\u9879\u662f\u4e3a\u4e86\u63d0\u9ad8\u547d\u4ee4\u7684\u53ef\u8bfb\u6027</p>"},{"location":"use/#\u7eaf\u51c0\u6a21\u5f0f","title":"\u7eaf\u51c0\u6a21\u5f0f","text":"<p>\u63a8\u51fa\u8be5\u529f\u80fd\u662f\u4e3a\u4e86\u4fbf\u4e8e\u5f00\u53d1\u4ee5\u53ca\u8fd0\u7ef4\u4eba\u5458\u4f7f\u7528\uff0c\u542f\u7528\u540e\u4f1a\u7cbe\u7b80\u811a\u672c\u5185\u5bb9\u8f93\u51fa\uff0c\u5efa\u8bae\u642d\u914d\u5176\u5b83\u547d\u4ee4\u9009\u9879\u65e0\u4ea4\u4e92\u4f7f\u7528</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --pure-mode\n</code></pre> <p>\u6eda\u52a8\u8f93\u51fa\u7684\u547d\u4ee4\u65e5\u5fd7\u53ef\u80fd\u5b58\u5728\u65e0\u6cd5\u9884\u6599\u7684\u663e\u793a\u95ee\u9898\uff0c\u4e0d\u8fc7\u76ee\u524d\u6682\u672a\u53d1\u73b0\u5f02\u5e38</p>"},{"location":"use/#\u5b9a\u5236\u811a\u672c","title":"\u5b9a\u5236\u811a\u672c","text":"<p>\u5982\u679c\u4f60\u662f\u5176\u5b83\u9879\u76ee\u7684\u5f00\u53d1\u8005\u5e0c\u671b\u901a\u8fc7\u672c\u9879\u76ee\u6765\u5236\u4f5c\u4e13\u5c5e\u811a\u672c\u90a3\u4e48\u8bf7\u53c2\u8003\u4e0b\u9762\u63d0\u5230\u7684\u5185\u5bb9\uff0c\u76ee\u524d\u5df2\u7ecf\u6709\u56fd\u5185\u6559\u80b2\u5355\u4f4d\u955c\u50cf\u7ad9\u7684\u7ef4\u62a4\u8005\u8fd9\u6837\u505a\u4e86\u3002</p> <ol> <li>\u9996\u5148\u4e0d\u5efa\u8bae\u4fee\u6539\u4ee3\u7801\u7684\u5e95\u5c42\u903b\u8f91\uff0c\u5e94\u5c3d\u91cf\u4e0e\u672c\u9879\u76ee\u6e90\u7801\u4fdd\u6301\u540c\u6b65\uff0c\u811a\u672c\u5185\u5bb9\u6267\u884c\u987a\u5e8f\u7531 <code>main</code> \u51fd\u6570\u63a7\u5236\uff0c\u4ee3\u7801\u903b\u8f91\u6e05\u6670</li> <li>\u4f60\u53ef\u4ee5\u7b80\u5355\u53bb\u9664\u4e00\u4e9b\u65e0\u5173\u5185\u5bb9\uff0c\u4f8b\u5982\u5c06\u8f6f\u4ef6\u6e90\u5217\u8868\uff08\u6570\u7ec4\uff09<code>mirror_list_(default|edu|abroad|extranet|intranet)</code> \u4e2d\u7684\u5185\u5bb9\u5220\u9664\uff0c\u4f8b\uff1a<code>mirror_list_default=()</code></li> <li>\u5982\u679c\u4f60\u60f3\u5b9a\u5236\u811a\u672c\u6253\u5370\u5185\u5bb9\u53ef\u76f4\u63a5\u4fee\u6539 <code>run_start</code> <code>run_end</code> <code>print_title</code> \u8fd9\u4e09\u4e2a\u51fd\u6570\u4e2d\u7684\u5185\u5bb9</li> <li>\u5982\u679c\u4f60\u60f3\u6dfb\u52a0\u81ea\u5b9a\u4e49 Shell \u5185\u5bb9\u8be6\u89c1 <code>main</code> \u51fd\u6570\u4e2d\u811a\u672c\u6267\u884c\u987a\u5e8f\uff0c\u53ef\u4ee5\u5728\u5bf9\u5e94\u4f4d\u7f6e\u76f4\u63a5\u63d2\u5165\u5185\u5bb9\u4e5f\u53ef\u4ee5\u5c01\u88c5\u51fd\u6570\u540e\u8c03\u7528</li> <li>\u5982\u679c\u4f60\u60f3\u8981\u7f29\u51cf\u811a\u672c\u4f53\u79ef\u90a3\u4e48\u53ef\u4ee5\u5220\u9664\u4e00\u4e9b\u4e0d\u5fc5\u8981\u7684\u5185\u5bb9\uff0c\u9664\u4e86\u4e0a\u9762\u63d0\u5230\u7684\u8f6f\u4ef6\u6e90\u5217\u8868\u8fd8\u6709\u4e00\u4e9b\u6d89\u53ca\u811a\u672c\u5de5\u4f5c\u7684\u90e8\u5206\u6a21\u5757\u5185\u5bb9\uff0c\u5177\u4f53\u5982\u4e0b\uff1a<ol> <li>\u9996\u5148\u5728\u5220\u9664\u5185\u5bb9\u65f6\u5e94\u5c3d\u53ef\u80fd\u4fdd\u7559\u811a\u672c\u539f\u59cb\u7ed3\u6784\uff0c\u76f4\u63a5\u628a\u6d89\u53ca\u51fd\u6570\u4e2d\u7684\u5185\u5bb9\u5220\u9664\u5373\u53ef\uff0c\u4f7f\u5176\u4fdd\u7559\u4e3a\u7a7a\u51fd\u6570</li> <li>\u53ef\u4ee5\u5220\u9664\u4e00\u4e9b\u4e0d\u4f7f\u7528\uff08\u64cd\u4f5c\u7cfb\u7edf\uff09\u7684\u8f6f\u4ef6\u6e90\u539f\u59cb\u5185\u5bb9 <code>gen_repo_files_xxx</code>\uff0c\u8fd9\u4e9b\u5185\u5bb9\u5360\u636e\u4e86\u811a\u672c <code>60%</code> \u4ee5\u4e0a\u7684\u4f53\u79ef</li> <li>\u5982\u679c\u4f60\u4e0d\u4f7f\u7528\u67d0\u4e9b\u529f\u80fd\u90a3\u4e48\u53ef\u4ee5\u5220\u9664\u5bf9\u5e94\u529f\u80fd\u6a21\u5757\u51fd\u6570\u4e2d\u7684\u5185\u5bb9\uff0c<code>\u547d\u4ee4\u9009\u9879 handle_command_options</code>\u3001<code>\u5907\u4efd\u539f\u6709\u8f6f\u4ef6\u6e90 backup_original_mirrors</code>\u3001<code>\u66f4\u65b0\u8f6f\u4ef6\u5305 upgrade_software</code></li> <li>\u79fb\u9664\u4e0d\u9700\u8981\u7684\u8bed\u8a00\u5305\uff0c\u4f8b\uff1a<code>function msg_pack_en() {}</code></li> </ol> </li> <li>\u811a\u672c\u4e3b\u8981\u529f\u80fd\u914d\u7f6e\u662f\u7531\u7edf\u4e00\u7684\u53d8\u91cf\u63a7\u5236\u7684\uff0c\u547d\u4ee4\u9009\u9879\u4ea6\u662f\u5982\u6b64\uff0c\u8fd9\u4e9b\u5168\u5c40\u53d8\u91cf\u7531\u5168\u5927\u5199\u5b57\u6bcd\u6784\u6210\u5e76\u9075\u5faa\u4e0b\u5212\u7ebf\u547d\u540d\u6cd5\uff0c\u5177\u4f53\u53d8\u91cf\u8be6\u89c1\u5982\u4e0b\u8868\u683c\uff0c\u4f60\u53ea\u9700\u8981\u5c06\u8fd9\u4e9b\u53d8\u91cf\u58f0\u660e\u5728\u811a\u672c\u5934\u90e8\uff08\u9884\u7559\u6ce8\u91ca\u533a\u57df\uff09\u5373\u53ef\u5feb\u901f\u5b8c\u6210\u5b9a\u5236</li> </ol> \u53d8\u91cf\u5217\u8868\uff08\u70b9\u51fb\u5c55\u5f00\u67e5\u770b\uff09 \u53d8\u91cf\u540d \u542b\u4e49 \u503c\u7c7b\u578b <code>SOURCE</code> \u6307\u5b9a\u8f6f\u4ef6\u6e90\u5730\u5740\uff08\u57df\u540d\u6216IP\uff09 <code>\u5730\u5740</code> <code>SOURCE_EPEL</code> \u6307\u5b9a EPEL \u9644\u52a0\u8f6f\u4ef6\u5305\u4ed3\u5e93\u7684\u8f6f\u4ef6\u6e90\u5730\u5740\uff08\u57df\u540d\u6216IP\uff09 <code>\u5730\u5740</code> <code>SOURCE_SECURITY</code> \u6307\u5b9a Debian / Ubuntu \u7cfb\u7edf security \u4ed3\u5e93\u7684\u8f6f\u4ef6\u6e90\u5730\u5740\uff08\u57df\u540d\u6216IP\uff09 <code>\u5730\u5740</code> <code>SOURCE_VAULT</code> \u6307\u5b9a CentOS / AlmaLinux \u7cfb\u7edf vault \u4ed3\u5e93\u7684\u8f6f\u4ef6\u6e90\u5730\u5740\uff08\u57df\u540d\u6216IP\uff09 <code>\u5730\u5740</code> <code>SOURCE_PORTAGE</code> \u6307\u5b9a Gentoo \u7cfb\u7edf portage \u4ed3\u5e93\u7684\u8f6f\u4ef6\u6e90\u5730\u5740\uff08\u57df\u540d\u6216IP\uff09 <code>\u5730\u5740</code> <code>SOURCE_BASE_SYSTEM</code> \u6307\u5b9a Linux Mint / Raspberry Pi OS \u5e95\u5c42\u7cfb\u7edf\u7684\u8f6f\u4ef6\u6e90\u5730\u5740\uff08\u57df\u540d\u6216IP\uff09 <code>\u5730\u5740</code> <code>SOURCE_BRANCH</code> \u6307\u5b9a\u8f6f\u4ef6\u6e90\u4ed3\u5e93\uff08\u8def\u5f84\uff09 <code>\u4ed3\u5e93\u540d</code> <code>SOURCE_EPEL_BRANCH</code> \u6307\u5b9a EPEL \u9644\u52a0\u8f6f\u4ef6\u5305\u4ed3\u5e93\u7684\u8f6f\u4ef6\u6e90\u4ed3\u5e93\uff08\u8def\u5f84\uff09 <code>\u4ed3\u5e93\u540d</code> <code>SOURCE_SECURITY_BRANCH</code> \u6307\u5b9a Debian \u7cfb\u7edf security \u4ed3\u5e93\u7684\u8f6f\u4ef6\u6e90\u4ed3\u5e93\uff08\u8def\u5f84\uff09 <code>\u4ed3\u5e93\u540d</code> <code>SOURCE_VAULT_BRANCH</code> \u6307\u5b9a CentOS / AlmaLinux \u7cfb\u7edf vault \u4ed3\u5e93\u7684\u8f6f\u4ef6\u6e90\u4ed3\u5e93\uff08\u8def\u5f84\uff09 <code>\u4ed3\u5e93\u540d</code> <code>SOURCE_PORTAGE_BRANCH</code> \u6307\u5b9a Gentoo \u7cfb\u7edf portage \u4ed3\u5e93\u7684\u8f6f\u4ef6\u6e90\u4ed3\u5e93\uff08\u8def\u5f84\uff09 <code>\u4ed3\u5e93\u540d</code> <code>SOURCE_BASE_SYSTEM_BRANCH</code> \u6307\u5b9a Linux Mint / Raspberry Pi OS \u5e95\u5c42\u7cfb\u7edf\u7684\u8f6f\u4ef6\u6e90\u4ed3\u5e93\uff08\u8def\u5f84\uff09 <code>\u4ed3\u5e93\u540d</code> <code>DEBIAN_CODENAME</code> \u6307\u5b9a Debian \u7cfb / openKylin \u64cd\u4f5c\u7cfb\u7edf\u7684\u7248\u672c\u4ee3\u53f7 <code>\u4ee3\u53f7\u540d\u79f0</code> <code>USE_INTRANET_SOURCE</code> \u662f\u5426\u4f18\u5148\u4f7f\u7528\u5185\u7f51\u8f6f\u4ef6\u6e90\u5730\u5740 <code>true</code> \u6216 <code>false</code> <code>USE_OFFICIAL_SOURCE</code> \u662f\u5426\u4f7f\u7528\u76ee\u6807\u64cd\u4f5c\u7cfb\u7edf\u7684\u5b98\u65b9\u8f6f\u4ef6\u6e90 <code>true</code> \u6216 <code>false</code> <code>USE_OFFICIAL_SOURCE_EPEL</code> \u662f\u5426\u4f7f\u7528 EPEL \u9644\u52a0\u8f6f\u4ef6\u5305\u7684\u5b98\u65b9\u8f6f\u4ef6\u6e90 <code>true</code> \u6216 <code>false</code> <code>WEB_PROTOCOL</code> \u6307\u5b9a Web \u534f\u8bae <code>http</code> \u6216 <code>https</code> <code>INSTALL_EPEL</code> \u662f\u5426\u5b89\u88c5 EPEL \u9644\u52a0\u8f6f\u4ef6\u5305 <code>true</code> \u6216 <code>false</code> <code>ONLY_EPEL</code> \u4ec5\u66f4\u6362 EPEL \u8f6f\u4ef6\u6e90\u6a21\u5f0f <code>true</code> \u6216 <code>false</code> <code>BACKUP</code> \u662f\u5426\u5907\u4efd\u539f\u6709\u8f6f\u4ef6\u6e90 <code>true</code> \u6216 <code>false</code> <code>IGNORE_BACKUP_TIPS</code> \u5ffd\u7565\u8986\u76d6\u5907\u4efd\u63d0\u793a\uff08\u5373\u4e0d\u8986\u76d6\u5907\u4efd\uff09 <code>true</code> \u6216 <code>false</code> <code>UPGRADE_SOFTWARE</code> \u662f\u5426\u66f4\u65b0\u8f6f\u4ef6\u5305 <code>true</code> \u6216 <code>false</code> <code>CLEAN_CACHE</code> \u662f\u5426\u5728\u66f4\u65b0\u8f6f\u4ef6\u5305\u540e\u6e05\u7406\u4e0b\u8f7d\u7f13\u5b58 <code>true</code> \u6216 <code>false</code> <code>CLEAN_SCREEN</code> \u662f\u5426\u5728\u8fd0\u884c\u524d\u6e05\u9664\u5c4f\u5e55\u4e0a\u7684\u6240\u6709\u5185\u5bb9 <code>true</code> \u6216 <code>false</code> <code>PRINT_DIFF</code> \u662f\u5426\u6253\u5370\u6e90\u6587\u4ef6\u4fee\u6539\u524d\u540e\u5dee\u5f02 <code>true</code> \u6216 <code>false</code> <code>PURE_MODE</code> \u7eaf\u51c0\u6a21\u5f0f\uff0c\u7cbe\u7b80\u6253\u5370\u5185\u5bb9 <code>true</code> \u6216 <code>false</code> <p>\u90e8\u5206\u53d8\u91cf\u5b58\u5728\u9ed8\u8ba4\u503c\uff0c\u672a\u6d89\u53ca\u7684\u53d8\u91cf\u65e0\u9700\u58f0\u660e\u4e3a\u7a7a\u503c\uff08\u7a7a\u5b57\u7b26\u4e32\uff09\uff0c\u53e6\u5916\u5982\u679c\u5bf9\u5e94\u529f\u80fd\u914d\u7f6e\u4e0d\u5b58\u5728\u90a3\u4e48\u5c31\u53ef\u80fd\u4f1a\u51fa\u73b0\u4ea4\u4e92</p>"},{"location":"use/repo-branchs/","title":"Repo branchs","text":"SYSTEM NAMES Debian <code>debian</code> <code>debian-archive</code> Ubuntu <code>ubuntu</code> <code>ubuntu-ports</code> Kali Linux <code>kali</code> Linux Mint <code>linuxmint</code> <code>ubuntu</code> <code>ubuntu-ports</code> <code>debian</code> Deepin <code>deepin</code> Zorin OS <code>ubuntu</code> <code>ubuntu-ports</code> Armbian <code>armbian</code> Proxmox VE <code>proxmox</code> Raspberry Pi OS <code>raspberrypi</code> <code>raspbian</code> <code>debian</code> <code>debian-archive</code> Red Hat Enterprise Linux <code>centos</code> <code>centos-stream</code> <code>centos-altarch</code> <code>centos-vault</code> Fedora <code>fedora</code> <code>fedora-archive</code> CentOS <code>centos</code> <code>centos-stream</code> <code>centos-altarch</code> <code>centos-vault</code> Rocky Linux <code>rocky</code> AlmaLinux <code>almalinux</code> <code>almalinux-vault</code> Oracle Linux <code>centos-stream</code> openEuler <code>openeuler</code> OpenCloudOS <code>opencloudos</code> openKylin <code>openkylin</code> Anolis OS <code>anolis</code> openSUSE <code>opensuse</code> Arch Linux <code>archlinux</code> <code>archlinuxarm</code> Manjaro <code>manjaro</code> EndeavourOS <code>endeavouros</code> Alpine Linux <code>alpine</code> Gentoo <code>gentoo</code> <code>gentoo-portage</code> NixOS <code>nix-channels</code>"},{"location":"zh-Hant/","title":"\u4e00\u9375\u8173\u672c\u8b93\u63db\u6e90\u66f4\u7c21\u55ae","text":"GNU/Linux \u66f4\u63db\u7cfb\u7d71\u8edf\u9ad4\u6e90\u8173\u672c\u53ca Docker \u5b89\u88dd\u8207\u63db\u6e90\u8173\u672c \u4e00\u9375\u8173\u672c\u8b93\u63db\u6e90\u66f4\u7c21\u55ae GNU/Linux Docker <ul> <li> <p> \u8f15\u9b06\u4f7f\u7528</p> <p>\u53ea\u9700\u8981\u4e00\u884c\u6307\u4ee4\u5c31\u80fd\u76f4\u63a5\u904b\u884c\uff0c\u96f6\u6280\u8853\u9580\u6abb\uff0c\u7121\u9700\u5b89\u88dd\u4efb\u4f55\u4f9d\u8cf4 \u6587\u4ef6\u6574\u5408\u4e86 AI \u641c\u5c0b\u8207\u804a\u5929\uff0c\u63d0\u4f9b\u5404\u7a2e\u4f7f\u7528\u5834\u666f\u7684\u89e3\u6c7a\u65b9\u6848</p> </li> <li> <p> \u7cfb\u7d71\u652f\u63f4\u5ee3\u6cdb</p> <p>\u5df2\u9069\u914d\u9ad8\u9054 <code>26+</code> \u4f5c\u696d\u7cfb\u7d71\uff0c\u6db5\u84cb\u5404\u985e\u7248\u672c\uff0c\u7cbe\u6e96\u8fa8\u8b58\u7cfb\u7d71\u985e\u578b \u8173\u672c\u76f8\u5bb9\u6027\u9ad8\uff0c\u4e0d\u652f\u63f4\u7684\u7cfb\u7d71\u6703\u6709\u5c0d\u61c9\u63d0\u793a\u4e26\u7121\u64cd\u4f5c\u8df3\u51fa</p> </li> <li> <p> \u591a\u5143\u8edf\u9ad4\u6e90\u9069\u914d</p> <p>\u6df1\u5165\u8003\u5bdf\u4e86\u4e2d\u570b\u5927\u9678\u93e1\u50cf\u7ad9\u7684\u7cfb\u7d71\u9069\u914d\u72c0\u6cc1\uff0c\u5c08\u70ba\u570b\u4eba\u6253\u9020 \u4e5f\u63d0\u4f9b\u5168\u7db2\u8490\u96c6\u7684\u570b\u5167\u6559\u80b2\u7db2\u548c\u6d77\u5916\u93e1\u50cf\u7ad9\u4f9b\u7528\u6236\u9078\u64c7</p> </li> <li> <p> \u5feb\uff0c\u4e14\u9ad8\u6548</p> <p>\u6700\u5feb\u50c5\u9700 10 \u79d2\u5373\u53ef\u5b8c\u6210\u8edf\u9ad4\u6e90\u7684\u66f4\u63db\uff0c\u9ad8\u6548\u80fd\u7dad\u904b\uff0c\u7bc0\u7701\u5927\u91cf\u6642\u9593\u6210\u672c \u5c08\u6848\u7d93\u904e\u6578\u5e74\u7684\u8fed\u4ee3\u8207\u6700\u4f73\u5316\uff0c\u8173\u672c\u6548\u80fd\u5353\u8d8a\u904b\u4f5c\u7a69\u5b9a\uff0c\u5834\u666f\u5224\u65b7\u5b8c\u5584</p> </li> <li> <p> \u5168\u7403\u7db2\u7d61\uff0c\u57f7\u884c\u7121\u6182</p> <p>\u672c\u7db2\u7ad9\u63d0\u4f9b\u5168\u7403\u908a\u7de3\u7db2\u8def\u52a0\u901f\uff0c\u4e0d\u754f\u5404\u7a2e\u7db2\u8def\u74b0\u5883\uff0c\u8f15\u9b06\u8a2a\u554f \u540c\u6642\u63d0\u4f9b\u4e86\u591a\u500b\u5099\u7528\u5730\u5740\u4ee5\u78ba\u4fdd\u5c08\u6848\u8173\u672c\u59cb\u7d42\u53ef\u7528\uff0c\u4e26\u771f\u6b63\u505a\u5230\u4f7f\u7528\u7121\u6182</p> </li> <li> <p> \u529f\u80fd\u5f37\u5927\uff0c\u7121\u8207\u502b\u6bd4</p> <p>\u8173\u672c\u900f\u904e\u65b9\u5411\u9375\u4e92\u52d5\u9010\u6b65\u5f15\u5c0e\u4f7f\u7528\u8005\u9078\u64c7\u8edf\u9ad4\u8edf\u9ad4\u6e90\u914d\u7f6e\uff0c\u8b93\u63db\u6e90\u66f4\u7c21\u55ae \u6b64\u5916\u8173\u672c\u63d0\u4f9b\u4e86\u8c50\u5bcc\u7684\u547d\u4ee4\u9078\u9805\uff0c\u652f\u63f4 CI/CD \u6574\u5408\u8207\u81ea\u52d5\u5316\u7dad\u904b</p> </li> <li> <p> \u9ad8\u5ea6\u53ef\u81ea\u5b9a\u7fa9</p> <p>\u8173\u672c\u547d\u4ee4\u9078\u9805\u9075\u5faa\u6b63\u5f0f\u61c9\u7528\u7a0b\u5f0f\u898f\u7bc4\u8a2d\u8a08\uff0c\u80fd\u5920\u6eff\u8db3\u5404\u7a2e\u9032\u968e\u9700\u6c42 \u7a0b\u5f0f\u78bc\u7d50\u69cb\u6e05\u6670\uff0c\u6613\u65bc\u95b1\u8b80\u548c\u4fee\u6539\uff0c\u652f\u63f4\u514b\u9686\u5f8c\u5b9a\u5236\uff0c\u652f\u63f4\u591a\u8a9e\u8a00\u5217\u5370</p> </li> <li> <p> \u81ea\u7531\uff0c\u958b\u6e90</p> <p>\u5c08\u6848\u5df2\u8a2d\u7acb MIT \u958b\u6e90\u6388\u6b0a\u5354\u5b9a\uff0c\u8173\u672c\u7a0b\u5f0f\u78bc\u5b8c\u5168\u958b\u6e90\u4e14\u514d\u8cbb\u4f7f\u7528 \u8acb\u5c0a\u91cd\u4f5c\u8005\u7684\u77e5\u8b58\u6210\u679c\uff0c\u50b3\u64ad\u6642\u8acb\u5728\u986f\u8457\u4f4d\u7f6e\u6a19\u8a3b\u8edf\u9ad4\u6e90\u6216\u5c08\u6848\u5730\u5740</p> </li> </ul> \u4f5c\u696d\u7cfb\u7d71 \u9069\u914d\u7248\u672c Debian 8\uff5e13 Ubuntu 14\uff5e25 Kali Linux all Linux Mint 17\uff5e22 / LMDE 2\uff5e7 Deepin all Zorin OS all Armbian all Proxmox VE all Raspberry Pi OS all Red Hat Enterprise Linux 7\uff5e10 Fedora 30\uff5e43 CentOS 7\uff5e8 / Stream 8\uff5e10 Rocky Linux 8\uff5e10 AlmaLinux 8\uff5e10 Oracle Linux 8\uff5e10 openEuler 20\uff5e25 OpenCloudOS 8.6\uff5e9 / Stream 23 openKylin all Anolis OS 8 / 23 openSUSE Leap 15 ~ 16 / Tumbleweed Arch Linux all Manjaro all EndeavourOS all Alpine Linux v3 / edge Gentoo all NixOS 19\uff5e25 <p>\u958b \u59cb \u4f7f \u7528 \u8edf\u9ad4\u6e90\u5217\u8868</p>"},{"location":"zh-Hant/other/","title":"Docker \u5b89\u88dd\u8207\u63db\u6e90\u8173\u672c","text":""},{"location":"zh-Hant/other/#\u4e00\u9375\u57f7\u884c\u547d\u4ee4","title":"\u4e00\u9375\u57f7\u884c\u547d\u4ee4","text":"\u5b89\u88dd\u50c5\u66f4\u63db\u93e1\u50cf\u52a0\u901f\u5668 \u5b98\u7db2\uff08\u63a8\u85a6\uff09 GitHub Gitee \u78bc\u96f2 (\u93e1\u50cf\u5009\u5eab) GitCode (\u93e1\u50cf\u5009\u5eab) jsDelivr (CDN) \u9a30\u8a0a\u96f2 EO (CDN) <pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --zh-hant\n</code></pre> <pre><code>bash <(curl -sSL https://raw.githubusercontent.com/SuperManito/LinuxMirrors/main/DockerInstallation.sh) --zh-hant\n</code></pre> <pre><code>bash <(curl -sSL https://gitee.com/SuperManito/LinuxMirrors/raw/main/DockerInstallation.sh) --zh-hant\n</code></pre> <p>\u5373\u6642\u540c\u6b65\u3001\u7121\u5ef6\u9072\uff0c\u4e2d\u570b\u5927\u9678\u7db2\u8def\u74b0\u5883\u5efa\u8b70\u4f7f\u7528</p> <pre><code>bash <(curl -sSL https://raw.gitcode.com/SuperManito/LinuxMirrors/raw/main/DockerInstallation.sh) --zh-hant\n</code></pre> <p>\u540c\u6b65\u5b58\u57281\u5c0f\u6642\u5ef6\u9072</p> <pre><code>bash <(curl -sSL https://cdn.jsdelivr.net/gh/SuperManito/LinuxMirrors@main/DockerInstallation.sh) --zh-hant\n</code></pre> <pre><code>bash <(curl -sSL https://edgeone.linuxmirrors.cn/docker.sh) --zh-hant\n</code></pre> <p>\u4e0d\u5efa\u8b70\u5728\u4e2d\u570b\u5927\u9678\u7db2\u8def\u74b0\u5883\u4e0b\u4f7f\u7528</p> <p>\u6574\u5408\u5b89\u88dd <code>Docker Engine</code> \u548c <code>Docker Compose</code>\uff0c\u652f\u63f4\u9078\u64c7\u6216\u66f4\u63db\u8edf\u9ad4\u6e90\uff08Docker \u8edf\u9ad4\u5009\u5eab\uff09\u4ee5\u53ca\u6620\u50cf\u5009\u5eab\u3001\u5b89\u88dd\u6307\u5b9a\u7248\u672c\u3001\u91cd\u88dd\u7b49\u529f\u80fd\uff0c\u652f\u63f4 ARM \u67b6\u69cb</p> <p>\u8173\u672c\u53c3\u8003\u5b98\u65b9\u6587\u4ef6\u4f7f\u7528\u7cfb\u7d71\u5957\u4ef6\u7ba1\u7406\u5de5\u5177\u9032\u884c\u5b89\u88dd\uff0c\u4e0d\u5b58\u5728\u76f8\u5bb9\u6027\u3001\u5b89\u5168\u6027\u7b49\u554f\u984c\uff0c\u53ef\u5b89\u88dd\u7684\u7248\u672c\u7531 Docker CE \u5009\u5eab\u6c7a\u5b9a</p> \u5b98\u7db2\uff08\u63a8\u85a6\uff09 GitHub Gitee \u78bc\u96f2 (\u6620\u50cf\u5009\u5eab) GitCode (\u6620\u50cf\u5009\u5eab) jsDelivr (CDN) \u9a30\u8a0a\u96f2 EO (CDN) <pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --zh-hant --only-registry\n</code></pre> <pre><code>bash <(curl -sSL https://raw.githubusercontent.com/SuperManito/LinuxMirrors/main/DockerInstallation.sh) --zh-hant --only-registry\n</code></pre> <pre><code>bash <(curl -sSL https://gitee.com/SuperManito/LinuxMirrors/raw/main/DockerInstallation.sh) --zh-hant --only-registry\n</code></pre> <p>\u5373\u6642\u540c\u6b65\u3001\u7121\u5ef6\u9072\uff0c\u4e2d\u570b\u5927\u9678\u7db2\u8def\u74b0\u5883\u5efa\u8b70\u4f7f\u7528</p> <pre><code>bash <(curl -sSL https://raw.gitcode.com/SuperManito/LinuxMirrors/raw/main/DockerInstallation.sh) --zh-hant --only-registry\n</code></pre> <p>\u540c\u6b65\u5b58\u57281\u5c0f\u6642\u5ef6\u9072</p> <pre><code>bash <(curl -sSL https://cdn.jsdelivr.net/gh/SuperManito/LinuxMirrors@main/DockerInstallation.sh) --zh-hant --only-registry\n</code></pre> <pre><code>bash <(curl -sSL https://edgeone.linuxmirrors.cn/docker.sh) --zh-hant --only-registry\n</code></pre> <p>\u4e0d\u5efa\u8b70\u5728\u4e2d\u570b\u5927\u9678\u7db2\u8def\u74b0\u5883\u4e0b\u4f7f\u7528</p> <ul> <li> <p> \u5b8c\u5168\u53d6\u4ee3\u5b98\u65b9\u5b89\u88dd\u8173\u672c</p> <p>\u8207 get.docker.com \u908f\u8f2f\u4e00\u81f4\uff0c\u878d\u5408\u4e86\u672c\u5c08\u6848\u63db\u6e90\u67b6\u69cb\u4ee5\u53ca\u7279\u6027</p> </li> <li> <p> \u652f\u63f4\u884d\u751f\u4f5c\u696d\u7cfb\u7d71</p> <p>\u76f8\u5bb9\u65bc\u5927\u91cf\u4e0d\u53d7\u5b98\u65b9\u5b89\u88dd\u8173\u672c\u652f\u63f4\u7684\u884d\u751f\u4f5c\u696d\u7cfb\u7d71 </p> </li> <li> <p> \u529f\u80fd\u5f37\u5927\u3001\u7121\u8207\u502b\u6bd4</p> <p>\u5168\u7db2\u6700\u5be6\u7528\u7684\u958b\u6e90\u904b\u7dad\u8173\u672c\u4e4b\u4e00\uff0c\u6548\u80fd\u5353\u8d8a</p> </li> <li> <p> \u7cbe\u5999\u7d55\u502b\u7684\u4e92\u52d5\u8a2d\u8a08</p> <p>\u6613\u65bc\u7406\u89e3\u548c\u4f7f\u7528\u7684\u4e92\u52d5\u5f0f\u547d\u4ee4\u5217\u4ecb\u9762\uff0c\u9059\u9059\u9818\u5148</p> </li> </ul> <p>\u2728 \u7d93\u904e\u4e86\u6578\u5e74\u7684\u6280\u8853\u6c89\u6fb1\u8207\u751f\u7522\u74b0\u5883\u6aa2\u9a57\uff0c\u5ee3\u53d7\u793e\u5340\u597d\u8a55\uff0c\u6df1\u5f97\u958b\u767c\u8005\u559c\u611b\uff0c\u5927\u5ee0\u90fd\u5728\u4f7f\u7528</p> <p></p> <p>Docker Compose \u4e0d\u518d\u9700\u8981\u7368\u7acb\u5b89\u88dd</p> <p>Docker Compose \u81ea V2 \u7248\u672c\u8d77\u958b\u59cb\u4f5c\u70ba Docker CLI\uff08\u547d\u4ee4\u5217\uff09\u7684\u4e00\u90e8\u5206\uff0c\u8173\u672c\u9810\u8a2d\u6574\u5408\u5b89\u88dd\u8a72\u63d2\u4ef6\uff0c\u8acb\u4f7f\u7528 <code>docker compose</code> \u6307\u4ee4\u53d6\u4ee3 <code>docker-compose</code></p> <p>\u8edf\u9ad4\u6e90\u8aaa\u660e</p> <ul> <li> <p>__Docker CE \u8edf\u9ad4\u5009\u5eab</p> <p>Docker CE \u5168\u7a31 Docker Community Edition\uff08Docker \u793e\u7fa4\u7248\uff09\uff0c\u662f Docker Engine \u7684\u5225\u7a31\uff0c\u8a72\u5009\u5eab\u7528\u65bc\u4e0b\u8f09\u4e26\u5b89\u88dd Docker \u76f8\u95dc\u8edf\u9ad4\u5305</p> </li> <li> <p>Docker Registry \u6620\u50cf\u5009\u5eab</p> <p>\u7528\u65bc\u63a7\u5236\u62c9\u53d6\u93e1\u50cf\u7684\u9810\u8a2d\u8edf\u9ad4\u6e90\u5132\u5b58\u5009\u5eab\uff0c\u53c8\u7a31\u70ba\u93e1\u50cf\u52a0\u901f\u5668\uff0c\u9810\u8a2d\u70ba\u5b98\u65b9\u5bb9\u5668\u6620\u50cf\u5009\u5eab Docker Hub </p> </li> </ul> <p>\u7531\u65bc\u4e00\u4e9b\u4e0d\u53ef\u6297\u529b\u7684\u56e0\u7d20\uff0c\u4e2d\u570b\u5927\u9678\u7db2\u8def\u74b0\u5883\u4e0b\u76ee\u524d\u7121\u6cd5\u8a2a\u554f Docker Hub \u56e0\u6b64\u7121\u6cd5\u6b63\u5e38\u62c9\u53d6\u93e1\u50cf\uff0c\u5efa\u8b70\u4f7f\u7528\u4e0b\u65b9\u63d0\u5230\u7684\u4e2d\u570b\u5927\u9678\u53ef\u7528\u6620\u50cf\u5009\u5eab\u6e90</p> <p>\u8a3b\uff1a\u8173\u672c\u5167\u7684\u6307\u5b9a Web \u5354\u5b9a\u4e92\u52d5\u50c5\u7528\u65bc\u63a7\u5236 <code>Docker CE</code> \u8edf\u9ad4\u6e90\uff0c<code>Docker Registry</code> \u5f37\u5236\u4f7f\u7528 <code>HTTPS</code> \u5354\u5b9a</p> <p>\u9810\u8a2d\u7684\u6620\u50cf\u5009\u5eab\u6e90</p> <p> \u4e2d\u570b\u5927\u9678\u53ef\u7528 \u540d\u7a31 \u4f4d\u5740 \u8aaa\u660e \u6beb\u79d2\u93e1\u50cf docker.1ms.run \u4f01\u696d\u93e1\u50cf\u7ad9\uff0cCDN\u667a\u6167\u5206\u9001\u901f\u5ea6\u6975\u5feb\uff0c\u652f\u63f4\u4ed8\u8cbb\u5b9a\u5236\uff0c\u63a8\u85a6\u4f7f\u7528 Docker Proxy dockerproxy.net \u7531 ghproxy \u5275\u5efa\uff0c\u53ef\u7528\u6027\u9ad8\u4f46\u901f\u5ea6\u5f88\u6162\uff0c\u652f\u63f4\u4f01\u696d\u93e1\u50cf\u4ed8\u8cbb\u52a0\u901f DaoCloud docker.m.daocloud.io \u8001\u724c\u4f01\u696d\u93e1\u50cf\u7ad9\uff0c\u53ef\u7528\u6027\u9ad8\u4e14\u901f\u5ea6\u5feb\uff0c\u73fe\u70ba\u767d\u540d\u55ae\u6a21\u5f0f 1Panel \u93e1\u50cf docker.1panel.live \u4f01\u696d\u7522\u54c1\u81ea\u7528\u93e1\u50cf <p>\u672c\u958b\u6e90\u5c08\u6848\u4e0d\u9069\u5408\u63a1\u96c6\u500b\u4eba\u81ea\u5efa\u7684\u93e1\u50cf\u52a0\u901f\u5668\uff0c\u5982\u6709\u9700\u8981\u53ef\u642d\u914d\u547d\u4ee4\u9078\u9805\u81ea\u884c\u4f7f\u7528</p> <p>\u5176\u5b83</p> \u540d\u7a31 \u4f4d\u5740 \u540d\u7a31 \u4f4d\u5740 Alibaba Cloud (Hangzhou) registry.cn-hangzhou.aliyuncs.com Alibaba Cloud (Japan - Tokyo) registry.ap-northeast-1.aliyuncs.com Alibaba Cloud (Shanghai) registry.cn-shanghai.aliyuncs.com Alibaba Cloud (Singapore) registry.ap-southeast-1.aliyuncs.com Alibaba Cloud (Qingdao) registry.cn-qingdao.aliyuncs.com Alibaba Cloud (Malaysia - Kuala Lumpur) registry.ap-southeast-3.aliyuncs.com Alibaba Cloud (Beijing) registry.cn-beijing.aliyuncs.com Alibaba Cloud (Indonesia - Jakarta) registry.ap-southeast-5.aliyuncs.com Alibaba Cloud (Zhangjiakou) registry.cn-zhangjiakou.aliyuncs.com Alibaba Cloud (Germany - Frankfurt) registry.eu-central-1.aliyuncs.com Alibaba Cloud (Hohhot) registry.cn-huhehaote.aliyuncs.com Alibaba Cloud (UK - London) registry.eu-west-1.aliyuncs.com Alibaba Cloud (Ulanqab) registry.cn-wulanchabu.aliyuncs.com Alibaba Cloud (US Western - Silicon Valley) registry.us-west-1.aliyuncs.com Alibaba Cloud (Shenzhen) registry.cn-shenzhen.aliyuncs.com Alibaba Cloud (US Eastern - Virginia) registry.us-east-1.aliyuncs.com Alibaba Cloud (Heyuan) registry.cn-heyuan.aliyuncs.com Alibaba Cloud (United Arab Emirates - Dubai) registry.me-east-1.aliyuncs.com Alibaba Cloud (Guangzhou) registry.cn-guangzhou.aliyuncs.com Google Cloud\uff08North America) gcr.io Alibaba Cloud (Chengdu) registry.cn-chengdu.aliyuncs.com Google Cloud\uff08Asia) asia.gcr.io Alibaba Cloud (Hong Kong) registry.cn-hongkong.aliyuncs.com Google Cloud\uff08Europe) eu.gcr.io Tencent Cloud mirror.ccs.tencentyun.com Docker Hub registry.hub.docker.com <p>\u8a3b\uff1a\u4e2d\u570b\u5927\u9678\u96f2\u7aef\u904b\u7b97\u4f01\u696d\u7684\u6620\u50cf\u5009\u5eab\u8edf\u9ad4\u6e90\u50c5\u91dd\u5c0d\u5176\u696d\u52d9\uff0c\u4e2d\u570b\u5927\u9678\u5883\u5167\u5be6\u4f8b\u53ef\u80fd\u4ecd\u7121\u6cd5\u9020\u8a2a Docker Hub</p>"},{"location":"zh-Hant/other/#\u547d\u4ee4\u9078\u9805\u9032\u968e\u7528\u6cd5","title":"\u547d\u4ee4\u9078\u9805\uff08\u9032\u968e\u7528\u6cd5\uff09","text":"bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --zh-hant --help \u547d\u4ee4\u9078\u9805(\u540d\u7a31/\u542b\u7fa9/\u503c)\uff1a --source \u6307\u5b9a Docker CE \u8edf\u9ad4\u6e90\u4f4d\u5740(\u7db2\u57df\u540d\u7a31\u6216IP) \u4f4d\u5740 --source-registry \u6307\u5b9a Docker \u6620\u50cf\u5009\u5eab\u4f4d\u5740 (\u7db2\u57df\u540d\u7a31\u6216IP) \u4f4d\u5740 --branch \u6307\u5b9a Docker CE \u8edf\u9ad4\u6e90\u5009\u5eab (\u8def\u5f91) \u5009\u5eab\u540d\u7a31 --branch-version \u6307\u5b9a Docker CE \u8edf\u9ad4\u6e90\u5009\u5eab\u7248\u672c \u7248\u672c\u865f --designated-version \u6307\u5b9a Docker Engine \u5b89\u88dd\u7248\u672c \u7248\u672c\u865f --codename \u6307\u5b9a Debian \u4fc2\u4f5c\u696d\u7cfb\u7d71\u7684\u7248\u672c\u4ee3\u865f \u4ee3\u865f\u540d\u7a31 --protocol \u6307\u5b9a Docker CE \u6e90\u7684 Web \u5354\u5b9a http \u6216 https --use-intranet-source \u662f\u5426\u512a\u5148\u4f7f\u7528\u5167\u90e8\u7db2\u8def Docker CE \u8edf\u9ad4\u6e90\u4f4d\u5740 true \u6216 false --install-latest \u662f\u5426\u5b89\u88dd\u6700\u65b0\u7248\u672c\u7684 Docker Engine true \u6216 false --close-firewall \u662f\u5426\u95dc\u9589\u9632\u706b\u7246 true \u6216 false --clean-screen \u662f\u5426\u5728\u904b\u884c\u524d\u6e05\u9664\u87a2\u5e55\u4e0a\u7684\u6240\u6709\u5167\u5bb9 true \u6216 false --lang \u6307\u5b9a\u8173\u672c\u8f38\u51fa\u7684\u8a9e\u8a00 \u8bed\u8a00 --only-registry \u50c5\u66f4\u63db\u6620\u50cf\u5009\u5eab\u6a21\u5f0f \u7121 --ignore-backup-tips \u5ffd\u7565\u8986\u84cb\u5099\u4efd\u63d0\u793a \u7121 --pure-mode \u7d14\u6de8\u6a21\u5f0f\uff0c\u7cbe\u7c21\u5217\u5370\u5167\u5bb9 \u7121 --help \u67e5\u770b\u5e6b\u52a9\u9078\u55ae \u7121 \u540d\u7a31 \u610f\u7fa9 \u9078\u9805\u503c <code>--source</code> \u6307\u5b9a <code>Docker CE</code> \u8edf\u9ad4\u6e90\u4f4d\u5740(\u7db2\u57df\u540d\u7a31\u6216IP) <code>\u4f4d\u5740</code> <code>--source-registry</code> \u6307\u5b9a <code>Docker</code> \u6620\u50cf\u5009\u5eab\u4f4d\u5740(\u7db2\u57df\u540d\u7a31\u6216IP) <code>\u4f4d\u5740\uff08\u591a\u500b\u7528\u82f1\u6587\u9017\u865f\u5206\u5272\uff09</code> <code>--branch</code> \u6307\u5b9a <code>Docker CE</code> \u8edf\u9ad4\u6e90\u5009\u5eab(\u8def\u5f91) <code>\u5009\u5eab\u540d\u7a31\uff08\u8a73\u898b\u4e0b\u65b9\u6587\u4ef6\uff09</code> <code>--branch-version</code> \u6307\u5b9a <code>Docker CE</code> \u8edf\u9ad4\u6e90\u5009\u5eab\u7248\u672c <code>\u7248\u672c\u865f\uff08\u8a73\u898b\u4e0b\u65b9\u6587\u4ef6\uff09</code> <code>--designated-version</code> \u6307\u5b9a <code>Docker Engine</code> \u5b89\u88dd\u7248\u672c <code>\u7248\u672c\u865f\uff08\u8a73\u898b\u4e0b\u65b9\u6587\u4ef6\uff09</code> <code>--codename</code> \u6307\u5b9a <code>Debian</code> \u4fc2\u4f5c\u696d\u7cfb\u7d71\u7684\u7248\u672c\u4ee3\u865f <code>\u4ee3\u865f\u540d\u7a31</code> <code>--protocol</code> \u6307\u5b9a <code>Docker CE</code> \u6e90\u7684 Web \u5354\u5b9a <code>http</code> \u6216 <code>https</code> <code>--use-intranet-source</code> \u662f\u5426\u512a\u5148\u4f7f\u7528\u5167\u90e8\u7db2\u8def <code>Docker CE</code> \u8edf\u9ad4\u6e90\u4f4d\u5740 <code>true</code> \u6216 <code>false</code> <code>--install-latest</code> \u662f\u5426\u5b89\u88dd\u6700\u65b0\u7248\u672c\u7684 <code>Docker Engine</code> <code>true</code> \u6216 <code>false</code> <code>--close-firewall</code> \u662f\u5426\u95dc\u9589\u9632\u706b\u7246 <code>true</code> \u6216 <code>false</code> <code>--clean-screen</code> \u662f\u5426\u5728\u904b\u884c\u524d\u6e05\u9664\u87a2\u5e55\u4e0a\u7684\u6240\u6709\u5167\u5bb9 <code>true</code> \u6216 <code>false</code> <code>--lang</code> \u6307\u5b9a\u8173\u672c\u8f38\u51fa\u7684\u8a9e\u8a00 <code>\u8a9e\u8a00ID\uff08\u8a73\u898b\u4e0b\u65b9\u6587\u4ef6\uff09</code> <code>--only-registry</code> \u50c5\u66f4\u63db\u6620\u50cf\u5009\u5eab\u6a21\u5f0f \u7121 <code>--ignore-backup-tips</code> \u5ffd\u7565\u8986\u84cb\u5099\u4efd\u63d0\u793a\uff08\u5373\u4e0d\u8986\u84cb\u5099\u4efd) \u7121 <code>--pure-mode</code> \u7d14\u6de8\u6a21\u5f0f\uff0c\u7cbe\u7c21\u5217\u5370\u5167\u5bb9 \u7121 <code>--help</code> \u67e5\u770b\u5e6b\u52a9\u9078\u55ae \u7121 <p>\u8edf\u9ad4\u6e90\u5b8c\u6574\u683c\u5f0f <code><WEB\u5354\u5b9a>://<\u8edf\u9ad4\u6e90\u4f4d\u5740(\u7db2\u57df\u540d\u7a31\u6216IP)>/<\u8edf\u9ad4\u6e90\u5009\u5eab(\u8def\u5f91)></code></p>"},{"location":"zh-Hant/other/#\u6307\u5b9a\u6620\u50cf\u5009\u5eab\u4f4d\u5740","title":"\u6307\u5b9a\u6620\u50cf\u5009\u5eab\u4f4d\u5740","text":"<pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --zh-hant --source-registry registry.example.com\n</code></pre> <p>\u53ef\u540c\u6642\u6307\u5b9a\u591a\u500b\u5730\u5740\uff0c\u9700\u4f7f\u7528\u82f1\u6587\u9017\u865f\u5206\u5272</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --zh-hant \\\n --source-registry \"registry-1.example.com,registry-2.example.com\"\n</code></pre>"},{"location":"zh-Hant/other/#\u50c5\u66f4\u63db\u6620\u50cf\u5009\u5eab","title":"\u50c5\u66f4\u63db\u6620\u50cf\u5009\u5eab","text":"\u4f7f\u7528\u8173\u672c\u4e00\u9375\u66ff\u63db\u624b\u52d5\u66ff\u63db <p>\u50c5\u66f4\u63db\u93e1\u50cf\u52a0\u901f\u5668\uff0c\u7576\u5075\u6e2c\u5230\u672a\u5b89\u88dd Docker \u6642\u6703\u5831\u932f\u8df3\u51fa</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --zh-hant --only-registry\n</code></pre> <p>\u61f6\u4eba\u4e00\u9375\u6307\u4ee4\uff08\u4f7f\u7528\u591a\u500b\u4f4d\u5740\uff09</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --zh-hant \\\n --only-registry \\\n --source-registry \"docker.1ms.run,docker.1panel.live,docker.m.daocloud.io\"\n</code></pre> <p>\u9078\u9805\u503c\u53ef\u4ee5\u6307\u5b9a\u591a\u500b\u4f4d\u5740\uff0c\u9700\u4f7f\u7528\u82f1\u6587\u9017\u865f\u5206\u5272</p> <ul> <li> <p>\u5b89\u88dd <code>jq</code> \u8edf\u9ad4\u5305</p> Debian \u7cfb / openKylinRedHat \u7cfb / openEuler / OpenCloudOS / Anolis OS <pre><code>apt-get install -y jq\n</code></pre> <p><code>Debian</code> <code>Ubuntu</code> <code>Kali</code> <code>Linux Mint</code> <code>Deepin</code> <code>Zorin OS</code> <code>Armbian</code> <code>Proxmox VE</code> <code>Raspberry Pi OS</code> <code>openKylin</code></p> <p>\u65b0\u88dd\u7cfb\u7d71\u9700\u8981\u5148\u57f7\u884c\u4e00\u6b21\u66f4\u65b0 <code>apt-get update</code></p> <pre><code>dnf install -y jq || yum install -y jq\n</code></pre> <p><code>Red Hat Enterprise Linux</code> <code>CentOS</code> <code>Rocky Linux</code> <code>AlmaLinux</code> <code>Fedora</code> <code>openEuler</code> <code>OpenCloudOS</code> <code>Anolis OS</code></p> </li> <li> <p>\u6307\u5b9a\u6620\u50cf\u5009\u5eab\u4f4d\u5740</p> <p>\u8acb\u624b\u52d5\u66ff\u63db <code><example.registry.com></code> \u70ba\u6620\u50cf\u5009\u5eab\u4f4d\u5740\u5f8c\u5728\u57f7\u884c\uff0c\u8a73\u898b\u4e0a\u65b9 \u201c\u5c08\u6848\u5167\u7f6e\u7684\u6620\u50cf\u5009\u5eab\u6e90\u201d \u8868\u683c\u4e2d\u7684\u4f4d\u5740\u5217</p> <p><pre><code>SOURCE_REGISTRY='\"https://<example.registry.com>\"'\n</code></pre> \u4e5f\u53ef\u4ee5\u6307\u5b9a\u591a\u500b\u6620\u50cf\u5009\u5eab\uff0c\u5982 <code>SOURCE_REGISTRY='\"https://example.registry.com\",\"https://test.registry.com\"'</code>\uff0c\u6ce8\u610f\u7528\u82f1\u6587\u9017\u865f\u5206\u5272</p> </li> <li> <p>\u66ff\u63db\u6620\u50cf\u5009\u5eab\u4f4d\u5740</p> <pre><code>[ -s \"/etc/docker/daemon.json\" ] || echo \"{}\" >/etc/docker/daemon.json\njq '.[\"registry-mirrors\"] = ['\"${SOURCE_REGISTRY}\"']' /etc/docker/daemon.json >/etc/docker/daemon.json.tmp && mv /etc/docker/daemon.json.tmp\n</code></pre> </li> <li> <p>\u91cd\u65b0\u555f\u52d5 Docker \u670d\u52d9</p> <pre><code>systemctl daemon-reload\n[[ $(systemctl is-active docker) == \"active\" ]] && systemctl restart docker || systemctl enable --now docker\n</code></pre> </li> </ul>"},{"location":"zh-Hant/other/#\u6307\u5b9a-docker-ce-\u8edf\u9ad4\u6e90\u4f4d\u5740","title":"\u6307\u5b9a <code>Docker CE</code> \u8edf\u9ad4\u6e90\u4f4d\u5740","text":"<pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --zh-hant --source mirror.example.com/docker-ce\n</code></pre> <p>\u6ce8\u610f\u8a72\u4f4d\u5740\u8def\u5f91\u9700\u8981\u5305\u542b\u6620\u50cf\u7ad9\u7684 Docker CE \u8edf\u9ad4\u6e90\u5009\u5eab\u8def\u5f91\u5373 <code>docker-ce</code></p>"},{"location":"zh-Hant/other/#\u6307\u5b9a-docker-ce-\u8edf\u9ad4\u6e90\u5009\u5eab","title":"\u6307\u5b9a Docker CE \u8edf\u9ad4\u6e90\u5009\u5eab","text":"<p>\u8173\u672c\u9810\u8a2d\u6703\u81ea\u52d5\u5224\u65b7\u4e00\u822c\u7121\u9700\u6307\u5b9a\uff0c\u9664\u975e\u4f60\u6709\u7279\u6b8a\u9700\u6c42</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --zh-hant --branch centos\n</code></pre> <p>\u5009\u5eab\u540d\u7a31\u662f\u56fa\u5b9a\u7684\uff0c\u76ee\u524d\u53ea\u6709 <code>centos</code> <code>debian</code> <code>fedora</code> <code>raspbian</code> <code>rhel</code> <code>sles</code> <code>static</code> <code>ubuntu</code> \u9019\u5e7e\u500b \u8a73\u60c5\u8acb\u898b \u5b98\u65b9\u5b89\u88dd\u6587\u4ef6 \u53ca Docker CE \u5b98\u65b9\u5009\u5eab</p> \u8fd8\u53ef\u4ee5\u6307\u5b9a\u5009\u5eab\u7248\u672c\u865f<pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --zh-hant \\\n --branch centos \\\n --branch-version 9\n</code></pre> <p>\u53ef\u4ee5\u4f7f\u7528\u6b64\u9078\u9805\u4f86\u63a7\u5236\u5b89\u88dd\u8edf\u9ad4\u5957\u4ef6\u7684\u76f8\u5bb9\u6027\uff08\u50c5\u9069\u7528\u65bc\u7d05\u5e3d\u4fc2\u4f5c\u696d\u7cfb\u7d71\uff09\uff0c\u5177\u9ad4\u8a73\u898b\u5c0d\u61c9\u5009\u5eab\u76ee\u9304\u4e2d\u4ee3\u8868\u7248\u672c\u865f\u7684\u8def\u5f91\u540d\u7a31\uff08\u6b63\u6574\u6578\uff09\u3002</p>"},{"location":"zh-Hant/other/#\u6307\u5b9a-docker-engine-\u5b89\u88dd\u7248\u672c","title":"\u6307\u5b9a Docker Engine \u5b89\u88dd\u7248\u672c","text":"<p>\u6307\u5b9a\u5b89\u88dd\u7248\u672c\u6642\u6703\u5ffd\u7565 <code>\u662f\u5426\u5b89\u88dd\u6700\u65b0\u7248\u672c</code> \u7684\u547d\u4ee4\u9078\u9805\uff0c\u683c\u5f0f\u70ba <code>\u4e3b\u7248.\u6b21\u7248\u672c.\u88dc\u4e01\u7248\u672c</code>\uff0c\u4f8b\u5982 <code>28.4.1</code>\u3002</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --zh-hant --designated-version 28.0.0\n</code></pre> <p>\u5982\u679c\u6307\u5b9a\u7684\u7248\u672c\u4e0d\u5b58\u5728\u6216\u4e0d\u652f\u63f4\u7576\u524d\u4f5c\u696d\u7cfb\u7d71\uff0c\u5c46\u6642\u8173\u672c\u6703\u5831\u932f\u8df3\u51fa</p> \u67e5\u770b\u7248\u672c\u6e05\u55ae\u7684\u65b9\u6cd5 Debian \u7cfbRedHat \u7cfb / openEuler / OpenCloudOS / Anolis OS <pre><code>apt-cache madison docker-ce | awk '{print $3}' | grep -Eo \"[0-9][0-9].[0-9]{1,2}.[0-9]{1,2}\" | sort -t '.' -k1,1nr -k2,2nr -k3,3nr\n</code></pre> <p><code>Debian</code> <code>Ubuntu</code> <code>Kali</code> <code>Linux Mint</code> <code>Deepin</code> <code>Zorin OS</code> <code>Armbian</code> <code>Proxmox VE</code> <code>Raspberry Pi OS</code></p> <pre><code>dnf list docker-ce --showduplicates | sort -r | awk '{print $2}' | grep -Eo \"[0-9][0-9].[0-9]{1,2}.[0-9]{1,2}\" | sort -t '.' -k1,1nr -k2,2nr -k3,3nr\n</code></pre> <p><code>Red Hat Enterprise Linux</code> <code>CentOS</code> <code>Rocky Linux</code> <code>AlmaLinux</code> <code>Fedora</code> <code>openEuler</code> <code>OpenCloudOS</code> <code>Anolis OS</code></p> <p>\u672a\u51fa\u73fe\u5728\u8a72\u6e05\u55ae\u4e2d\u7684\u7248\u672c\u5247\u4e0d\u652f\u63f4\u900f\u904e\u672c\u8173\u672c\u5b89\u88dd\uff0c\u5982\u679c\u53d6\u5f97\u4e0d\u5230\u7248\u672c\u6e05\u55ae\u8aaa\u660e\u4f60\u76ee\u524d\u7684\u7cfb\u7d71\u74b0\u5883\u9084\u6c92\u6709\u6b63\u78ba\u914d\u7f6e Docker CE \u8edf\u9ad4\u8edf\u9ad4\u6e90\uff08\u57f7\u884c\u8173\u672c\u6642\u4e0d\u5b58\u5728\u8a72\u554f\u984c\uff09</p>"},{"location":"zh-Hant/other/#\u570b\u969b\u5316i18n","title":"\u570b\u969b\u5316\uff08I18n\uff09","text":"<p>\u8173\u672c\u63d0\u4f9b\u591a\u8a9e\u8a00\u652f\u6301\uff0c\u76ee\u524d\u5167\u5efa <code>\u7b80\u4f53\u4e2d\u6587</code>\u3001<code>\u7e41\u9ad4\u4e2d\u6587</code>\u3001<code>English</code> \u5171\u4e09\u7a2e\u986f\u793a\u8a9e\u8a00\uff0c\u9810\u8a2d\u70ba <code>\u7b80\u4f53\u4e2d\u6587</code></p>"},{"location":"zh-Hant/other/#\u6307\u5b9a\u8a9e\u8a00","title":"\u6307\u5b9a\u8a9e\u8a00","text":"<pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --lang xxx\n</code></pre> \u985e\u578b \u503c \u7b80\u4f53\u4e2d\u6587 <code>zh-hans</code> <code>zh-cn</code> <code>zh</code> \u7e41\u9ad4\u4e2d\u6587 <code>zh-hant</code> <code>zh-tw</code> <code>zh-hk</code> English <code>en</code> <code>en-us</code> <p>\u4e5f\u53ef\u4ee5\u76f4\u63a5\u4f5c\u70ba\u6307\u4ee4\u9078\u9805\u4f7f\u7528</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --en\n</code></pre> <p><code>--en</code> <code>--en-us</code> <code>--zh</code> <code>--zh-cn</code> <code>--zh-hans</code> <code>--zh-hant</code></p>"},{"location":"zh-Hant/other/#\u900f\u904e\u4e92\u52d5\u9032\u884c\u9078\u64c7","title":"\u900f\u904e\u4e92\u52d5\u9032\u884c\u9078\u64c7","text":"<pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --lang auto\n</code></pre>"},{"location":"zh-Hant/other/#\u7121\u4eba\u503c\u5b88\u81ea\u52d5\u5316","title":"\u7121\u4eba\u503c\u5b88\uff08\u81ea\u52d5\u5316\uff09","text":"<p>\u4e0d\u900f\u904e\u4ea4\u4e92\u5b8c\u6210\u5b89\u88dd\u64cd\u4f5c\uff0c\u81f3\u5c11\u9700\u8981\u4f7f\u7528\u4ee5\u4e0b\u547d\u4ee4\u9078\u9805\u4f86\u5be6\u73fe\uff0c\u5efa\u8b70\u719f\u6089\u5f8c\u518d\u4f7f\u7528</p> \u53c2\u8003\u547d\u4ee4<pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --zh-hant \\\n --source mirror.example.com/docker-ce \\\n --source-registry registry.hub.docker.com \\\n --protocol http \\\n --use-intranet-source false \\\n --install-latest true \\\n --close-firewall true \\\n --ignore-backup-tips\n</code></pre> <p>\u5982\u679c\u5831\u932f <code>\u547d\u4ee4\u9078\u9805\u7121\u6548</code> \u90a3\u9ebc\u8acb\u6aa2\u67e5\u9078\u9805\u5408\u6cd5\u6027\u4ee5\u53ca\u7a7a\u683c\u5b57\u5143\u7de8\u78bc\uff0c\u5728\u7bc4\u4f8b\u4e2d\u4e00\u884c\u5beb\u4e00\u500b\u9078\u9805\u662f\u70ba\u4e86\u63d0\u9ad8\u547d\u4ee4\u7684\u53ef\u8b80\u6027</p>"},{"location":"zh-Hant/other/#\u7d14\u6de8\u6a21\u5f0f","title":"\u7d14\u6de8\u6a21\u5f0f","text":"<p>\u63a8\u51fa\u6b64\u529f\u80fd\u662f\u70ba\u4e86\u65b9\u4fbf\u958b\u767c\u4ee5\u53ca\u8fd0\u7ef4\u4eba\u54e1\u4f7f\u7528\uff0c\u555f\u7528\u5f8c\u6703\u7cbe\u7c21\u8173\u672c\u5167\u5bb9\u8f38\u51fa\uff0c\u5efa\u8b70\u642d\u914d\u5176\u5b83\u6307\u4ee4\u9078\u9805\u7121\u4e92\u52d5\u4f7f\u7528</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --zh-hant --pure-mode\n</code></pre> <p>\u6efe\u52d5\u8f38\u51fa\u7684\u547d\u4ee4\u65e5\u8a8c\u53ef\u80fd\u6709\u7121\u6cd5\u9810\u6599\u7684\u986f\u793a\u554f\u984c\uff0c\u4e0d\u904e\u76ee\u524d\u66ab\u672a\u767c\u73fe\u7570\u5e38</p>"},{"location":"zh-Hant/other/#\u5e38\u898b\u554f\u984c","title":"\u5e38\u898b\u554f\u984c","text":""},{"location":"zh-Hant/other/#\u95dc\u65bc\u670d\u52d9\u5831\u932f\u7121\u6cd5\u555f\u52d5","title":"\u95dc\u65bc\u670d\u52d9\u5831\u932f\u7121\u6cd5\u555f\u52d5","text":"<p>\u975e\u65b0\u88dd\u74b0\u5883\u53ef\u80fd\u6703\u5728\u57f7\u884c\u8173\u672c\u5f8c\u9047\u5230 <code>Docker</code> \u670d\u52d9\u7121\u6cd5\u555f\u52d5\u7684\u60c5\u6cc1\uff0c\u5efa\u8b70\u91cd\u65b0\u5b89\u88dd\u4f86\u89e3\u6c7a\uff0c\u5378\u8f09\u4e0d\u6703\u522a\u9664\u672c\u6a5f\u6620\u50cf\u548c\u5bb9\u5668\u8cc7\u6599</p> <p>\u5378\u8f09\u6307\u4ee4\u5982\u4e0b\uff1a</p> Debian \u7cfbRedHat \u7cfb / openEuler / OpenCloudOS / Anolis OS <pre><code>apt-get remove -y docker* containerd.io runc && apt-get autoremove\n</code></pre> <p><code>Debian</code> <code>Ubuntu</code> <code>Kali</code> <code>Linux Mint</code> <code>Deepin</code> <code>Zorin OS</code> <code>Armbian</code> <code>Proxmox VE</code> <code>Raspberry Pi OS</code></p> <pre><code>yum remove -y docker* containerd.io podman* runc\n</code></pre> <p><code>Red Hat Enterprise Linux</code> <code>CentOS</code> <code>Rocky Linux</code> <code>AlmaLinux</code> <code>Fedora</code> <code>openEuler</code> <code>OpenCloudOS</code> <code>Anolis OS</code></p> <p>\u5378\u8f09\u5b8c\u6210\u5f8c\u91cd\u65b0\u57f7\u884c\u8173\u672c\u5b89\u88dd\u5373\u53ef</p>"},{"location":"zh-Hant/other/#\u95dc\u65bc\u4e0d\u652f\u63f4\u7684\u4f5c\u696d\u7cfb\u7d71","title":"\u95dc\u65bc\u4e0d\u652f\u63f4\u7684\u4f5c\u696d\u7cfb\u7d71","text":"<p>\u5982\u679c\u63d0\u793a\u4e0d\u652f\u63f4\u90a3\u9ebc\u8acb\u4f7f\u7528\u7cfb\u7d71\u81ea\u5099\u7684\u5957\u4ef6\u7ba1\u7406\u5de5\u5177\u9032\u884c\u5b89\u88dd\u3002\u56e0\u70ba\u9019\u4e9b\u8edf\u9ad4\u5305\u7531 Linux \u767c\u884c\u7248\u7684\u8edf\u9ad4\u5305\u7dad\u8b77\u8005\u5efa\u69cb\u548c\u7dad\u8b77\uff0c\u53ef\u80fd\u5b58\u5728\u914d\u7f6e\u5dee\u7570\u6216\u7531\u4fee\u6539\u5f8c\u7684\u539f\u59cb\u78bc\u5efa\u69cb\u3002</p> <p>\u4e5f\u53ef\u4ee5\u4f7f\u7528 \u00a0 </p>"},{"location":"zh-Hant/other/#\u7cbe\u7c21\u7248lite","title":"\u7cbe\u7c21\u7248\uff08Lite\uff09","text":"<p>\u5c08\u6848\u984d\u5916\u63d0\u4f9b\u4e00\u500b\u7cbe\u7c21\u7248\u672c\uff0c\u662f\u4e3b\u8173\u672c\u7684\u8907\u88fd\uff0c\u9762\u5411\u4f01\u696d\u7522\u54c1\u3001\u5927\u578b\u958b\u6e90\u793e\u7fa4\u5c08\u6848\u4f7f\u7528\uff0c\u5177\u6709\u4ee5\u4e0b\u7279\u6027\uff1a</p> <ul> <li>\u55ae\u4e00\u986f\u793a\u8a9e\u8a00 <code>English</code>\uff0c\u7121 I18n \u570b\u969b\u5316\u529f\u80fd</li> <li>\u9810\u8a2d\u4f7f\u7528\u5b98\u65b9\u4f86\u6e90\uff0c\u53bb\u9664\u4e86\u4e92\u52d5\u9078\u64c7\u5167\u5efa\u8edf\u9ad4\u6e90\u529f\u80fd</li> <li>\u53bb\u9664\u4e86\u7121\u95dc\u7684\u5217\u5370\u5167\u5bb9</li> <li>\u4fdd\u7559\u6838\u5fc3\u908f\u8f2f\u8207\u6307\u4ee4\u9078\u9805\u8a2d\u8a08</li> </ul> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker-lite.sh)\n</code></pre> <p>\u8acb\u719f\u6089\u672c\u9805\u76ee\u5f8c\u518d\u4f7f\u7528\uff0c\u4e0d\u5efa\u8b70\u65b0\u624b\u4f7f\u7528\u8005\u4f7f\u7528</p> <ul> <li> </li> </ul> \u9069\u7528\u65bc\u4f01\u696d\u7522\u54c1\u90e8\u7f72\u4ee5\u53ca CI/CD \u7b49\u81ea\u52d5\u5316\u7dad\u904b\u5834\u666f\u7684\u7a0b\u5f0f\u78bc\u7bc4\u4f8b\uff08\u5c55\u958b\u6aa2\u8996\uff09 <p>\u5982\u679c\u4f60\u4e0d\u60f3\u8b93\u7528\u6236\u9032\u884c\u4efb\u4f55\u4ea4\u4e92\uff0c\u8acb\u4f7f\u7528 <code>\u5b8c\u5168\u81ea\u52d5\u5316</code> \u7bc4\u4f8b</p> <ul> <li> </li> <li> </li> </ul>"},{"location":"zh-Hant/other/#\u6700\u4f73\u5be6\u8e10","title":"\u6700\u4f73\u5be6\u8e10","text":""},{"location":"zh-Hant/other/#\u5b8c\u5168\u81ea\u52d5\u5316\u5efa\u8b70","title":"\u5b8c\u5168\u81ea\u52d5\u5316\uff08\u5efa\u8b70\uff09","text":"<pre><code># !/bin/bash\nfunction install_docker() {\n if command -v docker &>/dev/null; then\n return\n fi\n\n # script options\n local script_host=\"linuxmirrors.cn\" # official host (CDN), more host see official site\n local close_firewall=\"true\" # close firewalld service and selinux (redhat systems need)\n # mirrors options\n local source_docker_ce_address=\"mirrors.tencent.com/docker-ce\" # global high availability address\n local source_docker_ce_protocol=\"https\" # https or http\n local source_docker_registry_address=\"registry.hub.docker.com\"\n\n # judge network environment\n local region_code=\"$(curl -s ipinfo.io/country)\"\n if [[ \"${region_code}\" == \"CN\" ]]; then\n local source_intranet_address=\"\"\n # use intranet source if possible\n if [ -s \"/sys/class/dmi/id/sys_vendor\" ]; then\n local sys_vendor=\"$(cat /sys/class/dmi/id/sys_vendor)\"\n if [[ \"${sys_vendor}\" == *\"Alibaba\"* ]]; then\n source_intranet_address=\"mirrors.cloud.aliyuncs.com/docker-ce\"\n elif [[ \"${sys_vendor}\" == *\"Huawei\"* ]]; then\n source_intranet_address=\"mirrors.myhuaweicloud.com/docker-ce\"\n elif [[ \"${sys_vendor}\" == *\"Tencent\"* ]]; then\n source_intranet_address=\"mirrors.tencentyun.com/docker-ce\"\n elif [[ \"${sys_vendor}\" == *\"Inspur\"* ]]; then\n source_intranet_address=\"mirrors.ivolces.com/docker-ce\"\n fi\n else\n cat /etc/motd | grep \"Alibaba Cloud \" -q\n if [ $? -eq 0 ]; then\n source_intranet_address=\"mirrors.cloud.aliyuncs.com/docker-ce\"\n fi\n fi\n # check connectivity\n if [ -n \"${source_intranet_address}\" ]; then\n if ping -c1 -W1 \"${source_intranet_address%%/*}\" >/dev/null 2>&1; then\n source_docker_ce_address=\"${source_intranet_address}\"\n source_docker_ce_protocol=\"http\"\n fi\n fi\n # registry mirror (best choice for Chinese mainland)\n source_docker_registry_address=\"docker.1ms.run\"\n else\n # use official source\n source_docker_ce_address=\"download.docker.com\"\n source_docker_registry_address=\"registry.hub.docker.com\"\n fi\n\n # install docker engine\n bash <(curl -sSL https://${script_host}/docker-lite.sh) \\\n --source \"${source_docker_ce_address}\" \\\n --source-registry \"${source_docker_registry_address}\" \\\n --protocol \"${source_docker_ce_protocol}\" \\\n --close-firewall \"${close_firewall}\"\n}\n\ninstall_docker\n</code></pre>"},{"location":"zh-Hant/other/#\u7c21\u6613\u65b9\u5f0f","title":"\u7c21\u6613\u65b9\u5f0f","text":"<pre><code># !/bin/bash\nfunction install_docker() {\n if command -v docker &>/dev/null; then\n return\n fi\n\n bash <(curl -sSL https://${script_host}/docker.sh) \\\n --install-latest true \\\n --ignore-backup-tips \\\n --lang auto\n\n if command -v docker &>/dev/null; then\n echo -e \"\\n# Docker installation successful.\\n# Please run this script again manually after installation.\"\n exit 0\n else\n echo -e \"\\n# Docker installation failed.\\n# Please check the error message above.\"\n exit 1\n fi\n}\n\ninstall_docker\n</code></pre> <p>\u8a3b\uff1a\u4e0d\u6307\u5b9a <code>Docker CE \u6e90</code> \u4ee5\u53ca <code>\u6620\u50cf\u5009\u5eab\u6e90</code> \u5247\u6703\u4ea4\u7531\u4f7f\u7528\u8005\u9032\u884c\u4e92\u52d5\u9078\u64c7\uff0c\u5c46\u6642\u6703\u81ea\u52d5\u6e05\u5c4f <code>$ clear</code>\uff0c\u5f9e\u800c\u5c0e\u81f4\u4f60\u8173\u672c\u7684\u904b\u884c\u65e5\u8a8c\u88ab\u6e05\u9664</p>"},{"location":"zh-Hant/sponsor/","title":"\u8d0a\u52a9","text":""},{"location":"zh-Hant/sponsor/#_1","title":"\u8d0a\u52a9","text":"\u6210\u70ba\u8d0a\u52a9\u5546 <p>\u8acb\u524d\u5f80\u4f5c\u8005\u611b\u767c\u96fb\u4e3b\u9801\u67e5\u770b\u8aaa\u660e\u4e26\u8207\u4f5c\u8005\u53d6\u5f97\u806f\u7e6b</p>"},{"location":"zh-Hant/use/#\u4e00\u9375\u57f7\u884c\u547d\u4ee4","title":"\u4e00\u9375\u57f7\u884c\u547d\u4ee4","text":"\u4e2d\u570b\u5927\u9678 \u570b\u969b\u5730\u5340 \u4e2d\u570b\u5927\u9678\u6559\u80b2\u7db2 \u5b98\u7db2 (\u63a8\u85a6) GitHub Gitee \u78bc\u96f2 (\u93e1\u50cf\u5009\u5eab) GitCode (\u93e1\u50cf\u5009\u5eab) jsDelivr (CDN) \u9a30\u8a0a\u96f2 EO (CDN) <pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --zh-hant\n</code></pre> <pre><code>bash <(curl -sSL https://raw.githubusercontent.com/SuperManito/LinuxMirrors/main/ChangeMirrors.sh) --zh-hant\n</code></pre> <pre><code>bash <(curl -sSL https://gitee.com/SuperManito/LinuxMirrors/raw/main/ChangeMirrors.sh) --zh-hant\n</code></pre> <p>\u5373\u6642\u540c\u6b65\u3001\u7121\u5ef6\u9072\uff0c\u4e2d\u570b\u5927\u9678\u7db2\u8def\u74b0\u5883\u4e0b\u63a8\u85a6\u4f7f\u7528</p> <pre><code>bash <(curl -sSL https://raw.gitcode.com/SuperManito/LinuxMirrors/raw/main/ChangeMirrors.sh) --zh-hant\n</code></pre> <p>\u540c\u6b65\u5b58\u57281\u5c0f\u6642\u5ef6\u9072</p> <pre><code>bash <(curl -sSL https://cdn.jsdelivr.net/gh/SuperManito/LinuxMirrors@main/ChangeMirrors.sh) --zh-hant\n</code></pre> <pre><code>bash <(curl -sSL https://edgeone.linuxmirrors.cn/main.sh) --zh-hant\n</code></pre> <p>\u4e0d\u5efa\u8b70\u5728\u4e2d\u570b\u5927\u9678\u7db2\u8def\u74b0\u5883\u4e0b\u4f7f\u7528</p> \u5b98\u7db2 (\u63a8\u85a6) GitHub Gitee \u78bc\u96f2 (\u93e1\u50cf\u5009\u5eab) GitCode (\u93e1\u50cf\u5009\u5eab) jsDelivr (CDN) \u9a30\u8a0a\u96f2 EO (CDN) <pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --zh-hant --abroad\n</code></pre> <pre><code>bash <(curl -sSL https://raw.githubusercontent.com/SuperManito/LinuxMirrors/main/ChangeMirrors.sh) --zh-hant --abroad\n</code></pre> <pre><code>bash <(curl -sSL https://gitee.com/SuperManito/LinuxMirrors/raw/main/ChangeMirrors.sh) --zh-hant --abroad\n</code></pre> <p>\u5373\u6642\u540c\u6b65\u3001\u7121\u5ef6\u9072\uff0c\u4e2d\u570b\u5927\u9678\u7db2\u8def\u74b0\u5883\u4e0b\u63a8\u85a6\u4f7f\u7528</p> <pre><code>bash <(curl -sSL https://raw.gitcode.com/SuperManito/LinuxMirrors/raw/main/ChangeMirrors.sh) --zh-hant --abroad\n</code></pre> <p>\u540c\u6b65\u5b58\u57281\u5c0f\u6642\u5ef6\u9072</p> <pre><code>bash <(curl -sSL https://cdn.jsdelivr.net/gh/SuperManito/LinuxMirrors@main/ChangeMirrors.sh) --zh-hant --abroad\n</code></pre> <pre><code>bash <(curl -sSL https://edgeone.linuxmirrors.cn/main.sh) --zh-hant --abroad\n</code></pre> <p>\u4e0d\u5efa\u8b70\u5728\u4e2d\u570b\u5927\u9678\u7db2\u8def\u74b0\u5883\u4e0b\u4f7f\u7528</p> \u5b98\u7db2 (\u63a8\u85a6) GitHub Gitee \u78bc\u96f2 (\u93e1\u50cf\u5009\u5eab) GitCode (\u93e1\u50cf\u5009\u5eab) jsDelivr (CDN) \u9a30\u8a0a\u96f2 EO (CDN) <pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --zh-hant --edu\n</code></pre> <pre><code>bash <(curl -sSL https://raw.githubusercontent.com/SuperManito/LinuxMirrors/main/ChangeMirrors.sh) --zh-hant --edu\n</code></pre> <pre><code>bash <(curl -sSL https://gitee.com/SuperManito/LinuxMirrors/raw/main/ChangeMirrors.sh) --zh-hant --edu\n</code></pre> <p>\u5373\u6642\u540c\u6b65\u3001\u7121\u5ef6\u9072\uff0c\u4e2d\u570b\u5927\u9678\u7db2\u8def\u74b0\u5883\u4e0b\u63a8\u85a6\u4f7f\u7528</p> <pre><code>bash <(curl -sSL https://raw.gitcode.com/SuperManito/LinuxMirrors/raw/main/ChangeMirrors.sh) --zh-hant --edu\n</code></pre> <p>\u540c\u6b65\u5b58\u57281\u5c0f\u6642\u5ef6\u9072</p> <pre><code>bash <(curl -sSL https://cdn.jsdelivr.net/gh/SuperManito/LinuxMirrors@main/ChangeMirrors.sh) --zh-hant --edu\n</code></pre> <pre><code>bash <(curl -sSL https://edgeone.linuxmirrors.cn/main.sh) --zh-hant --edu\n</code></pre> <p>\u4e0d\u5efa\u8b70\u5728\u4e2d\u570b\u5927\u9678\u7db2\u8def\u74b0\u5883\u4e0b\u4f7f\u7528</p> <p>\u4f7f\u7528\u5e6b\u52a9</p> <p>\u9078\u9805\u5361\u5206\u5225\u4ee3\u8868\u8173\u672c\u5167\u5efa\u8edf\u9ad4\u6e90\uff08\u93e1\u50cf\u7ad9\uff09\u985e\u578b\u548c\u7372\u53d6\u8173\u672c\u9014\u5f91\uff0c\u8acb\u5728\u4f7f\u7528\u524d\u6aa2\u67e5\u76ee\u6a19\u93e1\u50cf\u7ad9\u662f\u5426\u652f\u63f4\u4f60\u6240\u4f7f\u7528\u7684\u4f5c\u696d\u7cfb\u7d71\uff0c\u53ef\u4ee5\u5728\u8edf\u9ad4\u6e90\u5217\u8868\u4e2d\u67e5\u770b\u3002 \u9810\u8a2d\u81ea\u52d5\u5099\u4efd\u539f\u6709\u8edf\u9ad4\u6e90\u5167\u5bb9\uff0c\u5982\u9700\u4e86\u89e3\u66f4\u591a\u8acb\u7ffb\u95b1\u4e0b\u65b9\u6587\u4ef6\u3002\u82e5\u4f7f\u7528\u904e\u7a0b\u4e2d\u7684\u67d0\u4e9b\u9078\u9805\u4ee4\u4f60\u7591\u60d1\u4e0d\u89e3\uff0c\u90a3\u9ebc\u5728\u9078\u64c7\u8edf\u9ad4\u6e90\u5f8c\u4e00\u8def\u56de\u8eca\u5373\u662f\u6700\u4f73\u5be6\u8e10\u3002</p> <p>\u652f\u63f4\u5728\u7cfb\u7d71\u539f\u6709\u8edf\u9ad4\u6e90\u640d\u58de\u3001\u7f3a\u5931\u3001\u7121\u6548\u7b49\u7570\u5e38\u74b0\u5883\u4e0b\u4f7f\u7528\uff0c\u7121\u9700\u984d\u5916\u5b89\u88dd\u4efb\u4f55\u4f9d\u8cf4\u3002</p> <p>\u95dc\u65bc\u8edf\u9ad4\u6e90\u7684\u9078\u64c7\uff08\u65b0\u7528\u6236\u5fc5\u8b80\uff09</p> <p>\u5982\u679c\u4f60\u4e0d\u4e86\u89e3\u9019\u4e9b\u93e1\u50cf\u7ad9\uff0c\u90a3\u9ebc\u5efa\u8b70\u4f7f\u7528 <code>\u963f\u91cc\u96f2 (\u76f8\u5bb9\u6027\u9ad8\u3001\u53ef\u7528\u6027\u5f37)</code> \u6216 <code>\u4e2d\u570b\u79d1\u5b78\u6280\u8853\u5927\u5b78 (\u901f\u5ea6\u5feb)</code>\uff0c\u8acb\u4e0d\u8981\u9677\u5165\u6e2c\u901f\u7126\u616e\uff0c\u5167\u5efa\u7684\u8edf\u9ad4\u6e90\u4e00\u822c\u4e0d\u6703\u6709\u592a\u5927\u7684\u5dee\u7570\u3002 \u672c\u5c08\u6848\u8173\u672c\u662f\u4e00\u500b\u81ea\u52d5\u5316\u7dad\u904b\u5de5\u5177\uff0c\u4e0d\u6703\u5c0d\u93e1\u50cf\u7ad9\u9032\u884c\u4e3b\u89c0\u7684\u512a\u52a3\u6392\u5e8f\u548c\u5ba2\u88fd\u5316\u9069\u914d\uff0c\u4f7f\u7528\u8005\u7684\u9078\u64c7\u61c9\u8a72\u662f\u81ea\u7531\u7684\uff0c\u9019\u4e5f\u662f\u70ba\u4e86\u958b\u6e90\u8edf\u9ad4\u7cbe\u795e\u80fd\u5920\u5f97\u5230\u66f4\u597d\u7684\u5ef6\u7e8c\u3002</p> <ul> <li> <p> \u9700\u8981 <code>ROOT</code> \u6b0a\u9650</p> <p>\u8acb\u4f7f\u7528 <code>root</code> \u5e33\u6236\u57f7\u884c\u672c\u8173\u672c\uff0c\u5207\u63db\u6307\u4ee4\u70ba <code>sudo -i</code> \u6216 <code>su root</code>\uff0c\u4e0d\u540c\u7cfb\u7d71\u4f7f\u7528\u7684\u6307\u4ee4\u4e0d\u540c\u3002\u53e6\u5916\u6ce8\u610f\u4e0d\u8981\u900f\u904e <code>sudo</code> \u76f4\u63a5\u57f7\u884c\u4e00\u9375\u6307\u4ee4\u4f8b\u5982 <code>sudo bash <(xxx)</code>\u3002</p> </li> <li> <p> \u5efa\u8b70\u4f7f\u7528\u73fe\u4ee3\u5316\u7684 <code>SSH</code> \u7528\u6236\u7aef\u61c9\u7528</p> <p>\u5982\u679c\u7cfb\u7d71\u547d\u4ee4\u5217\u4ecb\u9762\u7684\u4e2d\u6587\u986f\u793a\u4e82\u78bc\uff0c\u5c07\u5c0e\u81f4\u7121\u6cd5\u67e5\u770b\u4e92\u52d5\u5167\u5bb9\uff0c\u6b64\u5916\u90e8\u5206\u7cfb\u7d71 GUI \u5716\u5f62\u4ecb\u9762\u7684\u7d42\u7aef\u61c9\u7528\u53ef\u80fd\u5b58\u5728\u4e00\u4e9b\u7121\u6cd5\u9810\u6599\u7684\u986f\u793a\u554f\u984c\u3002\u90e8\u5206\u7cfb\u7d71\u6703\u81ea\u52d5\u958b\u555f SSH \u670d\u52d9\uff0c\u5426\u5247\u8acb\u53c3\u8003\u958b\u555f\u65b9\u6cd5\u3002</p> </li> <li> <p> \u5982\u679c\u662f\u5728\u65b0\u88dd\u7cfb\u7d71\u4e0a\u9996\u6b21\u57f7\u884c\u8173\u672c</p> <p>\u76ee\u524d\u4f9d\u8cf4 <code>curl</code> \u6307\u4ee4\u53d6\u5f97\u8173\u672c\u5167\u5bb9\uff0c\u4f46\u90e8\u5206\u4f5c\u696d\u7cfb\u7d71\u672a\u9810\u5148\u5b89\u88dd\u6b64\u8edf\u9ad4\u5305\uff0c\u5c07\u6703\u5831\u932f <code>Command not found</code>\uff0c\u5b89\u88dd\u65b9\u6cd5\u8a73\u898b\u4e0b\u65b9 \u95dc\u65bc\u5831\u932f Command not found\u3002\u8173\u672c\u672c\u8eab\u8207 <code>curl</code> <code>wget</code> \u6307\u4ee4\u7121\u95dc\uff0c\u4e0d\u6703\u4e0b\u8f09\u4efb\u4f55\u5167\u5bb9\u3002</p> </li> <li> <p> \u8173\u672c\u904b\u884c\u671f\u9593\u9700\u8981\u4e92\u52d5\u9078\u64c7\u914d\u7f6e</p> <p>\u8acb\u900f\u904e\u65b9\u5411\u9375 UpDownLeftRight \u6216 WASD \u63a7\u5236\u9078\u9805\u4e26\u6309 Enter \u56de\u8eca\u9375\u78ba\u8a8d\u3002\u5982\u679c\u767c\u73fe\u4e92\u52d5\u7570\u5e38\u8acb\u6539\u8b8a\u7d42\u7aef\u8edf\u9ad4\u7684\u8996\u7a97\u5927\u5c0f\u5f8c\u91cd\u8a66\uff0c\u907f\u514d\u8996\u7a97\u92ea\u6eff\u5168\u87a2\u5e55\u3002</p> </li> </ul>"},{"location":"zh-Hant/use/#\u5e38\u898b\u554f\u984c","title":"\u5e38\u898b\u554f\u984c","text":""},{"location":"zh-Hant/use/#\u95dc\u65bc\u5831\u932f-command-not-found","title":"\u95dc\u65bc\u5831\u932f Command not found","text":"<p>\u6b64\u5831\u932f\u662f\u7531\u65bc\u7cfb\u7d71\u6c92\u6709\u5b89\u88dd <code>curl</code> \u8edf\u9ad4\u5305\u5c0e\u81f4\uff0c\u5b89\u88dd\u547d\u4ee4\u5982\u4e0b</p> Debian \u7cfb / openKylinRedHat \u7cfb / openEuler / OpenCloudOS / Anolis OSopenSUSEArch Linux / ManjaroAlpine LinuxGentooNixOS <pre><code>apt-get install -y curl\n</code></pre> <p><code>Debian</code> <code>Ubuntu</code> <code>Kali</code> <code>Linux Mint</code> <code>Deepin</code> <code>Zorin OS</code> <code>Armbian</code> <code>Proxmox VE</code> <code>Raspberry Pi OS</code> <code>openKylin</code></p> <p>\u65b0\u88dd\u7cfb\u7d71\u9700\u8981\u5148\u57f7\u884c\u4e00\u904d\u66f4\u65b0 <code>apt-get update</code></p> <pre><code>dnf install -y curl || yum install -y curl\n</code></pre> <p><code>Red Hat Enterprise Linux</code> <code>CentOS</code> <code>Rocky Linux</code> <code>AlmaLinux</code> <code>Fedora</code> <code>openEuler</code> <code>OpenCloudOS</code> <code>Anolis OS</code></p> <pre><code>zypper install curl\n</code></pre> <pre><code>pacman -S curl\n</code></pre> <pre><code>apk --no-cache add -f curl bash ncurses\n</code></pre> <pre><code>emerge --ask curl\n</code></pre> <pre><code>nix-env -iA nixos.curl\n</code></pre> \u5b89\u88dd\u4e0d\u4e0a\uff1f \uff08\u9ede\u64ca\u5c55\u958b\u67e5\u770b\u5176\u5b83\u89e3\u6c7a\u65b9\u6cd5\uff09 <p>\u5047\u5982\u7cfb\u7d71\u539f\u6709\u8edf\u9ad4\u6e90\u662f\u7121\u6548\u7684\u5c0e\u81f4\u5b89\u88dd\u4e0d\u4e0a <code>curl</code> \u8edf\u9ad4\u5305\uff0c\u90a3\u9ebc\u5c0d\u65bc Linux \u521d\u5b78\u8005\u4f86\u8aaa\u53ef\u80fd\u6703\u6bd4\u8f03\u9ebb\u7169\uff0c\u9019\u88e1\u63d0\u4f9b\u5e7e\u500b\u5728\u7dda\u7372\u53d6\u8173\u672c\u7684\u61c9\u6025\u65b9\u6cd5</p> \u4f7f\u7528 Python \u4e0b\u8f09\u4f7f\u7528 wget \u6307\u4ee4\u4e0b\u8f09\u4f7f\u7528\u700f\u89bd\u5668\u4e0b\u8f09 <p>\u9069\u7528\u65bc\u5927\u90e8\u5206\u4f5c\u696d\u7cfb\u7d71\uff08<code>Alpine Linux</code> \u9664\u5916\uff09\uff0c<code>python3</code> \u8981\u662f\u4e0d\u5b58\u5728\u90a3\u5c31\u518d\u8a66\u8a66 <code>python</code> \u6307\u4ee4 <pre><code>python3 -c \"import urllib.request; urllib.request.urlretrieve('https://linuxmirrors.cn/main.sh', 'main.sh')\"\n</code></pre></p> <p>\u4e00\u822c\u6c92\u6709\u9810\u5148\u5b89\u88dd <code>curl</code> \u8edf\u9ad4\u5305\u7684\u7cfb\u7d71\u4e5f\u4e0d\u6703\u9810\u5148\u5b89\u88dd <code>wget</code> \u8edf\u9ad4\u5305\uff0c\u6240\u4ee5\u5927\u6a5f\u7387\u9019\u500b\u65b9\u6cd5\u61c9\u8a72\u662f\u4e0d\u884c\u7684 <pre><code>wget https://linuxmirrors.cn/main.sh\n</code></pre></p> <p>\u5982\u679c\u53ef\u4ee5\u8a2a\u554f\u7cfb\u7d71 \u200b\u200bGUI \u6620\u50cf\u4ecb\u9762\u548c\u684c\u9762\u7684\u8a71\u90a3\u53ef\u4ee5\u76f4\u63a5\u5728\u700f\u89bd\u5668\u4e2d\u958b\u555f\u9023\u7d50\u4e0b\u8f09\u8173\u672c\uff0c\u8a31\u591a\u7cfb\u7d71\u90fd\u6703\u9810\u5148\u5b89\u88dd Firefox \u706b\u72d0\u700f\u89bd\u5668</p> <p>\u4e4b\u5f8c\u518d\u57f7\u884c\u8173\u672c\u5373\u53ef</p> \u4e2d\u570b\u5927\u9678 \u570b\u969b\u5730\u5340 \u4e2d\u570b\u5927\u9678\u6559\u80b2\u7db2 <pre><code>bash main.sh --zh-hant\n</code></pre> <pre><code>bash main.sh --zh-hant --abroad\n</code></pre> <pre><code>bash main.sh --zh-hant --edu\n</code></pre> <p>\u5982\u679c\u4ee5\u4e0a\u65b9\u6cd5\u8a66\u4e86\u90fd\u4e0d\u884c\uff0c\u90a3\u5c31\u8907\u88fd\u539f\u59cb\u78bc\u81f3\u672c\u5730\u65b0\u5efa\u4efb\u610f\u540d\u7a31\u7684 <code>.sh</code> \u8173\u672c\uff0c\u8cbc\u4e0a\u539f\u59cb\u78bc\u5167\u5bb9\u5f8c\u900f\u904e <code>bash</code> \u6307\u4ee4\u624b\u52d5\u57f7\u884c\u3002</p>"},{"location":"zh-Hant/use/#\u5099\u4efd\u539f\u6709\u8edf\u9ad4\u6e90","title":"\u5099\u4efd\u539f\u6709\u8edf\u9ad4\u6e90","text":"<p>\u8173\u672c\u6703\u81ea\u52d5\u5099\u4efd\u539f\u6709\u8edf\u9ad4\u6e90\u5167\u5bb9\uff0c\u5099\u4efd\u8def\u5f91\u70ba\u539f\u59cb\u6587\u4ef6\u6216\u76ee\u9304\u7684\u7d55\u5c0d\u8def\u5f91\u52a0\u4e0a <code>.bak</code> \u5f8c\u7db4\uff0c\u4f8b\u5982 <code>/etc/apt/sources.list => /etc/apt/sources.list.bak</code>\uff0c\u6aa2\u67e5\u5df2\u5b58\u5728\u5099\u4efd\u5167\u5bb9\u6642\u6703\u8a62\u554f\u662f\u5426\u8986\u84cb\u5099\u4efd\u3002</p>"},{"location":"zh-Hant/use/#\u9084\u539f\u5df2\u5099\u4efd\u7684\u8edf\u9ad4\u6e90","title":"\u9084\u539f\u5df2\u5099\u4efd\u7684\u8edf\u9ad4\u6e90","text":"\u9ede\u64ca\u5c55\u958b\u67e5\u770b Debian \u7cfb / openKylinRedHat \u7cfb / openEuler / OpenCloudOS / Anolis OSopenSUSEArch Linux / ManjaroAlpine LinuxGentooNixOS \u50b3\u7d71\u683c\u5f0fDEB822 \u683c\u5f0f <pre><code>cp -rf /etc/apt/sources.list.bak /etc/apt/sources.list\napt-get update\n</code></pre> <pre><code>system_name=\"$(lsb_release -is | tr '[:upper:]' '[:lower:]')\"\ncp -rf \"/etc/apt/sources.list.d/${system_name}.sources.bak\" \"/etc/apt/sources.list.d/${system_name}.sources\"\napt-get update\n</code></pre> <p><code>Debian</code> <code>Ubuntu</code> <code>Kali</code> <code>Linux Mint</code> <code>Deepin</code> <code>Zorin OS</code> <code>Armbian</code> <code>Proxmox VE</code> <code>Raspberry Pi OS</code> <code>openKylin</code></p> <pre><code>cp -rf /etc/yum.repos.d.bak /etc/yum.repos.d\nyum makecache\n</code></pre> <p><code>Red Hat Enterprise Linux</code> <code>CentOS</code> <code>Rocky Linux</code> <code>AlmaLinux</code> <code>Fedora</code> <code>openEuler</code> <code>OpenCloudOS</code> <code>Anolis OS</code></p> <pre><code>cp -rf /etc/zypp/repos.d.bak /etc/zypp/repos.d\nzypper ref\n</code></pre> <pre><code>cp -rf /etc/pacman.d/mirrorlist.bak /etc/pacman.d/mirrorlist\npacman -Sy\n</code></pre> <pre><code>cp -rf /etc/apk/repositories.bak /etc/apk/repositories\napk update -f\n</code></pre> <pre><code>cp -rf /etc/portage/make.conf.bak /etc/portage/make.conf\n[ -d /etc/portage/repos.conf ] && cp -rf /etc/portage/repos.conf/gentoo.conf.bak /etc/portage/repos.conf/gentoo.conf\nemerge --sync --quiet\n</code></pre> <pre><code>cp -rf /etc/nix/nix.conf.bak /etc/nix/nix.conf\n</code></pre>"},{"location":"zh-Hant/use/#\u95dc\u65bc\u958b\u555f-ssh-\u9060\u7aef\u767b\u5165\u7684\u65b9\u6cd5","title":"\u95dc\u65bc\u958b\u555f SSH \u9060\u7aef\u767b\u5165\u7684\u65b9\u6cd5","text":"\u9ede\u64ca\u5c55\u958b\u67e5\u770b <p>\u6307\u4ee4\u4ee5\u53ca\u8a2d\u5b9a\u6b65\u9a5f\u50c5\u4f9b\u53c3\u8003\uff0c\u6ce8\u610f\u9748\u6d3b\u8b8a\u901a</p> <ul> <li> <p>\u9a57\u8b49\u662f\u5426\u5df2\u5b89\u88dd <code>SSH</code> \u670d\u52d9</p> <pre><code>ls /etc | grep ssh\n</code></pre> <p>\u5982\u679c\u6c92\u6709\u9019\u500b\u8cc7\u6599\u593e\u8aaa\u660e\u7cfb\u7d71\u672a\u5b89\u88dd <code>SSH</code> \u670d\u52d9\uff0c\u4f60\u9700\u8981\u900f\u904e\u5957\u4ef6\u7ba1\u7406\u5de5\u5177\u5b89\u88dd <code>openssh-server</code> \u8edf\u9ad4\u5305\uff0c\u5b89\u88dd\u6307\u4ee4\u5982\u4e0b\uff1a</p> Debian \u7cfb / openKylinRedHat \u7cfb / openEuler / OpenCloudOS / Anolis OSopenSUSEArch Linux / ManjaroAlpine LinuxGentoo <pre><code>apt-get install -y openssh-server\n</code></pre> <p><code>Debian</code> <code>Ubuntu</code> <code>Kali</code> <code>Linux Mint</code> <code>Deepin</code> <code>Zorin OS</code> <code>Armbian</code> <code>Proxmox VE</code> <code>Raspberry Pi OS</code> <code>openKylin</code></p> <p>\u65b0\u88dd\u7cfb\u7d71\u9700\u8981\u5148\u57f7\u884c\u4e00\u904d\u66f4\u65b0 <code>apt-get update</code></p> <pre><code>dnf install -y openssh-server || yum install -y openssh-server\n</code></pre> <p><code>Red Hat Enterprise Linux</code> <code>CentOS</code> <code>Rocky Linux</code> <code>AlmaLinux</code> <code>Fedora</code> <code>openEuler</code> <code>OpenCloudOS</code> <code>Anolis OS</code></p> <pre><code>zypper install openssh-server\n</code></pre> <pre><code>pacman -S openssh\n</code></pre> <pre><code>apk --no-cache add -f openssh\n</code></pre> <pre><code>emerge --ask --changed-use --oneshot net-misc/openssh\n</code></pre> <p>\u4e0d\u540c\u7cfb\u7d71\u4e0a\u7684\u8edf\u9ad4\u5305\u540d\u7a31\u6709\u6240\u5dee\u7570\uff0c\u5982\u679c\u63d0\u793a\u627e\u4e0d\u5230\u8a72\u8edf\u9ad4\u5305\u53ef\u5617\u8a66\u4f7f\u7528\u901a\u914d\u7b26 <code>openssh*</code> \u9032\u884c\u5b89\u88dd</p> </li> <li> <p>\u8a2d\u5b9a <code>SSH</code> \u670d\u52d9</p> \u5141\u8a31 root \u5e33\u6236\u767b\u5165<pre><code>cat /etc/ssh/sshd_config | grep -Eq \"^[# ]?PermitRootLogin \" ; [ $? -eq 0 ] && sed -i 's/^[# ]\\?PermitRootLogin.*/PermitRootLogin yes/g' /etc/ssh/sshd_config || echo -e \"\\nPermitRootLogin yes\" >> /etc/ssh/sshd_config\n</code></pre> \u555f\u7528\u5bc6\u78bc\u8a8d\u8b49<pre><code>cat /etc/ssh/sshd_config | grep -Eq \"^[# ]?PasswordAuthentication \" ; [ $? -eq 0 ] && sed -i 's/^[# ]\\?PasswordAuthentication.*/PasswordAuthentication yes/g' /etc/ssh/sshd_config || echo -e \"\\nPasswordAuthentication yes\" >> /etc/ssh/sshd_config\n</code></pre> </li> <li> <p>\u555f\u52d5/\u91cd\u555f <code>SSH</code> \u670d\u52d9</p> <pre><code>for ssh_svc in sshd ssh openssh; do systemctl restart \"${ssh_svc}\" 2>/dev/null && break ; systemctl enable --now \"${ssh_svc}\" 2>/dev/null && break ; done\n</code></pre> </li> </ul> <p>\u53cb\u60c5\u63d0\u793a\uff1a\u5982\u679c\u4f60\u6b63\u5728\u4f7f\u7528\u516c\u7db2\u4f3a\u670d\u5668\uff0c\u5efa\u8b70\u95dc\u9589 SSH \u5bc6\u78bc\u8a8d\u8b49\u65b9\u5f0f\u4e26\u8a2d\u5b9a\u91d1\u9470\u767b\u5165\u3002</p>"},{"location":"zh-Hant/use/#\u95dc\u65bc\u672a\u986f\u793a\u65b9\u5411\u9375\u4ea4\u4e92\u63a7\u5236\u4ecb\u9762","title":"\u95dc\u65bc\u672a\u986f\u793a\u65b9\u5411\u9375\u4ea4\u4e92\u63a7\u5236\u4ecb\u9762","text":"<p>\u5982\u679c\u767c\u73fe\u4e92\u52d5\u4ecb\u9762\u662f\u8f38\u5165\u800c\u975e\u65b0\u5f0f\u7684\u65b9\u5411\u9375\u63a7\u5236\uff0c\u90a3\u9ebc\u8acb\u81ea\u884c\u5b89\u88dd <code>ncurses</code> \u6216 <code>nano</code> \u8edf\u9ad4\u5305\uff0c\u65b0\u5f0f\u7684\u6309\u9375\u4e92\u52d5\u4f9d\u8cf4 <code>tput</code> \u6307\u4ee4\u5be6\u4f5c\u3002</p>"},{"location":"zh-Hant/use/#\u95dc\u65bc\u672a\u555f\u7528\u7684\u8edf\u9ad4\u6e90\u5009\u5eab","title":"\u95dc\u65bc\u672a\u555f\u7528\u7684\u8edf\u9ad4\u6e90\u5009\u5eab","text":"<p>\u8a31\u591a\u7cfb\u7d71\u7684\u8edf\u9ad4\u6e90\u6703\u555f\u7528\u591a\u500b\u5009\u5eab\uff0c\u8173\u672c\u9075\u5faa\u7cfb\u7d71\u9810\u8a2d\u8a2d\u7f6e\uff0c\u9810\u8a2d\u4e0d\u555f\u7528\u7684\u8edf\u9ad4\u6e90\uff08\u5009\u5eab\uff09\u4e0d\u6703\u5728\u904b\u884c\u5b8c\u672c\u8173\u672c\u5f8c\u88ab\u555f\u7528\uff0c\u4f46\u662f\u5b83\u5011\u4e5f\u96a8\u8173\u672c\u66f4\u63db\u4e86\u76ee\u6a19\u8edf\u9ad4\u6e90\u4f4d\u5740\uff0c\u5177\u9ad4\u555f\u7528\u65b9\u6cd5\u5982\u4e0b\uff1a</p> Debian \u7cfb / openKylinRedHat \u7cfb / openEuler / OpenCloudOS / Anolis OSopenSUSE <p>\u9810\u8a2d\u7981\u7528\u4e86<code>deb-src</code>\u539f\u59cb\u78bc\u5009\u5eab\u548c<code>proposed</code>\u9810\u767c\u4f48\u8edf\u9ad4\u6e90\uff0c\u82e5\u9700\u555f\u7528\u8acb\u5c07 <code>/etc/apt/sources.list</code> \u6587\u4ef6\u4e2d\u76f8\u95dc\u5167\u5bb9\u7684\u6240\u5728\u884c\u53d6\u6d88\u8a3b\u91cb</p> <p><code>Debian</code> <code>Ubuntu</code> <code>Kali</code> <code>Linux Mint</code> <code>Deepin</code> <code>Zorin OS</code> <code>Armbian</code> <code>Proxmox VE</code> <code>Raspberry Pi OS</code> <code>openKylin</code></p> <p>\u90e8\u5206\u5009\u5eab\u9810\u8a2d\u6c92\u6709\u555f\u7528\uff0c\u82e5\u9700\u555f\u7528\u8acb\u5c07 <code>/etc/yum.repos.d</code> \u76ee\u9304\u4e0b\u76f8\u95dc repo \u6587\u4ef6\u4e2d\u7684 <code>enabled</code> \u503c\u4fee\u6539\u70ba <code>1</code></p> <p><code>Red Hat Enterprise Linux</code> <code>CentOS</code> <code>Rocky Linux</code> <code>AlmaLinux</code> <code>Fedora</code> <code>openEuler</code> <code>OpenCloudOS</code> <code>Anolis OS</code></p> <p>\u90e8\u5206\u5009\u5eab\u9810\u8a2d\u6c92\u6709\u555f\u7528\uff0c\u82e5\u9700\u555f\u7528\u8acb\u5c07 <code>/etc/zypp/repos.d</code> \u76ee\u9304\u4e0b\u76f8\u95dc repo \u6587\u4ef6\u4e2d\u7684 <code>enabled</code> \u503c\u4fee\u6539\u70ba <code>1</code></p>"},{"location":"zh-Hant/use/#\u5176\u5b83","title":"\u5176\u5b83","text":"\u95dc\u65bc\u547c\u53eb\u8173\u672c\u7684\u4e92\u806f\u7db2\u4f4d\u7f6e <p>\u5c08\u6848\u5229\u7528 GitHub Action \u5728\u6bcf\u6b21\u63d0\u4ea4\u5f8c\u81ea\u52d5\u62f7\u8c9d\u539f\u59cb\u78bc\u5230\u6587\u4ef6\u76ee\u9304\u4f5c\u70ba\u7db2\u7ad9\u8cc7\u6e90\u767c\u4f48\uff0c\u7db2\u7ad9\u8a17\u7ba1\u65bc Netlify\uff0c\u5e7e\u4e4e\u6c92\u6709\u4f7f\u7528\u98a8\u96aa\u3002 </p> <p>\u7576\u7136\u4f60\u4e5f\u53ef\u4ee5\u4f7f\u7528\u7a0b\u5f0f\u78bc\u8a17\u7ba1\u5009\u5eab\u7684\u539f\u59cb\u4f4d\u5740\u4f86\u8abf\u7528\uff0c\u9019\u88e1\u53ea\u662f\u60f3\u544a\u8a34\u4f60\u70ba\u4ec0\u9ebc\u6703\u6709\u5e7e\u500b\u4e0d\u540c\u7684\u4f4d\u5740\uff0c\u9810\u8a2d\u7684\u5b98\u7db2\u4f4d\u5740\u66f4\u5bb9\u6613\u8a18\u61b6\u548c\u8a2a\u554f\u3002</p> \u95dc\u65bc\u8edf\u9ad4\u6e90\u4e0b\u8f09\u901f\u5ea6\u554f\u984c <p>\u9996\u5148\uff0c\u5728\u8edf\u9ad4\u6e90\u5217\u8868\u7684\u4f7f\u7528\u5e6b\u52a9\u8655\u6709\u5beb\u4f7f\u7528\u63a8\u85a6\uff0c\u9019\u662f\u6839\u64da\u4ee5\u5f80\u7d93\u9a57\u7e3d\u7d50\u51fa\u4f86\u7684\uff0c\u4f46\u7e3d\u6709\u7528\u6236\u5728\u7cfe\u7d50\u8edf\u9ad4\u6e90\u901f\u5ea6\u7684\u554f\u984c\u3002 </p> <p>\u8edf\u9ad4\u6e90\uff08\u93e1\u50cf\u7ad9\uff09\u7684\u7db2\u8def\u5ef6\u9072\u5373 <code>Ping</code> \u8207\u4e0b\u8f09\u901f\u5ea6\u6c92\u6709\u592a\u5927\u7684\u95dc\u806f\uff0c\u96d9\u65b9\u5730\u7406\u4f4d\u7f6e\u9593\u9694\u7684\u9060\u8fd1\u4e0d\u4ee3\u8868\u5be6\u969b\u9ad4\u9a57\uff0c\u6709\u4e9b\u93e1\u50cf\u7ad9\u4e0b\u884c\u7e3d\u983b\u5bec\u5f88\u9ad8\u4f46\u5be6\u969b\u6e2c\u901f\u537b\u4e26\u4e0d\u7406\u60f3\uff0c\u56e0\u70ba\u9019\u8207\u93e1\u50cf\u7ad9\u7684\u8ca0\u8f09\u7b56\u7565\u6709\u95dc\u3002 </p> <p>\u7db2\u8def\u4e0a\u4e5f\u6709\u5f88\u591a\u57fa\u65bc C\u3001Python \u7de8\u5beb\u7684\u93e1\u50cf\u7ad9\u6e2c\u901f\u958b\u6e90\u8173\u672c\uff0c\u800c\u672c\u5c08\u6848\u8173\u672c\u57fa\u65bc Bash Shell \u7de8\u5beb\u4e14\u4e0d\u4f9d\u8cf4\u4efb\u4f55\u7b2c\u4e09\u65b9\u5eab\uff0cBash \u662f Linux \u904b\u7dad\u4e2d\u6700\u5e38\u7528\u7684\u8173\u672c\u8a9e\u8a00\u4e26\u4e14\u7d55\u5927\u90e8\u5206\u767c\u884c\u7248\u90fd\u6703\u9810\u88dd\uff0c\u9019\u610f\u5473\u8457\u7528\u6236\u4e0d\u9700\u8981\u5b89\u88dd\u4efb\u4f55\u74b0\u5883\u5c31\u80fd\u76f4\u63a5\u904b\u884c\uff0c\u9019\u7a2e\u4fbf\u5229\u6027\u662f\u5176\u4ed6\u9ad8\u7d1a\u8a9e\u8a00\u7121\u6cd5\u66ff\u4ee3\u7684\uff0c\u4e0d\u904e\u76ee\u524d Bash \u8173\u672c\u53ef\u80fd\u4e0d\u592a\u5bb9\u6613\u5be6\u73fe\u7cbe\u6e96\u6e2c\u901f\u7684\u529f\u80fd\uff0c\u4f7f\u7528\u5176\u5b83\u9ad8\u7d1a\u8a9e\u8a00\u7de8\u5beb\u6e2c\u901f\u529f\u80fd\u7121\u7591\u662f\u9020\u8f2a\u5b50\u7684\u884c\u70ba\u3002</p> \u95dc\u65bc\u8edf\u9ad4\u6e90\u9078\u512a <p>\u5f88\u591a\u670b\u53cb\u53ef\u80fd\u90fd\u6703\u6709\u4e00\u500b\u7591\u554f\uff1a\u201c\u65e2\u7136\u8173\u672c\u5df2\u7d93\u5982\u6b64\u4fbf\u6377\u4e14\u5be6\u73fe\u4e86\u9ad8\u5ea6\u81ea\u52d5\u5316\uff0c\u70ba\u4ec0\u9ebc\u4e0d\u80fd\u5be6\u73fe\u8edf\u9ad4\u6e90\u81ea\u52d5\u9078\u512a\u5462\uff1f\u201d\uff0c\u4e0d\u662f\u505a\u4e0d\u5230\u800c\u662f\u4e0d\u80fd\u3002</p> <p>\u300c\u8edf\u9ad4\u6e90\u9078\u512a\u300d \u5728\u9019\u88e1\u6307\u7684\u662f\u8173\u672c\u6839\u64da\u5ba2\u6236\u7aef\u7684\u7db2\u8def\u74b0\u5883\u3001\u5730\u7406\u4f4d\u7f6e\u81ea\u52d5\u9078\u64c7\u4e00\u500b\u9ad4\u9a57\u6700\u4f73\u7684\u8edf\u9ad4\u6e90\uff0c\u9019\u500b\u554f\u984c\u8981\u5f9e\u591a\u500b\u89d2\u5ea6\u4f86\u8ad6\u8b49\uff1a</p> <ul> <li> <p>\u901f\u5ea6\u65b9\u9762</p> <p>\u5176\u5be6\u4e0a\u9762\u5df2\u7d93\u89e3\u91cb\u904e\u4e86\uff0c\u7e3d\u7d50\u4f86\u8aaa\u5c31\u662f\u8ffd\u6c42\u901f\u5ea6\u4e0d\u662f\u666e\u904d\u9700\u6c42\uff0c\u5c0d\u5927\u591a\u6578\u4eba\u4f86\u8aaa\u662f\u7121\u611f\u7684\u3001\u80fd\u7528\u5373\u53ef\uff0c\u6cc1\u4e14\u73fe\u5728\u5f88\u591a Linux \u767c\u884c\u7248\u4e0d\u9700\u8981\u63db\u6e90\u5c31\u6709\u4e0d\u932f\u7684\u901f\u5ea6\u3002</p> </li> <li> <p>\u5c0d\u65bc\u93e1\u50cf\u7ad9\u672c\u8eab</p> <p>\u8209\u500b\u6700\u7c21\u55ae\u7684\u4f8b\u5b50\uff0c\u4ee5\u524d\u963f\u91cc\u96f2\u93e1\u50cf\u7ad9\u56e0\u70ba\u901f\u5ea6\u5feb\u3001\u53ef\u7528\u6027\u9ad8\u5e7e\u4e4e\u88ab\u7576\u6210\u9996\u9078\uff0c\u4f46\u662f\u96a8\u8457\u7528\u6236\u8d8a\u4f86\u8d8a\u591a\u5c0e\u81f4\u901f\u5ea6\u8b8a\u7684\u539f\u4f86\u8d8a\u6162\u751a\u81f3\u53ef\u80fd\u4e0d\u8db3 10 Mbps\u3002 \u9577\u6b64\u4ee5\u5f80\uff0c\u90a3\u4e9b\u7528\u6236\u591a\u7684\u93e1\u50cf\u7ad9\u53ef\u80fd\u7121\u6cd5\u627f\u53d7\u904e\u9ad8\u7684\u6d41\u91cf\u800c\u5c0e\u81f4\u9ad4\u9a57\u4e0b\u964d\uff0c\u7528\u6236\u5c11\u7684\u93e1\u50cf\u7ad9\u53ef\u80fd\u6703\u6700\u7d42\u8d70\u5411\u95dc\u9589\uff0c\u9019\u4e0d\u5229\u65bc\u6574\u500b\u751f\u614b\u7684\u767c\u5c55\u3002</p> </li> <li> <p>\u958b\u767c\u8005\u89d2\u5ea6</p> <p>\u672c\u5c08\u6848\u7ad9\u5728\u7dad\u904b\u5de5\u5177\u7684\u89d2\u5ea6\u81f4\u529b\u65bc\u958b\u767c\u4e00\u500b\u901a\u7528\u7684\u63db\u6e90\u8173\u672c\uff0c\u800c\u4e0d\u662f\u4e00\u500b\u89e3\u6c7a\u8edf\u9ad4\u6e90\u9700\u6c42\u7684\u5177\u9ad4\u5316\u5de5\u5177\uff0c\u8981\u4f7f\u8173\u672c\u7684\u9810\u8a2d\u884c\u70ba\u9069\u7528\u65bc\u5927\u591a\u6578\u4f7f\u7528\u8005\u7fa4\u9ad4\u3002\u4f5c\u70ba\u7dad\u904b\u5de5\u5177\u8981\u6709\u660e\u78ba\u7684\u529f\u80fd\u5b9a\u4f4d\uff0c\u4f5c\u70ba\u8173\u672c\u8981\u5f9e\u64f4\u5c55\u6027\u3001\u5be6\u7528\u6027\u7b49\u591a\u500b\u65b9\u9762\u53bb\u8861\u91cf\u5229\u5f0a\uff0c\u8edf\u9ad4\u6e90\u7684\u9078\u64c7\u6b0a\u61c9\u8a72\u5b8c\u5168\u4ea4\u7d66\u4f7f\u7528\u8005\u3002</p> </li> </ul>"},{"location":"zh-Hant/use/#\u547d\u4ee4\u9078\u9805\u9032\u968e\u7528\u6cd5","title":"\u547d\u4ee4\u9078\u9805\uff08\u9032\u968e\u7528\u6cd5\uff09","text":"bash <(curl -sSL https://linuxmirrors.cn/main.sh) --zh-hant --help \u547d\u4ee4\u9078\u9805(\u540d\u7a31/\u542b\u7fa9/\u503c)\uff1a --abroad \u4f7f\u7528\u5883\u5916\u4ee5\u53ca\u6d77\u5916\u8edf\u9ad4\u6e90 \u7121 --edu \u4f7f\u7528\u4e2d\u570b\u5927\u9678\u6559\u80b2\u7db2\u8edf\u9ad4\u6e90 \u7121 --source \u6307\u5b9a\u8edf\u9ad4\u6e90\u5730\u5740(\u7db2\u57df\u540d\u7a31\u6216IP) \u4f4d\u5740 --source-epel \u6307\u5b9a EPEL \u9644\u52a0\u8edf\u9ad4\u5305\u5009\u5eab\u7684\u8edf\u9ad4\u6e90\u5730\u5740(\u7db2\u57df\u540d\u7a31\u6216IP) \u4f4d\u5740 --source-security \u6307\u5b9a Debian / Ubuntu \u7cfb\u7d71 security \u5009\u5eab\u7684\u8edf\u9ad4\u6e90\u5730\u5740(\u7db2\u57df\u540d\u7a31\u6216IP) \u4f4d\u5740 --source-vault \u6307\u5b9a CentOS / AlmaLinux \u7cfb\u7d71 vault \u5009\u5eab\u7684\u8edf\u9ad4\u6e90\u5730\u5740(\u7db2\u57df\u540d\u7a31\u6216IP) \u4f4d\u5740 --source-portage \u6307\u5b9a Gentoo \u7cfb\u7d71 portage \u5009\u5eab\u7684\u8edf\u9ad4\u6e90\u5730\u5740(\u7db2\u57df\u540d\u7a31\u6216IP) \u4f4d\u5740 --source-base-system \u6307\u5b9a Linux Mint / Raspberry Pi OS \u5e95\u5c64\u7cfb\u7d71\u7684\u8edf\u9ad4\u6e90\u5730\u5740(\u7db2\u57df\u540d\u7a31\u6216IP) \u4f4d\u5740 --branch \u6307\u5b9a\u8edf\u9ad4\u6e90\u5009\u5eab(\u8def\u5f91) \u5009\u5eab\u540d\u7a31 --branch-epel \u6307\u5b9a EPEL \u9644\u52a0\u8edf\u9ad4\u5305\u5009\u5eab\u7684\u8edf\u9ad4\u6e90\u5009\u5eab(\u8def\u5f91) \u5009\u5eab\u540d\u7a31 --branch-security \u6307\u5b9a Debian \u7cfb\u7d71 security \u5009\u5eab\u7684\u8edf\u9ad4\u6e90\u5009\u5eab(\u8def\u5f91) \u5009\u5eab\u540d\u7a31 --branch-vault \u6307\u5b9a CentOS / AlmaLinux \u7cfb\u7d71 vault \u5009\u5eab\u7684\u8edf\u9ad4\u6e90\u5009\u5eab(\u8def\u5f91) \u5009\u5eab\u540d\u7a31 --branch-portage \u6307\u5b9a Gentoo \u7cfb\u7d71 portage \u5009\u5eab\u7684\u8edf\u9ad4\u6e90\u5009\u5eab(\u8def\u5f91) \u5009\u5eab\u540d\u7a31 --branch-base-system \u6307\u5b9a Linux Mint / Raspberry Pi OS \u5e95\u5c64\u7cfb\u7d71\u7684\u8edf\u9ad4\u6e90\u5009\u5eab(\u8def\u5f91) \u5009\u5eab\u540d\u7a31 --codename \u6307\u5b9a Debian \u7cfb / openKylin \u7cfb\u7d71\u7684\u7248\u672c\u4ee3\u865f \u4ee3\u865f\u540d\u7a31 --protocol \u6307\u5b9a Web \u5354\u5b9a http \u6216 https --use-intranet-source \u662f\u5426\u512a\u5148\u4f7f\u7528\u5167\u90e8\u7db2\u8def\u8edf\u9ad4\u6e90\u4f4d\u5740 true \u6216 false --use-official-source \u662f\u5426\u4f7f\u7528\u76ee\u6a19\u7cfb\u7d71\u7684\u5b98\u65b9\u8edf\u9ad4\u6e90 true \u6216 false --use-official-source-epel \u662f\u5426\u4f7f\u7528 EPEL \u9644\u52a0\u8edf\u9ad4\u5305\u7684\u5b98\u65b9\u8edf\u9ad4\u6e90 true \u6216 false --install-epel \u662f\u5426\u5b89\u88dd EPEL \u9644\u52a0\u8edf\u9ad4\u5305 true \u6216 false --backup \u662f\u5426\u5099\u4efd\u539f\u6709\u8edf\u9ad4\u6e90 true \u6216 false --upgrade-software \u662f\u5426\u66f4\u65b0\u8edf\u9ad4\u5305 true \u6216 false --clean-cache \u662f\u5426\u5728\u66f4\u65b0\u8edf\u9ad4\u5305\u5f8c\u6e05\u7406\u4e0b\u8f09\u5feb\u53d6 true \u6216 false --clean-screen \u662f\u5426\u5728\u904b\u884c\u524d\u6e05\u9664\u87a2\u5e55\u4e0a\u7684\u6240\u6709\u5167\u5bb9 true \u6216 false --lang \u6307\u5b9a\u8173\u672c\u8f38\u51fa\u7684\u8a9e\u8a00 \u8bed\u8a00 --only-epel \u50c5\u66f4\u63db EPEL \u8edf\u9ad4\u6e90\u6a21\u5f0f \u7121 --ignore-backup-tips \u5ffd\u7565\u8986\u84cb\u5099\u4efd\u63d0\u793a \u7121 --print-diff \u662f\u5426\u5217\u5370\u539f\u59cb\u6587\u4ef6\u4fee\u6539\u524d\u5f8c\u5dee\u7570 \u7121 --pure-mode \u7d14\u6de8\u6a21\u5f0f\uff0c\u7cbe\u7c21\u5217\u5370\u5167\u5bb9 \u7121 --help \u67e5\u770b\u5e6b\u52a9\u9078\u55ae \u7121 \u540d\u7a31 \u542b\u7fa9 \u9078\u9805\u503c <code>--abroad</code> \u4f7f\u7528\u5883\u5916\u4ee5\u53ca\u6d77\u5916\u8edf\u9ad4\u6e90 \u7121 <code>--edu</code> \u4f7f\u7528\u4e2d\u570b\u5927\u9678\u6559\u80b2\u7db2\u8edf\u9ad4\u6e90 \u7121 <code>--source</code> \u6307\u5b9a\u8edf\u9ad4\u6e90\u4f4d\u5740\uff08\u7db2\u57df\u540d\u7a31\u6216IP\uff09 <code>\u4f4d\u5740</code> <code>--source-epel</code> \u6307\u5b9a EPEL \u9644\u52a0\u8edf\u9ad4\u5305\u5009\u5eab\u7684\u8edf\u9ad4\u6e90\u4f4d\u5740\uff08\u7db2\u57df\u540d\u7a31\u6216IP\uff09 <code>\u4f4d\u5740</code> <code>--source-security</code> \u6307\u5b9a Debian / Ubuntu \u7cfb\u7d71 security \u5009\u5eab\u7684\u8edf\u9ad4\u6e90\u4f4d\u5740\uff08\u7db2\u57df\u540d\u7a31\u6216IP\uff09 <code>\u4f4d\u5740</code> <code>--source-vault</code> \u6307\u5b9a CentOS / AlmaLinux \u7cfb\u7d71 vault \u5009\u5eab\u7684\u8edf\u9ad4\u6e90\u4f4d\u5740\uff08\u7db2\u57df\u540d\u7a31\u6216IP\uff09 <code>\u4f4d\u5740</code> <code>--source-portage</code> \u6307\u5b9a Gentoo \u7cfb\u7d71 portage \u5009\u5eab\u7684\u8edf\u9ad4\u6e90\u4f4d\u5740\uff08\u7db2\u57df\u540d\u7a31\u6216IP\uff09 <code>\u4f4d\u5740</code> <code>--source-base-system</code> \u6307\u5b9a Linux Mint / Raspberry Pi OS \u5e95\u5c64\u7cfb\u7d71\u7684\u8edf\u9ad4\u6e90\u4f4d\u5740\uff08\u7db2\u57df\u540d\u7a31\u6216IP\uff09 <code>\u4f4d\u5740</code> <code>--branch</code> \u6307\u5b9a\u8edf\u9ad4\u6e90\u5009\u5eab\uff08\u8def\u5f91\uff09 <code>\u5009\u5eab\u540d\u7a31</code> <code>--branch-epel</code> \u6307\u5b9a EPEL \u9644\u52a0\u8edf\u9ad4\u5305\u5009\u5eab\u7684\u8edf\u9ad4\u6e90\u5009\u5eab\uff08\u8def\u5f91\uff09 <code>\u5009\u5eab\u540d\u7a31</code> <code>--branch-security</code> \u6307\u5b9a Debian \u4fc2\u7d71 security \u5009\u5eab\u7684\u8edf\u9ad4\u6e90\u5009\u5eab\uff08\u8def\u5f91\uff09 <code>\u5009\u5eab\u540d\u7a31</code> <code>--branch-vault</code> \u6307\u5b9a CentOS / AlmaLinux \u7cfb\u7d71 vault \u5009\u5eab\u7684\u8edf\u9ad4\u6e90\u5009\u5eab\uff08\u8def\u5f91\uff09 <code>\u5009\u5eab\u540d\u7a31</code> <code>--branch-portage</code> \u6307\u5b9a Gentoo \u7cfb\u7d71 portage \u5009\u5eab\u7684\u8edf\u9ad4\u6e90\u5009\u5eab\uff08\u8def\u5f91\uff09 <code>\u5009\u5eab\u540d\u7a31</code> <code>--branch-base-system</code> \u6307\u5b9a Linux Mint / Raspberry Pi OS \u5e95\u5c64\u7cfb\u7d71\u7684\u8edf\u9ad4\u6e90\u5009\u5eab\uff08\u8def\u5f91\uff09 <code>\u5009\u5eab\u540d\u7a31</code> <code>--codename</code> \u6307\u5b9a Debian \u7cfb / openKylin \u4f5c\u696d\u7cfb\u7d71\u7684\u7248\u672c\u4ee3\u865f <code>\u4ee3\u865f\u540d\u7a31</code> <code>--protocol</code> \u6307\u5b9a Web \u5354\u5b9a <code>http</code> \u6216 <code>https</code> <code>--use-intranet-source</code> \u662f\u5426\u512a\u5148\u4f7f\u7528\u5167\u90e8\u7db2\u8def\u8edf\u9ad4\u6e90\u4f4d\u5740 <code>true</code> \u6216 <code>false</code> <code>--use-official-source</code> \u662f\u5426\u4f7f\u7528\u76ee\u6a19\u4f5c\u696d\u7cfb\u7d71\u7684\u5b98\u65b9\u8edf\u9ad4\u6e90 <code>true</code> \u6216 <code>false</code> <code>--use-official-source-epel</code> \u662f\u5426\u4f7f\u7528 EPEL \u9644\u52a0\u8edf\u9ad4\u5305\u7684\u5b98\u65b9\u8edf\u9ad4\u6e90 <code>true</code> \u6216 <code>false</code> <code>--install-epel</code> \u662f\u5426\u5b89\u88dd EPEL \u9644\u52a0\u8edf\u9ad4\u5305 <code>true</code> \u6216 <code>false</code> <code>--backup</code> \u662f\u5426\u5099\u4efd\u539f\u6709\u8edf\u9ad4\u6e90 <code>true</code> \u6216 <code>false</code> <code>--upgrade-software</code> \u662f\u5426\u66f4\u65b0\u8edf\u9ad4\u5957\u4ef6 <code>true</code> \u6216 <code>false</code> <code>--clean-cache</code> \u662f\u5426\u5728\u66f4\u65b0\u8edf\u9ad4\u5305\u5f8c\u6e05\u7406\u4e0b\u8f09\u5feb\u53d6 <code>true</code> \u6216 <code>false</code> <code>--clean-screen</code> \u662f\u5426\u5728\u904b\u884c\u524d\u6e05\u9664\u87a2\u5e55\u4e0a\u7684\u6240\u6709\u5167\u5bb9 <code>true</code> \u6216 <code>false</code> <code>--lang</code> \u6307\u5b9a\u8173\u672c\u8f38\u51fa\u7684\u8a9e\u8a00 <code>\u8a9e\u8a00ID\uff08\u8a73\u898b\u4e0b\u65b9\u6587\u4ef6\uff09</code> <code>--only-epel</code> \u50c5\u66f4\u63db EPEL \u8edf\u9ad4\u6e90\u6a21\u5f0f \u7121 <code>--ignore-backup-tips</code> \u5ffd\u7565\u8986\u84cb\u5099\u4efd\u63d0\u793a\uff08\u5373\u4e0d\u8986\u84cb\u5099\u4efd\uff09 \u7121 <code>--print-diff</code> \u662f\u5426\u5217\u5370\u539f\u59cb\u6587\u4ef6\u4fee\u6539\u524d\u5f8c\u5dee\u7570 \u7121 <code>--pure-mode</code> \u7d14\u6de8\u6a21\u5f0f\uff0c\u7cbe\u7c21\u5217\u5370\u5167\u5bb9 \u7121 <code>--help</code> \u67e5\u770b\u5e6b\u52a9\u9078\u55ae \u7121 <p>\u8edf\u9ad4\u6e90\u5b8c\u6574\u683c\u5f0f <code><WEB\u5354\u5b9a>://<\u8edf\u9ad4\u6e90\u4f4d\u5740(\u7db2\u57df\u540d\u7a31\u6216IP)>/<\u8edf\u9ad4\u6e90\u5009\u5eab(\u8def\u5f91)></code></p> <p>\u4ee5\u4e0b\u662f\u4e00\u4e9b\u9032\u968e\u7528\u6cd5\u7684\u8209\u4f8b</p>"},{"location":"zh-Hant/use/#\u6307\u5b9a\u8edf\u9ad4\u6e90\u4f4d\u5740","title":"\u6307\u5b9a\u8edf\u9ad4\u6e90\u4f4d\u5740","text":"<pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --zh-hant --source mirror.example.com\n</code></pre>"},{"location":"zh-Hant/use/#\u6307\u5b9a\u8edf\u9ad4\u6e90\u5009\u5eab\u76ee\u9304","title":"\u6307\u5b9a\u8edf\u9ad4\u6e90\u5009\u5eab\u76ee\u9304","text":"<p>\u9019\u88e1\u63cf\u8ff0\u7684\u8edf\u9ad4\u6e90\u5009\u5eab\u8207\u7cfb\u7d71\u8edf\u9ad4\u5009\u5eab\u4e0d\u540c\uff0c\u6307\u7684\u662f\u8edf\u9ad4\u6e90\uff08\u93e1\u50cf\u7ad9\uff09\u4f4d\u5740\u5f8c\u9762\u7684\u8def\u5f91\u5373\u93e1\u50cf\u7ad9\u7684\u5009\u5eab\u76ee\u9304\uff0c\u96d6\u7136\u540d\u7fa9\u4e0a\u90fd\u662f\u5009\u5eab\u4f46\u662f\u975e\u5e38\u5bb9\u6613\u6df7\u6dc6</p> <p>\u4e3b\u8981\u4f7f\u7528\u60c5\u5883\uff1a\u76ee\u6a19\u93e1\u50cf\u7ad9\u6709\u5c0d\u61c9\u7684\u7cfb\u7d71\u93e1\u50cf\u5009\u5eab\u4f46\u662f\u4e0d\u7b26\u5408\u672c\u5c08\u6848\u8173\u672c\u95dc\u65bc\u8edf\u9ad4\u6e90\u5009\u5eab\u8a2d\u5b9a\u7684\u9810\u8a2d\u898f\u5247</p> \u5c08\u6848\u5c0d\u65bc\u5404\u4f5c\u696d\u7cfb\u7d71\u6240\u4f7f\u7528\u7684\u9810\u8a2d\u5009\u5eab\u540d\u7a31\uff08\u9ede\u9078\u5c55\u958b\u6aa2\u8996\uff09 <p>\u5c08\u6848\u8173\u672c\u70ba\u4e86\u9069\u914d\u5927\u7684\u74b0\u5883\u4e0d\u6703\u91dd\u5c0d\u67d0\u4e00\u93e1\u50cf\u7ad9\u7368\u7279\u7684\u5009\u5eab\u540d\u7a31\u800c\u55ae\u7368\u9069\u914d</p> SYSTEM NAMES Debian <code>debian</code> <code>debian-archive</code> Ubuntu <code>ubuntu</code> <code>ubuntu-ports</code> Kali Linux <code>kali</code> Linux Mint <code>linuxmint</code> <code>ubuntu</code> <code>ubuntu-ports</code> <code>debian</code> Deepin <code>deepin</code> Zorin OS <code>ubuntu</code> <code>ubuntu-ports</code> Armbian <code>armbian</code> Proxmox VE <code>proxmox</code> Raspberry Pi OS <code>raspberrypi</code> <code>raspbian</code> <code>debian</code> <code>debian-archive</code> Red Hat Enterprise Linux <code>centos</code> <code>centos-stream</code> <code>centos-altarch</code> <code>centos-vault</code> Fedora <code>fedora</code> <code>fedora-archive</code> CentOS <code>centos</code> <code>centos-stream</code> <code>centos-altarch</code> <code>centos-vault</code> Rocky Linux <code>rocky</code> AlmaLinux <code>almalinux</code> <code>almalinux-vault</code> Oracle Linux <code>centos-stream</code> openEuler <code>openeuler</code> OpenCloudOS <code>opencloudos</code> openKylin <code>openkylin</code> Anolis OS <code>anolis</code> openSUSE <code>opensuse</code> Arch Linux <code>archlinux</code> <code>archlinuxarm</code> Manjaro <code>manjaro</code> EndeavourOS <code>endeavouros</code> Alpine Linux <code>alpine</code> Gentoo <code>gentoo</code> <code>gentoo-portage</code> NixOS <code>nix-channels</code> <p>\u8acb\u770b\u4e0b\u9762\u7684\u4f8b\u5b50</p> \u4f7f\u7528\u963f\u91cc\u96f2\u93e1\u50cf\u7ad9\u7684 Rocky Linux \u8edf\u9ad4\u6e90<pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --zh-hant \\\n --source mirrors.aliyun.com \\\n --branch rockylinux\n</code></pre> <p>\u963f\u91cc\u96f2\u93e1\u50cf\u7ad9\u7684 Rocky Linux \u5009\u5eab\u76ee\u9304\u540d\u7a31\u70ba <code>rockylinux</code>\uff0c\u4e0d\u7b26\u5408\u9810\u8a2d\u898f\u5247 <code>rocky</code>\uff0c\u4f46\u662f\u53ef\u4ee5\u900f\u904e\u547d\u4ee4\u9078\u9805\u7e5e\u904e\u8173\u672c\u9810\u8a2d\u898f\u5247\u4f86\u5be6\u73fe\u3002</p> <p>\u90e8\u5206\u7cfb\u7d71\u6703\u540c\u6642\u914d\u7f6e\u591a\u500b\u5009\u5eab\u7684\u8edf\u9ad4\u6e90\uff0c\u5177\u9ad4\u8a73\u898b\u547d\u4ee4\u9078\u9805</p> <p>\u7531\u65bc\u8edf\u9ad4\u6e90\u5009\u5eab\u4f5c\u7528\u5728\u8edf\u9ad4\u6e90\u4f4d\u5740\u4e0a\u56e0\u6b64\u4e5f\u53ef\u4ee5\u4f7f\u7528\u591a\u5c64\u8def\u5f91\uff0c\u4f8b\u5982 <code>--branch \"linux/debian\"</code> -> <code>https://mirrors.example.com/linux/debian</code></p>"},{"location":"zh-Hant/use/#\u55ae\u7368\u66f4\u63db-epel-\u6e90","title":"\u55ae\u7368\u66f4\u63db EPEL \u6e90","text":"<p>EPEL (Extra Packages for Enterprise Linux) \u662f\u7531 Fedora \u7d44\u7e54\u7dad\u8b77\u7684\u4e00\u500b\u9644\u52a0\u8edf\u9ad4\u5305\u5009\u5eab\uff0c\u5b83\u4e3b\u8981\u9069\u7528\u65bc\u9664 Fedora \u4f5c\u696d\u7cfb\u7d71\u4ee5\u5916\u7684\u7d05\u5e3d\u7cfb Linux \u767c\u884c\u7248\uff0c\u914d\u7f6e EPEL \u5009\u5eab\u5df2\u6210\u70ba\u5ee3\u5927\u7528\u6236\u7684\u666e\u904d\u9700\u6c42\uff0c\u5efa\u8b70\u9810\u8a2d\u5b89\u88dd\u5b83</p> <p>\u6709\u4e9b\u6642\u5019\u4f60\u6703\u767c\u73fe\u60f3\u4f7f\u7528\u7684\u93e1\u50cf\u7ad9\u6c92\u6709 EPEL \u5009\u5eab\uff0c\u90a3\u9ebc\u4f60\u53ef\u4ee5\u5728\u7b2c\u4e00\u6b21\u904b\u884c\u8173\u672c\u6642\u4e0d\u5b89\u88dd\u6216\u66f4\u63db EPEL \u8edf\u9ad4\u6e90\uff0c\u7136\u5f8c\u518d\u55ae\u7368\u57f7\u884c\u4e0b\u9762\u7684\u547d\u4ee4</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --zh-hant --only-epel\n</code></pre> <p>\u5c0d\u65bc\u5df2\u7d93 EOL \u7684 EPEL 7\uff0c\u6ce8\u610f\u9700\u8981\u4f7f\u7528 <code>archive</code> \u5009\u5eab\uff0c\u5883\u5916\u4ee5\u53ca\u6d77\u5916\u7db2\u7d61\u74b0\u5883\u5efa\u8b70\u901a\u904e\u547d\u4ee4\u9078\u9805 <code>--use-official-source-epel true</code> \u4f7f\u7528\u5b98\u65b9\u6e90</p>"},{"location":"zh-Hant/use/#\u6062\u5fa9\u4f7f\u7528\u5b98\u65b9\u6e90","title":"\u6062\u5fa9\u4f7f\u7528\u5b98\u65b9\u6e90","text":"<p>\u7576\u4f60\u4e0d\u5c0f\u5fc3\u522a\u9664\u4e86\u5b98\u65b9\u8edf\u9ad4\u6e90\u7684\u5099\u4efd\u6642\u53ef\u4ee5\u4f7f\u7528\u6b64\u547d\u4ee4\u4f86\u6062\u5fa9\uff0c\u4f7f\u7528\u6b64\u547d\u4ee4\u9078\u9805\u5f8c\u5c07\u8df3\u904e\u9078\u64c7\u8edf\u9ad4\u6e90\u6b65\u9a5f</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --zh-hant --use-official-source true\n</code></pre> <p>\u90e8\u5206\u7cfb\u7d71\u4e0d\u5b58\u5728\u5b98\u65b9\u8edf\u9ad4\u6e90\u4f8b\u5982 <code>Arch Linux</code>\uff0c\u5c46\u6642\u6703\u81ea\u52d5\u66f4\u63db\u6210\u76f8\u5bb9\u6027\u8f03\u9ad8\u7684\u963f\u91cc\u96f2\u93e1\u50cf\u7ad9</p>"},{"location":"zh-Hant/use/#\u7279\u5b9a\u4fc2\u7d71\u7684\u4f7f\u7528\u7bc4\u4f8b","title":"\u7279\u5b9a\u4fc2\u7d71\u7684\u4f7f\u7528\u7bc4\u4f8b","text":""},{"location":"zh-Hant/use/#\u95dc\u65bc-centos-\u505c\u670d\u554f\u984c","title":"\u95dc\u65bc CentOS \u505c\u670d\u554f\u984c","text":"<p>\u8173\u672c\u5c0d\u65bc\u5df2\u7d93 EOL \u7684 CentOS 7/8\u3001CentOS Stream 8 \u9032\u884c\u4e86\u9069\u914d</p> <ul> <li> <p>\u4e2d\u570b\u5927\u9678</p> <p>\u6b63\u5e38\u4f7f\u7528\u8173\u672c\uff0c\u6c92\u6709\u984d\u5916\u64cd\u4f5c\uff0c\u56e0\u70ba\u5927\u90e8\u5206\u4e2d\u570b\u5927\u9678\u93e1\u50cf\u7ad9\u90fd\u5df2\u540c\u6b65 <code>CentOS Vault</code> \u5009\u5eab</p> </li> <li> <p>\u570b\u969b\u5730\u5340</p> <p>\u5efa\u8b70\u4f7f\u7528 <code>\u9a30\u8a0a\u96f2</code> \u6216 <code>\u963f\u91cc\u96f2</code> \u93e1\u50cf\u7ad9\uff0c\u6216\u900f\u904e <code>--use-official-source true</code> \u547d\u4ee4\u9078\u9805\u4f7f\u7528\u5b98\u65b9\u8edf\u9ad4\u6e90</p> </li> </ul> <p>\u53e6\u5916 EPEL 7 \u4e5f\u9032\u5165\u4e86 EOL\uff0c\u8173\u672c\u540c\u6a23\u5c0d\u5176\u9032\u884c\u4e86\u9069\u914d</p>"},{"location":"zh-Hant/use/#\u6307\u5b9a-gnulinux-debian-\u4f5c\u696d\u7cfb\u7d71\u7684-security-\u8edf\u9ad4\u6e90","title":"\u6307\u5b9a GNU/Linux Debian \u4f5c\u696d\u7cfb\u7d71\u7684 Security \u8edf\u9ad4\u6e90","text":"<p>\u5982\u679c\u4f60\u60f3\u76e1\u53ef\u80fd\u63d0\u9ad8\u4f3a\u670d\u5668\u7684\u5b89\u5168\u6027\u5efa\u8b70\u4f7f\u7528\u5b98\u65b9\u8edf\u9ad4\u6e90\uff0c\u56e0\u70ba\u93e1\u50cf\u540c\u6b65\u5b58\u5728\u5ef6\u9072</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --zh-hant \\\n --source-security security.debian.org \\\n --branch-security debian-security\n</code></pre>"},{"location":"zh-Hant/use/#\u6307\u5b9a-debian-\u7cfb-linux-\u4f5c\u696d\u7cfb\u7d71\u7684\u7248\u672c\u4ee3\u865f","title":"\u6307\u5b9a Debian \u7cfb Linux \u4f5c\u696d\u7cfb\u7d71\u7684\u7248\u672c\u4ee3\u865f","text":"<p>\u5927\u591a\u6578\u60c5\u6cc1\u4e0b\u81ea\u8a02\u7248\u672c\u4ee3\u865f\u7528\u65bc\u66f4\u63db\u7cfb\u7d71\u7248\u672c\uff0c\u8acb\u770b\u4e0b\u9762\u7684\u4f8b\u5b50</p> \u5347\u7d1a GNU/Linux Debian \u81f3 13 \"trixie\"\u5c07 GNU/Linux Debian \u7684\u7248\u672c\u5207\u63db\u5230\u6e2c\u8a66\u5206\u652f <ul> <li> <p>\u66f4\u63db\u7248\u672c\u4ee3\u865f</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --zh-hant \\\n --codename trixie \\\n --upgrade-software false\n</code></pre> </li> <li> <p>\u505c\u7528 backports \u5009\u5eab</p> <pre><code>sed -i '/backports/s/^/# /' /etc/apt/sources.list\n</code></pre> </li> <li> <p>\u5347\u7d1a\u7cfb\u7d71</p> <pre><code>apt-get update\napt-get dist-upgrade\n</code></pre> </li> <li> <p>\u5347\u7d1a\u5b8c\u6210\u4e26\u91cd\u65b0\u5f15\u5c0e\u7cfb\u7d71\u5f8c\u57f7\u884c\u4e0b\u5217\u6b65\u9a5f</p> <pre><code># \u6e05\u7a7a\u539f\u6709\u8edf\u9ad4\u6e90\uff08\u5982\u6709\u975e\u7cfb\u7d71\u8edf\u9ad4\u6e90\u5167\u5bb9\u8acb\u5148\u81ea\u884c\u624b\u52d5\u5099\u4efd\uff09\nsed -i '1,$d' /etc/apt/sources.list\n# \u91cd\u65b0\u57f7\u884c\u63db\u6e90\u8173\u672c\nbash <(curl -sSL https://linuxmirrors.cn/main.sh) --zh-hant\n</code></pre> </li> </ul> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --zh-hant \\\n --codename testing \\\n --upgrade-software false\n</code></pre> \u5982\u679c\u8173\u672c\u7121\u6cd5\u5be6\u73fe\u6307\u5b9a\u7248\u672c\u4ee3\u865f\uff0c\u4f60\u4e5f\u53ef\u4ee5\u5728\u57f7\u884c\u8173\u672c\u5f8c\u624b\u52d5\u66ff\u63db<pre><code>sed -i \"s/$(lsb_release -cs)/\u6307\u5b9a\u7248\u672c\u4ee3\u865f/g\" /etc/apt/sources.list\n</code></pre>"},{"location":"zh-Hant/use/#\u66f4\u63db-ubuntu-eol\u7248\u672c\u8edf\u9ad4\u6e90","title":"\u66f4\u63db Ubuntu EOL\u7248\u672c\u8edf\u9ad4\u6e90","text":"<p>EOL \u70ba\u751f\u547d\u9031\u671f\u7d50\u675f\u7684\u7e2e\u5beb\uff08End Of Life\uff09\uff0cUbuntu \u8fed\u4ee3\u901f\u5ea6\u8f03\u5feb\u4e00\u822c\u975eLTS(\u9577\u671f\u652f\u6301)\u7248\u672c\u7684\u751f\u547d\u9031\u671f\u53ea\u67099\u500b\u6708\u3002\u5b98\u65b9\u6703\u5b9a\u671f\u5f9e\u4e3b\u5009\u5eab\u79fb\u9664\u4e0d\u5728\u751f\u547d\u9031\u671f\u5167\u7684\u7248\u672c\u5009\u5eab\u76ee\u9304\uff0c\u5c46\u6642\u53ef\u80fd\u5c31\u9700\u8981\u4f7f\u7528\u93e1\u50cf\u7ad9\u7684 <code>Ubuntu Old Releases</code> \u5009\u5eab</p> <p>\u5177\u9ad4\u7248\u672c\u652f\u63f4\u60c5\u6cc1\u8a73\u898b\u5b98\u65b9 Wiki\uff0c\u95dc\u65bc <code>Ubuntu Old Releases</code> \u5009\u5eab\u7684\u652f\u63f4\u60c5\u6cc1\u8a73\u898b\u5404\u93e1\u50cf\u7ad9</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --zh-hant \\\n --source mirrors.ustc.edu.cn \\\n --branch ubuntu-old-releases\n</code></pre>"},{"location":"zh-Hant/use/#arch-linux-\u4f7f\u7528\u4e2d\u6587\u793e\u7fa4\u5009\u5eab","title":"Arch Linux \u4f7f\u7528\u4e2d\u6587\u793e\u7fa4\u5009\u5eab","text":"<p>\u672c\u5c08\u6848\u8173\u672c\u76ee\u524d\u4e0d\u652f\u63f4\u6b64\u984d\u5916\u5009\u5eab\uff0c\u56e0\u4f7f\u7528\u4eba\u6578\u8f03\u5c11\u7b49\u539f\u56e0\u66ab\u4e0d\u8003\u616e\u9069\u914d\uff0c\u82e5\u60f3\u4f7f\u7528\u8acb\u53c3\u8003\u4e0b\u65b9\u7684\u4e00\u9375\u8a2d\u5b9a\u547d\u4ee4</p> <pre><code>SOURCE=\"https://mirrors.aliyun.com/archlinuxcn\" # \u6307\u5b9a\u8edf\u9ad4\u6e90\u4f4d\u5740\ngrep -q \"\\[archlinuxcn\\]\" /etc/pacman.conf || echo -e \"[archlinuxcn]\\nServer = ${SOURCE}/\\$arch\" >>/etc/pacman.conf # \u4e00\u9375\u914d\u7f6e\u547d\u4ee4\n</code></pre>"},{"location":"zh-Hant/use/#\u570b\u969b\u5316i18n","title":"\u570b\u969b\u5316\uff08I18n\uff09","text":"<p>\u8173\u672c\u63d0\u4f9b\u591a\u8a9e\u8a00\u652f\u6301\uff0c\u76ee\u524d\u5167\u5efa <code>\u7b80\u4f53\u4e2d\u6587</code>\u3001<code>\u7e41\u9ad4\u4e2d\u6587</code>\u3001<code>English</code> \u5171\u4e09\u7a2e\u986f\u793a\u8a9e\u8a00\uff0c\u9810\u8a2d\u70ba <code>\u7b80\u4f53\u4e2d\u6587</code></p>"},{"location":"zh-Hant/use/#\u6307\u5b9a\u8a9e\u8a00","title":"\u6307\u5b9a\u8a9e\u8a00","text":"<pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --lang xxx\n</code></pre> \u985e\u578b \u503c \u7b80\u4f53\u4e2d\u6587 <code>zh-hans</code> <code>zh-cn</code> <code>zh</code> \u7e41\u9ad4\u4e2d\u6587 <code>zh-hant</code> <code>zh-tw</code> <code>zh-hk</code> English <code>en</code> <code>en-us</code> <p>\u4e5f\u53ef\u4ee5\u76f4\u63a5\u4f5c\u70ba\u6307\u4ee4\u9078\u9805\u4f7f\u7528</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --en\n</code></pre> <p><code>--en</code> <code>--en-us</code> <code>--zh</code> <code>--zh-cn</code> <code>--zh-hans</code> <code>--zh-hant</code></p>"},{"location":"zh-Hant/use/#\u900f\u904e\u4e92\u52d5\u9032\u884c\u9078\u64c7","title":"\u900f\u904e\u4e92\u52d5\u9032\u884c\u9078\u64c7","text":"<pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --lang auto\n</code></pre>"},{"location":"zh-Hant/use/#\u7121\u4eba\u503c\u5b88\u81ea\u52d5\u5316","title":"\u7121\u4eba\u503c\u5b88\uff08\u81ea\u52d5\u5316\uff09","text":"<p>\u4e0d\u900f\u904e\u4ea4\u4e92\u5b8c\u6210\u63db\u6e90\u64cd\u4f5c\uff0c\u81f3\u5c11\u9700\u8981\u4f7f\u7528\u4ee5\u4e0b\u547d\u4ee4\u9078\u9805\u4f86\u5be6\u73fe\uff0c\u5efa\u8b70\u719f\u6089\u5f8c\u518d\u4f7f\u7528</p> \u53c2\u8003\u547d\u4ee4<pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --zh-hant \\\n --source mirror.example.com \\\n --protocol http \\\n --use-intranet-source false \\\n --install-epel true \\\n --backup true \\\n --upgrade-software false \\\n --clean-cache false \\\n --ignore-backup-tips\n</code></pre> <p>\u5982\u679c\u5831\u932f <code>\u547d\u4ee4\u9078\u9805\u7121\u6548</code> \u90a3\u9ebc\u8acb\u6aa2\u67e5\u9078\u9805\u5408\u6cd5\u6027\u4ee5\u53ca\u7a7a\u683c\u5b57\u5143\u7de8\u78bc\uff0c\u5728\u7bc4\u4f8b\u4e2d\u4e00\u884c\u5beb\u4e00\u500b\u9078\u9805\u662f\u70ba\u4e86\u63d0\u9ad8\u547d\u4ee4\u7684\u53ef\u8b80\u6027</p>"},{"location":"zh-Hant/use/#\u7d14\u6de8\u6a21\u5f0f","title":"\u7d14\u6de8\u6a21\u5f0f","text":"<p>\u63a8\u51fa\u6b64\u529f\u80fd\u662f\u70ba\u4e86\u65b9\u4fbf\u958b\u767c\u4ee5\u53ca\u8fd0\u7dad\u4eba\u54e1\u4f7f\u7528\uff0c\u555f\u7528\u5f8c\u6703\u7cbe\u7c21\u8173\u672c\u5167\u5bb9\u8f38\u51fa\uff0c\u5efa\u8b70\u642d\u914d\u5176\u5b83\u6307\u4ee4\u9078\u9805\u7121\u4e92\u52d5\u4f7f\u7528</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --zh-hant --pure-mode\n</code></pre> <p>\u6efe\u52d5\u8f38\u51fa\u7684\u547d\u4ee4\u65e5\u8a8c\u53ef\u80fd\u6709\u7121\u6cd5\u9810\u6599\u7684\u986f\u793a\u554f\u984c\uff0c\u4e0d\u904e\u76ee\u524d\u66ab\u672a\u767c\u73fe\u7570\u5e38</p>"},{"location":"zh-Hant/use/#\u5ba2\u88fd\u5316\u8173\u672c","title":"\u5ba2\u88fd\u5316\u8173\u672c","text":"<p>\u5982\u679c\u4f60\u662f\u5176\u5b83\u5c08\u6848\u7684\u958b\u767c\u8005\u5e0c\u671b\u900f\u904e\u672c\u5c08\u6848\u4f86\u88fd\u4f5c\u5c08\u5c6c\u8173\u672c\uff0c\u90a3\u9ebc\u8acb\u53c3\u8003\u4e0b\u9762\u63d0\u5230\u7684\u5167\u5bb9\uff0c\u76ee\u524d\u5df2\u7d93\u6709\u4e2d\u570b\u5927\u9678\u6559\u80b2\u55ae\u4f4d\u93e1\u50cf\u7ad9\u7684\u7dad\u8b77\u8005\u9019\u6a23\u505a\u4e86\u3002</p> <ol> <li>\u9996\u5148\u4e0d\u5efa\u8b70\u4fee\u6539\u7a0b\u5f0f\u78bc\u7684\u5e95\u5c64\u908f\u8f2f\uff0c\u61c9\u76e1\u91cf\u8207\u672c\u5c08\u6848\u539f\u59cb\u78bc\u4fdd\u6301\u540c\u6b65\uff0c\u8173\u672c\u5167\u5bb9\u57f7\u884c\u9806\u5e8f\u7531 <code>main</code> \u51fd\u6578\u63a7\u5236\uff0c\u7a0b\u5f0f\u78bc\u908f\u8f2f\u6e05\u6670</li> <li>\u4f60\u53ef\u4ee5\u7c21\u55ae\u53bb\u9664\u4e00\u4e9b\u7121\u95dc\u5167\u5bb9\uff0c\u4f8b\u5982\u5c07\u8edf\u9ad4\u6e90\u5217\u8868\uff08\u9663\u5217\uff09<code>mirror_list_(default|edu|abroad|extranet|intranet)</code> \u4e2d\u7684\u5167\u5bb9\u522a\u9664\uff0c\u4f8b\u5982\uff1a<code>mirror_list_default=()</code></li> <li>\u5982\u679c\u4f60\u60f3\u8981\u81ea\u5b9a\u7fa9\u8173\u672c\u5217\u5370\u5167\u5bb9\u53ef\u76f4\u63a5\u4fee\u6539 <code>run_start</code> <code>run_end</code> <code>print_title</code> \u9019\u4e09\u500b\u51fd\u6578\u4e2d\u7684\u5167\u5bb9</li> <li>\u5982\u679c\u4f60\u60f3\u52a0\u5165\u81ea\u5b9a\u7fa9 Shell \u5167\u5bb9\u8acb\u53c3\u898b <code>main</code> \u51fd\u6578\u4e2d\u8173\u672c\u57f7\u884c\u9806\u5e8f\uff0c\u53ef\u4ee5\u5728\u5c0d\u61c9\u4f4d\u7f6e\u76f4\u63a5\u63d2\u5165\u5167\u5bb9\u4e5f\u53ef\u4ee5\u5c01\u88dd\u51fd\u6578\u5f8c\u8abf\u7528</li> <li>\u5982\u679c\u4f60\u60f3\u8981\u7e2e\u6e1b\u8173\u672c\u9ad4\u7a4d\u90a3\u9ebc\u53ef\u4ee5\u522a\u9664\u4e00\u4e9b\u4e0d\u5fc5\u8981\u7684\u5167\u5bb9\uff0c\u9664\u4e86\u4e0a\u9762\u63d0\u5230\u7684\u8edf\u9ad4\u6e90\u5217\u8868\u9084\u6709\u4e00\u4e9b\u6d89\u53ca\u8173\u672c\u5de5\u4f5c\u7684\u90e8\u5206\u6a21\u7d44\u5167\u5bb9\uff0c\u5177\u9ad4\u5982\u4e0b\uff1a<ol> <li>\u9996\u5148\u5728\u522a\u9664\u5167\u5bb9\u6642\u61c9\u76e1\u53ef\u80fd\u4fdd\u7559\u8173\u672c\u539f\u59cb\u7d50\u69cb\uff0c\u76f4\u63a5\u628a\u6d89\u53ca\u51fd\u6578\u4e2d\u7684\u5167\u5bb9\u522a\u9664\u5373\u53ef\uff0c\u4f7f\u5176\u4fdd\u7559\u70ba\u7a7a\u51fd\u6578</li> <li>\u53ef\u4ee5\u522a\u9664\u4e00\u4e9b\u4e0d\u4f7f\u7528\uff08\u4f5c\u696d\u7cfb\u7d71\uff09\u7684\u8edf\u9ad4\u6e90\u539f\u59cb\u5167\u5bb9 <code>gen_repo_files_xxx</code>\uff0c\u9019\u4e9b\u5167\u5bb9\u4f54\u64da\u4e86\u8173\u672c <code>60%</code> \u4ee5\u4e0a\u7684\u9ad4\u7a4d</li> <li>\u5982\u679c\u4f60\u4e0d\u4f7f\u7528\u67d0\u4e9b\u529f\u80fd\uff0c\u90a3\u9ebc\u53ef\u4ee5\u522a\u9664\u5c0d\u61c9\u529f\u80fd\u6a21\u7d44\u51fd\u6578\u4e2d\u7684\u5167\u5bb9\uff0c<code>\u547d\u4ee4\u9078\u9805 handle_command_options</code>\u3001<code>\u5099\u4efd\u539f\u6709\u8edf\u9ad4\u6e90 backup_original_mirrors</code>\u3001<code>\u66f4\u65b0\u8edf\u9ad4\u5305 upgrade_software</code></li> <li>\u79fb\u9664\u4e0d\u9700\u8981\u7684\u8a9e\u8a00\u5305\uff0c\u4f8b\uff1a<code>function msg_pack_en() {}</code></li> </ol> </li> <li>\u8173\u672c\u4e3b\u8981\u529f\u80fd\u914d\u7f6e\u662f\u7531\u7d71\u4e00\u7684\u8b8a\u91cf\u63a7\u5236\u7684\uff0c\u547d\u4ee4\u9078\u9805\u4ea6\u662f\u5982\u6b64\uff0c\u9019\u4e9b\u5168\u5c40\u8b8a\u91cf\u7531\u5168\u5927\u5beb\u5b57\u6bcd\u69cb\u6210\u4e26\u9075\u5faa\u4e0b\u5283\u7dda\u547d\u540d\u6cd5\uff0c\u5177\u9ad4\u8b8a\u91cf\u8a73\u898b\u5982\u4e0b\u8868\u683c\uff0c\u4f60\u53ea\u9700\u8981\u5c07\u9019\u4e9b\u8b8a\u91cf\u8072\u660e\u5728\u8173\u672c\u982d\u90e8\uff08\u9810\u7559\u8a3b\u91cb\u5340\u57df\uff09\u5373\u53ef\u5feb\u901f\u5b8c\u6210\u5b9a\u5236</li> </ol> \u8b8a\u6578\u5217\u8868\uff08\u9ede\u64ca\u5c55\u958b\u67e5\u770b\uff09 \u540d\u7a31 \u542b\u7fa9 \u503c\u578b\u5225 <code>SOURCE</code> \u6307\u5b9a\u8edf\u9ad4\u6e90\u4f4d\u5740\uff08\u7db2\u57df\u540d\u7a31\u6216IP\uff09 <code>\u4f4d\u5740</code> <code>SOURCE_EPEL</code> \u6307\u5b9a EPEL \u9644\u52a0\u8edf\u9ad4\u5305\u5009\u5eab\u7684\u8edf\u9ad4\u6e90\u4f4d\u5740\uff08\u7db2\u57df\u540d\u7a31\u6216IP\uff09 <code>\u4f4d\u5740</code> <code>SOURCE_SECURITY</code> \u6307\u5b9a Debian / Ubuntu \u7cfb\u7d71 security \u5009\u5eab\u7684\u8edf\u9ad4\u6e90\u4f4d\u5740\uff08\u7db2\u57df\u540d\u7a31\u6216IP\uff09 <code>\u4f4d\u5740</code> <code>SOURCE_VAULT</code> \u6307\u5b9a CentOS / AlmaLinux \u7cfb\u7d71 vault \u5009\u5eab\u7684\u8edf\u9ad4\u6e90\u4f4d\u5740\uff08\u7db2\u57df\u540d\u7a31\u6216IP\uff09 <code>\u4f4d\u5740</code> <code>SOURCE_PORTAGE</code> \u6307\u5b9a Gentoo \u7cfb\u7d71 portage \u5009\u5eab\u7684\u8edf\u9ad4\u6e90\u4f4d\u5740\uff08\u7db2\u57df\u540d\u7a31\u6216IP\uff09 <code>\u4f4d\u5740</code> <code>SOURCE_BASE_SYSTEM</code> \u6307\u5b9a Linux Mint / Raspberry Pi OS \u5e95\u5c64\u7cfb\u7d71\u7684\u8edf\u9ad4\u6e90\u4f4d\u5740\uff08\u7db2\u57df\u540d\u7a31\u6216IP\uff09 <code>\u4f4d\u5740</code> <code>SOURCE_BRANCH</code> \u6307\u5b9a\u8edf\u9ad4\u6e90\u5009\u5eab\uff08\u8def\u5f91\uff09 <code>\u5009\u5eab\u540d\u7a31</code> <code>SOURCE_EPEL_BRANCH</code> \u6307\u5b9a EPEL \u9644\u52a0\u8edf\u9ad4\u5957\u4ef6\u5009\u5eab\u7684\u8edf\u9ad4\u6e90\u5009\u5eab\uff08\u8def\u5f91\uff09 <code>\u5009\u5eab\u540d\u7a31</code> <code>SOURCE_SECURITY_BRANCH</code> \u6307\u5b9a Debian \u7cfb\u7d71 security \u5009\u5eab\u7684\u8edf\u9ad4\u6e90\u5009\u5eab\uff08\u8def\u5f91\uff09 <code>\u5009\u5eab\u540d\u7a31</code> <code>SOURCE_VAULT_BRANCH</code> \u6307\u5b9a CentOS / AlmaLinux \u7cfb\u7d71 vault \u5009\u5eab\u7684\u8edf\u9ad4\u6e90\u5009\u5eab\uff08\u8def\u5f91\uff09 <code>\u5009\u5eab\u540d\u7a31</code> <code>SOURCE_PORTAGE_BRANCH</code> \u6307\u5b9a Gentoo \u7cfb\u7d71 portage \u5009\u5eab\u7684\u8edf\u9ad4\u6e90\u5009\u5eab\uff08\u8def\u5f91\uff09 <code>\u5009\u5eab\u540d\u7a31</code> <code>SOURCE_BASE_SYSTEM_BRANCH</code> \u6307\u5b9a Linux Mint / Raspberry Pi OS \u5e95\u5c64\u7cfb\u7d71\u7684\u8edf\u9ad4\u6e90\u5009\u5eab\uff08\u8def\u5f91\uff09 <code>\u5009\u5eab\u540d\u7a31</code> <code>DEBIAN_CODENAME</code> \u6307\u5b9a Debian \u7cfb / openKylin \u4f5c\u696d\u7cfb\u7d71\u7684\u7248\u672c\u4ee3\u865f <code>\u4ee3\u865f\u540d\u7a31</code> <code>USE_INTRANET_SOURCE</code> \u662f\u5426\u512a\u5148\u4f7f\u7528\u5167\u7db2\u8edf\u9ad4\u6e90\u4f4d\u5740 <code>true</code> \u6216 <code>false</code> <code>USE_OFFICIAL_SOURCE</code> \u662f\u5426\u4f7f\u7528\u76ee\u6a19\u4f5c\u696d\u7cfb\u7d71\u7684\u5b98\u65b9\u8edf\u9ad4\u6e90 <code>true</code> \u6216 <code>false</code> <code>USE_OFFICIAL_SOURCE_EPEL</code> \u662f\u5426\u4f7f\u7528 EPEL \u9644\u52a0\u8edf\u9ad4\u5305\u7684\u5b98\u65b9\u8edf\u9ad4\u6e90 <code>true</code> \u6216 <code>false</code> <code>WEB_PROTOCOL</code> \u6307\u5b9a Web \u5354\u5b9a <code>http</code> \u6216 <code>https</code> <code>INSTALL_EPEL</code> \u662f\u5426\u5b89\u88dd EPEL \u9644\u52a0\u8edf\u9ad4\u5305 <code>true</code> \u6216 <code>false</code> <code>ONLY_EPEL</code> \u50c5\u66f4\u63db EPEL \u8edf\u9ad4\u6e90\u6a21\u5f0f <code>true</code> \u6216 <code>false</code> <code>BACKUP</code> \u662f\u5426\u5099\u4efd\u539f\u6709\u8edf\u9ad4\u6e90 <code>true</code> \u6216 <code>false</code> <code>IGNORE_BACKUP_TIPS</code> \u5ffd\u7565\u8986\u84cb\u5099\u4efd\u63d0\u793a\uff08\u5373\u4e0d\u8986\u84cb\u5099\u4efd\uff09 <code>true</code> \u6216 <code>false</code> <code>UPGRADE_SOFTWARE</code> \u662f\u5426\u66f4\u65b0\u8edf\u9ad4\u5305 <code>true</code> \u6216 <code>false</code> <code>CLEAN_CACHE</code> \u662f\u5426\u5728\u66f4\u65b0\u8edf\u9ad4\u5305\u5f8c\u6e05\u7406\u4e0b\u8f09\u5feb\u53d6 <code>true</code> \u6216 <code>false</code> <code>CLEAN_SCREEN</code> \u662f\u5426\u5728\u904b\u884c\u524d\u6e05\u9664\u87a2\u5e55\u4e0a\u7684\u6240\u6709\u5167\u5bb9 <code>true</code> \u6216 <code>false</code> <code>PRINT_DIFF</code> \u662f\u5426\u5217\u5370\u539f\u59cb\u6a94\u6848\u4fee\u6539\u524d\u5f8c\u5dee\u7570 <code>true</code> \u6216 <code>false</code> <code>PURE_MODE</code> \u7d14\u6de8\u6a21\u5f0f\uff0c\u7cbe\u7c21\u5217\u5370\u5167\u5bb9 <code>true</code> \u6216 <code>false</code> <p>\u90e8\u5206\u8b8a\u6578\u5b58\u5728\u9810\u8a2d\u503c\uff0c\u672a\u6d89\u53ca\u7684\u8b8a\u6578\u7121\u9700\u5ba3\u544a\u70ba\u7a7a\u503c\uff08\u7a7a\u5b57\u4e32\uff09\uff0c\u53e6\u5916\u5982\u679c\u5c0d\u61c9\u529f\u80fd\u914d\u7f6e\u4e0d\u5b58\u5728\u90a3\u9ebc\u5c31\u53ef\u80fd\u6703\u51fa\u73fe\u4ea4\u4e92</p>"},{"location":"en/","title":"One-Click Script Makes Mirror Switching Easier","text":"GNU/Linux mirror switching script & Docker installation and registry mirror switching script One-Click Script Makes Mirror Switching Easier GNU/Linux Docker <ul> <li> <p> Easy to Use</p> <p>Just one command to run directly, zero technical barrier, no dependencies required Documentation integrates AI search and chat, providing solutions for various use cases</p> </li> <li> <p> Wide System Support</p> <p>Supports up to <code>26+</code> operating systems, covering various versions, accurately identifying system types High script compatibility, unsupported systems will prompt and exit without operation</p> </li> <li> <p> Diverse Mirror Adaptation</p> <p>In-depth research on domestic mirror site compatibility Also provides a collection of domestic education network and overseas mirrors for users to choose</p> </li> <li> <p> Fast and Efficient</p> <p>Mirror switching can be completed in as little as 10 seconds, efficient operations, saving a lot of time The project has undergone years of iteration and optimization, with excellent script performance and stability, and comprehensive scenario handling</p> </li> <li> <p> Global Network, Worry-Free Access</p> <p>This website provides global edge network acceleration, easily accessible in any network environment Multiple backup addresses are provided to ensure the script is always available, truly worry-free usage</p> </li> <li> <p> Powerful and Unmatched</p> <p>The script guides users step by step to select mirror configurations via arrow key interaction, making switching easier In addition, the script offers rich command options, supporting CI/CD integration and automated operations</p> </li> <li> <p> Highly Customizable</p> <p>Script command options are designed according to formal application standards, meeting various advanced needs Code structure is clear, easy to read and modify, and supports customization after cloning, supports multi-language printing</p> </li> <li> <p> Free and Open Source</p> <p>The project is licensed under the MIT open source license, script code is fully open source and free to use Please respect the author's intellectual achievements, and indicate the source or project address prominently when sharing</p> </li> </ul> Operating System Supported Versions Debian 8\uff5e13 Ubuntu 14\uff5e25 Kali Linux all Linux Mint 17\uff5e22 / LMDE 2\uff5e7 Deepin all Zorin OS all Armbian all Proxmox VE all Raspberry Pi OS all Red Hat Enterprise Linux 7\uff5e10 Fedora 30\uff5e43 CentOS 7\uff5e8 / Stream 8\uff5e10 Rocky Linux 8\uff5e10 AlmaLinux 8\uff5e10 Oracle Linux 8\uff5e10 openEuler 20\uff5e25 OpenCloudOS 8.6\uff5e9 / Stream 23 openKylin all Anolis OS 8 / 23 openSUSE Leap 15 ~ 16 / Tumbleweed Arch Linux all Manjaro all EndeavourOS all Alpine Linux v3 / edge Gentoo all NixOS 19\uff5e25 <p>Get Started Mirror List</p>"},{"location":"en/other/","title":"Docker Installation & Registry Mirror Switcher","text":""},{"location":"en/other/#one-click-command","title":"One-Click Command","text":"InstallOnly Switch Registry Mirror Official Site (Recommended) GitHub Gitee GitCode jsDelivr (CDN) Tencent Cloud EO (CDN) <pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --en\n</code></pre> <pre><code>bash <(curl -sSL https://raw.githubusercontent.com/SuperManito/LinuxMirrors/main/DockerInstallation.sh) --en\n</code></pre> <pre><code>bash <(curl -sSL https://gitee.com/SuperManito/LinuxMirrors/raw/main/DockerInstallation.sh) --en\n</code></pre> <p>Real-time sync, no delay. Recommended for use in Chinese mainland network environments.</p> <pre><code>bash <(curl -sSL https://raw.gitcode.com/SuperManito/LinuxMirrors/raw/main/DockerInstallation.sh) --en\n</code></pre> <p>1-hour sync delay.</p> <pre><code>bash <(curl -sSL https://cdn.jsdelivr.net/gh/SuperManito/LinuxMirrors@main/DockerInstallation.sh) --en\n</code></pre> <pre><code>bash <(curl -sSL https://edgeone.linuxmirrors.cn/docker.sh) --en\n</code></pre> <p>Not recommended in Chinese mainland network environments.</p> <p>Integrates installation of <code>Docker Engine</code> and <code>Docker Compose</code>, supports selecting or switching software repositories (Docker repositories) and registry mirrors, installing specific versions, reinstalling, and supports ARM architecture.</p> <p>The script refers to the official documentation and uses the system package manager for installation. There are no compatibility or security issues. The available versions are determined by the Docker CE repository.</p> Official Site (Recommended) GitHub Gitee GitCode jsDelivr (CDN) Tencent Cloud EO (CDN) <pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --en --only-registry\n</code></pre> <pre><code>bash <(curl -sSL https://raw.githubusercontent.com/SuperManito/LinuxMirrors/main/DockerInstallation.sh) --en --only-registry\n</code></pre> <pre><code>bash <(curl -sSL https://gitee.com/SuperManito/LinuxMirrors/raw/main/DockerInstallation.sh) --en --only-registry\n</code></pre> <p>Real-time sync, no delay. Recommended for use in Chinese mainland network environments.</p> <pre><code>bash <(curl -sSL https://raw.gitcode.com/SuperManito/LinuxMirrors/raw/main/DockerInstallation.sh) --en --only-registry\n</code></pre> <p>1-hour sync delay.</p> <pre><code>bash <(curl -sSL https://cdn.jsdelivr.net/gh/SuperManito/LinuxMirrors@main/DockerInstallation.sh) --en --only-registry\n</code></pre> <pre><code>bash <(curl -sSL https://edgeone.linuxmirrors.cn/docker.sh) --en --only-registry\n</code></pre> <p>Not recommended in Chinese mainland network environments.</p> <ul> <li> <p> Completely replace the official installation script</p> <p>It is logically consistent with get.docker.com and incorporates the repositories and features of this project.</p> </li> <li> <p> Supports domestic derivative operating systems</p> <p>Compatible with a number of derivative operating systems not supported by the official installation script. </p> </li> <li> <p> Powerful and unparalleled</p> <p>One of the most practical open source operation and maintenance scripts on the entire network, with excellent performance</p> </li> <li> <p> Exquisite interactive design</p> <p>An interactive command line interface that is easy to understand and use, way ahead of the competition</p> </li> </ul> <p>\u2728 After years of technical accumulation and production environment testing, it has been widely praised by the community and deeply loved by developers. It is used by major companies.</p> <p></p> <p>Docker Compose does not require a separate installation</p> <p>Starting from V2, Docker Compose is part of the Docker CLI. The script integrates the installation of this plugin by default. Please use the <code>docker compose</code> command instead of <code>docker-compose</code>.</p> <p>About Software Sources</p> <ul> <li> <p>Docker CE Software Repository</p> <p>Docker CE stands for Docker Community Edition, which is another name for Docker Engine. This repository is used to download and install Docker-related packages.</p> </li> <li> <p>Docker Registry Mirror</p> <p>Used to control the default source repository for pulling images, also known as a registry accelerator. The default is the official container registry Docker Hub.</p> </li> </ul> <p>Due to some force majeure, Docker Hub is currently inaccessible in the Chinese mainland network environment, so the image cannot be pulled normally. It is recommended to use the image warehouse source available in Chinese mainland mentioned below.</p> <p>Note: The specified Web protocol in the script is only for controlling the <code>Docker CE</code> software source. <code>Docker Registry</code> always uses the <code>HTTPS</code> protocol.</p> <p>Built-in Registry Mirrors</p> <p> Available in Chinese mainland Site Name Address Description 1ms Mirror docker.1ms.run Enterprise mirror, CDN smart distribution, extremely fast, supports paid customization, recommended Docker Proxy dockerproxy.net Created by ghproxy, highly available but slow, supports paid enterprise acceleration DaoCloud docker.m.daocloud.io Well-known enterprise mirror, highly available and fast, now whitelist only 1Panel Mirror docker.1panel.live Enterprise product self-use mirror <p>This open source project is not suitable for collecting personal self-built registry accelerators. If needed, you can use command options to specify your own.</p> <p>Others</p> Site Name Address Site Name Address Alibaba Cloud (Hangzhou) registry.cn-hangzhou.aliyuncs.com Alibaba Cloud (Japan - Tokyo) registry.ap-northeast-1.aliyuncs.com Alibaba Cloud (Shanghai) registry.cn-shanghai.aliyuncs.com Alibaba Cloud (Singapore) registry.ap-southeast-1.aliyuncs.com Alibaba Cloud (Qingdao) registry.cn-qingdao.aliyuncs.com Alibaba Cloud (Malaysia - Kuala Lumpur) registry.ap-southeast-3.aliyuncs.com Alibaba Cloud (Beijing) registry.cn-beijing.aliyuncs.com Alibaba Cloud (Indonesia - Jakarta) registry.ap-southeast-5.aliyuncs.com Alibaba Cloud (Zhangjiakou) registry.cn-zhangjiakou.aliyuncs.com Alibaba Cloud (Germany - Frankfurt) registry.eu-central-1.aliyuncs.com Alibaba Cloud (Hohhot) registry.cn-huhehaote.aliyuncs.com Alibaba Cloud (UK - London) registry.eu-west-1.aliyuncs.com Alibaba Cloud (Ulanqab) registry.cn-wulanchabu.aliyuncs.com Alibaba Cloud (US West - Silicon Valley) registry.us-west-1.aliyuncs.com Alibaba Cloud (Shenzhen) registry.cn-shenzhen.aliyuncs.com Alibaba Cloud (US East - Virginia) registry.us-east-1.aliyuncs.com Alibaba Cloud (Heyuan) registry.cn-heyuan.aliyuncs.com Alibaba Cloud (UAE - Dubai) registry.me-east-1.aliyuncs.com Alibaba Cloud (Guangzhou) registry.cn-guangzhou.aliyuncs.com Google Cloud (North America) gcr.io Alibaba Cloud (Chengdu) registry.cn-chengdu.aliyuncs.com Google Cloud (Asia) asia.gcr.io Alibaba Cloud (Hong Kong) registry.cn-hongkong.aliyuncs.com Google Cloud (Europe) eu.gcr.io Tencent Cloud mirror.ccs.tencentyun.com Docker Hub registry.hub.docker.com <p>Note: Registry mirrors from domestic cloud computing companies are only for their own business. Instances in Chinese mainland may still not be able to access Docker Hub.</p>"},{"location":"en/other/#command-options-advanced-usage","title":"Command Options (Advanced Usage)","text":"bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --en --help Command options(name/meaning/value): --source Specify Docker CE mirror address (domain or IP) address --source-registry Specify Docker Registry mirror address (domain or IP) address --branch Specify Docker CE mirror repository (path) repo name --branch-version Specify Docker CE mirror repository version version --designated-version Specify Docker Engine installation version version --codename Specify Debian-based OS codename codename --protocol Specify Web protocol for Docker CE mirror http or https --use-intranet-source Prefer intranet Docker CE mirror address true or false --install-latest Whether to install the latest Docker Engine true or false --close-firewall Whether to disable the firewall true or false --clean-screen Whether to clear the screen before running true or false --lang Specify the language of the script output language --only-registry Only switch registry mirror mode none --ignore-backup-tips Ignore backup overwrite prompt (do not backup) none --pure-mode Pure mode, minimal output none --help Show help menu none Name Meaning Value <code>--source</code> Specify <code>Docker CE</code> mirror address (domain or IP) <code>address</code> <code>--source-registry</code> Specify <code>Docker Registry</code> mirror address (domain or IP) <code>address (separate multiple entries with commas)</code> <code>--branch</code> Specify <code>Docker CE</code> mirror repository (path) <code>repo name (see docs below)</code> <code>--branch-version</code> Specify <code>Docker CE</code> mirror repository version <code>version (see docs below)</code> <code>--designated-version</code> Specify <code>Docker Engine</code> installation version <code>version (see docs below)</code> <code>--codename</code> Specify <code>Debian-based</code> OS codename <code>codename</code> <code>--protocol</code> Specify Web protocol for <code>Docker CE</code> mirror <code>http</code> or <code>https</code> <code>--use-intranet-source</code> Prefer intranet <code>Docker CE</code> mirror address <code>true</code> or <code>false</code> <code>--install-latest</code> Whether to install the latest <code>Docker Engine</code> <code>true</code> or <code>false</code> <code>--close-firewall</code> Whether to disable the firewall <code>true</code> or <code>false</code> <code>--clean-screen</code> Whether to clear the screen before running <code>true</code> or <code>false</code> <code>--lang</code> Specify the language of the script output <code>language id (see docs below)</code> <code>--only-registry</code> Only switch registry mirror mode none <code>--ignore-backup-tips</code> Ignore backup overwrite prompt (do not backup) none <code>--pure-mode</code> Pure mode, minimal output none <code>--help</code> Show help menu none <p>Full source format: <code>< Web protocol>://<source address (domain or IP)>/<repository path></code></p>"},{"location":"en/other/#specify-registry-mirror-address","title":"Specify Registry Mirror Address","text":"<pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --en --source-registry registry.example.com\n</code></pre> <p>Can specify multiple addresses at the same time, and they must be separated by commas.</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --en \\\n --source-registry \"registry-1.example.com,registry-2.example.com\"\n</code></pre>"},{"location":"en/other/#only-switch-registry-mirror","title":"Only Switch Registry Mirror","text":"Use Script for One-Click ReplacementManual Replacement <p>Only switches the registry accelerator. If Docker is not installed, an error will be reported and exit.</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --en --only-registry\n</code></pre> <p>Lazy one-click command (using multiple addresses)</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --en \\\n --only-registry \\\n --source-registry \"docker.1ms.run,docker.1panel.live,docker.m.daocloud.io\"\n</code></pre> <p>The option value can specify multiple addresses, which must be separated by commas.</p> <ul> <li> <p>Install the <code>jq</code> package</p> Debian-based / openKylinRedHat-based / openEuler / OpenCloudOS / Anolis OS <pre><code>apt-get install -y jq\n</code></pre> <p><code>Debian</code> <code>Ubuntu</code> <code>Kali</code> <code>Linux Mint</code> <code>Deepin</code> <code>Zorin OS</code> <code>Armbian</code> <code>Proxmox VE</code> <code>Raspberry Pi OS</code> <code>openKylin</code></p> <p>For new systems, run <code>apt-get update</code> first.</p> <pre><code>dnf install -y jq || yum install -y jq\n</code></pre> <p><code>Red Hat Enterprise Linux</code> <code>CentOS</code> <code>Rocky Linux</code> <code>AlmaLinux</code> <code>Fedora</code> <code>openEuler</code> <code>OpenCloudOS</code> <code>Anolis OS</code></p> </li> <li> <p>Specify registry mirror address</p> <p>Manually replace <code><example.registry.com></code> with the registry address. See the address column in the \"Built-in Registry Mirrors\" table above.</p> <p><pre><code>SOURCE_REGISTRY='\"https://<example.registry.com>\"'\n</code></pre> You can also specify multiple registry mirrors, e.g., <code>SOURCE_REGISTRY='\"https://example.registry.com\",\"https://test.registry.com\"'</code>, separated by commas.</p> </li> <li> <p>Replace registry mirror address</p> <pre><code>[ -s \"/etc/docker/daemon.json\" ] || echo \"{}\" >/etc/docker/daemon.json\njq '.[\"registry-mirrors\"] = ['\"${SOURCE_REGISTRY}\"']' /etc/docker/daemon.json >/etc/docker/daemon.json.tmp && mv /etc/docker/daemon.json.tmp\n</code></pre> </li> <li> <p>Restart Docker service</p> <pre><code>systemctl daemon-reload\n[[ $(systemctl is-active docker) == \"active\" ]] && systemctl restart docker || systemctl enable --now docker\n</code></pre> </li> </ul>"},{"location":"en/other/#specify-docker-ce-source-address","title":"Specify Docker CE Source Address","text":"<pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --en --source mirror.example.com/docker-ce\n</code></pre> <p>Note: The address path must include the Docker CE mirror repository path, i.e., <code>docker-ce</code>.</p>"},{"location":"en/other/#specify-docker-ce-source-repository","title":"Specify Docker CE Source Repository","text":"<p>The script will automatically detect this in most cases. Specify only if you have special requirements.</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --en --branch centos\n</code></pre> <p>Repository names are fixed: <code>centos</code> <code>debian</code> <code>fedora</code> <code>raspbian</code> <code>rhel</code> <code>sles</code> <code>static</code> <code>ubuntu</code> See official installation docs and Docker CE official repo for details.</p> Can also specify the repository version number.<pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --en \\\n --branch centos \\\n --branch-version 9\n</code></pre> <p>This option can be used to control the compatibility of the installed software package (only applicable to Red Hat operating systems). For details, see the path name (positive integer) representing the version number in the corresponding warehouse directory.</p>"},{"location":"en/other/#specify-docker-engine-installation-version","title":"Specify Docker Engine Installation Version","text":"<p>When specifying a version, the \"install latest\" option is ignored. Format: <code>major.minor.patch</code>, e.g., <code>28.4.1</code>.</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --en --designated-version 28.0.0\n</code></pre> <p>If the specified version does not exist or is not supported on your system, the script will report an error and exit.</p> How to view available versions Debian-basedRedHat-based / openEuler / OpenCloudOS / Anolis OS <pre><code>apt-cache madison docker-ce | awk '{print $3}' | grep -Eo \"[0-9][0-9].[0-9]{1,2}.[0-9]{1,2}\" | sort -t '.' -k1,1nr -k2,2nr -k3,3nr\n</code></pre> <p><code>Debian</code> <code>Ubuntu</code> <code>Kali</code> <code>Linux Mint</code> <code>Deepin</code> <code>Zorin OS</code> <code>Armbian</code> <code>Proxmox VE</code> <code>Raspberry Pi OS</code></p> <pre><code>dnf list docker-ce --showduplicates | sort -r | awk '{print $2}' | grep -Eo \"[0-9][0-9].[0-9]{1,2}.[0-9]{1,2}\" | sort -t '.' -k1,1nr -k2,2nr -k3,3nr\n</code></pre> <p><code>Red Hat Enterprise Linux</code> <code>CentOS</code> <code>Rocky Linux</code> <code>AlmaLinux</code> <code>Fedora</code> <code>openEuler</code> <code>OpenCloudOS</code> <code>Anolis OS</code></p> <p>Versions not listed are not supported by this script. If you cannot get the version list, your system environment has not been properly configured for the Docker CE repository (this will not happen when running the script).</p>"},{"location":"en/other/#i18n-internationalization","title":"I18n (Internationalization)","text":"<p>The script provides multi-language support. Currently, there are three built-in display languages: <code>\u7b80\u4f53\u4e2d\u6587</code>\u3001<code>\u7e41\u9ad4\u4e2d\u6587</code>\u3001<code>English</code>. The default is <code>\u7b80\u4f53\u4e2d\u6587</code>.</p>"},{"location":"en/other/#specify-language","title":"Specify Language","text":"<pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --lang xxx\n</code></pre> Type Value \u7b80\u4f53\u4e2d\u6587 <code>zh-hans</code> <code>zh-cn</code> <code>zh</code> \u7e41\u9ad4\u4e2d\u6587 <code>zh-hant</code> <code>zh-tw</code> <code>zh-hk</code> English <code>en</code> <code>en-us</code> <p>It can also be used directly as a command option</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --zh-hant\n</code></pre> <p><code>--en</code> <code>--en-us</code> <code>--zh</code> <code>--zh-cn</code> <code>--zh-hans</code> <code>--zh-hant</code></p>"},{"location":"en/other/#select-through-interaction","title":"Select through interaction","text":"<pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --lang auto\n</code></pre>"},{"location":"en/other/#unattended-automation","title":"Unattended (Automation)","text":"<p>To perform installation without interaction, use at least the following options. Recommended for experienced users.</p> Example Command<pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --en \\\n --source mirror.example.com/docker-ce \\\n --source-registry registry.hub.docker.com \\\n --protocol http \\\n --use-intranet-source false \\\n --install-latest true \\\n --close-firewall true \\\n --ignore-backup-tips\n</code></pre> <p>If you get an \"invalid option\" error, check the option validity and whitespace encoding. Each option is written on a separate line for readability.</p>"},{"location":"en/other/#pure-mode","title":"Pure Mode","text":"<p>This feature is introduced to facilitate the use of developers and operation and maintenance personnel. After it is enabled, the script content output will be simplified. It is recommended to use it with other command options without interaction.</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker.sh) --en --pure-mode\n</code></pre> <p>Scrolling command logs may have unpredictable display issues, but no problems have been found so far.</p>"},{"location":"en/other/#faq","title":"FAQ","text":""},{"location":"en/other/#about-service-startup-errors","title":"About Service Startup Errors","text":"<p>In non-fresh environments, you may encounter <code>Docker</code> service startup failures after running the script. It is recommended to reinstall to resolve this. Uninstalling will not delete local images or container data.</p> <p>Uninstall commands:</p> Debian-basedRedHat-based / openEuler / OpenCloudOS / Anolis OS <pre><code>apt-get remove -y docker* containerd.io runc && apt-get autoremove\n</code></pre> <p><code>Debian</code> <code>Ubuntu</code> <code>Kali</code> <code>Linux Mint</code> <code>Deepin</code> <code>Zorin OS</code> <code>Armbian</code> <code>Proxmox VE</code> <code>Raspberry Pi OS</code></p> <pre><code>yum remove -y docker* containerd.io podman* runc\n</code></pre> <p><code>Red Hat Enterprise Linux</code> <code>CentOS</code> <code>Rocky Linux</code> <code>AlmaLinux</code> <code>Fedora</code> <code>openEuler</code> <code>OpenCloudOS</code> <code>Anolis OS</code></p> <p>After uninstalling, simply rerun the script to install.</p>"},{"location":"en/other/#about-unsupported-operating-systems","title":"About unsupported operating systems","text":"<p>If it prompts that it is not supported, please use the system's own package management tool to install it. Because these packages are built and maintained by the Linux distribution's package maintainers and may have differences in configuration or are built from modified source code.</p> <p>You can also use \u00a0 </p>"},{"location":"en/other/#lite-version","title":"Lite Version","text":"<p>The project also provides a simplified version, which is a copy of the main script, designed for enterprise products and large open-source community projects. It has the following features:</p> <ul> <li>Single display language <code>English</code>, no I18n internationalization</li> <li>Uses the official source by default, removing the interactive selection of built-in software sources</li> <li>Removes irrelevant printouts</li> <li>Retains core logic and command option design</li> </ul> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/docker-lite.sh)\n</code></pre> <p>Please familiarize yourself with this project before using it. It is not recommended for novice users.</p>"},{"location":"en/other/#best-practices","title":"Best Practices","text":"Code examples for enterprise product deployment and automated operations such as CI/CD (expand to view) <p>If you don't want any user interaction, use the <code>fully automated</code> example.</p>"},{"location":"en/other/#fully-automated-recommended","title":"Fully automated (recommended)","text":"<pre><code># !/bin/bash\nfunction install_docker() {\n if command -v docker &>/dev/null; then\n return\n fi\n\n # script options\n local script_host=\"linuxmirrors.cn\" # official host (CDN), more host see official site\n local close_firewall=\"true\" # close firewalld service and selinux (redhat systems need)\n # mirrors options\n local source_docker_ce_address=\"mirrors.tencent.com/docker-ce\" # global high availability address\n local source_docker_ce_protocol=\"https\" # https or http\n local source_docker_registry_address=\"registry.hub.docker.com\"\n\n # judge network environment\n local region_code=\"$(curl -s ipinfo.io/country)\"\n if [[ \"${region_code}\" == \"CN\" ]]; then\n local source_intranet_address=\"\"\n # use intranet source if possible\n if [ -s \"/sys/class/dmi/id/sys_vendor\" ]; then\n local sys_vendor=\"$(cat /sys/class/dmi/id/sys_vendor)\"\n if [[ \"${sys_vendor}\" == *\"Alibaba\"* ]]; then\n source_intranet_address=\"mirrors.cloud.aliyuncs.com/docker-ce\"\n elif [[ \"${sys_vendor}\" == *\"Huawei\"* ]]; then\n source_intranet_address=\"mirrors.myhuaweicloud.com/docker-ce\"\n elif [[ \"${sys_vendor}\" == *\"Tencent\"* ]]; then\n source_intranet_address=\"mirrors.tencentyun.com/docker-ce\"\n elif [[ \"${sys_vendor}\" == *\"Inspur\"* ]]; then\n source_intranet_address=\"mirrors.ivolces.com/docker-ce\"\n fi\n else\n cat /etc/motd | grep \"Alibaba Cloud \" -q\n if [ $? -eq 0 ]; then\n source_intranet_address=\"mirrors.cloud.aliyuncs.com/docker-ce\"\n fi\n fi\n # check connectivity\n if [ -n \"${source_intranet_address}\" ]; then\n if ping -c1 -W1 \"${source_intranet_address%%/*}\" >/dev/null 2>&1; then\n source_docker_ce_address=\"${source_intranet_address}\"\n source_docker_ce_protocol=\"http\"\n fi\n fi\n # registry mirror (best choice for Chinese mainland)\n source_docker_registry_address=\"docker.1ms.run\"\n else\n # use official source\n source_docker_ce_address=\"download.docker.com\"\n source_docker_registry_address=\"registry.hub.docker.com\"\n fi\n\n # install docker engine\n bash <(curl -sSL https://${script_host}/docker-lite.sh) \\\n --source \"${source_docker_ce_address}\" \\\n --source-registry \"${source_docker_registry_address}\" \\\n --protocol \"${source_docker_ce_protocol}\" \\\n --close-firewall \"${close_firewall}\"\n}\n\ninstall_docker\n</code></pre>"},{"location":"en/other/#simple-method","title":"Simple method","text":"<pre><code># !/bin/bash\nfunction install_docker() {\n if command -v docker &>/dev/null; then\n return\n fi\n\n bash <(curl -sSL https://${script_host}/docker.sh) \\\n --install-latest true \\\n --ignore-backup-tips \\\n --lang auto\n\n if command -v docker &>/dev/null; then\n echo -e \"\\n# Docker installation successful.\\n# Please run this script again manually after installation.\"\n exit 0\n else\n echo -e \"\\n# Docker installation failed.\\n# Please check the error message above.\"\n exit 1\n fi\n}\n\ninstall_docker\n</code></pre> <p>Note: If you don't specify <code>Docker CE</code> and <code>Docker Registry</code> mirrors, the script will be interactively selected by the user. The screen will be automatically cleared (<code>$ clear</code>) at this point, which will cause your script's log to be cleared.</p>"},{"location":"en/sponsor/","title":"Sponsor","text":""},{"location":"en/sponsor/#_1","title":"Sponsor","text":"Become a Sponsor <p>Please go to the author's afdian homepage to view instructions and contact the author</p>"},{"location":"en/use/","title":"Use","text":""},{"location":"en/use/#one-click-command","title":"One-Click Command","text":"Chinese mainland International Regions China Education Network Official Site (Recommended) GitHub Gitee GitCode jsDelivr (CDN) Tencent Cloud EO (CDN) <pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --en\n</code></pre> <pre><code>bash <(curl -sSL https://raw.githubusercontent.com/SuperManito/LinuxMirrors/main/ChangeMirrors.sh) --en\n</code></pre> <pre><code>bash <(curl -sSL https://gitee.com/SuperManito/LinuxMirrors/raw/main/ChangeMirrors.sh) --en\n</code></pre> <p>Real-time sync, no delay. Recommended for use in Chinese mainland network environments.</p> <pre><code>bash <(curl -sSL https://raw.gitcode.com/SuperManito/LinuxMirrors/raw/main/ChangeMirrors.sh) --en\n</code></pre> <p>1-hour sync delay.</p> <pre><code>bash <(curl -sSL https://cdn.jsdelivr.net/gh/SuperManito/LinuxMirrors@main/ChangeMirrors.sh) --en\n</code></pre> <pre><code>bash <(curl -sSL https://edgeone.linuxmirrors.cn/main.sh) --en\n</code></pre> <p>Not recommended in Chinese mainland network environments.</p> Official Site (Recommended) GitHub Gitee GitCode jsDelivr (CDN) Tencent Cloud EO (CDN) <pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --en --abroad\n</code></pre> <pre><code>bash <(curl -sSL https://raw.githubusercontent.com/SuperManito/LinuxMirrors/main/ChangeMirrors.sh) --en --abroad\n</code></pre> <pre><code>bash <(curl -sSL https://gitee.com/SuperManito/LinuxMirrors/raw/main/ChangeMirrors.sh) --en --abroad\n</code></pre> <p>Real-time sync, no delay. Recommended for use in Chinese mainland network environments.</p> <pre><code>bash <(curl -sSL https://raw.gitcode.com/SuperManito/LinuxMirrors/raw/main/ChangeMirrors.sh) --en --abroad\n</code></pre> <p>1-hour sync delay.</p> <pre><code>bash <(curl -sSL https://cdn.jsdelivr.net/gh/SuperManito/LinuxMirrors@main/ChangeMirrors.sh) --en --abroad\n</code></pre> <pre><code>bash <(curl -sSL https://edgeone.linuxmirrors.cn/main.sh) --abroad\n</code></pre> <p>Not recommended in Chinese mainland network environments.</p> Official Site (Recommended) GitHub Gitee GitCode jsDelivr (CDN) Tencent Cloud EO (CDN) <pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --en --edu\n</code></pre> <pre><code>bash <(curl -sSL https://raw.githubusercontent.com/SuperManito/LinuxMirrors/main/ChangeMirrors.sh) --en --edu\n</code></pre> <pre><code>bash <(curl -sSL https://gitee.com/SuperManito/LinuxMirrors/raw/main/ChangeMirrors.sh) --en --edu\n</code></pre> <p>Real-time sync, no delay. Recommended for use in Chinese mainland network environments.</p> <pre><code>bash <(curl -sSL https://raw.gitcode.com/SuperManito/LinuxMirrors/raw/main/ChangeMirrors.sh) --en --edu\n</code></pre> <p>1-hour sync delay.</p> <pre><code>bash <(curl -sSL https://cdn.jsdelivr.net/gh/SuperManito/LinuxMirrors@main/ChangeMirrors.sh) --en --edu\n</code></pre> <pre><code>bash <(curl -sSL https://edgeone.linuxmirrors.cn/main.sh) --en --edu\n</code></pre> <p>Not recommended in Chinese mainland network environments.</p> <p>Usage Help</p> <p>The tabs represent the built-in mirror site types and script sources. Please check whether your target mirror site supports your operating system before use. You can check in the Mirror List. By default, the original mirror configuration will be automatically backed up. For more details, see the documentation below. If you are confused by some options during use, just press Enter all the way after selecting the mirror, which is the best practice.</p> <p>It supports use in abnormal environments such as when the original system software source is damaged, missing, or invalid. There is no need to install any additional dependencies.</p> <p>About Mirror Selection (Must Read for New Users)</p> <p>If you are not familiar with these mirrors, it is recommended to use <code>Aliyun (high compatibility, strong availability)</code> or <code>USTC (fast speed)</code>. Don't worry about speed tests, the built-in mirrors generally do not differ much. This project script is an automated operation and maintenance tool. It does not subjectively rank or customize mirrors. User choice should be free, which is also to better continue the spirit of open source software.</p> <ul> <li> <p> <code>ROOT</code> privileges required</p> <p>Please run this script using the <code>root</code> account, switching between the <code>sudo -i</code> and <code>su root</code> commands, as the commands vary depending on the system. Also, avoid directly running one-click commands such as <code>sudo bash <(xxx)</code> using <code>sudo</code>.</p> </li> <li> <p> It is recommended to use a modern <code>SSH</code> client</p> <p>The system's GUI graphical interface terminal application may experience some unpredictable display issues. Some systems will automatically enable the SSH service; otherwise, please refer to how to enable SSH.</p> </li> <li> <p> If running the script for the first time on a new system</p> <p>The script relies on <code>curl</code> to fetch content, but some systems do not preinstall this package, resulting in <code>Command not found</code> errors. See About Command not found below for installation. The script itself is unrelated to <code>curl</code> or <code>wget</code> and does not download any content.</p> </li> <li> <p> Interactive configuration is required during script execution</p> <p>Use arrow keys UpDownLeftRight or WASD to control options and press Enter to confirm. If interaction is abnormal, try resizing the terminal window and avoid full screen.</p> </li> </ul>"},{"location":"en/use/#faq","title":"FAQ","text":""},{"location":"en/use/#about-command-not-found-error","title":"About Command not found error","text":"<p>This error is caused by the system not having the <code>curl</code> package installed. Install it as follows:</p> Debian-based / openKylinRedHat-based / openEuler / OpenCloudOS / Anolis OSopenSUSEArch Linux / ManjaroAlpine LinuxGentooNixOS <pre><code>apt-get install -y curl\n</code></pre> <p><code>Debian</code> <code>Ubuntu</code> <code>Kali</code> <code>Linux Mint</code> <code>Deepin</code> <code>Zorin OS</code> <code>Armbian</code> <code>Proxmox VE</code> <code>Raspberry Pi OS</code> <code>openKylin</code></p> <p>For new systems, run <code>apt-get update</code> first.</p> <pre><code>dnf install -y curl || yum install -y curl\n</code></pre> <p><code>Red Hat Enterprise Linux</code> <code>CentOS</code> <code>Rocky Linux</code> <code>AlmaLinux</code> <code>Fedora</code> <code>openEuler</code> <code>OpenCloudOS</code> <code>Anolis OS</code></p> <pre><code>zypper install curl\n</code></pre> <pre><code>pacman -S curl\n</code></pre> <pre><code>apk --no-cache add -f curl bash ncurses\n</code></pre> <pre><code>emerge --ask curl\n</code></pre> <pre><code>nix-env -iA nixos.curl\n</code></pre> Can't install? (Click to see more solutions) <p>If your system's original mirror is invalid and you can't install <code>curl</code>, here are some emergency ways to fetch the script online:</p> Download with PythonDownload with wgetDownload with browser <p>Works for most systems (except <code>Alpine Linux</code>). If <code>python3</code> is missing, try <code>python</code>. <pre><code>python3 -c \"import urllib.request; urllib.request.urlretrieve('https://linuxmirrors.cn/main.sh', 'main.sh')\"\n</code></pre></p> <p>Usually, systems without <code>curl</code> also lack <code>wget</code>, so this may not work. <pre><code>wget https://linuxmirrors.cn/main.sh\n</code></pre></p> <p>If you have GUI access, open the link in a browser to download the script. Many systems preinstall Firefox.</p> <p>Then run the script:</p> Chinese mainland International Regions China Education Network <pre><code>bash main.sh --en\n</code></pre> <pre><code>bash main.sh --en --abroad\n</code></pre> <pre><code>bash main.sh --en --edu\n</code></pre> <p>If none of these work, copy the source code to a new <code>.sh</code> file and run it with <code>bash</code>.</p>"},{"location":"en/use/#backup-of-original-mirrors","title":"Backup of original mirrors","text":"<p>The script automatically backs up the original mirror configuration. The backup path is the original file or directory with <code>.bak</code> appended, e.g., <code>/etc/apt/sources.list => /etc/apt/sources.list.bak</code>. If a backup exists, you will be prompted whether to overwrite it.</p>"},{"location":"en/use/#restore-backed-up-mirrors","title":"Restore backed up mirrors","text":"Click to expand and view Debian-based / openKylinRedHat-based / openEuler / OpenCloudOS / Anolis OSopenSUSEArch Linux / ManjaroAlpine LinuxGentooNixOS Traditional formatDEB822 format <pre><code>cp -rf /etc/apt/sources.list.bak /etc/apt/sources.list\napt-get update\n</code></pre> <pre><code>system_name=\"$(lsb_release -is | tr '[:upper:]' '[:lower:]')\"\ncp -rf \"/etc/apt/sources.list.d/${system_name}.sources.bak\" \"/etc/apt/sources.list.d/${system_name}.sources\"\napt-get update\n</code></pre> <p><code>Debian</code> <code>Ubuntu</code> <code>Kali</code> <code>Linux Mint</code> <code>Deepin</code> <code>Zorin OS</code> <code>Armbian</code> <code>Proxmox VE</code> <code>Raspberry Pi OS</code> <code>openKylin</code></p> <pre><code>cp -rf /etc/yum.repos.d.bak /etc/yum.repos.d\nyum makecache\n</code></pre> <p><code>Red Hat Enterprise Linux</code> <code>CentOS</code> <code>Rocky Linux</code> <code>AlmaLinux</code> <code>Fedora</code> <code>openEuler</code> <code>OpenCloudOS</code> <code>Anolis OS</code></p> <pre><code>cp -rf /etc/zypp/repos.d.bak /etc/zypp/repos.d\nzypper ref\n</code></pre> <pre><code>cp -rf /etc/pacman.d/mirrorlist.bak /etc/pacman.d/mirrorlist\npacman -Sy\n</code></pre> <pre><code>cp -rf /etc/apk/repositories.bak /etc/apk/repositories\napk update -f\n</code></pre> <pre><code>cp -rf /etc/portage/make.conf.bak /etc/portage/make.conf\n[ -d /etc/portage/repos.conf ] && cp -rf /etc/portage/repos.conf/gentoo.conf.bak /etc/portage/repos.conf/gentoo.conf\nemerge --sync --quiet\n</code></pre> <pre><code>cp -rf /etc/nix/nix.conf.bak /etc/nix/nix.conf\n</code></pre>"},{"location":"en/use/#how-to-enable-ssh-remote-login","title":"How to enable SSH remote login","text":"Click to expand and view <p>The commands and configuration steps are for reference only; please be flexible and adapt them accordingly.</p> <ul> <li> <p>Check if <code>SSH</code> service is installed</p> <pre><code>ls /etc | grep ssh\n</code></pre> <p>If this folder does not exist, SSH is not installed. Install the <code>openssh-server</code> package with your package manager. The installation command is as follows:</p> Debian-based / openKylinRedHat-based / openEuler / OpenCloudOS / Anolis OSopenSUSEArch Linux / ManjaroAlpine LinuxGentoo <pre><code>apt-get install -y openssh-server\n</code></pre> <p><code>Debian</code> <code>Ubuntu</code> <code>Kali</code> <code>Linux Mint</code> <code>Deepin</code> <code>Zorin OS</code> <code>Armbian</code> <code>Proxmox VE</code> <code>Raspberry Pi OS</code> <code>openKylin</code></p> <p>For new systems, run <code>apt-get update</code> first.</p> <pre><code>dnf install -y openssh-server || yum install -y openssh-server\n</code></pre> <p><code>Red Hat Enterprise Linux</code> <code>CentOS</code> <code>Rocky Linux</code> <code>AlmaLinux</code> <code>Fedora</code> <code>openEuler</code> <code>OpenCloudOS</code> <code>Anolis OS</code></p> <pre><code>zypper install openssh-server\n</code></pre> <pre><code>pacman -S openssh\n</code></pre> <pre><code>apk --no-cache add -f openssh\n</code></pre> <pre><code>emerge --ask --changed-use --oneshot net-misc/openssh\n</code></pre> <p>Package names may vary across different systems. If you encounter a \"package not found\" error, try using wildcards <code>openssh*</code> to install it.</p> </li> <li> <p>Configure <code>SSH</code> service</p> Allow root account login<pre><code>cat /etc/ssh/sshd_config | grep -Eq \"^[# ]?PermitRootLogin \" ; [ $? -eq 0 ] && sed -i 's/^[# ]\\?PermitRootLogin.*/PermitRootLogin yes/g' /etc/ssh/sshd_config || echo -e \"\\nPermitRootLogin yes\" >> /etc/ssh/sshd_config\n</code></pre> Enable password authentication<pre><code>cat /etc/ssh/sshd_config | grep -Eq \"^[# ]?PasswordAuthentication \" ; [ $? -eq 0 ] && sed -i 's/^[# ]\\?PasswordAuthentication.*/PasswordAuthentication yes/g' /etc/ssh/sshd_config || echo -e \"\\nPasswordAuthentication yes\" >> /etc/ssh/sshd_config\n</code></pre> </li> <li> <p>Start/restart <code>SSH</code> service</p> <pre><code>for ssh_svc in sshd ssh openssh; do systemctl restart \"${ssh_svc}\" 2>/dev/null && break ; systemctl enable --now \"${ssh_svc}\" 2>/dev/null && break ; done\n</code></pre> </li> </ul> <p>Friendly reminder: If you are using a public server, it is recommended to disable SSH password authentication and set up key-based login.</p>"},{"location":"en/use/#no-arrow-key-interactive-ui","title":"No arrow key interactive UI","text":"<p>If you see a text input instead of the new arrow key UI, install the <code>ncurses</code> or <code>nano</code> package. The new interaction relies on the <code>tput</code> command.</p>"},{"location":"en/use/#about-disabled-repositories","title":"About disabled repositories","text":"<p>Many systems have multiple repositories. The script follows the system default. Disabled repositories will not be enabled after running the script, but their URLs will be updated. To enable them:</p> Debian-based / openKylinRedHat-based / openEuler / OpenCloudOS / Anolis OSopenSUSE <p>By default, <code>deb-src</code> and <code>proposed</code> are disabled. Uncomment the relevant lines in <code>/etc/apt/sources.list</code> to enable.</p> <p><code>Debian</code> <code>Ubuntu</code> <code>Kali</code> <code>Linux Mint</code> <code>Deepin</code> <code>Zorin OS</code> <code>Armbian</code> <code>Proxmox VE</code> <code>Raspberry Pi OS</code> <code>openKylin</code></p> <p>Some repos are disabled by default. Set <code>enabled=1</code> in the relevant repo files under <code>/etc/yum.repos.d</code>.</p> <p><code>Red Hat Enterprise Linux</code> <code>CentOS</code> <code>Rocky Linux</code> <code>AlmaLinux</code> <code>Fedora</code> <code>openEuler</code> <code>OpenCloudOS</code> <code>Anolis OS</code></p> <p>Some repos are disabled by default. Set <code>enabled=1</code> in the relevant repo files under <code>/etc/zypp/repos.d</code>.</p>"},{"location":"en/use/#other","title":"Other","text":"About the script's online location <p>The project uses GitHub Action to automatically copy the source code to the docs directory after each commit for website publishing. The site is hosted on Netlify, with almost no risk of hijacking.</p> <p>You can also use the raw address from the code repository. This is just to explain why there are several different addresses; the default official site address is easier to remember and access.</p> About mirror download speed <p>First, see the recommendations in the Mirror List usage help. These are based on experience, but some users still worry about speed.</p> <p>The network latency (<code>Ping</code>) of a mirror is not directly related to download speed. Distance does not equal experience. Some mirrors have high bandwidth but poor speed due to load strategies.</p> <p>There are many open source speed test scripts written in C or Python. This project is written in Bash Shell and does not depend on third-party libraries. Bash is the most common scripting language for Linux operations and is preinstalled on most distributions, so users can run it directly without installing anything. This convenience cannot be replaced by other languages. However, Bash scripts may not easily achieve accurate speed testing; using other languages for this is reinventing the wheel.</p> About software source selection <p>Many people may wonder, \"Since scripts are so convenient and highly automated, why can't we automatically select the optimal software source?\" It's not that it can't be done, but that it can't be done.</p> <p>\"Software source selection\" here refers to the script automatically selecting a software source with the best experience based on the client's network environment and location. This question needs to be addressed from multiple perspectives:</p> <ul> <li> <p>Speed</p> <p>As explained above, in summary, the pursuit of speed isn't a universal requirement. For most people, it's simply not noticeable; it's enough to get it working. Moreover, many Linux distributions now offer good speeds without switching sources.</p> </li> <li> <p>Regarding mirror sites themselves</p> <p>To give a simple example, Alibaba Cloud mirror sites were once considered the top choice due to their high speed and availability. However, as the number of users increased, their speeds became increasingly slower, sometimes even below 10 Mbps. Over time, mirror sites with large user bases may not be able to handle the high traffic, resulting in a poor user experience. Mirror sites with fewer users may eventually close, which is detrimental to the development of the entire ecosystem.</p> </li> <li> <p>From Developer's Perspective</p> <p>This project aims to develop a universal repository switching script from the perspective of an operations and maintenance tool, rather than a tool that specifically addresses software repository requirements. The script's default behavior should be suitable for the majority of users. As an operations and maintenance tool, it should have a clear functional positioning. As a script, its pros and cons should be carefully considered from multiple perspectives, including scalability,and practicality. The choice of software repository should be fully vested in the user.</p> </li> </ul>"},{"location":"en/use/#command-options-advanced-usage","title":"Command Options (Advanced Usage)","text":"bash <(curl -sSL https://linuxmirrors.cn/main.sh) --en --help Command options(name/meaning/value): --abroad Use overseas mirrors none --edu Use China education network mirrors none --source Specify mirror address (domain or IP) address --source-epel Specify EPEL repository address (domain or IP) address --source-security Specify Debian/Ubuntu security repo address (domain or IP) address --source-vault Specify CentOS/AlmaLinux vault repo address (domain or IP) address --source-portage Specify Gentoo portage repo address (domain or IP) address --source-base-system Specify Linux Mint/Raspberry Pi OS base system repo address (domain or IP) address --branch Specify mirror repository (repo name) repo name --branch-epel Specify EPEL repository (path) repo name --branch-security Specify Debian security repo (path) repo name --branch-vault Specify CentOS/AlmaLinux vault repo (path) repo name --branch-portage Specify Gentoo portage repo (path) repo name --branch-base-system Specify Linux Mint/Raspberry Pi OS base system repo (path) repo name --codename Specify Debian/openKylin codename codename --protocol Specify web protocol http or https --use-intranet-source Prefer intranet mirror address true or false --use-official-source Use official mirror of target OS true or false --use-official-source-epel Use official EPEL repo true or false --install-epel Install EPEL repository true or false --backup Backup original mirrors true or false --upgrade-software Upgrade packages true or false --clean-cache Clean cache after upgrade true or false --clean-screen Clear screen before running true or false --lang Specify the language of the script output language --only-epel Only switch EPEL repo none --ignore-backup-tips Ignore backup overwrite prompt none --print-diff Print diff before and after modification none --pure-mode Pure mode, minimal output none --help Show help menu none Name Meaning Value <code>--abroad</code> Use overseas mirrors none <code>--edu</code> Use China education network mirrors none <code>--source</code> Specify mirror address (domain or IP) <code>address</code> <code>--source-epel</code> Specify EPEL repository address (domain or IP) <code>address</code> <code>--source-security</code> Specify Debian/Ubuntu security repo address (domain or IP) <code>address</code> <code>--source-vault</code> Specify CentOS/AlmaLinux vault repo address (domain or IP) <code>address</code> <code>--source-portage</code> Specify Gentoo portage repo address (domain or IP) <code>address</code> <code>--source-base-system</code> Specify Linux Mint/Raspberry Pi OS base system repo address (domain or IP) <code>address</code> <code>--branch</code> Specify mirror repository (path) <code>repo name</code> <code>--branch-epel</code> Specify EPEL repository (path) <code>repo name</code> <code>--branch-security</code> Specify Debian security repo (path) <code>repo name</code> <code>--branch-vault</code> Specify CentOS/AlmaLinux vault repo (path) <code>repo name</code> <code>--branch-portage</code> Specify Gentoo portage repo (path) <code>repo name</code> <code>--branch-base-system</code> Specify Linux Mint/Raspberry Pi OS base system repo (path) <code>repo name</code> <code>--codename</code> Specify Debian/openKylin codename <code>codename</code> <code>--protocol</code> Specify web protocol <code>http</code> or <code>https</code> <code>--use-intranet-source</code> Prefer intranet mirror address <code>true</code> or <code>false</code> <code>--use-official-source</code> Use official mirror of target OS <code>true</code> or <code>false</code> <code>--use-official-source-epel</code> Use official EPEL repo <code>true</code> or <code>false</code> <code>--install-epel</code> Install EPEL repository <code>true</code> or <code>false</code> <code>--backup</code> Backup original mirrors <code>true</code> or <code>false</code> <code>--upgrade-software</code> Upgrade packages <code>true</code> or <code>false</code> <code>--clean-cache</code> Clean cache after upgrade <code>true</code> or <code>false</code> <code>--clean-screen</code> Clear screen before running <code>true</code> or <code>false</code> <code>--lang</code> Specify the language of the script output <code>language id (see docs below)</code> <code>--only-epel</code> Only switch EPEL repo none <code>--ignore-backup-tips</code> Ignore backup overwrite prompt none <code>--print-diff</code> Print diff before and after modification none <code>--pure-mode</code> Pure mode, minimal output none <code>--help</code> Show help menu none <p>Full mirror format: <code><Web protocol>://<mirror address (domain or IP)>/<repo path></code></p> <p>Below are some advanced usage examples</p>"},{"location":"en/use/#specify-mirror-address","title":"Specify mirror address","text":"<pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --en --source mirror.example.com\n</code></pre>"},{"location":"en/use/#specify-mirror-repository-directory","title":"Specify mirror repository directory","text":"<p>The repository here refers to the directory after the mirror site address, i.e., the repository directory on the mirror site. Although all are called repositories, it is easy to confuse.</p> <p>Main scenario: The target mirror site has a corresponding system repository but does not match the default rule in this script.</p> Default repo names for each OS (click to expand) <p>The script does not adapt to unique repo names of a single mirror site for compatibility.</p> SYSTEM NAMES Debian <code>debian</code> <code>debian-archive</code> Ubuntu <code>ubuntu</code> <code>ubuntu-ports</code> Kali Linux <code>kali</code> Linux Mint <code>linuxmint</code> <code>ubuntu</code> <code>ubuntu-ports</code> <code>debian</code> Deepin <code>deepin</code> Zorin OS <code>ubuntu</code> <code>ubuntu-ports</code> Armbian <code>armbian</code> Proxmox VE <code>proxmox</code> Raspberry Pi OS <code>raspberrypi</code> <code>raspbian</code> <code>debian</code> <code>debian-archive</code> Red Hat Enterprise Linux <code>centos</code> <code>centos-stream</code> <code>centos-altarch</code> <code>centos-vault</code> Fedora <code>fedora</code> <code>fedora-archive</code> CentOS <code>centos</code> <code>centos-stream</code> <code>centos-altarch</code> <code>centos-vault</code> Rocky Linux <code>rocky</code> AlmaLinux <code>almalinux</code> <code>almalinux-vault</code> Oracle Linux <code>centos-stream</code> openEuler <code>openeuler</code> OpenCloudOS <code>opencloudos</code> openKylin <code>openkylin</code> Anolis OS <code>anolis</code> openSUSE <code>opensuse</code> Arch Linux <code>archlinux</code> <code>archlinuxarm</code> Manjaro <code>manjaro</code> EndeavourOS <code>endeavouros</code> Alpine Linux <code>alpine</code> Gentoo <code>gentoo</code> <code>gentoo-portage</code> NixOS <code>nix-channels</code> <p>Example:</p> Use Aliyun mirror for Rocky Linux<pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --en \\\n --source mirrors.aliyun.com \\\n --branch rockylinux\n</code></pre> <p>The repository directory name for Rocky Linux on Aliyun is <code>rockylinux</code>, not the default <code>rocky</code>, but you can override the default rule with the command option.</p> <p>Some systems configure multiple repos at once. See command options for details.</p> <p>Since the repo path is appended to the mirror address, you can use multi-level paths, e.g., <code>--branch \"linux/debian\"</code> -> <code>https://mirrors.example.com/linux/debian</code></p>"},{"location":"en/use/#switch-epel-repo-only","title":"Switch EPEL repo only","text":"<p>EPEL (Extra Packages for Enterprise Linux) is an additional repo maintained by Fedora, mainly for Red Hat-based distributions except Fedora itself. Configuring EPEL is a common need and is recommended by default.</p> <p>Sometimes your desired mirror does not have EPEL. You can skip EPEL during the first run and then run:</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --en --only-epel\n</code></pre> <p>For EPEL 7 (EOL), use the <code>archive</code> repo. For overseas networks, use <code>--use-official-source-epel true</code> to use the official repo.</p>"},{"location":"en/use/#restore-official-mirrors","title":"Restore official mirrors","text":"<p>If you accidentally deleted the backup of the official mirror, use this command to restore. This skips mirror selection.</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --en --use-official-source true\n</code></pre> <p>Some systems (e.g., <code>Arch Linux</code>) have no official mirror, so Aliyun will be used as a fallback.</p>"},{"location":"en/use/#usage-examples-for-specific-systems","title":"Usage examples for specific systems","text":""},{"location":"en/use/#about-centos-eol","title":"About CentOS EOL","text":"<p>The script adapts to EOL CentOS 7/8 and CentOS Stream 8.</p> <ul> <li> <p>Chinese mainland</p> <p>Use the script as usual, no additional steps are required. As most mirror sites in Chinese mainland have already synchronized the <code>CentOS Vault</code> repository.</p> </li> <li> <p>International</p> <p>Use <code>Tencent Cloud</code> or <code>Aliyun</code> mirrors, or use <code>--use-official-source true</code> for the official repo.</p> </li> </ul> <p>EPEL 7 is also EOL and is supported by the script.</p>"},{"location":"en/use/#specify-gnulinux-debian-security-repo","title":"Specify GNU/Linux Debian Security repo","text":"<p>For maximum security, use the official repo due to mirror sync delays.</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --en \\\n --source-security security.debian.org \\\n --branch-security debian-security\n</code></pre>"},{"location":"en/use/#specify-debian-based-codename","title":"Specify Debian-based codename","text":"<p>Usually for switching system versions. Example:</p> Upgrade GNU/Linux Debian to 13 \"trixie\"Switch GNU/Linux Debian to testing branch <ul> <li> <p>Change version code</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --en \\\n --codename trixie \\\n --upgrade-software false\n</code></pre> </li> <li> <p>Disable the backports repository</p> <pre><code>sed -i '/backports/s/^/# /' /etc/apt/sources.list\n</code></pre> </li> <li> <p>Upgrade the system</p> <pre><code>apt-get update\napt-get dist-upgrade\n</code></pre> </li> <li> <p>After the upgrade is complete and the system is rebooted, perform the following steps</p> <pre><code># Clear the original software sources (If there is any non-system software source content, please back it up manually first)\nsed -i '1,$d' /etc/apt/sources.list\n# Rerun the mirror switching script\nbash <(curl -sSL https://linuxmirrors.cn/main.sh) --en\n</code></pre> </li> </ul> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --en \\\n --codename testing \\\n --upgrade-software false\n</code></pre> If the script can't set the codename, you can manually replace it after running<pre><code>sed -i \"s/$(lsb_release -cs)/your-codename/g\" /etc/apt/sources.list\n</code></pre>"},{"location":"en/use/#switch-ubuntu-eol-version-mirrors","title":"Switch Ubuntu EOL version mirrors","text":"<p>EOL means End Of Life. Non-LTS Ubuntu versions are supported for only 9 months. Old versions are removed from the main repo and may require using the <code>Ubuntu Old Releases</code> repo.</p> <p>See the official Wiki for version support and check each mirror for <code>Ubuntu Old Releases</code> support.</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --en \\\n --source mirrors.ustc.edu.cn \\\n --branch ubuntu-old-releases\n</code></pre>"},{"location":"en/use/#arch-linux-use-chinese-community-repo","title":"Arch Linux use Chinese community repo","text":"<p>This script does not support this extra repo. For reference, use:</p> <pre><code>SOURCE=\"https://mirrors.aliyun.com/archlinuxcn\"\ngrep -q \"\\[archlinuxcn\\]\" /etc/pacman.conf || echo -e \"[archlinuxcn]\\nServer = ${SOURCE}/\\$arch\" >>/etc/pacman.conf\n</code></pre>"},{"location":"en/use/#i18n-internationalization","title":"I18n (Internationalization)","text":"<p>The script provides multi-language support. Currently, there are three built-in display languages: <code>\u7b80\u4f53\u4e2d\u6587</code>\u3001<code>\u7e41\u9ad4\u4e2d\u6587</code>\u3001<code>English</code>. The default is <code>\u7b80\u4f53\u4e2d\u6587</code>.</p>"},{"location":"en/use/#specify-language","title":"Specify Language","text":"<pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --lang xxx\n</code></pre> Type Value \u7b80\u4f53\u4e2d\u6587 <code>zh-hans</code> <code>zh-cn</code> <code>zh</code> \u7e41\u9ad4\u4e2d\u6587 <code>zh-hant</code> <code>zh-tw</code> <code>zh-hk</code> English <code>en</code> <code>en-us</code> <p>It can also be used directly as a command option</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --zh-hant\n</code></pre> <p><code>--en</code> <code>--en-us</code> <code>--zh</code> <code>--zh-cn</code> <code>--zh-hans</code> <code>--zh-hant</code></p>"},{"location":"en/use/#select-through-interaction","title":"Select through interaction","text":"<pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --lang auto\n</code></pre>"},{"location":"en/use/#unattended-automation","title":"Unattended (Automation)","text":"<p>To run without interaction, use at least the following options. Recommended for experienced users.</p> Example Command<pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --en \\\n --source mirror.example.com \\\n --protocol http \\\n --use-intranet-source false \\\n --install-epel true \\\n --backup true \\\n --upgrade-software false \\\n --clean-cache false \\\n --ignore-backup-tips\n</code></pre> <p>If you get an \"invalid option\" error, check the option validity and whitespace encoding. Each option is written on a separate line for readability.</p>"},{"location":"en/use/#pure-mode","title":"Pure mode","text":"<p>This feature is introduced to facilitate the use of developers and operation and maintenance personnel. After it is enabled, the script content output will be simplified. It is recommended to use it with other command options without interaction.</p> <pre><code>bash <(curl -sSL https://linuxmirrors.cn/main.sh) --en --pure-mode\n</code></pre> <p>Scrolling command logs may have unpredictable display issues, but no problems have been found so far.</p>"},{"location":"en/use/#customizing-the-script","title":"Customizing the Script","text":"<p>If you are a developer of another project and want to create a custom script based on this project, refer to the following. Some maintainers of China education network mirrors have already done so.</p> <ol> <li>It is not recommended to modify the core logic. Keep in sync with the upstream source code. The script execution order is controlled by the <code>main</code> function and is clear.</li> <li>You can simply remove irrelevant content, e.g., clear the mirror list arrays <code>mirror_list_(default|edu|abroad|extranet|intranet)</code>, e.g., <code>mirror_list_default=()</code></li> <li>To customize script output, modify the <code>run_start</code>, <code>run_end</code>, and <code>print_title</code> functions.</li> <li>To add custom shell content, see the execution order in <code>main</code>. Insert content directly or encapsulate in a function.</li> <li>To reduce script size, delete unnecessary content. Besides the mirror lists, you can remove some modules:<ol> <li>Keep the original structure; empty out the function bodies if not needed.</li> <li>Remove unused OS repo content <code>gen_repo_files_xxx</code>, which takes up over 60% of the script.</li> <li>Remove unused feature modules, e.g., <code>handle_command_options</code>, <code>backup_original_mirrors</code>, <code>upgrade_software</code>.</li> <li>Remove unnecessary language packs, for example: <code>function msg_pack_en() {}</code></li> </ol> </li> <li>Main configuration is controlled by unified variables, as are command options. These global variables are all uppercase and use underscores. See the table below. Declare them at the top of the script (reserved comment area) for quick customization.</li> </ol> Variable list (click to expand) Variable Meaning Value Type <code>SOURCE</code> Specify mirror address (domain or IP) <code>address</code> <code>SOURCE_EPEL</code> Specify EPEL repo address (domain or IP) <code>address</code> <code>SOURCE_SECURITY</code> Specify Debian/Ubuntu security repo address (domain or IP) <code>address</code> <code>SOURCE_VAULT</code> Specify CentOS/AlmaLinux vault repo address (domain or IP) <code>address</code> <code>SOURCE_PORTAGE</code> Specify Gentoo portage repo address (domain or IP) <code>address</code> <code>SOURCE_BASE_SYSTEM</code> Specify Linux Mint/Raspberry Pi OS base system repo address (domain or IP) <code>address</code> <code>SOURCE_BRANCH</code> Specify mirror repo (path) <code>repo name</code> <code>SOURCE_EPEL_BRANCH</code> Specify EPEL repo (path) <code>repo name</code> <code>SOURCE_SECURITY_BRANCH</code> Specify Debian security repo (path) <code>repo name</code> <code>SOURCE_VAULT_BRANCH</code> Specify CentOS/AlmaLinux vault repo (path) <code>repo name</code> <code>SOURCE_PORTAGE_BRANCH</code> Specify Gentoo portage repo (path) <code>repo name</code> <code>SOURCE_BASE_SYSTEM_BRANCH</code> Specify Linux Mint/Raspberry Pi OS base system repo (path) <code>repo name</code> <code>DEBIAN_CODENAME</code> Specify Debian/openKylin codename <code>codename</code> <code>USE_INTRANET_SOURCE</code> Prefer intranet mirror address <code>true</code> or <code>false</code> <code>USE_OFFICIAL_SOURCE</code> Use official mirror of target OS <code>true</code> or <code>false</code> <code>USE_OFFICIAL_SOURCE_EPEL</code> Use official EPEL repo <code>true</code> or <code>false</code> <code>WEB_PROTOCOL</code> Specify Web protocol <code>http</code> or <code>https</code> <code>INSTALL_EPEL</code> Install EPEL repository <code>true</code> or <code>false</code> <code>ONLY_EPEL</code> Only switch EPEL repo <code>true</code> or <code>false</code> <code>BACKUP</code> Backup original mirrors <code>true</code> or <code>false</code> <code>IGNORE_BACKUP_TIPS</code> Ignore backup overwrite prompt <code>true</code> or <code>false</code> <code>UPGRADE_SOFTWARE</code> Upgrade packages <code>true</code> or <code>false</code> <code>CLEAN_CACHE</code> Clean cache after upgrade <code>true</code> or <code>false</code> <code>CLEAN_SCREEN</code> Clear screen before running <code>true</code> or <code>false</code> <code>PRINT_DIFF</code> Print diff before and after modification <code>true</code> or <code>false</code> <code>PURE_MODE</code> Pure mode, minimal output <code>true</code> or <code>false</code> <p>Some variables have defaults. Unused variables do not need to be declared as empty strings. If a configuration is missing, interaction may occur.</p>"}]} |