Skip to content

Commit 91b7318

Browse files
authored
Merge pull request #4231 from thaJeztah/23.0_backport_test_fixes
[23.0 backport] ci: add validation for generated docs, bump docker/bake-action
2 parents ced769f + 17357a7 commit 91b7318

3 files changed

Lines changed: 25 additions & 8 deletions

File tree

.github/workflows/build.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ jobs:
5858
uses: docker/setup-buildx-action@v2
5959
-
6060
name: Build
61-
uses: docker/bake-action@v2
61+
uses: docker/bake-action@v3
6262
with:
6363
targets: ${{ matrix.target }}
6464
set: |
@@ -121,7 +121,7 @@ jobs:
121121
uses: docker/setup-buildx-action@v2
122122
-
123123
name: Build
124-
uses: docker/bake-action@v2
124+
uses: docker/bake-action@v3
125125
with:
126126
targets: plugins-cross
127127
set: |

.github/workflows/test.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ jobs:
2626
uses: docker/setup-buildx-action@v2
2727
-
2828
name: Test
29-
uses: docker/bake-action@v2
29+
uses: docker/bake-action@v3
3030
with:
3131
targets: test-coverage
3232
-

.github/workflows/validate.yml

Lines changed: 22 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -29,14 +29,33 @@ jobs:
2929
-
3030
name: Checkout
3131
uses: actions/checkout@v3
32-
with:
33-
fetch-depth: 0
3432
-
3533
name: Run
36-
uses: docker/bake-action@v2
34+
uses: docker/bake-action@v3
3735
with:
3836
targets: ${{ matrix.target }}
3937

38+
# check that the generated Markdown and the checked-in files match
39+
validate-md:
40+
runs-on: ubuntu-20.04
41+
steps:
42+
-
43+
name: Checkout
44+
uses: actions/checkout@v3
45+
-
46+
name: Generate
47+
shell: 'script --return --quiet --command "bash {0}"'
48+
run: |
49+
make -f docker.Makefile mddocs
50+
-
51+
name: Validate
52+
run: |
53+
if [[ $(git diff --stat) != '' ]]; then
54+
echo 'fail: generated files do not match checked-in files'
55+
git --no-pager diff
56+
exit 1
57+
fi
58+
4059
validate-make:
4160
runs-on: ubuntu-20.04
4261
strategy:
@@ -49,8 +68,6 @@ jobs:
4968
-
5069
name: Checkout
5170
uses: actions/checkout@v3
52-
with:
53-
fetch-depth: 0
5471
-
5572
name: Run
5673
shell: 'script --return --quiet --command "bash {0}"'

0 commit comments

Comments
 (0)