@@ -407,40 +407,51 @@ jobs:
407
407
service_account : github-plugin-ci-workflows@grafanalabs-workload-identity.iam.gserviceaccount.com
408
408
409
409
- name : Determine GCS artifacts paths
410
+ id : paths
410
411
run : |
411
412
plugin_version='${{ fromJSON(needs.ci.outputs.plugin).version }}'
412
413
gcs_artifacts_release_base="${{ env.GCS_ARTIFACTS_BUCKET }}/${{ fromJSON(needs.ci.outputs.plugin).id }}/release"
413
414
{
415
+ echo "gcs_artifacts_release_base=$gcs_artifacts_release_base"
414
416
echo "gcs_artifacts_release_path_latest=$gcs_artifacts_release_base/latest"
415
417
echo "gcs_artifacts_release_path_tag=$gcs_artifacts_release_base/$plugin_version"
416
418
fn=$(basename ${{ needs.ci.outputs.gcs-universal-zip-url-commit }})
417
419
latest_fn=${fn//${{ fromJSON(needs.ci.outputs.plugin).version }}/latest}
418
420
if [ "${{ matrix.platform }}" == 'any' ]; then
419
421
echo "gcs_upload_glob=$fn*"
420
- echo "gcs_upload_glob_latest=$latest_fn* "
422
+ echo "gcs_upload_glob_latest=$latest_fn"
421
423
else
422
424
# strip the extension (.zip) and append the platform instead
423
425
echo "gcs_upload_glob=${fn%.*}.${{ matrix.platform }}*"
424
426
echo "gcs_upload_glob_latest=${latest_fn%.*}.${{ matrix.platform }}*"
425
427
fi
426
- } >> "$GITHUB_ENV "
428
+ } >> "$GITHUB_OUTPUT "
427
429
shell : bash
428
430
429
431
- name : Upload GCS release artifact (tag)
430
432
uses :
google-github-actions/[email protected]
431
433
with :
432
434
path : /tmp/dist-artifacts
433
- glob : ${{ env .gcs_upload_glob }}
434
- destination : " ${{ env .gcs_artifacts_release_path_tag }}/${{ matrix.platform }}"
435
+ glob : ${{ steps.paths.outputs .gcs_upload_glob }}
436
+ destination : " ${{ steps.paths.outputs .gcs_artifacts_release_path_tag }}/${{ matrix.platform }}"
435
437
parent : false
436
438
process_gcloudignore : false
437
439
438
440
- name : Upload GCS release artifact (latest)
439
441
uses :
google-github-actions/[email protected]
440
442
with :
441
443
path : /tmp/dist-artifacts-latest
442
- glob : ${{ env.gcs_upload_glob_latest }}
443
- destination : " ${{ env.gcs_artifacts_release_path_latest }}/${{ matrix.platform }}"
444
+ glob : ${{ steps.paths.outputs.gcs_upload_glob_latest }}
445
+ destination : " ${{ steps.paths.outputs.gcs_artifacts_release_path_latest }}/${{ matrix.platform }}"
446
+ parent : false
447
+ process_gcloudignore : false
448
+
449
+ - name : Upload GCS release artifacst (latest, any)
450
+ if : ${{ matrix.platform == 'any' }}
451
+ uses :
google-github-actions/[email protected]
452
+ with :
453
+ path : /tmp/dist-artifacts-latest/${{ steps.paths.outputs.gcs_upload_glob_latest }}
454
+ destination : " ${{ steps.paths.outputs.gcs_artifacts_release_base }}/${{ fromJSON(needs.ci.outputs.plugin).id }}-latest.zip"
444
455
parent : false
445
456
process_gcloudignore : false
446
457
0 commit comments