This is an automated email from the ASF dual-hosted git repository.
adoroszlai pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/ozone.git
The following commit(s) were added to refs/heads/master by this push:
new efe589297c HDDS-11641. Allow testing Hadoop with custom docker images
(#7393)
efe589297c is described below
commit efe589297c471100c5348f57fdf8aa91d8968795
Author: Doroszlai, Attila <[email protected]>
AuthorDate: Tue Nov 5 21:09:13 2024 +0100
HDDS-11641. Allow testing Hadoop with custom docker images (#7393)
---
hadoop-ozone/dist/src/main/compose/common/hadoop-test.sh | 16 +++++++++-------
1 file changed, 9 insertions(+), 7 deletions(-)
diff --git a/hadoop-ozone/dist/src/main/compose/common/hadoop-test.sh
b/hadoop-ozone/dist/src/main/compose/common/hadoop-test.sh
index 4b66baca42..7bf5607443 100755
--- a/hadoop-ozone/dist/src/main/compose/common/hadoop-test.sh
+++ b/hadoop-ozone/dist/src/main/compose/common/hadoop-test.sh
@@ -21,6 +21,12 @@ if [[ ${SECURITY_ENABLED} == "true" ]]; then
fi
export
COMPOSE_FILE="${COMPOSE_FILE:-docker-compose.yaml}":../common/${extra_compose_file}
+# need temp variables because maven filtering replaces only one item per line
+hadoop2_version="${hadoop2.version}"
+hadoop_version="${hadoop.version}"
+
+: ${HADOOP_TEST_VERSIONS:="apache/hadoop:${hadoop2_version}
flokkr/hadoop:3.1.2 apache/hadoop:${hadoop_version}"}
+
export HADOOP_MAJOR_VERSION=3
export HADOOP_VERSION=unused # will be set for each test version below
export OZONE_REPLICATION_FACTOR=3
@@ -42,14 +48,10 @@ export OZONE_DIR=/opt/ozone
# shellcheck source=/dev/null
source "$COMPOSE_DIR/../testlib.sh"
-for HADOOP_VERSION in ${hadoop2.version} 3.1.2 ${hadoop.version}; do
- export HADOOP_VERSION
+for test_version in $HADOOP_TEST_VERSIONS; do
+ export HADOOP_IMAGE="${test_version%%:*}"
+ export HADOOP_VERSION="${test_version##*:}"
export HADOOP_MAJOR_VERSION=${HADOOP_VERSION%%.*}
- if [[ "${HADOOP_VERSION}" == "${hadoop2.version}" ]] || [[
"${HADOOP_VERSION}" == "${hadoop.version}" ]]; then
- export HADOOP_IMAGE=apache/hadoop
- else
- export HADOOP_IMAGE=flokkr/hadoop
- fi
docker-compose --ansi never --profile hadoop up -d nm rm
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]