Skip to content

Commit 9dc8805

Browse files
authored
Always deploy (#557)
* Always deploy * test * Revert "test" This reverts commit 90165cd. * Fix conditions
1 parent 3ee7757 commit 9dc8805

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

.github/workflows/preview-build.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -130,11 +130,11 @@ jobs:
130130
strict: ${{ fromJSON(inputs.strict != '' && inputs.strict || 'true') }}
131131

132132
- uses: elastic/docs-builder/.github/actions/aws-auth@main
133-
if: steps.deployment.outputs.result
133+
if: ${{ !cancelled() && steps.deployment.outputs.result }}
134134

135135
- name: Upload to S3
136136
id: s3-upload
137-
if: steps.deployment.outputs.result
137+
if: ${{ !cancelled() && steps.deployment.outputs.result }}
138138
run: |
139139
aws s3 sync .artifacts/docs/html "s3://elastic-docs-v3-website-preview${PATH_PREFIX}" --delete
140140
aws cloudfront create-invalidation \
@@ -156,7 +156,7 @@ jobs:
156156
owner: context.repo.owner,
157157
repo: context.repo.repo,
158158
deployment_id: ${{ steps.deployment.outputs.result }},
159-
state: "${{ job.status == 'success' && 'success' || 'failure' }}",
159+
state: "${{ steps.s3-upload.outcome == 'success' && 'success' || 'failure' }}",
160160
environment_url: `https://docs-v3-preview.elastic.dev${process.env.PATH_PREFIX}`,
161161
log_url: `https://github.com/${context.repo.owner}/${context.repo.repo}/actions/runs/${context.runId}`,
162162
})

0 commit comments

Comments
 (0)