File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -19,16 +19,17 @@ jobs:
1919 prepare :
2020 runs-on : ubuntu-latest
2121 outputs :
22- targets : ${{ steps.targets .outputs.matrix }}
22+ targets : ${{ steps.generate .outputs.targets }}
2323 steps :
2424 -
2525 name : Checkout
2626 uses : actions/checkout@v4
2727 -
28- name : Targets matrix
29- id : targets
30- run : |
31- echo "matrix=$(docker buildx bake validate --print | jq -cr '.group.validate.targets')" >> $GITHUB_OUTPUT
28+ name : List targets
29+ id : generate
30+ uses : docker/bake-action/subaction/list-targets@v6
31+ with :
32+ target : validate
3233
3334 validate :
3435 runs-on : ubuntu-latest
3940 matrix :
4041 target : ${{ fromJson(needs.prepare.outputs.targets) }}
4142 steps :
42- -
43- name : Checkout
44- uses : actions/checkout@v4
4543 -
4644 name : Validate
47- uses : docker/bake-action@v5
45+ uses : docker/bake-action@v6
4846 with :
4947 targets : ${{ matrix.target }}
Original file line number Diff line number Diff line change 1+ target "_common" {
2+ args = {
3+ BUILDKIT_CONTEXT_KEEP_GIT_DIR = 1
4+ }
5+ }
6+
17group "default" {
28 targets = [" build" ]
39}
@@ -17,6 +23,7 @@ target "build" {
1723}
1824
1925target "build-validate" {
26+ inherits = [" _common" ]
2027 dockerfile = " dev.Dockerfile"
2128 target = " build-validate"
2229 output = [" type=cacheonly" ]
@@ -41,6 +48,7 @@ target "vendor" {
4148}
4249
4350target "vendor-validate" {
51+ inherits = [" _common" ]
4452 dockerfile = " dev.Dockerfile"
4553 target = " vendor-validate"
4654 output = [" type=cacheonly" ]
You can’t perform that action at this time.
0 commit comments