feat: support private mirrors (#1240)

* feat: support private mirrors

* chore: change fallback message with mirrors
This commit is contained in:
Marco Ippolito
2025-04-02 17:49:47 +02:00
committed by GitHub
parent 40337cb8f7
commit e3ce749e20
14 changed files with 322 additions and 44 deletions

View File

@ -36,6 +36,8 @@ export async function run() {
if (version) {
const token = core.getInput('token');
const auth = !token ? undefined : `token ${token}`;
const mirror = core.getInput('mirror');
const mirrorToken = core.getInput('mirror-token');
const stable =
(core.getInput('stable') || 'true').toUpperCase() === 'TRUE';
const checkLatest =
@ -45,7 +47,9 @@ export async function run() {
checkLatest,
auth,
stable,
arch
arch,
mirror,
mirrorToken
};
const nodeDistribution = getNodejsDistribution(nodejsInfo);
await nodeDistribution.setupNodeJs();