Skip to content

Commit

Permalink
feat: added env for machine id (#218)
Browse files Browse the repository at this point in the history
Co-authored-by: miguelangarano <[email protected]>
  • Loading branch information
miguelangaranocurrents and miguelangarano authored Nov 21, 2024
1 parent c85dfbd commit 34888c5
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 0 deletions.
1 change: 1 addition & 0 deletions packages/cypress-cloud/lib/api/types/run.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ export type CreateRunPayload = {
autoCancelAfterFailures: ValidatedCurrentsParameters["autoCancelAfterFailures"];
coverageEnabled?: boolean;
previousCiBuildId?: string;
providedMachineId?: string;
};

export type CloudWarning = {
Expand Down
4 changes: 4 additions & 0 deletions packages/cypress-cloud/lib/run.ts
Original file line number Diff line number Diff line change
Expand Up @@ -110,10 +110,14 @@ export async function run(params: CurrentsRunParameters = {}) {
autoCancelAfterFailures,
coverageEnabled: experimentalCoverageRecording,
previousCiBuildId: process.env.CURRENTS_PREVIOUS_CI_BUILD_ID,
providedMachineId: process.env.CURRENTS_MACHINE_ID,
});

setRunId(run.runId);
info("🎥 Run URL:", bold(run.runUrl));
process.env.CURRENTS_MACHINE_ID
? info("🤖 Machine ID:", bold(run.machineId))
: null;
cutInitialOutput();

await startWSS();
Expand Down
1 change: 1 addition & 0 deletions turbo.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
"CURRENTS_API_URL",
"CURRENTS_RECORD_KEY",
"CURRENTS_PREVIOUS_CI_BUILD_ID",
"CURRENTS_MACHINE_ID",
"TF_BUILD",
"TF_BUILD_BUILDNUMBER",
"AZURE_HTTP_USER_AGENT",
Expand Down

0 comments on commit 34888c5

Please sign in to comment.