Skip to content

Commit

Permalink
DOP-4414 checking main
Browse files Browse the repository at this point in the history
  • Loading branch information
anabellabuckvar committed Mar 18, 2024
1 parent db82c8d commit 635025b
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions api/controllers/v2/github.ts
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,14 @@ export const triggerSmokeTestAutomatedBuild = async (event: APIGatewayEvent): Pr
' completed successfully but only Deploy Staging ECS workflow completion will trigger smoke test site deployments',
};

return {
statusCode: 202,
headers: { 'Content-Type': 'text/plain' },
body:
'Build on branch' +
body.workflow_run.head_branch +
' will not trigger site deployments as it was not on master branch in upstream repo',
};
// if the build was not building master, no need for smoke test sites
if (body.workflow_run.head_branch != 'main' || body.repository.fork) {
console.log('Build was not on master branch in main repo, sites will not deploy as no smoke tests are needed');
Expand Down

0 comments on commit 635025b

Please sign in to comment.