From 8de6e63d8ca308a73cd568fc89113dbe68cc0f34 Mon Sep 17 00:00:00 2001 From: zhangguoqiang <18372634969@163.com> Date: Wed, 25 Oct 2023 17:46:34 +0800 Subject: [PATCH 1/3] s3 address is determined based on the configuration --- docker/thirdparties/custom_settings.env | 2 ++ .../docker-compose/hive/scripts/hive-metastore.sh | 8 ++++++-- docker/thirdparties/run-thirdparties-docker.sh | 2 ++ 3 files changed, 10 insertions(+), 2 deletions(-) diff --git a/docker/thirdparties/custom_settings.env b/docker/thirdparties/custom_settings.env index d1f9fbb6285633..d0f610b0e07510 100644 --- a/docker/thirdparties/custom_settings.env +++ b/docker/thirdparties/custom_settings.env @@ -21,3 +21,5 @@ # eg: CONTAINER_UID="doris-jack-" # NOTICE: change this uid will modify the file in docker-compose. CONTAINER_UID="doris--" +s3Endpoint = "cos.ap-hongkong.myqcloud.com" +s3BucketName = "doris-build-hk-1308700295" diff --git a/docker/thirdparties/docker-compose/hive/scripts/hive-metastore.sh b/docker/thirdparties/docker-compose/hive/scripts/hive-metastore.sh index 2d19c7aa1c3de4..0157dc26d40581 100755 --- a/docker/thirdparties/docker-compose/hive/scripts/hive-metastore.sh +++ b/docker/thirdparties/docker-compose/hive/scripts/hive-metastore.sh @@ -25,7 +25,9 @@ sleep 10s if [[ ! -d "/mnt/scripts/tpch1.db" ]]; then echo "/mnt/scripts/tpch1.db does not exist" cd /mnt/scripts/ - wget -P /mnt/scripts https://doris-build-hk-1308700295.cos.ap-hongkong.myqcloud.com/regression/load/tpch1_parquet/tpch1.db.tar.gz + #curl -O /mnt/scripts https://doris-build-hk-1308700295.cos.ap-hongkong.myqcloud.com/regression/load/tpch1_parquet/tpch1.db.tar.gz + echo "curl -O s3BucketName.s3Endpoint/regression/datalake/pipeline_data/tpch1.db.tar.gz" + curl -O https://s3BucketName.s3Endpoint/regression/datalake/pipeline_data/tpch1.db.tar.gz tar -zxf tpch1.db.tar.gz rm -rf tpch1.db.tar.gz cd - @@ -45,7 +47,9 @@ hadoop fs -put /mnt/scripts/tpch1.db /user/doris/ if [[ ! -d "/mnt/scripts/paimon1" ]]; then echo "/mnt/scripts/paimon1 does not exist" cd /mnt/scripts/ - curl -O https://doris-build-hk-1308700295.cos.ap-hongkong.myqcloud.com/regression/paimon/paimon1.tar.gz + #curl -O https://doris-build-hk-1308700295.cos.ap-hongkong.myqcloud.com/regression/paimon/paimon1.tar.gz + echo "curl -O s3BucketName.s3Endpoint/regression/datalake/pipeline_data/paimon1.tar.gz" + curl -O https://s3BucketName.s3Endpoint/regression/datalake/pipeline_data/paimon1.tar.gz tar -zxf paimon1.tar.gz rm -rf paimon1.tar.gz cd - diff --git a/docker/thirdparties/run-thirdparties-docker.sh b/docker/thirdparties/run-thirdparties-docker.sh index de1422d1afcabf..31494fd3599ea9 100755 --- a/docker/thirdparties/run-thirdparties-docker.sh +++ b/docker/thirdparties/run-thirdparties-docker.sh @@ -309,6 +309,8 @@ if [[ "${RUN_HIVE}" -eq 1 ]]; then sed -i "s/externalEnvIp/${IP_HOST}/g" "${ROOT}"/docker-compose/hive/hive-2x.yaml sed -i "s/externalEnvIp/${IP_HOST}/g" "${ROOT}"/docker-compose/hive/hadoop-hive.env.tpl sed -i "s/\${externalEnvIp}/${IP_HOST}/g" "${ROOT}"/docker-compose/hive/gen_env.sh + sed -i "s/s3Endpoint/${s3Endpoint}/g" "${ROOT}"/docker-compose/hive/scripts/hive-metastores.sh + sed -i "s/s3BucketName/${s3BucketName}/g" "${ROOT}"/docker-compose/hive/scripts/hive-metastores.sh sudo bash "${ROOT}"/docker-compose/hive/gen_env.sh sudo docker compose -f "${ROOT}"/docker-compose/hive/hive-2x.yaml --env-file "${ROOT}"/docker-compose/hive/hadoop-hive.env down if [[ "${STOP}" -ne 1 ]]; then From 042fb9ac068ac2d5af350f8da46045ad5692887b Mon Sep 17 00:00:00 2001 From: zhangguoqiang <18372634969@163.com> Date: Wed, 25 Oct 2023 19:07:09 +0800 Subject: [PATCH 2/3] fix format bug --- docker/thirdparties/custom_settings.env | 4 ++-- docker/thirdparties/run-thirdparties-docker.sh | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/docker/thirdparties/custom_settings.env b/docker/thirdparties/custom_settings.env index d0f610b0e07510..ac178c81726f67 100644 --- a/docker/thirdparties/custom_settings.env +++ b/docker/thirdparties/custom_settings.env @@ -21,5 +21,5 @@ # eg: CONTAINER_UID="doris-jack-" # NOTICE: change this uid will modify the file in docker-compose. CONTAINER_UID="doris--" -s3Endpoint = "cos.ap-hongkong.myqcloud.com" -s3BucketName = "doris-build-hk-1308700295" +s3Endpoint="cos.ap-hongkong.myqcloud.com" +s3BucketName="doris-build-hk-1308700295" diff --git a/docker/thirdparties/run-thirdparties-docker.sh b/docker/thirdparties/run-thirdparties-docker.sh index 31494fd3599ea9..2ef00331d5725b 100755 --- a/docker/thirdparties/run-thirdparties-docker.sh +++ b/docker/thirdparties/run-thirdparties-docker.sh @@ -309,8 +309,8 @@ if [[ "${RUN_HIVE}" -eq 1 ]]; then sed -i "s/externalEnvIp/${IP_HOST}/g" "${ROOT}"/docker-compose/hive/hive-2x.yaml sed -i "s/externalEnvIp/${IP_HOST}/g" "${ROOT}"/docker-compose/hive/hadoop-hive.env.tpl sed -i "s/\${externalEnvIp}/${IP_HOST}/g" "${ROOT}"/docker-compose/hive/gen_env.sh - sed -i "s/s3Endpoint/${s3Endpoint}/g" "${ROOT}"/docker-compose/hive/scripts/hive-metastores.sh - sed -i "s/s3BucketName/${s3BucketName}/g" "${ROOT}"/docker-compose/hive/scripts/hive-metastores.sh + sed -i "s/s3Endpoint/${s3Endpoint}/g" "${ROOT}"/docker-compose/hive/scripts/hive-metastore.sh + sed -i "s/s3BucketName/${s3BucketName}/g" "${ROOT}"/docker-compose/hive/scripts/hive-metastore.sh sudo bash "${ROOT}"/docker-compose/hive/gen_env.sh sudo docker compose -f "${ROOT}"/docker-compose/hive/hive-2x.yaml --env-file "${ROOT}"/docker-compose/hive/hadoop-hive.env down if [[ "${STOP}" -ne 1 ]]; then From 288144c8ed75e548695eb94be9e6ad57f2e0c037 Mon Sep 17 00:00:00 2001 From: zhangguoqiang <18372634969@163.com> Date: Wed, 25 Oct 2023 20:48:28 +0800 Subject: [PATCH 3/3] change iceberg_data.zip s3 address --- docker/thirdparties/run-thirdparties-docker.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docker/thirdparties/run-thirdparties-docker.sh b/docker/thirdparties/run-thirdparties-docker.sh index 2ef00331d5725b..b498f9f6e195d9 100755 --- a/docker/thirdparties/run-thirdparties-docker.sh +++ b/docker/thirdparties/run-thirdparties-docker.sh @@ -336,7 +336,7 @@ if [[ "${RUN_ICEBERG}" -eq 1 ]]; then sudo docker compose -f "${ROOT}"/docker-compose/iceberg/iceberg.yaml --env-file "${ROOT}"/docker-compose/iceberg/iceberg.env down sudo rm -rf "${ROOT}"/docker-compose/iceberg/data if [[ "${STOP}" -ne 1 ]]; then - wget -P ${ROOT}/docker-compose/iceberg https://doris-build-hk-1308700295.cos.ap-hongkong.myqcloud.com/regression/iceberg/iceberg_data.zip + wget -P "${ROOT}"/docker-compose/iceberg https://"${s3BucketName}.${s3Endpoint}"/regression/datalake/pipeline_data/iceberg_data.zip sudo unzip -d "${ROOT}"/docker-compose/iceberg -q ${ROOT}/docker-compose/iceberg/iceberg_data.zip sudo mv "${ROOT}"/docker-compose/iceberg/iceberg_data "${ROOT}"/docker-compose/iceberg/data sudo rm -rf ${ROOT}/docker-compose/iceberg/iceberg_data.zip