Skip to content

Commit cd343d0

Browse files
Merge remote-tracking branch 'origin/main' into new-grid-based-interactive-layout
# Conflicts: # dotcom-rendering/src/layouts/InteractiveLayout.tsx Co-authored-by: frederickobrien <11380557+frederickobrien@users.noreply.github.com>
2 parents ee74010 + 89a6570 commit cd343d0

198 files changed

Lines changed: 13757 additions & 9135 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/ab-testing-ci.yml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ jobs:
2020
run:
2121
working-directory: ab-testing
2222
steps:
23-
- uses: actions/checkout@v6
23+
- uses: actions/checkout@v7
2424

2525
- name: Set up Node environment
2626
uses: ./.github/actions/setup-node-env
@@ -42,7 +42,7 @@ jobs:
4242
FASTLY_API_TOKEN: ${{ secrets.FASTLY_PROD_API_TOKEN }}
4343
needs: [ab-testing-checks]
4444
steps:
45-
- uses: actions/checkout@v6
45+
- uses: actions/checkout@v7
4646

4747
- name: Set up Node environment
4848
uses: ./.github/actions/setup-node-env
@@ -68,7 +68,7 @@ jobs:
6868
contents: read
6969
needs: [ab-testing-checks]
7070
steps:
71-
- uses: actions/checkout@v6
71+
- uses: actions/checkout@v7
7272

7373
- name: Set up Node environment
7474
uses: ./.github/actions/setup-node-env
@@ -93,7 +93,7 @@ jobs:
9393
contents: read
9494
needs: [ab-testing-checks]
9595
steps:
96-
- uses: actions/checkout@v6
96+
- uses: actions/checkout@v7
9797

9898
- name: Set up Node environment
9999
uses: ./.github/actions/setup-node-env
@@ -123,7 +123,7 @@ jobs:
123123
contents: read
124124
needs: [ab-testing-checks]
125125
steps:
126-
- uses: actions/checkout@v6
126+
- uses: actions/checkout@v7
127127

128128
- name: Set up Node environment
129129
uses: ./.github/actions/setup-node-env
@@ -157,7 +157,7 @@ jobs:
157157

158158
steps:
159159
- name: Checkout
160-
uses: actions/checkout@v6
160+
uses: actions/checkout@v7
161161
with:
162162
fetch-depth: 0
163163
persist-credentials: false
@@ -196,7 +196,7 @@ jobs:
196196
run: pnpm --filter @guardian/ab-testing-cdk synth
197197

198198
- name: Riff-Raff Upload
199-
uses: guardian/actions-riff-raff@v4.3.4
199+
uses: guardian/actions-riff-raff@v4.3.6
200200
with:
201201
roleArn: ${{ secrets.GU_RIFF_RAFF_ROLE_ARN }}
202202
githubToken: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/build-check.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ name: DCR Build Check
22
on:
33
merge_group:
44
types: [checks_requested]
5-
push:
5+
pull_request:
66
paths-ignore:
77
- 'dotcom-rendering/docs/**'
88

@@ -12,7 +12,7 @@ jobs:
1212
runs-on: ubuntu-latest
1313
steps:
1414
- name: Checkout code
15-
uses: actions/checkout@v6
15+
uses: actions/checkout@v7
1616

1717
- name: Set up Node environment
1818
uses: ./.github/actions/setup-node-env

.github/workflows/bundle-analyser.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ jobs:
99
runs-on: ubuntu-latest
1010
steps:
1111
- name: Checkout code
12-
uses: actions/checkout@v6
12+
uses: actions/checkout@v7
1313

1414
- name: Set up Node environment
1515
uses: ./.github/actions/setup-node-env

.github/workflows/check-chromatic-paths.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,10 @@ jobs:
1818
outputs:
1919
relevant: ${{ steps.filter.outputs.relevant }}
2020
steps:
21-
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6
21+
- uses: actions/checkout@v7
2222
with:
2323
fetch-depth: 0
24-
- uses: dorny/paths-filter@fbd0ab8f3e69293af611ebaee6363fc25e6d187d # v4
24+
- uses: dorny/paths-filter@ceb8a2b8f2d89434be7ff52d3de7ec3738c5cc9d # v4
2525
id: filter
2626
with:
2727
# Only run Chromatic if files that affect visual rendering have changed.

.github/workflows/check-islands.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ jobs:
99
runs-on: ubuntu-latest
1010
steps:
1111
- name: Checkout code
12-
uses: actions/checkout@v6
12+
uses: actions/checkout@v7
1313

1414
- name: Set up Node environment
1515
uses: ./.github/actions/setup-node-env

.github/workflows/cicd.yml

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,19 +23,24 @@ jobs:
2323
production-image-digest: ${{ needs.production-container.outputs.imageDigest }}
2424

2525
prettier:
26+
if: github.ref != 'refs/heads/main'
2627
uses: ./.github/workflows/prettier.yml
2728

2829
jest:
30+
if: github.ref != 'refs/heads/main'
2931
uses: ./.github/workflows/jest.yml
3032

3133
lint:
34+
if: github.ref != 'refs/heads/main'
3235
uses: ./.github/workflows/lint.yml
3336

3437
islands:
38+
if: github.ref != 'refs/heads/main'
3539
uses: ./.github/workflows/check-islands.yml
3640

3741
playwright:
3842
needs: [container]
43+
if: github.ref != 'refs/heads/main'
3944
uses: ./.github/workflows/playwright.yml
4045
with:
4146
container-image: ${{ needs.container.outputs.container-image }}
@@ -46,7 +51,16 @@ jobs:
4651
contents: read
4752
pull-requests: write # required by riff-raff action
4853
needs: [container, islands, prettier, jest, lint, playwright]
49-
if: github.event_name == 'push' # We don't need a riff-raff deployment for merge_group events
54+
# We don't need a riff-raff deployment for merge_group events.
55+
# `!cancelled()` forces this job to be evaluated even when some of the
56+
# `needs` jobs are skipped (the checks are skipped on push to main), and
57+
# `!contains(needs.*.result, 'failure')` still blocks publish if any needed
58+
# job actually failed. Without a status-check function here, a skipped
59+
# dependency would cause this job to be skipped as well.
60+
if: >-
61+
!cancelled() &&
62+
!contains(needs.*.result, 'failure') &&
63+
github.event_name == 'push'
5064
uses: ./.github/workflows/publish.yml
5165
with:
5266
container-image: ${{ needs.container.outputs.container-image }}

.github/workflows/container-production.yml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,8 @@ jobs:
2121
id: get-build-facts
2222

2323
build-production-image:
24-
runs-on: ubuntu-latest
24+
# ECS tasks run on ARM, so we use the arm runner to natively build the containaer image (rather than rely on emulation)
25+
runs-on: ubuntu-24.04-arm
2526
needs:
2627
- facts
2728
permissions:
@@ -30,12 +31,12 @@ jobs:
3031
outputs:
3132
imageDigest: ${{ steps.publish-image.outputs.imageDigest }}
3233
steps:
33-
- uses: actions/checkout@v6.0.2
34+
- uses: actions/checkout@v7
3435
- name: Add commit hash for PRout
3536
working-directory: dotcom-rendering
3637
run: echo 'export const GIT_COMMIT_HASH = "${{ needs.facts.outputs.commitSha }}";' > src/server/prout.ts
3738
- name: Build image
38-
run: docker buildx build -f Production.dockerfile -t ${{ github.repository }}:latest .
39+
run: docker buildx build --platform linux/arm64 -f Production.dockerfile -t ${{ github.repository }}:latest .
3940
- name: Publish Image
4041
uses: guardian/actions-publish-image@v0.0.2
4142
id: publish-image

.github/workflows/container.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ jobs:
2424

2525
steps:
2626
- name: Checkout repository
27-
uses: actions/checkout@v6
27+
uses: actions/checkout@v7
2828

2929
- name: Set up Node environment
3030
uses: ./.github/actions/setup-node-env

.github/workflows/dcr-chromatic.yml

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,6 @@ name: DCR Chromatic 👓
33
on:
44
merge_group:
55
types: [checks_requested]
6-
push:
7-
branches: [main]
86
pull_request:
97
types: [opened, labeled, synchronize]
108

@@ -21,24 +19,26 @@ jobs:
2119
# reported. When skipping, Chromatic posts a passing status without building Storybook.
2220
steps:
2321
- name: Checkout - On Pull Request
24-
uses: actions/checkout@v6
22+
uses: actions/checkout@v7
2523
if: ${{ github.event_name == 'pull_request'}}
2624
with:
2725
fetch-depth: 0
2826
# By default the pull_request event will run on a ephermeral merge commit which simulates a merge between the pull request
2927
# and the target branch. This can cause issues with Chromatic https://www.chromatic.com/docs/turbosnap#github-pullrequest-triggers
3028
# Hopefully by checking out the HEAD commit of a PR instead of the merge commit we can avoid some of those issues.
31-
ref: ${{ github.event.pull_request.head.sha }}
29+
# We fallback to github.sha in case the workflow is triggered by a merge_group event, which doesn't have a pull_request object, see https://www.chromatic.com/docs/faq/merge-queue-ref/
30+
ref: ${{ github.event.pull_request.head.ref || github.sha }}
31+
3232
- name: Checkout - On Push Event
33-
uses: actions/checkout@v6
34-
if: ${{ github.event_name == 'push' || github.event_name == 'merge_group' }}
33+
uses: actions/checkout@v7
34+
if: ${{ github.event_name == 'merge_group' }}
3535
with:
3636
fetch-depth: 0
3737

3838
- name: Set up Node environment
3939
# Only needed for a full Chromatic run.
4040
if: |
41-
(github.event_name == 'push' || github.event_name == 'merge_group') ||
41+
github.event_name == 'merge_group' ||
4242
(github.event_name == 'pull_request' &&
4343
contains(github.event.pull_request.labels.*.name, 'run_chromatic'))
4444
uses: ./.github/actions/setup-node-env
@@ -51,7 +51,7 @@ jobs:
5151
NODE_OPTIONS: '--max_old_space_size=4096'
5252
uses: chromaui/action@v17.4.1
5353
if: |
54-
(github.event_name == 'push' || github.event_name == 'merge_group') ||
54+
github.event_name == 'merge_group' ||
5555
(github.event_name == 'pull_request' &&
5656
contains(github.event.pull_request.labels.*.name, 'run_chromatic')) ||
5757
(github.event_name == 'pull_request' && needs.check-paths.outputs.relevant != 'true')

.github/workflows/delete-old-packages.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,4 +25,4 @@ jobs:
2525
package-name: 'dotcom-rendering'
2626
package-type: 'container'
2727
min-versions-to-keep: ${{ env.NUM_OF_VERSIONS_TO_KEEP }}
28-
ignore-versions: main
28+
delete-only-untagged-versions: 'true'

0 commit comments

Comments
 (0)