Skip to content

Commit da88285

Browse files
committed
TCLOUD-4780: Prefix the run number so it's more readable
1 parent 3a992a9 commit da88285

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

.github/workflows/preview_create.yml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ permissions:
1414

1515
env:
1616
PR_NUMBER: ${{ github.event.number }}
17+
RUN_NUMBER: ${{ github.run_attempt }}
1718

1819
jobs:
1920

@@ -59,12 +60,12 @@ jobs:
5960

6061
- name: Upload website preview to S3 # put in the docs subfolder as we rely on that path in redirects
6162
run: |
62-
aws s3 sync ./build s3://tiny-cloud-antora-docs-preview/pr${PR_NUMBER}/${GITHUB_RUN_ATTEMPT}
63+
aws s3 sync ./build s3://tiny-cloud-antora-docs-preview/pr${PR_NUMBER}/run${RUN_NUMBER}
6364
6465
- name: Create redirects on S3
6566
run: |
66-
node .github/workflows/scripts/generate_redirects.mjs tiny-cloud-antora-docs-preview pr${PR_NUMBER}/${GITHUB_RUN_ATTEMPT}
67+
node .github/workflows/scripts/generate_redirects.mjs tiny-cloud-antora-docs-preview pr${PR_NUMBER}/run${RUN_NUMBER}
6768
6869
- name: Update pointer to current run output # put in the docs subfolder as we rely on that path in redirects
6970
run: |
70-
aws s3api put-object --bucket tiny-cloud-antora-docs-preview --key pr${PR_NUMBER}/index.html --body .github/workflows/scripts/empty.html --content-type text/html --metadata pointer=${GITHUB_RUN_ATTEMPT}
71+
aws s3api put-object --bucket tiny-cloud-antora-docs-preview --key pr${PR_NUMBER}/index.html --body .github/workflows/scripts/empty.html --content-type text/html --metadata pointer=run${RUN_NUMBER}

0 commit comments

Comments
 (0)