mirror of
https://github.com/step-security/harden-runner.git
synced 2026-06-06 13:47:06 +00:00
Merge branch 'rc-v2.6.1' into fix-cache
This commit is contained in:
commit
b750996025
5 changed files with 36 additions and 8 deletions
13
dist/post/index.js
vendored
13
dist/post/index.js
vendored
|
|
@ -3002,12 +3002,21 @@ function isDocker() {
|
|||
|
||||
;// CONCATENATED MODULE: ./src/arc-runner.ts
|
||||
|
||||
|
||||
function isArcRunner() {
|
||||
const runnerUserAgent = process.env["GITHUB_ACTIONS_RUNNER_EXTRA_USER_AGENT"];
|
||||
let isARC = false;
|
||||
if (!runnerUserAgent) {
|
||||
return false;
|
||||
isARC = false;
|
||||
}
|
||||
return runnerUserAgent.includes("actions-runner-controller/");
|
||||
else {
|
||||
isARC = runnerUserAgent.includes("actions-runner-controller/");
|
||||
}
|
||||
return isARC || isSecondaryPod();
|
||||
}
|
||||
function isSecondaryPod() {
|
||||
const workDir = "/__w";
|
||||
return external_fs_.existsSync(workDir);
|
||||
}
|
||||
function getRunnerTempDir() {
|
||||
const isTest = process.env["isTest"];
|
||||
|
|
|
|||
2
dist/post/index.js.map
vendored
2
dist/post/index.js.map
vendored
File diff suppressed because one or more lines are too long
13
dist/pre/index.js
vendored
13
dist/pre/index.js
vendored
|
|
@ -69771,12 +69771,21 @@ var cacheHttpClient = __nccwpck_require__(8245);
|
|||
var cacheUtils = __nccwpck_require__(1518);
|
||||
;// CONCATENATED MODULE: ./src/arc-runner.ts
|
||||
|
||||
|
||||
function isArcRunner() {
|
||||
const runnerUserAgent = process.env["GITHUB_ACTIONS_RUNNER_EXTRA_USER_AGENT"];
|
||||
let isARC = false;
|
||||
if (!runnerUserAgent) {
|
||||
return false;
|
||||
isARC = false;
|
||||
}
|
||||
return runnerUserAgent.includes("actions-runner-controller/");
|
||||
else {
|
||||
isARC = runnerUserAgent.includes("actions-runner-controller/");
|
||||
}
|
||||
return isARC || isSecondaryPod();
|
||||
}
|
||||
function isSecondaryPod() {
|
||||
const workDir = "/__w";
|
||||
return external_fs_.existsSync(workDir);
|
||||
}
|
||||
function getRunnerTempDir() {
|
||||
const isTest = process.env["isTest"];
|
||||
|
|
|
|||
2
dist/pre/index.js.map
vendored
2
dist/pre/index.js.map
vendored
File diff suppressed because one or more lines are too long
|
|
@ -1,14 +1,24 @@
|
|||
import * as cp from "child_process";
|
||||
import * as fs from "fs";
|
||||
import { sleep } from "./setup";
|
||||
|
||||
export function isArcRunner(): boolean {
|
||||
const runnerUserAgent = process.env["GITHUB_ACTIONS_RUNNER_EXTRA_USER_AGENT"];
|
||||
|
||||
let isARC = false;
|
||||
|
||||
if (!runnerUserAgent) {
|
||||
return false;
|
||||
isARC = false;
|
||||
} else {
|
||||
isARC = runnerUserAgent.includes("actions-runner-controller/");
|
||||
}
|
||||
|
||||
return runnerUserAgent.includes("actions-runner-controller/");
|
||||
return isARC || isSecondaryPod();
|
||||
}
|
||||
|
||||
function isSecondaryPod(): boolean {
|
||||
const workDir = "/__w";
|
||||
return fs.existsSync(workDir);
|
||||
}
|
||||
|
||||
function getRunnerTempDir(): string {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue