Update int code

This commit is contained in:
Varun Sharma 2024-03-26 17:35:45 -07:00
commit 03b5d23dca
No known key found for this signature in database
GPG key ID: CE30C1F427CE6272
3 changed files with 5 additions and 3 deletions

3
dist/pre/index.js vendored
View file

@ -71801,12 +71801,13 @@ var setup_awaiter = (undefined && undefined.__awaiter) || function (thisArg, _ar
downloadPath = yield tool_cache.downloadTool("https://packages.stepsecurity.io/github-hosted/harden-runner_1.1.0_linux_amd64.tar.gz");
verifyChecksum(downloadPath, true); // NOTE: verifying tls_agent's checksum, before extracting
downloadPath = yield tool_cache.extractTar(downloadPath);
downloadPath = external_path_.join(downloadPath, "agent");
}
else {
downloadPath = yield tool_cache.downloadTool(`https://step-security-agent.s3.us-west-2.amazonaws.com/refs/heads/${env}/agent`);
//verifyChecksum(downloadPath, false); // NOTE: verifying agent's checksum, before extracting
}
let cmd = "cp", args = [external_path_.join(downloadPath, "agent"), "/home/agent/agent"];
let cmd = "cp", args = [downloadPath, "/home/agent/agent"];
external_child_process_.execFileSync(cmd, args);
external_child_process_.execSync("chmod +x /home/agent/agent");
external_fs_.writeFileSync("/home/agent/agent.json", confgStr);

File diff suppressed because one or more lines are too long

View file

@ -210,6 +210,7 @@ import { isGithubHosted, isTLSEnabled } from "./tls-inspect";
);
verifyChecksum(downloadPath, true); // NOTE: verifying tls_agent's checksum, before extracting
downloadPath = await tc.extractTar(downloadPath);
downloadPath = path.join(downloadPath, "agent");
} else {
downloadPath = await tc.downloadTool(
`https://step-security-agent.s3.us-west-2.amazonaws.com/refs/heads/${env}/agent`
@ -219,7 +220,7 @@ import { isGithubHosted, isTLSEnabled } from "./tls-inspect";
}
let cmd = "cp",
args = [path.join(downloadPath, "agent"), "/home/agent/agent"];
args = [downloadPath, "/home/agent/agent"];
cp.execFileSync(cmd, args);