KanonConductor

changeset 40:0ebe01765780 jenkins-support

fix some error for jenkins.
author chris
date Mon, 28 Mar 2011 18:05:30 +0900
parents 818ff3eb8a6f
children 720bf987d35a
files kanon-setup
diffstat 1 files changed, 8 insertions(+), 6 deletions(-) [+]
line diff
     1.1 --- a/kanon-setup	Mon Mar 28 17:26:17 2011 +0900
     1.2 +++ b/kanon-setup	Mon Mar 28 18:05:30 2011 +0900
     1.3 @@ -7,6 +7,7 @@
     1.4  then
     1.5      OS='debian'
     1.6      APACHE_USER=www-data
     1.7 +    echo "Debian / Ubuntu が検出されました。"
     1.8  elif [ -f /etc/redhat-release ]
     1.9  then
    1.10      APACHE_USER=apache
    1.11 @@ -14,8 +15,10 @@
    1.12      if [ "$CHK" != '' ]
    1.13      then
    1.14          OS='rhel5'
    1.15 +        echo "RHEL 5.x / CentOS 5.x / OEL 5.xが検出されました。"
    1.16      else
    1.17          OS='rhel6'
    1.18 +        echo "RHEL 6.x / CentOS 6.x / OEL 6.xが検出されました。"        
    1.19      fi
    1.20  else
    1.21      echo "サポートされていないOSです。"
    1.22 @@ -63,7 +66,7 @@
    1.23  echo -n "Mavenをインストールしますか?(y/n) "
    1.24  read YN
    1.25  
    1.26 -if [ "$YN" != "y" ]
    1.27 +if [ "$YN" = "y" ]
    1.28  then
    1.29      MAVEN=y
    1.30  fi
    1.31 @@ -75,7 +78,7 @@
    1.32  echo -n "Jenkinsをインストールしますか?(y/n) "
    1.33  read YN
    1.34  
    1.35 -if [ "$YN" != "y" ]
    1.36 +if [ "$YN" = "y" ]
    1.37  then
    1.38      JENKINS=y
    1.39  fi
    1.40 @@ -119,7 +122,7 @@
    1.41              fi
    1.42              apt-get update
    1.43              apt-get -y install jenkins openjdk-6-jdk
    1.44 -            CHK=`grep "/etc/default/jenkins" prefix`
    1.45 +            CHK=`grep prefix "/etc/default/jenkins"`
    1.46              if [ "$CHK" = '' ]
    1.47              then
    1.48                  cat /etc/default/jenkins |sed 's/JENKINS_ARGS="/JENKINS_ARGS="--prefix=\/jenkins /' > /tmp/jenkins_config
    1.49 @@ -129,9 +132,8 @@
    1.50              ;;
    1.51          rhel5|rhel6)
    1.52              wget -O /etc/yum.repos.d/jenkins.repo http://pkg.jenkins-ci.org/redhat/jenkins.repo
    1.53 -            rpm --import http://pkg.jenkins-ci.org/redhat/jenkins-ci.org.key
    1.54 -            yum -y install jenkins
    1.55 -            CHK=`grep "/etc/sysconfig/jenkins" prefix`
    1.56 +            yum -y --nogpgcheck install jenkins
    1.57 +            CHK=`grep prefix "/etc/sysconfig/jenkins"`
    1.58              if [ "$CHK" = '' ]
    1.59              then
    1.60                  cat /etc/sysconfig/jenkins |sed 's/JENKINS_ARGS=""/JENKINS_ARGS="--prefix=\/jenkins"/' > /tmp/jenkins_config