From d19e45158956bd5518812ec9dd8ad5a020797c80 Mon Sep 17 00:00:00 2001 From: China-zoupanpan Date: Tue, 2 Apr 2024 21:40:52 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E5=B0=86DevkitDistribute=E4=B8=8Elkp?= =?UTF-8?q?=E8=A7=A3=E5=81=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .gitignore | 3 ++- component/DevkitDistribute/check_install_result.sh | 2 +- component/DevkitDistribute/install.sh | 7 ++----- tools/install_dependency/src/constant.py | 2 +- .../install_dependency/src/download/download_config.py | 6 +++++- .../install_dependency/src/download/download_utils.py | 10 +++++++--- tools/install_dependency/src/machine/machine.py | 2 +- 7 files changed, 19 insertions(+), 13 deletions(-) diff --git a/.gitignore b/.gitignore index 31aec5c..6093f6b 100644 --- a/.gitignore +++ b/.gitignore @@ -8,4 +8,5 @@ component/LkpTests/compatibility_help/compatibility_testing component/LkpTests/compatibility_help/compatibility_testing.tar.gz component/LkpTests/lkp_help/lkp-tests.tar.gz component/DevkitDistribute/devkit_distribute/config/log.ini -component/DevkitDistribute/devkit_distribute/config/devkit_distribute.yaml \ No newline at end of file +component/DevkitDistribute/devkit_distribute/config/devkit_distribute.yaml +devkitdependencies \ No newline at end of file diff --git a/component/DevkitDistribute/check_install_result.sh b/component/DevkitDistribute/check_install_result.sh index 2f65208..d04a89b 100644 --- a/component/DevkitDistribute/check_install_result.sh +++ b/component/DevkitDistribute/check_install_result.sh @@ -1,6 +1,6 @@ #!/bin/bash -if [ -e "${HOME}"/.local/lkp-tests/programs/devkit_distribute ] ; then +if [ -e "${HOME}"/.local/devkit_distribute ] ; then echo "true" else echo "false" diff --git a/component/DevkitDistribute/install.sh b/component/DevkitDistribute/install.sh index 3d2a3b8..1f4a094 100644 --- a/component/DevkitDistribute/install.sh +++ b/component/DevkitDistribute/install.sh @@ -4,11 +4,8 @@ set -e function main (){ - devkit_distribute_tar=$1 - echo "Decompress devkit_distribute.tar.gz to ${HOME}/.local/lkp-tests/programs" - tar --no-same-owner -zxf "${devkit_distribute_tar}" -C "${HOME}"/.local/lkp-tests/programs - chmod 755 "${HOME}"/.local/lkp-tests/programs/devkit_distribute/bin/start.sh - ln -s "${HOME}"/.local/lkp-tests/programs/devkit_distribute/bin/start.sh "${HOME}"/.local/lkp-tests/tests/devkit_distribute + echo "Decompress devkit_distribute.tar.gz to ${HOME}/.local/" + tar --no-same-owner -zxf /tmp/devkitdependencies/devkit_distribute.tar.gz -C ${HOME}/.local echo "Decompress devkit_distribute.tar.gz to ${HOME}/.local finished." } diff --git a/tools/install_dependency/src/constant.py b/tools/install_dependency/src/constant.py index c58f279..9602352 100644 --- a/tools/install_dependency/src/constant.py +++ b/tools/install_dependency/src/constant.py @@ -16,7 +16,7 @@ ROLE_COMPONENT = { SCANNER: ["BiShengJDK17", "DevKitCLI"], C_BUIDLER: ["GCCforOpenEuler", "BiShengCompiler", "BiShengJDK17", "A-FOT", "NonInvasiveSwitching"], JAVA_BUILDER: ["BiShengJDK17", "BiShengJDK8"], - EXECUTOR: ["BiShengJDK17", "LkpTests"], + EXECUTOR: ["BiShengJDK17", "DevkitDistribute", "LkpTests"], DEVKIT: ["DevKitWeb"] } diff --git a/tools/install_dependency/src/download/download_config.py b/tools/install_dependency/src/download/download_config.py index ac84b37..b9d1623 100644 --- a/tools/install_dependency/src/download/download_config.py +++ b/tools/install_dependency/src/download/download_config.py @@ -25,7 +25,11 @@ LkpTests = { "file": "https://gitee.com/openeuler/devkit-pipeline/releases/download/v0.2/lkp-tests.tar.gz", "GemDependency": "https://gitee.com/openeuler/devkit-pipeline/releases/download/v0.2/gem_dependencies.zip", "CompatibilityTesting": "https://gitee.com/openeuler/devkit-pipeline/releases/download/v0.2/compatibility_testing.tar.gz", - "DevkitDistribute": "https://gitee.com/openeuler/devkit-pipeline/releases/download/v0.2/devkit_distribute.tar.gz", +} + +DevkitDistribute = { + "component_name": "DevkitDistribute", + "file": "https://gitee.com/openeuler/devkit-pipeline/releases/download/v0.2/devkit_distribute.tar.gz", } A_FOT = { diff --git a/tools/install_dependency/src/download/download_utils.py b/tools/install_dependency/src/download/download_utils.py index 4be85f2..4080a25 100644 --- a/tools/install_dependency/src/download/download_utils.py +++ b/tools/install_dependency/src/download/download_utils.py @@ -79,9 +79,13 @@ component_collection_map = { SAVE_PATH: f"{os.path.join(DEFAULT_PATH, download_config.LkpTests.get('CompatibilityTesting').split('/')[-1])}", FILE_SIZE: "76645477", }, - "DevkitDistribute": { - URL: f"{download_config.LkpTests.get('DevkitDistribute')}", - SAVE_PATH: f"{os.path.join(DEFAULT_PATH, download_config.LkpTests.get('DevkitDistribute').split('/')[-1])}", + + }, + + "DevkitDistribute": { + "download file": { + URL: f"{download_config.DevkitDistribute.get(FILE)}", + SAVE_PATH: f"{os.path.join(DEFAULT_PATH, download_config.DevkitDistribute.get(FILE).split('/')[-1])}", FILE_SIZE: "13349694", } }, diff --git a/tools/install_dependency/src/machine/machine.py b/tools/install_dependency/src/machine/machine.py index ed67933..6bf8b78 100644 --- a/tools/install_dependency/src/machine/machine.py +++ b/tools/install_dependency/src/machine/machine.py @@ -136,6 +136,7 @@ class Machine: "BiShengCompiler": self.default_install_component_handle, "BiShengJDK17": self.default_install_component_handle, "BiShengJDK8": self.default_install_component_handle, + "DevkitDistribute": self.default_install_component_handle, "LkpTests": self.lkptest_install_component_handle, "NonInvasiveSwitching": self.nis_install_component_handle, "DevKitWeb": self.devkitweb_install_component_handle, @@ -248,7 +249,6 @@ class Machine: # 清理tmp临时文件 self.clear_tmp_file_at_remote_machine(ssh_client, remote_file_list) self.__install_component_on_lkptest("CompatibilityTesting", sftp_client, ssh_client) - self.__install_component_on_lkptest("DevkitDistribute", sftp_client, ssh_client) def __install_component_on_lkptest(self, sub_component_name, sftp_client, ssh_client): # 上传 tar.gz 文件 -- Gitee From 5cff4864f7cb9c0d92df20e87883d9582f282422 Mon Sep 17 00:00:00 2001 From: zoupanpan Date: Sun, 7 Apr 2024 09:36:58 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E9=BB=98=E8=AE=A4?= =?UTF-8?q?=E5=AF=86=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- component/DevkitDistribute/devkit_distribute/bin/entrance.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/component/DevkitDistribute/devkit_distribute/bin/entrance.py b/component/DevkitDistribute/devkit_distribute/bin/entrance.py index 26aedf1..1f7c799 100644 --- a/component/DevkitDistribute/devkit_distribute/bin/entrance.py +++ b/component/DevkitDistribute/devkit_distribute/bin/entrance.py @@ -318,7 +318,7 @@ def main(): help="the port of the kunpeng DevKit server") parser.add_argument("-U", "--devkit-user", dest="devkit_user", default="devadmin", help="the user of the kunpeng DevKit server") - parser.add_argument("-W", "--devkit-password", dest="devkit_password", default="admin100", + parser.add_argument("-W", "--devkit-password", dest="devkit_password", default="devkit123", help="the password of the user of the kunpeng DevKit server") parser.add_argument("-a", "--app", required=True, dest="applications", help="the process names that can be multiple, each separated by a comma") -- Gitee