mirror of
https://github.com/rustfs/rustfs.git
synced 2026-10-04 12:31:36 +00:00
fix(ci): publish version-tagged preview Docker images (#8068)
This commit is contained in:
@@ -203,8 +203,7 @@ IFS= read -r -d '' expected_docker_automatic_guard <<'EOF' || true
|
||||
github.event_name == 'workflow_dispatch' ||
|
||||
(github.event.workflow_run.conclusion == 'success' &&
|
||||
github.event.workflow_run.event == 'push' &&
|
||||
github.event.workflow_run.head_branch != 'main' &&
|
||||
!contains(github.event.workflow_run.head_branch, '-preview'))
|
||||
github.event.workflow_run.head_branch != 'main')
|
||||
EOF
|
||||
expected_docker_automatic_guard=${expected_docker_automatic_guard%$'\n'}
|
||||
require_job_if "$docker_workflow" "build-check" "$expected_docker_automatic_guard"
|
||||
@@ -216,15 +215,7 @@ require_line "$docker_workflow" ' SOURCE_REVISION="$(git rev-parse HEAD
|
||||
require_line "$docker_workflow" ' LABELS="$LABELS,org.opencontainers.image.revision=$SOURCE_REVISION"' "Docker revision label"
|
||||
require_absent "$docker_workflow" 'org.opencontainers.image.revision=${{ github.sha }}' "Docker revision must not use the workflow branch SHA"
|
||||
|
||||
docker_manual_guard=$(awk '
|
||||
$0 == " *-preview*)" { in_preview = 1 }
|
||||
in_preview { print }
|
||||
in_preview && $0 == " ;;" { exit }
|
||||
' "$docker_workflow")
|
||||
for assignment in 'build_type="preview"' 'is_prerelease=true' 'should_build=false' 'should_push=false'; do
|
||||
name="${assignment%%=*}"
|
||||
require_assignment "$docker_manual_guard" "$name" "${assignment#*=}"
|
||||
done
|
||||
python3 scripts/test_docker_workflow.py
|
||||
|
||||
IFS= read -r -d '' expected_helm_guard <<'EOF' || true
|
||||
if: |
|
||||
|
||||
Reference in New Issue
Block a user