From 4035949188dca997cadcf45dfdb3f5b266ea74d3 Mon Sep 17 00:00:00 2001 From: lizw <1183409807@qq.com> Date: Mon, 31 Oct 2022 22:19:39 +0800 Subject: [PATCH] 07env-install-centos.sh --- 00base/08jenkins-agent-install-centos.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/00base/08jenkins-agent-install-centos.sh b/00base/08jenkins-agent-install-centos.sh index 00ea86f..84bfd96 100644 --- a/00base/08jenkins-agent-install-centos.sh +++ b/00base/08jenkins-agent-install-centos.sh @@ -219,7 +219,7 @@ function init:mkdir() { log::info "[mkdir]" "创建目录..." local host="127.0.0.1" command::exec "${host}" " - mkdir -p ${BASE_DIR} + sudo mkdir -p ${BASE_DIR} sudo chown -R \\\$(id -u):\\\$(id -g) ${BASE_DIR} " check::exit_code "$?" "git" "$host 创建目录:${BASE_DIR}" "exit" @@ -231,8 +231,8 @@ function init:git() { log::info "[git]" "安装git环境..." local host="127.0.0.1" command::exec "${host}" " - yum -y install https://packages.endpointdev.com/rhel/7/os/x86_64/endpoint-repo.x86_64.rpm - yum -y install git + sudo yum -y install https://packages.endpointdev.com/rhel/7/os/x86_64/endpoint-repo.x86_64.rpm + sudo yum -y install git git --version git config --global credential.helper store "