Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Avoid using ephemeral runners in publishing workflows since ephemeral runners are new feature and using them during the release can complicate the process. #3122

Merged
merged 1 commit into from
Feb 11, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 10 additions & 2 deletions .github/workflows/go-cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,16 @@ jobs:
id: load-platform-matrix
shell: bash
run: |
# Get the matrix from the matrix.json file, without the object that has the IMAGE key
export "PLATFORM_MATRIX=$(jq 'map(select(.PACKAGE_MANAGERS | contains(["pkg_go_dev"])))' < .github/json_matrices/build-matrix.json | jq -c .)"
# Filter entries with pkg_go_dev in PACKAGE_MANAGERS and remove "ephemeral" from RUNNER
export PLATFORM_MATRIX=$(jq 'map(
select(.PACKAGE_MANAGERS != null and (.PACKAGE_MANAGERS | contains(["pkg_go_dev"])))
| .RUNNER = (
if (.RUNNER | type == "array")
then (.RUNNER | map(select(. != "ephemeral")))
else .RUNNER
end
)
)' < .github/json_matrices/build-matrix.json | jq -c .)
echo "PLATFORM_MATRIX=${PLATFORM_MATRIX}" >> $GITHUB_OUTPUT

validate-release-version:
Expand Down
12 changes: 10 additions & 2 deletions .github/workflows/java-cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,16 @@ jobs:
id: load-platform-matrix
shell: bash
run: |
# Get the matrix from the matrix.json file, without the object that has the IMAGE key
export "PLATFORM_MATRIX=$(jq 'map(select(.PACKAGE_MANAGERS | contains(["maven"])))' < .github/json_matrices/build-matrix.json | jq -c .)"
# Filter entries with maven in PACKAGE_MANAGERS and remove "ephemeral" from RUNNER
export PLATFORM_MATRIX=$(jq 'map(
select(.PACKAGE_MANAGERS != null and (.PACKAGE_MANAGERS | contains(["maven"])))
| .RUNNER = (
if (.RUNNER | type == "array")
then (.RUNNER | map(select(. != "ephemeral")))
else .RUNNER
end
)
)' < .github/json_matrices/build-matrix.json | jq -c .)
echo "PLATFORM_MATRIX=${PLATFORM_MATRIX}" >> $GITHUB_OUTPUT

set-release-version:
Expand Down
12 changes: 10 additions & 2 deletions .github/workflows/npm-cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,16 @@ jobs:
id: load-platform-matrix
shell: bash
run: |
# Get the matrix from the matrix.json file, without the object that has the IMAGE key
export "PLATFORM_MATRIX=$(jq 'map(select(.PACKAGE_MANAGERS != null and (.PACKAGE_MANAGERS | contains(["npm"]))))' < .github/json_matrices/build-matrix.json | jq -c .)"
# Filter entries with npm in PACKAGE_MANAGERS and remove "ephemeral" from RUNNER
export PLATFORM_MATRIX=$(jq 'map(
select(.PACKAGE_MANAGERS != null and (.PACKAGE_MANAGERS | contains(["npm"])))
| .RUNNER = (
if (.RUNNER | type == "array")
then (.RUNNER | map(select(. != "ephemeral")))
else .RUNNER
end
)
)' < .github/json_matrices/build-matrix.json | jq -c .)
echo "PLATFORM_MATRIX=${PLATFORM_MATRIX}" >> $GITHUB_OUTPUT

publish-binaries:
Expand Down
12 changes: 10 additions & 2 deletions .github/workflows/pypi-cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,16 @@ jobs:
id: load-platform-matrix
shell: bash
run: |
# Get the matrix from the matrix.json file, without the object that has the IMAGE key
export "PLATFORM_MATRIX=$(jq 'map(select(.PACKAGE_MANAGERS != null and (.PACKAGE_MANAGERS | contains(["pypi"]))))' < .github/json_matrices/build-matrix.json | jq -c .)"
# Filter entries with pypi in PACKAGE_MANAGERS and remove "ephemeral" from RUNNER
export PLATFORM_MATRIX=$(jq 'map(
select(.PACKAGE_MANAGERS != null and (.PACKAGE_MANAGERS | contains(["pypi"])))
| .RUNNER = (
if (.RUNNER | type == "array")
then (.RUNNER | map(select(. != "ephemeral")))
else .RUNNER
end
)
)' < .github/json_matrices/build-matrix.json | jq -c .)
echo "PLATFORM_MATRIX=${PLATFORM_MATRIX}" >> $GITHUB_OUTPUT

start-self-hosted-runner:
Expand Down
Loading