فهرست منبع

Workflows: Fix github.ref_name sometimes is empty when building Docker images (#4937)

From https://github.com/XTLS/Xray-core/pull/4809
Meow 3 ماه پیش
والد
کامیت
66025f2889
1فایلهای تغییر یافته به همراه3 افزوده شده و 0 حذف شده
  1. 3 0
      .github/workflows/docker.yml

+ 3 - 0
.github/workflows/docker.yml

@@ -38,6 +38,9 @@ jobs:
           if [[ -z "$SOURCE_TAG" ]]; then
             SOURCE_TAG="${{ github.ref_name }}"
           fi
+          if [[ -z "$SOURCE_TAG" ]]; then
+            SOURCE_TAG="${{ github.event.release.tag_name }}"
+          fi
 
           if [[ -z "$SOURCE_TAG" ]]; then
             echo "Error: Could not determine a valid tag source. Input tag and context tag (github.ref_name) are both empty."