Skip to content

Commit

Permalink
Bug 1929673 - Only use Taskcluster staging for PR comments
Browse files Browse the repository at this point in the history
  • Loading branch information
ahal committed Nov 15, 2024
1 parent a3eee9f commit 439b1a2
Showing 1 changed file with 11 additions and 5 deletions.
16 changes: 11 additions & 5 deletions .taskcluster.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@ policy:
tasks:
- $let:
trustDomain: ci
taskclusterInstance:
$switch:
'taskcluster_root_url == "https://firefox-ci-tc.services.mozilla.com"': "firefoxci"
'taskcluster_root_url == "https://stage.taskcluster.nonprod.cloudops.mozgcp.net"': "staging"
isPullRequest:
$eval: 'tasks_for[:19] == "github-pull-request" || tasks_for == "github-issue-comment"'
pullRequestAction:
Expand Down Expand Up @@ -102,11 +106,13 @@ tasks:
$default: '${head_ref}'
in:
$if: >
tasks_for in ["action", "pr-action", "cron"]
|| (tasks_for == "github-release" && releaseAction == "published")
|| (tasks_for == "github-push" && short_head_ref == "main")
|| (isPullRequest && pullRequestAction in ["opened", "reopened", "synchronize"])
|| (isPullRequest && issueCommentAction in ["created", "edited"])
(taskclusterInstance == "firefoxci"
&& (tasks_for in ["action", "pr-action", "cron"]
|| (tasks_for == "github-release" && releaseAction == "published")
|| (tasks_for == "github-push" && short_head_ref == "main")
|| (isPullRequest && pullRequestAction in ["opened", "reopened", "synchronize"])))
|| (taskclusterInstance == "staging"
&& (isPullRequest && issueCommentAction in ["created", "edited"]))
then:
taskId: {$if: 'tasks_for != "action"', then: '${ownTaskId}'}
taskGroupId:
Expand Down

0 comments on commit 439b1a2

Please sign in to comment.