From 0bb97846c2fe44bcec9af6215bda55676a312163 Mon Sep 17 00:00:00 2001 From: Daniel Moody Date: Thu, 22 Jan 2026 13:58:56 -0600 Subject: [PATCH] SERVER-106413 add rhel10 variant (#46800) Co-authored-by: Cloud User GitOrigin-RevId: 653c6f01abc2762500a7cedfdb0e6dbdad231623 --- MODULE.bazel.lock | 2 +- bazel/platforms/BUILD.bazel | 2 + .../platforms/remote_execution_containers.bzl | 5 + .../rhel10/dockerfile | 26 +++ bazel/toolchains/cc/mongo_linux/mongo_gdb.bzl | 70 +++++- .../cc/mongo_linux/mongo_gdb_version_v5.bzl | 10 + .../mongo_toolchain_version_v5.bzl | 10 + bazel/utils.bzl | 1 + buildscripts/mongo_toolchain.py | 3 + buildscripts/package_test.py | 6 + buildscripts/packager.py | 1 + buildscripts/packager_enterprise.py | 14 +- etc/evergreen_yml_components/definitions.yml | 4 + .../tasks/compile_tasks_nightly.yml | 2 + .../tasks/misc_tasks.yml | 36 ++++ .../variants/rhel/test_release.yml | 203 ++++++++++++++++++ evergreen/package.sh | 2 + rpm/mongodb-enterprise-init.spec | 9 +- rpm/mongodb-enterprise-unstable-init.spec | 9 +- rpm/mongodb-enterprise-unstable.spec | 9 +- rpm/mongodb-enterprise.spec | 9 +- rpm/mongodb-org-init.spec | 9 +- rpm/mongodb-org-unstable-init.spec | 9 +- rpm/mongodb-org-unstable.spec | 9 +- rpm/mongodb-org.spec | 9 +- src/third_party/librdkafka/BUILD.bazel | 5 +- 26 files changed, 448 insertions(+), 26 deletions(-) create mode 100644 bazel/remote_execution_container/rhel10/dockerfile diff --git a/MODULE.bazel.lock b/MODULE.bazel.lock index 5ae7065d8c9..3529e7abac0 100644 --- a/MODULE.bazel.lock +++ b/MODULE.bazel.lock @@ -211,7 +211,7 @@ "moduleExtensions": { "//bazel:bzlmod.bzl%setup_mongo_python_toolchains": { "general": { - "bzlTransitiveDigest": "fy26F18Xxy4wMeHucToHUJoIIIzEgTo84vEw2RmzBi8=", + "bzlTransitiveDigest": "Dwxo/QwDjQGgn4U/fsgKDKiVQL70RREiOtzSOUI+Uss=", "usagesDigest": "bUxjq9n+hj2YwYT/lcSP4lHyQ2GVy5JpFgSmddUqUZg=", "recordedFileInputs": {}, "recordedDirentsInputs": {}, diff --git a/bazel/platforms/BUILD.bazel b/bazel/platforms/BUILD.bazel index e15dffce677..fa85fdfd675 100644 --- a/bazel/platforms/BUILD.bazel +++ b/bazel/platforms/BUILD.bazel @@ -29,6 +29,7 @@ constraint_setting(name = "distro") "debian12", "rhel8", "rhel9", + "rhel10", "suse12", "suse15", ] @@ -52,6 +53,7 @@ constraint_setting(name = "distro") "debian12", "rhel8", "rhel9", + "rhel10", "suse15", ] for cache_silo in [ diff --git a/bazel/platforms/remote_execution_containers.bzl b/bazel/platforms/remote_execution_containers.bzl index ffd82c56198..10756604fde 100644 --- a/bazel/platforms/remote_execution_containers.bzl +++ b/bazel/platforms/remote_execution_containers.bzl @@ -37,6 +37,11 @@ REMOTE_EXECUTION_CONTAINERS = { "dockerfile": "bazel/remote_execution_container/rhel93/Dockerfile", "web-url": "https://quay.io/repository/mongodb/bazel-remote-execution/manifest/sha256:908f34e965161a34088e212f0a09250a1e601f0400472e1ae2beabdfa377b5e5", }, + "rhel10": { + "container-url": "docker://quay.io/mongodb/bazel-remote-execution@sha256:89fe0c2909ca20da05301f56156becd78a9f4b6eedac8e1f31768453acf58afb", + "dockerfile": "bazel/remote_execution_container/rhel10/Dockerfile", + "web-url": "https://quay.io/repository/mongodb/bazel-remote-execution/manifest/sha256:89fe0c2909ca20da05301f56156becd78a9f4b6eedac8e1f31768453acf58afb", + }, "suse15": { "container-url": "docker://quay.io/mongodb/bazel-remote-execution@sha256:5295903271760e7e555590fb8858c1f7a74d3c0dd109d8ca200130ce07343ea4", "dockerfile": "bazel/remote_execution_container/suse/Dockerfile", diff --git a/bazel/remote_execution_container/rhel10/dockerfile b/bazel/remote_execution_container/rhel10/dockerfile new file mode 100644 index 00000000000..d5464d44e06 --- /dev/null +++ b/bazel/remote_execution_container/rhel10/dockerfile @@ -0,0 +1,26 @@ +# DO NOT EDIT. +# +# This Dockerfile is generated by the 'repin_dockerfiles.sh' script. To repin +# versions or change packages, edit that script instead. +# +# To repin the hashes: +# +# bazel run \ +# //bazel/remote_execution_container:repin_dockerfiles \ +# --config=local + +FROM redhat/ubi10:10.0@sha256:158b70012c4898a0951abc5b4f98cefff6ec6bff3fb99957ff2f1793df7c681a + +RUN yum check-update || true && \ + yum install -y \ + cyrus-sasl-devel \ + cyrus-sasl-gssapi \ + glibc-devel \ + krb5-devel \ + libcurl-devel \ + openldap-devel \ + openssl-devel \ + systemtap-sdt-devel \ + && yum clean all && rm -rf /var/cache/yum/* + +CMD ["/bin/bash"] diff --git a/bazel/toolchains/cc/mongo_linux/mongo_gdb.bzl b/bazel/toolchains/cc/mongo_linux/mongo_gdb.bzl index d31d2525079..06998b9be44 100644 --- a/bazel/toolchains/cc/mongo_linux/mongo_gdb.bzl +++ b/bazel/toolchains/cc/mongo_linux/mongo_gdb.bzl @@ -35,6 +35,9 @@ def _gdb_download(ctx): external = str(ctx.path("..")) pythonhome = external + "/gdb_" + ctx.attr.version + "/stow/python3-" + ctx.attr.version + gdbhome = external + "/gdb_" + ctx.attr.version + "/stow/gdb-" + ctx.attr.version + gdb_prefix = external + "/gdb_" + ctx.attr.version + "/" + ctx.attr.version + mongodb_toolchain_path = external + "/mongo_toolchain_" + ctx.attr.version stdlib_pp_dir = mongodb_toolchain_path + "/stow/gcc-" + ctx.attr.version + "/share" readelf = mongodb_toolchain_path + "/" + ctx.attr.version + "/bin/llvm-readelf" @@ -43,9 +46,21 @@ def _gdb_download(ctx): # our toolchain python version requires newer openssl, which is not available on AL2 # so we can use pretty printers on AL2 python_env = "{}" + wrapper_python_setup = "" else: # here we only have one dependency for our pretty printers to run. It must be installed into the python # that gdb was built with. We use pip since this is a single dependency that we own. + # + # NOTE: The bundled python is dynamically linked against libpython. Ensure it can locate its shared + # library during repository fetch (and later at runtime) by providing LD_LIBRARY_PATH. + python_lib_path = ":".join([ + pythonhome + "/lib", + pythonhome + "/lib64", + ]) + python_execute_env = { + "PYTHONHOME": pythonhome, + "LD_LIBRARY_PATH": python_lib_path, + } result = ctx.execute([ pythonhome + "/bin/python3", "-m", @@ -53,7 +68,7 @@ def _gdb_download(ctx): "install", "pymongo==4.12.0", "--target=" + pythonhome + "/lib/python" + python3_version + "/site-packages", - ]) + ], environment = python_execute_env) if result.return_code != 0: if ctx.getenv("CI"): fail("Failed to install python module:\n" + result.stdout + "\n" + result.stderr) @@ -64,17 +79,54 @@ def _gdb_download(ctx): python_env = """{ "PYTHONPATH": "%s/lib/python3.10", "PYTHONHOME": "%s", + "LD_LIBRARY_PATH": "%s", "MONGO_GDB_PP_DIR": "%s", "MONGO_GDB_READELF": "%s", - }""" % (pythonhome, pythonhome, stdlib_pp_dir, readelf) + }""" % (pythonhome, pythonhome, python_lib_path, stdlib_pp_dir, readelf) + + # The wrapper scripts must also export these so gdb can load its python runtime (and pretty printers) + # when invoked via bazel run/test. + wrapper_python_setup = """ +PYTHONHOME="${RUNFILES_WORKING_DIRECTORY}/../gdb_%s/stow/python3-%s" +export PYTHONHOME +export PYTHONPATH="${PYTHONHOME}/lib/python%s:${PYTHONPATH:-}" +export LD_LIBRARY_PATH="${PYTHONHOME}/lib:${PYTHONHOME}/lib64:${LD_LIBRARY_PATH:-}" +""" % (ctx.attr.version, ctx.attr.version, python3_version) + + # GDB itself is dynamically linked against its own runtime libraries (e.g. libopcodes). Ensure those are + # available in runfiles and on the loader path regardless of platform. + wrapper_gdb_setup = """ +GDB_PREFIX="${RUNFILES_WORKING_DIRECTORY}/../gdb_%s/%s" +GDBHOME="${RUNFILES_WORKING_DIRECTORY}/../gdb_%s/stow/gdb-%s" +export LD_LIBRARY_PATH="${GDB_PREFIX}/lib:${GDBHOME}/lib:${LD_LIBRARY_PATH:-}" +""" % (ctx.attr.version, ctx.attr.version, ctx.attr.version, ctx.attr.version) ctx.file( "BUILD.bazel", """ +filegroup( + name = "python_runtime", + srcs = glob(["stow/python3-%s/**"]), + visibility = ["//visibility:private"], +) + +filegroup( + name = "gdb_runtime", + srcs = glob([ + "%s/lib/**", + "stow/gdb-%s/**", + ]), + visibility = ["//visibility:private"], +) + sh_binary( name = "gdb", srcs = ["working_dir_gdb.sh"], - data = ["%s/bin/gdb"], + data = [ + "%s/bin/gdb", + ":gdb_runtime", + ":python_runtime", + ], env = %s, visibility = ["//visibility:public"], ) @@ -85,10 +137,12 @@ sh_binary( data = [ "gdb", "%s/bin/gdbserver", + ":gdb_runtime", + ":python_runtime", ], visibility = ["//visibility:public"], ) -""" % (ctx.attr.version, python_env, ctx.attr.version), +""" % (ctx.attr.version, ctx.attr.version, ctx.attr.version, ctx.attr.version, python_env, ctx.attr.version), ) ctx.file( @@ -106,8 +160,10 @@ if [ -z $BUILD_WORKING_DIRECTORY ]; then fi cd $BUILD_WORKING_DIRECTORY +%s +%s ${RUNFILES_WORKING_DIRECTORY}/../gdb_%s/%s/bin/gdb -iex "set auto-load safe-path %s/.gdbinit" "${@:1}" -""" % (ctx.attr.version, ctx.attr.version, str(ctx.workspace_root)), +""" % (wrapper_gdb_setup, wrapper_python_setup, ctx.attr.version, ctx.attr.version, str(ctx.workspace_root)), ) ctx.file( @@ -128,8 +184,10 @@ cd $BUILD_WORKING_DIRECTORY # RUNTEST_PRESERVE_CWD forces us to reconstruct the binary path original_args="${@:1}" +%s +%s ${RUNFILES_WORKING_DIRECTORY}/external/gdb_%s/%s/bin/gdbserver localhost:1234 ${TEST_SRCDIR}/_main/${original_args[0]} "${@:2}" -""" % (ctx.attr.version, ctx.attr.version), +""" % (wrapper_gdb_setup, wrapper_python_setup, ctx.attr.version, ctx.attr.version), ) return None diff --git a/bazel/toolchains/cc/mongo_linux/mongo_gdb_version_v5.bzl b/bazel/toolchains/cc/mongo_linux/mongo_gdb_version_v5.bzl index 362d06fd11c..cb2723e43a0 100644 --- a/bazel/toolchains/cc/mongo_linux/mongo_gdb_version_v5.bzl +++ b/bazel/toolchains/cc/mongo_linux/mongo_gdb_version_v5.bzl @@ -72,6 +72,16 @@ TOOLCHAIN_MAP_V5 = { "sha": "bedecdddd9a83d5b307bbb5d8aa48b3ec298234483c1a5edf407594b429ef7c0", "url": "https://s3.amazonaws.com/boxes.10gen.com/build/toolchain/bazel_v5_gdb-rhel90-a579bff08e941a4dae705e4708ec8da38805b6f1.tar.gz", }, + "rhel10_x86_64": { + "platform_name": "rhel10", + "sha": "4f8bf9a3ce2454a6ce2636e45746dc2a25de139413fe2e60c28aac9b44b07df9", + "url": "https://s3.amazonaws.com/boxes.10gen.com/build/toolchain/bazel_v5_gdb-rhel10-e921fc32d5c23d7cdb5cf406b05bf16eb5ab8dbd.tar.gz", + }, + "rhel10_aarch64": { + "platform_name": "rhel10", + "sha": "52869b742dc8a3550d9656187a4c0e8f95fe8bea542949c25717557cbfbafd42", + "url": "https://s3.amazonaws.com/boxes.10gen.com/build/toolchain/bazel_v5_gdb-rhel10-arm64-e921fc32d5c23d7cdb5cf406b05bf16eb5ab8dbd.tar.gz", + }, "suse15_x86_64": { "platform_name": "suse15", "sha": "14bcc17c41082207b9a033bd879ad66f2195a8581bb4fb0d8c03159d14ae30e1", diff --git a/bazel/toolchains/cc/mongo_linux/mongo_toolchain_version_v5.bzl b/bazel/toolchains/cc/mongo_linux/mongo_toolchain_version_v5.bzl index 1813202484f..78e8d648f85 100644 --- a/bazel/toolchains/cc/mongo_linux/mongo_toolchain_version_v5.bzl +++ b/bazel/toolchains/cc/mongo_linux/mongo_toolchain_version_v5.bzl @@ -72,6 +72,16 @@ TOOLCHAIN_MAP_V5 = { "sha": "8f16b5dfbf59945a6d130182826b3ef0149a3d12690a60a075023b15b98c980c", "url": "https://s3.amazonaws.com/boxes.10gen.com/build/toolchain/bazel_v5_toolchain-rhel90-8c3aa505608c8462ca46fd42f5323c4e15c21d75.tar.gz", }, + "rhel10_x86_64": { + "platform_name": "rhel10", + "sha": "5aa5980fa2fe96a2ddaf9c8c43a9850273e70af766e25150a0c700f91635eb11", + "url": "https://s3.amazonaws.com/boxes.10gen.com/build/toolchain/bazel_v5_toolchain-rhel10-e921fc32d5c23d7cdb5cf406b05bf16eb5ab8dbd.tar.gz", + }, + "rhel10_aarch64": { + "platform_name": "rhel10", + "sha": "664a86f9c6286b756009d901c46a5e3504a6d1c36ebb2ae813dfc0a0fdebaa49", + "url": "https://s3.amazonaws.com/boxes.10gen.com/build/toolchain/bazel_v5_toolchain-rhel10-arm64-e921fc32d5c23d7cdb5cf406b05bf16eb5ab8dbd.tar.gz", + }, "suse15_x86_64": { "platform_name": "suse15", "sha": "1971b554d55a38ce39d408f17cbc0b5e8b43860e83089578e4d8ae4b2534d52d", diff --git a/bazel/utils.bzl b/bazel/utils.bzl index b8cc9434c77..f4a97b53294 100644 --- a/bazel/utils.bzl +++ b/bazel/utils.bzl @@ -139,6 +139,7 @@ def get_host_distro_major_version(repository_ctx): "Debian GNU/Linux 12": "debian12", "Red Hat Enterprise Linux 8*": "rhel8", "Red Hat Enterprise Linux 9*": "rhel9", + "Red Hat Enterprise Linux 10*": "rhel10", "SLES 15*": "suse15", } diff --git a/buildscripts/mongo_toolchain.py b/buildscripts/mongo_toolchain.py index 4079988379e..924a06b1169 100644 --- a/buildscripts/mongo_toolchain.py +++ b/buildscripts/mongo_toolchain.py @@ -182,6 +182,9 @@ def get_mongo_toolchain( from_bazel_value = os.environ.get("MONGO_TOOLCHAIN_FROM_BAZEL", "true") from_bazel = _parse_from_bazel_envvar(from_bazel_value) + if not from_bazel: + from_bazel = not os.path.exists(_get_installed_toolchain_path(version)) + if from_bazel: return _get_bazel_toolchain(version) return _get_installed_toolchain(version) diff --git a/buildscripts/package_test.py b/buildscripts/package_test.py index d585cbaf918..0926be32758 100644 --- a/buildscripts/package_test.py +++ b/buildscripts/package_test.py @@ -248,6 +248,12 @@ OS_DOCKER_LOOKUP = { frozenset(["python3", "wget", "pkgconfig", "systemd", "procps", "file"]), "python3", ), + "rhel10": ( + "almalinux:10", + "yum", + frozenset(["python3", "wget", "pkgconfig", "systemd", "procps", "file"]), + "python3", + ), "sunos5": None, "suse11": None, "suse12": None, diff --git a/buildscripts/packager.py b/buildscripts/packager.py index 0ea6012492b..d10e5361bcb 100755 --- a/buildscripts/packager.py +++ b/buildscripts/packager.py @@ -376,6 +376,7 @@ class Distro(object): return ["suse11", "suse12", "suse15"] elif re.search("(redhat|fedora|centos)", self.dname): return [ + "rhel10", "rhel93", "rhel90", "rhel88", diff --git a/buildscripts/packager_enterprise.py b/buildscripts/packager_enterprise.py index ee50a7b7710..32c38460ec3 100755 --- a/buildscripts/packager_enterprise.py +++ b/buildscripts/packager_enterprise.py @@ -192,7 +192,7 @@ class EnterpriseDistro(packager.Distro): return ["ubuntu1804", "ubuntu2004", "ubuntu2204", "ubuntu2404"] if arch == "aarch64": if self.dname == "redhat": - return ["rhel82", "rhel88", "rhel90", "rhel93"] + return ["rhel82", "rhel88", "rhel90", "rhel93", "rhel10"] if self.dname == "amazon2": return ["amazon2"] if self.dname == "amazon2023": @@ -200,7 +200,17 @@ class EnterpriseDistro(packager.Distro): return [] if re.search("(redhat|fedora|centos)", self.dname): - return ["rhel90", "rhel93", "rhel80", "rhel70", "rhel79", "rhel62", "rhel57", "rhel88"] + return [ + "rhel10", + "rhel90", + "rhel93", + "rhel80", + "rhel70", + "rhel79", + "rhel62", + "rhel57", + "rhel88", + ] return super(EnterpriseDistro, self).build_os(arch) diff --git a/etc/evergreen_yml_components/definitions.yml b/etc/evergreen_yml_components/definitions.yml index a062a45f2c1..7f739694642 100644 --- a/etc/evergreen_yml_components/definitions.yml +++ b/etc/evergreen_yml_components/definitions.yml @@ -30,12 +30,16 @@ variables: - rhel-8-arm64 - rhel93 - rhel93-arm64 + - rhel10-64-bit + - rhel10-arm64 - enterprise-rhel-8-64-bit - enterprise-rhel-8-64-bit-suggested # For testing selinux. - enterprise-rhel-8-arm64 - enterprise-rhel-83-s390x - enterprise-rhel-93-64-bit - enterprise-rhel-93-arm64 + - enterprise-rhel-10-64-bit + - enterprise-rhel-10-arm64 - suse15 - enterprise-suse15-64 - ubuntu2004-arm64 diff --git a/etc/evergreen_yml_components/tasks/compile_tasks_nightly.yml b/etc/evergreen_yml_components/tasks/compile_tasks_nightly.yml index 92c36f0f932..307513e2c73 100644 --- a/etc/evergreen_yml_components/tasks/compile_tasks_nightly.yml +++ b/etc/evergreen_yml_components/tasks/compile_tasks_nightly.yml @@ -31,6 +31,8 @@ variables: - enterprise-rhel-90-arm64 - enterprise-rhel-93-64-bit - enterprise-rhel-93-arm64 + - enterprise-rhel-10-64-bit + - enterprise-rhel-10-arm64 - enterprise-suse15-64 - enterprise-ubuntu2004-arm64 - enterprise-ubuntu2204-arm64 diff --git a/etc/evergreen_yml_components/tasks/misc_tasks.yml b/etc/evergreen_yml_components/tasks/misc_tasks.yml index 533c21e848e..79979ade0e1 100644 --- a/etc/evergreen_yml_components/tasks/misc_tasks.yml +++ b/etc/evergreen_yml_components/tasks/misc_tasks.yml @@ -1819,6 +1819,42 @@ tasks: distro: rhel90-selinux test_list: jstests/selinux/*.js + - name: selinux_rhel10_enterprise + tags: ["assigned_to_jira_team_server_security", "auxiliary"] + depends_on: + - name: archive_dist_test + - name: package + commands: + - command: manifest.load + - func: "git get project and add git tag" + - func: "f_expansions_write" + - func: "set up venv" + - func: "fetch packages" + - func: "fetch binaries" + - func: "extract binaries" + - func: "run selinux tests" + vars: + distro: rhel10-selinux + test_list: jstests/selinux/*.js src/mongo/db/modules/enterprise/jstests/selinux/*.js + + - name: selinux_rhel10_org + tags: ["assigned_to_jira_team_server_security", "auxiliary"] + depends_on: + - name: archive_dist_test + - name: package + commands: + - command: manifest.load + - func: "git get project and add git tag" + - func: "f_expansions_write" + - func: "set up venv" + - func: "fetch packages" + - func: "fetch binaries" + - func: "extract binaries" + - func: "run selinux tests" + vars: + distro: rhel10-selinux + test_list: jstests/selinux/*.js + - name: sync_repo_with_copybara tags: ["assigned_to_jira_team_devprod_correctness", "auxiliary"] patchable: false diff --git a/etc/evergreen_yml_components/variants/rhel/test_release.yml b/etc/evergreen_yml_components/variants/rhel/test_release.yml index 28112771752..42bba90546f 100644 --- a/etc/evergreen_yml_components/variants/rhel/test_release.yml +++ b/etc/evergreen_yml_components/variants/rhel/test_release.yml @@ -440,3 +440,206 @@ buildvariants: - name: .release_critical .requires_large_host distros: - rhel93-arm64-m8g-4xlarge + + - name: rhel10-64-bit + display_name: RHEL 10.0 + tags: ["forbid_tasks_tagged_with_experimental"] + cron: "0 4 * * *" # From the ${project_nightly_cron} parameter. + run_on: + - rhel10.0-small + expansions: + push_path: linux + push_bucket: downloads.mongodb.org + push_bucket_new: cdn-origin-mongodb-server-community + push_role_arn: arn:aws:iam::119629040606:role/s3-access.cdn-origin-mongodb-server-community + push_name: linux + push_arch: x86_64-rhel10 + mciuploads_binary_permissions_push: public-read + mciuploads_binary_visibility_push: public + bazel_compile_flags: >- + --define=MONGO_DISTMOD=rhel10 + --build_enterprise=False + --remote_executor= + compile_all_but_not_unittests_flags: >- + --linkopt=-s + test_flags: >- + --excludeWithAnyTags=requires_external_data_source + --modules=none + multiversion_platform: rhel10 + multiversion_edition: targeted + has_packages: true + packager_script: packager.py + packager_arch: x86_64 + packager_distro: rhel10 + repo_edition: org + large_distro_name: rhel10.0-large + compile_variant: rhel10-64-bit + tasks: + - name: compile_test_and_package_serial_TG + distros: + - rhel10.0-large + - name: run_unit_tests_TG + distros: + - rhel10.0-large + - name: test_packages + distros: + - ubuntu2204-large + - name: selinux_rhel10_org + - name: .development_critical !.requires_large_host !.incompatible_community + - name: .development_critical .requires_large_host !.incompatible_community + distros: + - rhel10.0-large + - name: .release_critical !.requires_large_host !.incompatible_community !.publish + - name: .release_critical .requires_large_host !.incompatible_community !.publish + distros: + - rhel10.0-large + + - name: enterprise-rhel-10-64-bit + display_name: "Enterprise RHEL 10.0" + tags: ["forbid_tasks_tagged_with_experimental"] + cron: "0 4 * * *" # From the ${project_nightly_cron} parameter. + run_on: + - rhel10.0-small + expansions: + additional_package_targets: archive-mongocryptd-stripped archive-mongocryptd-debug + push_path: linux + push_bucket: downloads.10gen.com + push_bucket_new: cdn-origin-mongodb-server-enterprise + push_role_arn: arn:aws:iam::119629040606:role/s3-access.cdn-origin-mongodb-server-enterprise + push_name: linux + push_arch: x86_64-enterprise-rhel10 + mciuploads_binary_permissions_push: public-read + mciuploads_binary_visibility_push: public + bazel_compile_flags: --define=MONGO_DISTMOD=rhel10 --remote_executor= + compile_all_but_not_unittests_flags: >- + --linkopt=-s + test_flags: --excludeWithAnyTags=requires_external_data_source + multiversion_platform: rhel10 + multiversion_edition: enterprise + has_packages: true + packager_script: packager_enterprise.py + packager_arch: x86_64 + packager_distro: rhel10 + repo_edition: enterprise + compile_variant: enterprise-rhel-10-64-bit + core_analyzer_distro_name: rhel10-large + large_distro_name: rhel10.0-large + tasks: + - name: compile_test_and_package_serial_TG + distros: + - rhel10.0-large + - name: run_unit_tests_TG + distros: + - rhel10.0-large + - name: test_packages + distros: + - ubuntu2204-large + - name: selinux_rhel10_enterprise + - name: .development_critical !.requires_large_host + - name: .development_critical .requires_large_host + distros: + - rhel10.0-large + - name: .release_critical !.requires_large_host !.publish + - name: .release_critical .requires_large_host !.publish + distros: + - rhel10.0-large + + - name: rhel10-arm64 + display_name: RHEL 10.0 arm64 + tags: ["bazel_check", "forbid_tasks_tagged_with_experimental"] + cron: "0 4 * * *" # From the ${project_nightly_cron} parameter. + run_on: + - rhel10.0-arm64-small + expansions: + push_path: linux + push_bucket: downloads.mongodb.org + push_bucket_new: cdn-origin-mongodb-server-community + push_role_arn: arn:aws:iam::119629040606:role/s3-access.cdn-origin-mongodb-server-community + push_name: linux + push_arch: aarch64-rhel10 + mciuploads_binary_permissions_push: public-read + mciuploads_binary_visibility_push: public + bazel_compile_flags: >- + --define=MONGO_DISTMOD=rhel10 + --build_enterprise=False + --remote_executor= + compile_all_but_not_unittests_flags: >- + --linkopt=-s + test_flags: >- + --excludeWithAnyTags=requires_external_data_source + --modules=none + has_packages: true + packager_script: packager.py + packager_arch: aarch64 + packager_distro: rhel10 + repo_edition: org + large_distro_name: rhel10.0-arm64-large + compile_variant: rhel10-arm64 + tasks: + - name: compile_test_and_package_serial_TG + distros: + - rhel10.0-arm64-large + - name: run_unit_tests_TG + distros: + - rhel10.0-arm64-large + - name: test_packages + distros: + - ubuntu2204-arm64-small + - name: .development_critical !.requires_large_host !.incompatible_community + - name: .development_critical .requires_large_host !.incompatible_community + distros: + - rhel10.0-arm64-large + - name: .release_critical !.requires_large_host !.incompatible_community !.publish + - name: .release_critical .requires_large_host !.incompatible_community !.publish + distros: + - rhel10.0-arm64-large + + - name: enterprise-rhel-10-arm64 + display_name: "Enterprise RHEL 10.0 arm64" + tags: ["forbid_tasks_tagged_with_experimental"] + cron: "0 4 * * *" # From the ${project_nightly_cron} parameter. + run_on: + - rhel10.0-arm64-small + expansions: + additional_package_targets: >- + archive-mongocryptd-stripped + archive-mongocryptd-debug + push_path: linux + push_bucket: downloads.10gen.com + push_bucket_new: cdn-origin-mongodb-server-enterprise + push_role_arn: arn:aws:iam::119629040606:role/s3-access.cdn-origin-mongodb-server-enterprise + push_name: linux + push_arch: aarch64-enterprise-rhel10 + mciuploads_binary_permissions_push: public-read + mciuploads_binary_visibility_push: public + bazel_compile_flags: >- + --define=MONGO_DISTMOD=rhel10 + --remote_executor= + compile_all_but_not_unittests_flags: >- + --linkopt=-s + test_flags: --excludeWithAnyTags=requires_external_data_source + has_packages: true + packager_script: packager_enterprise.py + packager_arch: aarch64 + packager_distro: rhel10 + repo_edition: enterprise + large_distro_name: rhel10.0-arm64-large + compile_variant: enterprise-rhel-10-arm64 + tasks: + - name: compile_test_and_package_serial_TG + distros: + - rhel10.0-arm64-large + - name: run_unit_tests_TG + distros: + - rhel10.0-arm64-large + - name: test_packages + distros: + - ubuntu2204-arm64-small + - name: .development_critical !.requires_large_host + - name: .development_critical .requires_large_host + distros: + - rhel10.0-arm64-large + - name: .release_critical !.requires_large_host !.publish + - name: .release_critical .requires_large_host !.publish + distros: + - rhel10.0-arm64-large diff --git a/evergreen/package.sh b/evergreen/package.sh index d5cdfb794a8..94a5ee9ab02 100755 --- a/evergreen/package.sh +++ b/evergreen/package.sh @@ -36,6 +36,8 @@ valid_mongocryptd_variants=( "enterprise-rhel-90-arm64" "enterprise-rhel-93-64-bit" "enterprise-rhel-93-arm64" + "enterprise-rhel-10-64-bit" + "enterprise-rhel-10-arm64" "enterprise-suse15-64" "enterprise-ubuntu2004-arm64" "enterprise-ubuntu2204-arm64" diff --git a/rpm/mongodb-enterprise-init.spec b/rpm/mongodb-enterprise-init.spec index 0ab3421a75d..921f6f4201b 100644 --- a/rpm/mongodb-enterprise-init.spec +++ b/rpm/mongodb-enterprise-init.spec @@ -27,8 +27,13 @@ URL: http://www.mongodb.org Group: Applications/Databases Requires: mongodb-enterprise-cryptd, mongodb-enterprise-mongos, mongodb-enterprise-server, mongodb-enterprise-database-tools-extra -%if 0%{?rhel} >= 8 || 0%{?fedora} >= 30 +%if 0%{?rhel} >= 10 +BuildRequires: python-rpm-macros, python3-devel +%global pathfix /usr/lib/rpm/redhat/pathfix.py + +%elif 0%{?rhel} >= 8 || 0%{?fedora} >= 30 BuildRequires: /usr/bin/pathfix.py, python3-devel +%global pathfix /usr/bin/pathfix.py %endif Source0: %{_name}-%{version}.tar.gz @@ -249,7 +254,7 @@ This package provides the MongoDB static library and header files needed to deve %prep %setup -n %{_name}-%{version} %if 0%{?rhel} >= 8 || 0%{?fedora} >= 30 -pathfix.py -pni "%{__python3} %{py3_shbang_opts}" bin/install_compass +%{__python3} %{pathfix} -pni "%{__python3} %{py3_shbang_opts}" bin/install_compass %endif %build diff --git a/rpm/mongodb-enterprise-unstable-init.spec b/rpm/mongodb-enterprise-unstable-init.spec index 6ff0a5fb98a..e7371da1491 100644 --- a/rpm/mongodb-enterprise-unstable-init.spec +++ b/rpm/mongodb-enterprise-unstable-init.spec @@ -26,8 +26,13 @@ URL: http://www.mongodb.org Group: Applications/Databases Requires: mongodb-enterprise-unstable-cryptd, mongodb-enterprise-unstable-mongos, mongodb-enterprise-unstable-server, mongodb-enterprise-unstable-database-tools-extra -%if 0%{?rhel} >= 8 || 0%{?fedora} >= 30 +%if 0%{?rhel} >= 10 +BuildRequires: python-rpm-macros, python3-devel +%global pathfix /usr/lib/rpm/redhat/pathfix.py + +%elif 0%{?rhel} >= 8 || 0%{?fedora} >= 30 BuildRequires: /usr/bin/pathfix.py, python3-devel +%global pathfix /usr/bin/pathfix.py %endif Source0: %{_name}-%{version}.tar.gz @@ -240,7 +245,7 @@ This package provides the MongoDB static library and header files needed to deve %prep %setup -n %{_name}-%{version} %if 0%{?rhel} >= 8 || 0%{?fedora} >= 30 -pathfix.py -pni "%{__python3} %{py3_shbang_opts}" bin/install_compass +%{__python3} %{pathfix} -pni "%{__python3} %{py3_shbang_opts}" bin/install_compass %endif %build diff --git a/rpm/mongodb-enterprise-unstable.spec b/rpm/mongodb-enterprise-unstable.spec index 3a367cc93f8..469c06dbdad 100644 --- a/rpm/mongodb-enterprise-unstable.spec +++ b/rpm/mongodb-enterprise-unstable.spec @@ -26,8 +26,13 @@ URL: http://www.mongodb.org Group: Applications/Databases Requires: mongodb-enterprise-unstable-cryptd, mongodb-enterprise-unstable-mongos, mongodb-enterprise-unstable-server, mongodb-enterprise-unstable-database-tools-extra -%if 0%{?rhel} >= 8 || 0%{?fedora} >= 30 +%if 0%{?rhel} >= 10 +BuildRequires: python-rpm-macros, python3-devel +%global pathfix /usr/lib/rpm/redhat/pathfix.py + +%elif 0%{?rhel} >= 8 || 0%{?fedora} >= 30 BuildRequires: /usr/bin/pathfix.py, python3-devel +%global pathfix /usr/bin/pathfix.py %endif Source0: %{_name}-%{version}.tar.gz @@ -247,7 +252,7 @@ This package provides the MongoDB static library and header files needed to deve %prep %setup -n %{_name}-%{version} %if 0%{?rhel} >= 8 || 0%{?fedora} >= 30 -pathfix.py -pni "%{__python3} %{py3_shbang_opts}" bin/install_compass +%{__python3} %{pathfix} -pni "%{__python3} %{py3_shbang_opts}" bin/install_compass %endif %build diff --git a/rpm/mongodb-enterprise.spec b/rpm/mongodb-enterprise.spec index c5e2d550ebc..8e8200f1c30 100644 --- a/rpm/mongodb-enterprise.spec +++ b/rpm/mongodb-enterprise.spec @@ -27,8 +27,13 @@ URL: http://www.mongodb.org Group: Applications/Databases Requires: mongodb-enterprise-cryptd, mongodb-enterprise-mongos, mongodb-enterprise-server, mongodb-enterprise-database-tools-extra -%if 0%{?rhel} >= 8 || 0%{?fedora} >= 30 +%if 0%{?rhel} >= 10 +BuildRequires: python-rpm-macros, python3-devel +%global pathfix /usr/lib/rpm/redhat/pathfix.py + +%elif 0%{?rhel} >= 8 || 0%{?fedora} >= 30 BuildRequires: /usr/bin/pathfix.py, python3-devel +%global pathfix /usr/bin/pathfix.py %endif Source0: %{_name}-%{version}.tar.gz @@ -256,7 +261,7 @@ This package provides the MongoDB static library and header files needed to deve %prep %setup -n %{_name}-%{version} %if 0%{?rhel} >= 8 || 0%{?fedora} >= 30 -pathfix.py -pni "%{__python3} %{py3_shbang_opts}" bin/install_compass +%{__python3} %{pathfix} -pni "%{__python3} %{py3_shbang_opts}" bin/install_compass %endif %build diff --git a/rpm/mongodb-org-init.spec b/rpm/mongodb-org-init.spec index 92b17e2db37..d36ec170f11 100644 --- a/rpm/mongodb-org-init.spec +++ b/rpm/mongodb-org-init.spec @@ -28,8 +28,13 @@ Group: Applications/Databases Requires: mongodb-org-mongos, mongodb-org-server, mongodb-org-database-tools-extra -%if 0%{?rhel} >= 8 || 0%{?fedora} >= 30 +%if 0%{?rhel} >= 10 +BuildRequires: python-rpm-macros, python3-devel +%global pathfix /usr/lib/rpm/redhat/pathfix.py + +%elif 0%{?rhel} >= 8 || 0%{?fedora} >= 30 BuildRequires: /usr/bin/pathfix.py, python3-devel +%global pathfix /usr/bin/pathfix.py %endif Source0: %{_name}-%{version}.tar.gz @@ -226,7 +231,7 @@ This package provides the MongoDB static library and header files needed to deve %prep %setup -n %{_name}-%{version} %if 0%{?rhel} >= 8 || 0%{?fedora} >= 30 -pathfix.py -pni "%{__python3} %{py3_shbang_opts}" bin/install_compass +%{__python3} %{pathfix} -pni "%{__python3} %{py3_shbang_opts}" bin/install_compass %endif %build diff --git a/rpm/mongodb-org-unstable-init.spec b/rpm/mongodb-org-unstable-init.spec index 626c3d1dd76..b536ad30f7f 100644 --- a/rpm/mongodb-org-unstable-init.spec +++ b/rpm/mongodb-org-unstable-init.spec @@ -25,8 +25,13 @@ URL: http://www.mongodb.org Group: Applications/Databases Requires: mongodb-org-unstable-mongos, mongodb-org-unstable-mongod, mongodb-org-unstable-database-tools-extra -%if 0%{?rhel} >= 8 || 0%{?fedora} >= 30 +%if 0%{?rhel} >= 10 +BuildRequires: python-rpm-macros, python3-devel +%global pathfix /usr/lib/rpm/redhat/pathfix.py + +%elif 0%{?rhel} >= 8 || 0%{?fedora} >= 30 BuildRequires: /usr/bin/pathfix.py, python3-devel +%global pathfix /usr/bin/pathfix.py %endif Source0: %{_name}-%{version}.tar.gz @@ -215,7 +220,7 @@ This package provides the MongoDB static library and header files needed to deve %prep %setup -n %{_name}-%{version} %if 0%{?rhel} >= 8 || 0%{?fedora} >= 30 -pathfix.py -pni "%{__python3} %{py3_shbang_opts}" bin/install_compass +%{__python3} %{pathfix} -pni "%{__python3} %{py3_shbang_opts}" bin/install_compass %endif %build diff --git a/rpm/mongodb-org-unstable.spec b/rpm/mongodb-org-unstable.spec index cbd76a73635..260850803a4 100644 --- a/rpm/mongodb-org-unstable.spec +++ b/rpm/mongodb-org-unstable.spec @@ -25,8 +25,13 @@ URL: http://www.mongodb.org Group: Applications/Databases Requires: mongodb-org-unstable-mongos, mongodb-org-unstable-server, mongodb-org-unstable-database-tools-extra -%if 0%{?rhel} >= 8 || 0%{?fedora} >= 30 +%if 0%{?rhel} >= 10 +BuildRequires: python-rpm-macros, python3-devel +%global pathfix /usr/lib/rpm/redhat/pathfix.py + +%elif 0%{?rhel} >= 8 || 0%{?fedora} >= 30 BuildRequires: /usr/bin/pathfix.py, python3-devel +%global pathfix /usr/bin/pathfix.py %endif Source0: %{_name}-%{version}.tar.gz @@ -222,7 +227,7 @@ This package provides the MongoDB static library and header files needed to deve %prep %setup -n %{_name}-%{version} %if 0%{?rhel} >= 8 || 0%{?fedora} >= 30 -pathfix.py -pni "%{__python3} %{py3_shbang_opts}" bin/install_compass +%{__python3} %{pathfix} -pni "%{__python3} %{py3_shbang_opts}" bin/install_compass %endif %build diff --git a/rpm/mongodb-org.spec b/rpm/mongodb-org.spec index 22ef07d95ff..76ae6cc4e3c 100644 --- a/rpm/mongodb-org.spec +++ b/rpm/mongodb-org.spec @@ -27,8 +27,13 @@ URL: http://www.mongodb.org Group: Applications/Databases Requires: mongodb-org-mongos, mongodb-org-server, mongodb-org-database-tools-extra -%if 0%{?rhel} >= 8 || 0%{?fedora} >= 30 +%if 0%{?rhel} >= 10 +BuildRequires: python-rpm-macros, python3-devel +%global pathfix /usr/lib/rpm/redhat/pathfix.py + +%elif 0%{?rhel} >= 8 || 0%{?fedora} >= 30 BuildRequires: /usr/bin/pathfix.py, python3-devel +%global pathfix /usr/bin/pathfix.py %endif Source0: %{_name}-%{version}.tar.gz @@ -233,7 +238,7 @@ This package provides the MongoDB static library and header files needed to deve %prep %setup -n %{_name}-%{version} %if 0%{?rhel} >= 8 || 0%{?fedora} >= 30 -pathfix.py -pni "%{__python3} %{py3_shbang_opts}" bin/install_compass +%{__python3} %{pathfix} -pni "%{__python3} %{py3_shbang_opts}" bin/install_compass %endif %build diff --git a/src/third_party/librdkafka/BUILD.bazel b/src/third_party/librdkafka/BUILD.bazel index 08939f6b6e8..2a6986b37ef 100644 --- a/src/third_party/librdkafka/BUILD.bazel +++ b/src/third_party/librdkafka/BUILD.bazel @@ -151,7 +151,10 @@ mongo_cc_library( "//bazel/config:compiler_type_gcc": [ "-Wno-maybe-uninitialized", ], - "//conditions:default": ["//conditions:incompatible"], + "//conditions:default": [], + }) + select({ + "//bazel/platforms:rhel10": ["-DOPENSSL_NO_ENGINE"], + "//conditions:default": [], }), includes = [ "dist/src",