Skip to content

Commit 683dba9

Browse files
Avoid secondary umbrella archive collisions in actions (backport #8653) (backport #8669) (#8679)
* Avoid secondary umbrella archive collisions in actions (backport #8653) (#8669) * Avoid secondary umbrella archive collisions in actions (#8653) * Store secondary umbrella archives used in mixed version tests in a path which implies the erlang version used * Infer the secondary umbrella otp version from the url This avoids having two copies that need to be kept in sync (cherry picked from commit 464182a) # Conflicts: # .github/workflows/test-mixed-versions.yaml * Fixup backport conflicts --------- Co-authored-by: Rin Kuryloski <[email protected]> (cherry picked from commit 89f668a) # Conflicts: # .github/workflows/test-mixed-versions.yaml # bazel/bzlmod/secondary_umbrella.bzl * Fixup backport conflicts * Use 3.10.24 as the secondary umbrella --------- Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com> Co-authored-by: Rin Kuryloski <[email protected]>
1 parent 64dea55 commit 683dba9

File tree

2 files changed

+10
-9
lines changed

2 files changed

+10
-9
lines changed

.github/workflows/test-mixed-versions.yaml

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -31,9 +31,6 @@ jobs:
3131
ensure-mixed-version-archive:
3232
name: Prepare Artifacts
3333
runs-on: ubuntu-20.04
34-
env:
35-
# must be a version supported by builds on both this and the secondary umbrella branch
36-
otp_version_id: 25
3734
steps:
3835
- name: CHECKOUT REPOSITORY
3936
uses: actions/checkout@v3
@@ -59,9 +56,13 @@ jobs:
5956
fi
6057
echo "exists=${exists}" | tee $GITHUB_ENV
6158
59+
OTP_VERSION_ID=${ARCHIVE_URL#*secondary-umbrellas/rbe-}
60+
OTP_VERSION_ID=${OTP_VERSION_ID%*/package-generic-unix-for-mixed-version-testing-v*.tar.xz}
61+
echo "otp_version_id=${OTP_VERSION_ID}" | tee -a $GITHUB_OUTPUT
62+
6263
VERSION=${ARCHIVE_URL#*package-generic-unix-for-mixed-version-testing-v}
6364
VERSION=${VERSION%*.tar.xz}
64-
echo "version=${VERSION}" | tee $GITHUB_OUTPUT
65+
echo "version=${VERSION}" | tee -a $GITHUB_OUTPUT
6566
- name: CHECKOUT REPOSITORY (MIXED VERSION)
6667
if: env.exists != 'true'
6768
uses: actions/checkout@v3
@@ -96,15 +97,15 @@ jobs:
9697
9798
sed -i"_orig" -E "/APP_VERSION/ s/3\.[0-9]+\.[0-9]+/${{ steps.check.outputs.version }}/" rabbitmq.bzl
9899
bazelisk build :package-generic-unix \
99-
--config=rbe-${{ env.otp_version_id }} \
100+
--config=rbe-${{ steps.check.outputs.otp_version_id }} \
100101
--test_build \
101102
--verbose_failures
102103
103104
OUTPUT_DIR=${{ github.workspace }}/output
104-
mkdir ${OUTPUT_DIR}
105+
mkdir -p ${OUTPUT_DIR}/rbe-${{ steps.check.outputs.otp_version_id }}
105106
cp \
106107
bazel-bin/package-generic-unix.tar.xz \
107-
${OUTPUT_DIR}/package-generic-unix-for-mixed-version-testing-v${{ steps.check.outputs.version }}.tar.xz
108+
${OUTPUT_DIR}/rbe-${{ steps.check.outputs.otp_version_id }}/package-generic-unix-for-mixed-version-testing-v${{ steps.check.outputs.version }}.tar.xz
108109
- name: UPLOAD THE ARCHIVE TO S3
109110
if: env.exists != 'true'
110111
uses: jakejarvis/[email protected]

bazel/bzlmod/secondary_umbrella.bzl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,8 @@ def secondary_umbrella():
2828
name = "rabbitmq-server-generic-unix-3.10",
2929
build_file = "@//:BUILD.package_generic_unix",
3030
patch_cmds = [ADD_PLUGINS_DIR_BUILD_FILE],
31-
strip_prefix = "rabbitmq_server-3.10.14",
31+
strip_prefix = "rabbitmq_server-3.10.24",
3232
urls = [
33-
"https://rabbitmq-github-actions.s3.eu-west-1.amazonaws.com/secondary-umbrellas/package-generic-unix-for-mixed-version-testing-v3.10.14.tar.xz",
33+
"https://rabbitmq-github-actions.s3.eu-west-1.amazonaws.com/secondary-umbrellas/rbe-25/package-generic-unix-for-mixed-version-testing-v3.10.24.tar.xz",
3434
],
3535
)

0 commit comments

Comments
 (0)