Allow setting alternate URLs to download yarn versions
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 3.8k
- Forks
- 279
- Avg merge
- 1h 47m
- Merged PRs (30d)
- 2
Description
Hello,
I'm using Renovate to update Yarn in hundreds of repositories.
Renovate leverages corepack to download Yarn which seems to result in our source IP being banned because we download Yarn too often.
I operate a Nexus Repository from which I could download a release only once and then use it from there as a cache, but apparently there is no way to provide an alternative baseURL for Yarn?
I only see COREPACK_NPM_REGISTRY but that doesn't apply for Yarn.
! Corepack is about to download https://repo.yarnpkg.com/4.17.1/packages/yarnpkg-cli/bin/yarn.js
Is it possible to introduce COREPACK_YARN_MIRROR ?
COREPACK_YARN_MIRROR=https://repo.yarnpkg.com/
I would be happy to send a Pull Request should this be accepted.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by tracing Corepack's Yarn download path from the reported repo.yarnpkg.com URL and compare it with the existing COREPACK_NPM_REGISTRY handling. Determine where an alternate Yarn base URL can be read and applied, then add or update tests showing that the environment variable changes the download URL while preserving the default behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- tooling
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 68/100