Skip to content

Commit bfb5bb9

Browse files
committed
Append query parameter to downloads
This allows mirrors to know how much traffic is coming from Actions, and hence allows us to observe if some mirrors are having bandwidth or usage issues due to this Action. The query parameter is hardcoded as `?source=github-actions`, and contains no information about the workflow, job, or run.
1 parent 6f02cca commit bfb5bb9

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

main.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,9 @@ const MIRRORS = [
2121
];
2222

2323
async function downloadFromMirror(mirror, tarball_name, tarball_ext) {
24-
const tarball_path = await tc.downloadTool(`${mirror}/${tarball_name}${tarball_ext}`);
24+
const tarball_path = await tc.downloadTool(`${mirror}/${tarball_name}${tarball_ext}?source=github-actions`);
2525

26-
const signature_response = await fetch(`${mirror}/${tarball_name}${tarball_ext}.minisig`);
26+
const signature_response = await fetch(`${mirror}/${tarball_name}${tarball_ext}.minisig?source=github-actions`);
2727
const signature_data = Buffer.from(await signature_response.arrayBuffer());
2828

2929
const tarball_data = await fs.readFile(tarball_path);

0 commit comments

Comments
 (0)