From fbd17ca914328fe7a246f0217d35814e9327c6b1 Mon Sep 17 00:00:00 2001 From: chenhaoran Date: Tue, 23 Jul 2024 17:19:42 +0800 Subject: [PATCH] test: add deploy in CI --- ...ile_list.txt => ci_deploy_dependency_file_list.txt} | 0 tests/ci/deploy_ci_machines.sh | 10 +++++----- 2 files changed, 5 insertions(+), 5 deletions(-) rename tests/ci/{ci_deploy_dependcy_file_list.txt => ci_deploy_dependency_file_list.txt} (100%) diff --git a/tests/ci/ci_deploy_dependcy_file_list.txt b/tests/ci/ci_deploy_dependency_file_list.txt similarity index 100% rename from tests/ci/ci_deploy_dependcy_file_list.txt rename to tests/ci/ci_deploy_dependency_file_list.txt diff --git a/tests/ci/deploy_ci_machines.sh b/tests/ci/deploy_ci_machines.sh index 1f1b9ebf27..e34ec1d6e5 100644 --- a/tests/ci/deploy_ci_machines.sh +++ b/tests/ci/deploy_ci_machines.sh @@ -30,19 +30,19 @@ sudo systemctl start docker mkdir -p /var/lib/jenkins/workspace/log # Assuming you have a file called 'file_list.txt' with one filename per line -file_list="ci_deploy_dependcy_file_list.txt" -moniterip="192.168.1.59" +file_list="ci_deploy_dependency_file_list.txt" +monitorip="192.168.1.59" passwd_all="abcdefg" # Read the file list and call scp_file_from_host for each file while IFS= read -r source_filename; do - scp_file_from_host "$moniterip" "$passwd_all" "$source_filename" + scp_file_from_host "$monitorip" "$passwd_all" "$source_filename" done < "$file_list" # modify the configuration file ip=$(ifconfig |grep inet|grep 192 |awk '{print $2}') -sed -i "s/${moniterip}/$ip/" /home/log_server.json -sed -i "s/${moniterip}/$ip/" /home/m.json +sed -i "s/${monitorip}/$ip/" /home/log_server.json +sed -i "s/${monitorip}/$ip/" /home/m.json #mkdir corefile dir and configure the system to automatically set corefile dir at startup mkdir -p /home/coredump/ && echo "echo '/home/coredump/core_%e-%p' | sudo tee /proc/sys/kernel/core_pattern " >> /root/.bashrc