Enable in-build signing based on branch (#81496)
authorMatt Mitchell <mmitche@microsoft.com>
Wed, 1 Feb 2023 20:18:26 +0000 (12:18 -0800)
committerGitHub <noreply@github.com>
Wed, 1 Feb 2023 20:18:26 +0000 (12:18 -0800)
eng/pipelines/common/internal-variables.yml

index d511369..acdb254 100644 (file)
@@ -4,5 +4,9 @@ parameters:
 variables:
   - name: TeamName
     value: ${{ parameters.teamName }}
-  - name: PostBuildSign
-    value: true
+  - ${{ if or(startswith(variables['Build.SourceBranch'], 'refs/heads/release/'), startswith(variables['Build.SourceBranch'], 'refs/heads/internal/release/'), eq(variables['Build.Reason'], 'Manual')) }}:
+    - name: PostBuildSign
+      value: false
+  - ${{ else }}:
+    - name: PostBuildSign
+      value: true