Skip to content

Commit 8e30558

Browse files
yrodierebeikov
authored andcommitted
Fix upload of Develocity build scans
Don't tar them, as this was broken: we ended up uploading the build-scan-data directory instead of the tar, while still expecting a tar when dowloading, which made everything fail. We don't need tars anyway, as workflow artifacts are already zipped. (cherry picked from commit 6551aa5)
1 parent 9739428 commit 8e30558

File tree

2 files changed

+4
-10
lines changed

2 files changed

+4
-10
lines changed

.github/workflows/ci-report.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,11 +66,11 @@ jobs:
6666
run: |
6767
shopt -s nullglob # Don't run the loop below if there are no artifacts
6868
status=0
69+
mkdir -p ~/.gradle/
6970
for build_scan_data_directory in /tmp/downloaded-build-scan-data/*
7071
do
7172
rm -rf ~/.gradle/build-scan-data
72-
mkdir -p ~/.gradle/build-scan-data
73-
tar -xzf "$build_scan_data_directory/build-scan-data.tgz" -C ~/.gradle/build-scan-data \
73+
mv "$build_scan_data_directory" ~/.gradle/build-scan-data \
7474
&& ./gradlew --no-build-cache buildScanPublishPrevious || status=1
7575
done
7676
exit $status

.github/workflows/ci.yml

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -115,12 +115,9 @@ jobs:
115115
POPULATE_REMOTE_GRADLE_CACHE: ${{ github.event_name == 'push' && github.repository == 'hibernate/hibernate-orm' && 'true' || 'false' }}
116116
DEVELOCITY_ACCESS_KEY: "${{ secrets.DEVELOCITY_ACCESS_KEY }}"
117117

118-
# For jobs running on 'pull_request', tar and upload build scan data.
118+
# For jobs running on 'pull_request', upload build scan data.
119119
# The actual publishing must be done in a separate job (see ci-report.yml).
120120
# We don't write to the remote cache as that would be unsafe.
121-
- name: Tar build scan content pushed to subsequent jobs
122-
if: "${{ github.event_name == 'pull_request' && !cancelled() }}"
123-
run: tar -czf build-scan-data.tgz -C ~/.gradle/build-scan-data .
124121
- name: Upload GitHub Actions artifact for the Develocity build scan
125122
uses: actions/upload-artifact@v4
126123
if: "${{ github.event_name == 'pull_request' && !cancelled() }}"
@@ -220,13 +217,10 @@ jobs:
220217
RUNID: ${{ github.run_number }}
221218
run: ./ci/build-github.sh
222219
shell: bash
223-
# Tar and upload build scan data.
220+
# Upload build scan data.
224221
# The actual publishing must be done in a separate job (see ci-report.yml).
225222
# We don't write to the remote cache as that would be unsafe.
226223
# That's even on push, because we do not trust Atlas runners to hold secrets: they are shared infrastructure.
227-
- name: Tar build scan content pushed to subsequent jobs
228-
if: "${{ !cancelled() }}"
229-
run: tar -czf build-scan-data.tgz -C ~/.gradle/build-scan-data .
230224
- name: Upload GitHub Actions artifact for the Develocity build scan
231225
uses: actions/upload-artifact@v4
232226
if: "${{ !cancelled() }}"

0 commit comments

Comments
 (0)