项目作者: carlosCharz

项目描述 :
Install jenkins 2.x in AWS (Amazon Linux AMI)
高级语言:
项目地址: git://github.com/carlosCharz/installjenkinsaws.git
创建时间: 2017-07-17T14:39:05Z
项目社区:https://github.com/carlosCharz/installjenkinsaws

开源协议:

下载


Install Jenkins 2.x in AWS EC2 Instance (Amazon Linux AMI)

Software to install

  • Java 8
  • Jenkins 2.x

Check YUM Updates

  1. sudo su
  2. yum list installed
  3. yum update

Install Java 8

  1. yum install java-1.8.0
  2. yum remove java-1.7.0-openjdk

Install Jenkins 2.x

1 Download Jenkins from the Red Hat Repository

  1. wget -O /etc/yum.repos.d/jenkins.repo http://pkg.jenkins-ci.org/redhat/jenkins.repo

2 Import the verification key using the package manager RPM

  1. rpm --import https://jenkins-ci.org/redhat/jenkins-ci.org.key

3 Install Jenkins with yum command

  1. yum install jenkins

Start Jenkins Service

  1. service jenkins start

Jenkins Paths

1 To change the default port of Jenkins you need to edit the jenkins config file

  1. vim /etc/sysconfig/jenkins

2 Change the port according your desired configuration (vi commands: “i” for insert mode, “ESC” key to escape the inserting mode, “:wq” for write an quit)

  1. JENKINS_PORT="8081"

Check Jenkins Installation

  • fuser: to display the process id(PID) of every process using the specified files
    1. fuser -v -n tcp 8080
  • netstat: to list out all the network (socket) connections on a system
    1. netstat -na | grep 8080

Set Auto Start for Jenkins Service

  1. sudo chkconfig --list jenkins
  2. sudo chkconfig jenkins on