(docs): update force deployment condition for build docs (#22954)
previous shouldDeploy condition have not been included in deployment condition. This variable has been updated to "forceDeployment" and included back in the deployment condition. shouldDeploy has been updated to check if release builds are the latest version in its major version series.
This commit is contained in:
Родитель
512e53f04e
Коммит
e432720309
|
@ -64,18 +64,11 @@ variables:
|
|||
value: true
|
||||
- name: isMain
|
||||
value: ${{ eq(variables['Build.SourceBranchName'], 'main') }}
|
||||
- name: shouldDeploy
|
||||
value: ${{ or(
|
||||
eq(parameters.deployOverride, 'force'),
|
||||
and(eq(variables.isMain, true), eq(parameters.deployOverride, 'default'))
|
||||
)}}
|
||||
- name: shouldRetainGuardianAssets
|
||||
value: ${{ or(
|
||||
eq(parameters.guardianAssetRetentionOverride, 'force'),
|
||||
and(eq(variables.isMain, true), eq(parameters.guardianAssetRetentionOverride, 'default'))
|
||||
)}}
|
||||
- name: arrow.releasedtoproduction
|
||||
value: eq(variables.shouldDeploy, true)
|
||||
- name: deploymentToken
|
||||
${{ if eq( parameters['deployEnvironment'], 'new' ) }}:
|
||||
value: "$(FLUID_WEBSITE_TORUS_API_TOKEN)"
|
||||
|
@ -121,7 +114,6 @@ stages:
|
|||
echo latestPipeline ${{ variables.latestPipeline }}
|
||||
echo n1Pipeline ${{ variables.n1Pipeline }}
|
||||
echo repoToTrigger ${{ variables.repoToTrigger }}
|
||||
echo shouldDeploy ${{ variables.shouldDeploy }}
|
||||
echo shouldRetainGuardianAssets ${{ variables.shouldRetainGuardianAssets }}
|
||||
echo publishGuardianBaselines ${{ variables.publishGuardianBaselines }}
|
||||
displayName: Show Variables
|
||||
|
@ -339,7 +331,12 @@ stages:
|
|||
displayName: 'Deploy website'
|
||||
pool: Small
|
||||
dependsOn: ['build', 'guardian', 'check_branch_version']
|
||||
condition: eq(dependencies.check_branch_version.outputs['check_branch_version.SetShouldDeploy.shouldDeploy'], 'true')
|
||||
condition: and(
|
||||
not(eq(parameters.deployOverride, 'skip')),
|
||||
or(
|
||||
eq(dependencies.check_branch_version.outputs['check_branch_version.SetShouldDeploy.shouldDeploy'], 'true'),
|
||||
eq(parameters.deployOverride, 'force')
|
||||
))
|
||||
jobs:
|
||||
- job: deploy_site
|
||||
displayName: 'Deploy website'
|
||||
|
@ -357,7 +354,6 @@ stages:
|
|||
|
||||
- task: AzureStaticWebApp@0
|
||||
displayName: 'Deploy website to ASWA'
|
||||
condition: eq(variables.shouldDeploy, true)
|
||||
inputs:
|
||||
skip_app_build: true # site was built in previous stage
|
||||
skip_api_build: true # api is written in js, no build needed
|
||||
|
|
Загрузка…
Ссылка в новой задаче