Skip to content

Commit b39ae61

Browse files
committed
🐛 修复几个 bug
1 parent e5ea9cd commit b39ae61

3 files changed

Lines changed: 12 additions & 4 deletions

File tree

codes/deploy/main.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ function chooseOper() {
7373
git) ${filepath}/tool/git/install-git.sh;;
7474
svn) ${filepath}/tool/svn/install-svn.sh;;
7575
jdk8) ${filepath}/tool/jdk/install-jdk8.sh;;
76-
maven) ${filepath}/tool/maven/install-maven.sh;;
76+
maven) ${filepath}/tool/maven/install-maven3.sh;;
7777
nginx) ${filepath}/tool/nginx/install-nginx.sh;;
7878
nodejs) ${filepath}/tool/nodejs/install-nodejs.sh;;
7979
tomcat) ${filepath}/tool/tomcat/install-tomcat8.sh;;

codes/deploy/tool/jdk/install-jdk8.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,12 @@ echo -e "\n>>>>>>>>> install jdk8"
44

55
yum -y install java-1.8.0-openjdk-devel-debug.x86_64
66

7-
cat >/etc/profile.d/jdk.sh<<EOF
7+
cat >> /etc/profile << EOF
88
JAVA_HOME=/usr/lib/jvm/java
99
PATH=${JAVA_HOME}/bin:\$PATH
1010
CLASSPATH=.:\$JAVA_HOME/lib/dt.jar:\$JAVA_HOME/lib/tools.jar
1111
export JAVA_HOME
1212
export PATH
1313
export CLASSPATH
1414
EOF
15-
chown root.root /etc/profile.d/jdk.sh
15+
source /etc/profile

codes/deploy/tool/maven/install-maven3.sh

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,5 +6,13 @@ mkdir -p /opt/software/maven
66
cd /opt/software/maven
77

88
version=3.5.2
9-
wget --no-check-certificate --no-cookies --header "Cookie: oraclelicense=accept-securebackup-cookie" http://mirrors.shuosc.org/apache/maven/maven-3/${version}/binaries/apache-maven-${version}-bin.tar.gz
9+
wget --no-check-certificate --no-cookies --header "Cookie: oraclelicense=accept-securebackup-cookie" http://mirrors.tuna.tsinghua.edu.cn/apache/maven/maven-3/${version}/binaries/apache-maven-${version}-bin.tar.gz
1010
tar -zxvf apache-maven-${version}-bin.tar.gz
11+
12+
cat >> /etc/profile << EOF
13+
MAVEN_HOME=/opt/software/maven/apache-maven-\${version}
14+
PATH=\${MAVEN_HOME}/bin:\${PATH}
15+
export MAVEN_HOME
16+
export PATH
17+
EOF
18+
source /etc/profile

0 commit comments

Comments
 (0)