Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

yarn原始安装包 #342

Open
yunnysunny opened this issue Sep 8, 2022 · 3 comments
Open

yarn原始安装包 #342

yunnysunny opened this issue Sep 8, 2022 · 3 comments

Comments

@yunnysunny
Copy link

项目介绍 / Project Introduction

yarn 是 Node.js 的一个包管理工具,广泛应用于 Node 领域,Node 官方 docker 镜像中也会包含此工具。

上游地址及镜像方式 / Upstream location & mirror method

原始 yarn 的二进制文件的下载地址格式为:
https://yarnpkg.com/downloads/$YARN_VERSION/yarn-v$YARN_VERSION.tar.gz
其中 $YARN_VERSION 为版本号。

为什么希望添加该镜像 / Why do you want we to add this mirror

原始 yarn 的下载地址,最终会 302 到 objects.githubusercontent.com 域名进行下载,但是这个地址在国内不一定能时刻访问的到。在导致制作自定义镜像时会下载此文件失败,导致镜像无法构建成功。

其他信息 / Extra information

gpg 密钥文件 https://yarnpkg.com/downloads/$YARN_VERSION/yarn-v$YARN_VERSION.tar.gz.asc

  • 镜像容量(Mirror size):~1MB
  • 该镜像需求是否曾在之前的 issue 中提出过:否
@zhsj
Copy link
Contributor

zhsj commented Sep 8, 2022

https://yarnpkg.com/downloads 这里只有yarn 1.x吧? 2.0 以后是用corepack装的,而corepack是写死路径的。https://github.com/nodejs/corepack/blob/2ede2b15cab3d7e588b4f5dbc31e7a71cd51a63f/config.json#L109

@zhsj
Copy link
Contributor

zhsj commented Sep 8, 2022

yarn 1.x 如果要镜像,可以镜像 https://github.com/yarnpkg/yarn/releases/ 这个。

本身https://yarnpkg.com/downloads 也是302到github release的。

@yunnysunny
Copy link
Author

yunnysunny commented Sep 8, 2022 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants