Skip to content

Commit 7250955

Browse files
committed
Use docker socket from docker/setup-docker-action
1 parent 5982370 commit 7250955

File tree

1 file changed

+10
-16
lines changed

1 file changed

+10
-16
lines changed

.github/workflows/moby-latest.yml

Lines changed: 10 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -13,37 +13,31 @@ jobs:
1313
test_docker:
1414
strategy:
1515
matrix:
16-
install-docker-type: ["STABLE", "ROOTLESS", "ROOTFUL"]
17-
name: "Core tests using Docker ${{ matrix.install-docker-type }}"
16+
include:
17+
- { install-docker-type: "STABLE", channel: stable, rootless: false }
18+
- { install-docker-type: "ROOTLESS", channel: stable, rootless: true }
19+
- { install-docker-type: "ROOTFUL", channel: test, rootless: false }
20+
name: "Core tests using Docker ${{ matrix.install-docker-type }} (channel ${{ matrix.channel }})"
1821
runs-on: ubuntu-22.04
1922
continue-on-error: true
2023
steps:
2124
- uses: actions/checkout@v4
2225
- uses: ./.github/actions/setup-build
2326

2427
- name: Install Stable Docker
25-
if: ${{ matrix.install-docker-type == 'STABLE' }}
28+
id: setup_docker
2629
uses: docker/setup-docker-action@v4
2730
with:
28-
channel: stable
29-
30-
- name: Install Docker from the TEST channel
31-
if: ${{ matrix.install-docker-type == 'ROOTFUL' }}
32-
uses: docker/setup-docker-action@v4
33-
with:
34-
channel: test
35-
36-
- name: Setup rootless Docker
37-
if: ${{ matrix.install-docker-type == 'ROOTLESS' }}
38-
uses: docker/setup-docker-action@v4
39-
with:
40-
rootless: true
31+
channel: ${{ matrix.channel }}
32+
rootless: ${{ matrix.rootless }}
4133

4234
- name: Check Docker version
4335
run: docker version
4436

4537
- name: Build with Gradle
4638
run: ./gradlew cleanTest --no-daemon --continue --scan -Dscan.tag.DOCKER_${{ matrix.install-docker-type }} testcontainers:test -Dorg.gradle.caching=false
39+
env:
40+
DOCKER_HOST: ${{steps.setup_docker.outputs.sock}}
4741
- uses: ./.github/actions/setup-junit-report
4842

4943
- name: Notify to Slack on failures

0 commit comments

Comments
 (0)