diff --git a/lib/start-proxy-action.js b/lib/start-proxy-action.js index 21747c4356..a7cbc96d52 100644 --- a/lib/start-proxy-action.js +++ b/lib/start-proxy-action.js @@ -32,8 +32,8 @@ const actionsUtil = __importStar(require("./actions-util")); const logging_1 = require("./logging"); const util = __importStar(require("./util")); const UPDATEJOB_PROXY = "update-job-proxy"; -const UPDATEJOB_PROXY_VERSION = "v2.0.20240722180912"; -const UPDATEJOB_PROXY_URL = "https://github.com/github/codeql-action/releases/download/codeql-bundle-v2.18.1/update-job-proxy.tar.gz"; +const UPDATEJOB_PROXY_VERSION = "v2.0.20241023203727"; +const UPDATEJOB_PROXY_URL_PREFIX = "https://github.com/github/codeql-action/releases/download/codeql-bundle-v2.18.1/"; const PROXY_USER = "proxy_user"; const KEY_SIZE = 2048; const KEY_EXPIRY_YEARS = 2; @@ -196,13 +196,21 @@ function getProxyAuth() { return; } async function getProxyBinaryPath() { - let proxyBin = toolcache.find(UPDATEJOB_PROXY, UPDATEJOB_PROXY_VERSION); + const proxyFileName = process.platform === "win32" ? `${UPDATEJOB_PROXY}.exe` : UPDATEJOB_PROXY; + const platform = process.platform === "win32" + ? "win64" + : process.platform === "darwin" + ? "osx64" + : "linux64"; + const proxyPackage = `${UPDATEJOB_PROXY}-${platform}.tar.gz`; + const proxyURL = `${UPDATEJOB_PROXY_URL_PREFIX}${proxyPackage}`; + let proxyBin = toolcache.find(proxyFileName, UPDATEJOB_PROXY_VERSION); if (!proxyBin) { - const temp = await toolcache.downloadTool(UPDATEJOB_PROXY_URL); + const temp = await toolcache.downloadTool(proxyURL); const extracted = await toolcache.extractTar(temp); - proxyBin = await toolcache.cacheDir(extracted, UPDATEJOB_PROXY, UPDATEJOB_PROXY_VERSION); + proxyBin = await toolcache.cacheDir(extracted, proxyFileName, UPDATEJOB_PROXY_VERSION); } - proxyBin = path.join(proxyBin, UPDATEJOB_PROXY); + proxyBin = path.join(proxyBin, proxyFileName); return proxyBin; } function credentialToStr(c) { diff --git a/lib/start-proxy-action.js.map b/lib/start-proxy-action.js.map index aeb0dbb61b..2c8afc41cf 100644 --- a/lib/start-proxy-action.js.map +++ b/lib/start-proxy-action.js.map @@ -1 +1 @@ -{"version":3,"file":"start-proxy-action.js","sourceRoot":"","sources":["../src/start-proxy-action.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;AAAA,iDAAoD;AACpD,2CAA6B;AAE7B,oDAAsC;AACtC,+DAAiD;AACjD,2CAAiC;AAEjC,4DAA8C;AAC9C,uCAAqD;AACrD,6CAA+B;AAE/B,MAAM,eAAe,GAAG,kBAAkB,CAAC;AAC3C,MAAM,uBAAuB,GAAG,qBAAqB,CAAC;AACtD,MAAM,mBAAmB,GACvB,yGAAyG,CAAC;AAC5G,MAAM,UAAU,GAAG,YAAY,CAAC;AAChC,MAAM,QAAQ,GAAG,IAAI,CAAC;AACtB,MAAM,gBAAgB,GAAG,CAAC,CAAC;AA2B3B,MAAM,YAAY,GAAG;IACnB;QACE,IAAI,EAAE,YAAY;QAClB,KAAK,EAAE,wBAAwB;KAChC;IACD;QACE,IAAI,EAAE,kBAAkB;QACxB,KAAK,EAAE,aAAa;KACrB;IACD;QACE,SAAS,EAAE,IAAI;QACf,KAAK,EAAE,YAAY;KACpB;IACD;QACE,IAAI,EAAE,aAAa;QACnB,KAAK,EAAE,IAAI;KACZ;IACD;QACE,SAAS,EAAE,IAAI;QACf,KAAK,EAAE,YAAY;KACpB;IACD;QACE,IAAI,EAAE,cAAc;QACpB,KAAK,EAAE,eAAe;KACvB;CACF,CAAC;AAEF,SAAS,4BAA4B;IACnC,MAAM,IAAI,GAAG,gBAAG,CAAC,GAAG,CAAC,eAAe,CAAC,QAAQ,CAAC,CAAC;IAC/C,MAAM,IAAI,GAAG,gBAAG,CAAC,iBAAiB,EAAE,CAAC;IACrC,IAAI,CAAC,SAAS,GAAG,IAAI,CAAC,SAAS,CAAC;IAChC,IAAI,CAAC,YAAY,GAAG,IAAI,CAAC;IACzB,IAAI,CAAC,QA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f,CAAC,CAAC;IACL,CAAC;IACD,OAAO,GAAG,CAAC;AACb,CAAC;AAED,4EAA4E;AAC5E,SAAS,YAAY;IACnB,MAAM,cAAc,GAAG,WAAW,CAAC,gBAAgB,CAAC,gBAAgB,CAAC,CAAC;IACtE,IAAI,cAAc,EAAE,CAAC;QACnB,OAAO;YACL,QAAQ,EAAE,UAAU;YACpB,QAAQ,EAAE,cAAc;SACzB,CAAC;IACJ,CAAC;IACD,OAAO;AACT,CAAC;AAED,KAAK,UAAU,kBAAkB;IAC/B,IAAI,QAAQ,GAAG,SAAS,CAAC,IAAI,CAAC,eAAe,EAAE,uBAAuB,CAAC,CAAC;IACxE,IAAI,CAAC,QAAQ,EAAE,CAAC;QACd,MAAM,IAAI,GAAG,MAAM,SAAS,CAAC,YAAY,CAAC,mBAAmB,CAAC,CAAC;QAC/D,MAAM,SAAS,GAAG,MAAM,SAAS,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;QACnD,QAAQ,GAAG,MAAM,SAAS,CAAC,QAAQ,CACjC,SAAS,EACT,eAAe,EACf,uBAAuB,CACxB,CAAC;IACJ,CAAC;IACD,QAAQ,GAAG,IAAI,CAAC,IAAI,CAAC,QAAQ,EAAE,eAAe,CAAC,CAAC;IAChD,OAAO,QAAQ,CAAC;AAClB,CAAC;AAED,SAAS,eAAe,CAAC,CAAa;IACpC,OAAO,SAAS,CAAC,CAAC,IAAI,WAAW,CAAC,CAAC,IAAI,UAAU,CAAC,CAAC,GAAG,cACpD,CAAC,CAAC,QACJ,eAAe,CAAC,CAAC,QAAQ,KAAK,SAAS,YAAY,CAAC,CAAC,KAAK,KAAK,SAAS,EAAE,CAAC;AAC7E,CAAC;AAED,KAAK,UAAU,EAAE,CAAC"} \ No newline at end of file +{"version":3,"file":"start-proxy-action.js","sourceRoot":"","sources":["../src/start-proxy-action.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;AAAA,iDAAoD;AACpD,2CAA6B;AAE7B,oDAAsC;AAC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U,EAAE,CAAC"} \ No newline at end of file diff --git a/src/start-proxy-action.ts b/src/start-proxy-action.ts index 9b8deb59e2..d9edf674c4 100644 --- a/src/start-proxy-action.ts +++ b/src/start-proxy-action.ts @@ -10,9 +10,9 @@ import { getActionsLogger, Logger } from "./logging"; import * as util from "./util"; const UPDATEJOB_PROXY = "update-job-proxy"; -const UPDATEJOB_PROXY_VERSION = "v2.0.20240722180912"; -const UPDATEJOB_PROXY_URL = - "https://github.com/github/codeql-action/releases/download/codeql-bundle-v2.18.1/update-job-proxy.tar.gz"; +const UPDATEJOB_PROXY_VERSION = "v2.0.20241023203727"; +const UPDATEJOB_PROXY_URL_PREFIX = + "https://github.com/github/codeql-action/releases/download/codeql-bundle-v2.18.1/"; const PROXY_USER = "proxy_user"; const KEY_SIZE = 2048; const KEY_EXPIRY_YEARS = 2; @@ -229,17 +229,28 @@ function getProxyAuth(): BasicAuthCredentials | undefined { } async function getProxyBinaryPath(): Promise { - let proxyBin = toolcache.find(UPDATEJOB_PROXY, UPDATEJOB_PROXY_VERSION); + const proxyFileName = + process.platform === "win32" ? `${UPDATEJOB_PROXY}.exe` : UPDATEJOB_PROXY; + const platform = + process.platform === "win32" + ? "win64" + : process.platform === "darwin" + ? "osx64" + : "linux64"; + const proxyPackage = `${UPDATEJOB_PROXY}-${platform}.tar.gz`; + const proxyURL = `${UPDATEJOB_PROXY_URL_PREFIX}${proxyPackage}`; + + let proxyBin = toolcache.find(proxyFileName, UPDATEJOB_PROXY_VERSION); if (!proxyBin) { - const temp = await toolcache.downloadTool(UPDATEJOB_PROXY_URL); + const temp = await toolcache.downloadTool(proxyURL); const extracted = await toolcache.extractTar(temp); proxyBin = await toolcache.cacheDir( extracted, - UPDATEJOB_PROXY, + proxyFileName, UPDATEJOB_PROXY_VERSION, ); } - proxyBin = path.join(proxyBin, UPDATEJOB_PROXY); + proxyBin = path.join(proxyBin, proxyFileName); return proxyBin; }