Skip to content

Commit 0aee559

Browse files
authored
ci: use appropriate cache paths for each ci jobs (elastic#15593)
dependency path defaults to the go.sum in the root folder. use the systemtest go.sum for systemtests and tools go.sum for packaging jobs remove systemtest output junit file logic used back in the jenkins job
1 parent d811d76 commit 0aee559

File tree

2 files changed

+11
-11
lines changed

2 files changed

+11
-11
lines changed

.github/workflows/ci.yml

+10-11
Original file line numberDiff line numberDiff line change
@@ -61,21 +61,14 @@ jobs:
6161
with:
6262
go-version-file: systemtest/go.mod
6363
cache: true
64+
cache-dependency-path: |
65+
go.sum
66+
systemtest/go.sum
6467
- run: docker compose up -d
6568
- env:
6669
GOTESTFLAGS: "-v -json"
67-
OUTPUT_JSON_FILE: "build/TEST-go-system_tests.out.json"
68-
OUTPUT_JUNIT_FILE: "build/TEST-go-system_tests.xml"
6970
GH_TOKEN: ${{ github.token }}
70-
run: |
71-
go run -modfile=tools/go.mod gotest.tools/gotestsum \
72-
--no-color -f standard-quiet --jsonfile "$OUTPUT_JSON_FILE" --junitfile "$OUTPUT_JUNIT_FILE" \
73-
--raw-command -- make system-test
74-
- uses: actions/upload-artifact@v4 # upload test results
75-
if: ${{ always() }} # run this step even if previous step failed
76-
with:
77-
name: test-results
78-
path: 'build/*.xml'
71+
run: make system-test
7972

8073
test-package:
8174
runs-on: ubuntu-latest
@@ -85,6 +78,9 @@ jobs:
8578
with:
8679
go-version-file: go.mod
8780
cache: false
81+
cache-dependency-path: |
82+
go.sum
83+
tools/go.sum
8884
- run: make package-snapshot
8985
env:
9086
GH_TOKEN: ${{ github.token }}
@@ -101,6 +97,9 @@ jobs:
10197
with:
10298
go-version-file: go.mod
10399
cache: false
100+
cache-dependency-path: |
101+
go.sum
102+
tools/go.sum
104103
- name: Log in to the Elastic Container registry
105104
uses: docker/login-action@9780b0c442fbb1117ed29e0efdff1e18412f7567 # v3.3.0
106105
with:

.github/workflows/setup-cluster-env/action.yml

+1
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ runs:
99
- uses: actions/setup-go@v5
1010
with:
1111
go-version-file: go.mod
12+
cache: true
1213
cache-dependency-path: |
1314
go.sum
1415
tools/go.sum

0 commit comments

Comments
 (0)