From 141997eaa1a20eff9936055d1185d3f92b965a9e Mon Sep 17 00:00:00 2001
From: Johan Lorenzo <jlorenzo@mozilla.com>
Date: Thu, 1 Sep 2022 14:39:47 +0200
Subject: [PATCH] Bug 1786780 - part 2: Fix assume scope when SSH is used

---
 .taskcluster.yml | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/.taskcluster.yml b/.taskcluster.yml
index cb4e91282cd..6e91285be97 100644
--- a/.taskcluster.yml
+++ b/.taskcluster.yml
@@ -207,21 +207,20 @@ tasks:
                                             - index.mobile.v2.${project}.branch.${head_ref}.revision.${head_sha}.taskgraph.decision-${cron.job_name}
                                             - index.mobile.v2.${project}.branch.${head_ref}.revision.${head_sha}.taskgraph.cron.${ownTaskId}
                         scopes:
-                            # `https://` is 8 characters so, ${repoUrl[8:]} is the repository without the protocol.
                             $if: 'tasks_for == "github-push"'
                             then:
                                 - 'assume:repo:github.com/${repoFullName}:branch:${short_head_ref}'
                             else:
                                 $if: 'tasks_for == "github-pull-request"'
                                 then:
-                                    - 'assume:repo:github.com/${event.pull_request.base.repo.full_name}:pull-request'
+                                    - 'assume:repo:github.com/${repoFullName}:pull-request'
                                 else:
                                     $if: 'tasks_for == "action"'
                                     then:
                                         # when all actions are hooks, we can calculate this directly rather than using a variable
                                         - '${action.repo_scope}'
                                     else:
-                                        - 'assume:repo:${repoUrl[8:]}:cron:${cron.job_name}'
+                                        - 'assume:repo:github.com/${repoFullName}:cron:${cron.job_name}'
 
                         requires: all-completed
                         priority: lowest
-- 
GitLab