File tree Expand file tree Collapse file tree 3 files changed +22
-1
lines changed Expand file tree Collapse file tree 3 files changed +22
-1
lines changed Original file line number Diff line number Diff line change 1616
1717 steps :
1818 - uses : actions/checkout@v4
19+
20+ # 2) enable BuildKit
21+ - name : Set up Docker Buildx
22+ uses : docker/setup-buildx-action@v2
23+
24+ # 3) build & cache the client image
25+ - name : Build & cache client image
26+ uses : docker/build-push-action@v3
27+ with :
28+ context : .
29+ file : Dockerfile
30+ load : true # so the image is available locally
31+ push : false
32+ cache-from : type=gha
33+ cache-to : type=gha,mode=max
34+ build-args : PHP_VERSION=${{ matrix.php }}
35+ tags : integration-client:${{ matrix.php }}
36+
37+
1938 - name : Populate .env
2039 run : |
2140 echo "PHP_VERSION=${{ matrix.php }}" > .env
3756
3857 - name : Run integration tests
3958 run : |
40- docker compose up -d --build -- remove-orphans --wait \
59+ docker compose up -d --remove-orphans --wait --no-build \
4160 server1 \
4261 server2 \
4362 server3 \
Original file line number Diff line number Diff line change @@ -28,6 +28,7 @@ networks:
2828
2929services :
3030 client :
31+ image : " integration-client:${PHP_VERSION-8.1}"
3132 build :
3233 context : .
3334 dockerfile : Dockerfile
Original file line number Diff line number Diff line change @@ -22,6 +22,7 @@ x-definitions:
2222 - .env
2323 x-common-php :
2424 &common-php
25+ image : " integration-client:${PHP_VERSION-8.1}"
2526 build :
2627 context : .
2728 dockerfile : Dockerfile
You can’t perform that action at this time.
0 commit comments