Skip to content

Commit 6d7ee6b

Browse files
authored
Update docIndex to kick off the docs SDK CI run for main (Azure#38791)
* Update docIndex to kick off the docs SDK CI run for main * spacing, it's the win!
1 parent c5b78cb commit 6d7ee6b

File tree

2 files changed

+28
-3
lines changed

2 files changed

+28
-3
lines changed
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"target_repo": {
33
"url": "https://github.com/MicrosoftDocs/azure-docs-sdk-python",
4-
"branch": "%%DailyDocsBranchName%%"
4+
"branch": "%%DocsBranchName%%"
55
},
66
"run_post_toc_script": false
77
}

eng/pipelines/docindex.yml

Lines changed: 27 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,12 @@ parameters:
77
type: boolean
88
default: true
99

10+
- name: StartMainSDKCIRun
11+
displayName: |
12+
Kick off the main SDK CI docs run when manually running the pipeline
13+
type: boolean
14+
default: false
15+
1016
- name: ForceDailyUpdate
1117
displayName: |
1218
Force the daily branch update (includes starting daily branch run).
@@ -110,6 +116,24 @@ jobs:
110116
TargetRepoOwner: $(DocRepoOwner)
111117
WorkingDirectory: $(DocRepoLocation)
112118

119+
- task: AzureCLI@2
120+
displayName: Queue Docs CI build for main
121+
condition: and(succeeded(), or(eq(variables['Build.Reason'], 'Schedule'), eq(${{ parameters.StartMainSDKCIRun }}, true)))
122+
inputs:
123+
azureSubscription: msdocs-apidrop-connection
124+
scriptType: pscore
125+
scriptLocation: inlineScript
126+
inlineScript: |
127+
# Resource here is the Devops API scope
128+
$accessToken = az account get-access-token --resource "499b84ac-1321-427f-aa17-267ca6975798" --query "accessToken" --output tsv
129+
$buildParamJson = (@{ params = (Get-Content ./eng/docsSDKCIConfig.json -Raw) -replace '%%DocsBranchName%%', "main" } | ConvertTo-Json)
130+
eng/common/scripts/Queue-Pipeline.ps1 `
131+
-Organization "apidrop" `
132+
-Project "Content%20CI" `
133+
-DefinitionId 5533 `
134+
-BuildParametersJson $buildParamJson `
135+
-BearerToken $accessToken
136+
113137
# The scenario for running a Manual build is normally only for the main updates. The daily build
114138
# should really only get kicked off for scheduled runs.
115139
- ${{ if or(eq(variables['Build.Reason'], 'Schedule'), parameters.ForceDailyUpdate) }}:
@@ -177,14 +201,15 @@ jobs:
177201
PushArgs: -f
178202

179203
- task: AzureCLI@2
180-
displayName: Queue Docs CI build
204+
displayName: Queue Docs CI build for daily branch
181205
inputs:
182206
azureSubscription: msdocs-apidrop-connection
183207
scriptType: pscore
184208
scriptLocation: inlineScript
185209
inlineScript: |
210+
# Resource here is the Devops API scope
186211
$accessToken = az account get-access-token --resource "499b84ac-1321-427f-aa17-267ca6975798" --query "accessToken" --output tsv
187-
$buildParamJson = (@{ params = (Get-Content ./eng/dailydocsconfig.json -Raw) -replace '%%DailyDocsBranchName%%', "$(DailyDocsBranchName)" } | ConvertTo-Json)
212+
$buildParamJson = (@{ params = (Get-Content ./eng/docsSDKCIConfig.json -Raw) -replace '%%DocsBranchName%%', "$(DailyDocsBranchName)" } | ConvertTo-Json)
188213
eng/common/scripts/Queue-Pipeline.ps1 `
189214
-Organization "apidrop" `
190215
-Project "Content%20CI" `

0 commit comments

Comments
 (0)