Skip to content

Commit e611136

Browse files
committed
TCLOUD-4780: Improve output prefix
1 parent da88285 commit e611136

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

.github/workflows/preview_create.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@ permissions:
1313
id-token: write
1414

1515
env:
16-
PR_NUMBER: ${{ github.event.number }}
17-
RUN_NUMBER: ${{ github.run_attempt }}
16+
PR: pr-${{ github.event.number }}
17+
RUN: run-${{ github.run_number }}-${{ github.run_attempt }}
1818

1919
jobs:
2020

@@ -60,12 +60,12 @@ jobs:
6060

6161
- name: Upload website preview to S3 # put in the docs subfolder as we rely on that path in redirects
6262
run: |
63-
aws s3 sync ./build s3://tiny-cloud-antora-docs-preview/pr${PR_NUMBER}/run${RUN_NUMBER}
63+
aws s3 sync ./build s3://tiny-cloud-antora-docs-preview/${PR}/{RUN}
6464
6565
- name: Create redirects on S3
6666
run: |
67-
node .github/workflows/scripts/generate_redirects.mjs tiny-cloud-antora-docs-preview pr${PR_NUMBER}/run${RUN_NUMBER}
67+
node .github/workflows/scripts/generate_redirects.mjs tiny-cloud-antora-docs-preview ${PR}/${RUN}
6868
6969
- name: Update pointer to current run output # put in the docs subfolder as we rely on that path in redirects
7070
run: |
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}
71+
aws s3api put-object --bucket tiny-cloud-antora-docs-preview --key ${PR}/index.html --body .github/workflows/scripts/empty.html --content-type text/html --metadata pointer=${RUN}

0 commit comments

Comments
 (0)