본문 바로가기
CI CD

Jenkins [1] 설치

by jongSuN 2021. 10. 1.

CentOS 7

sudo yum update

sudo yum install nmap

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

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

sudo yum install jenkins
rpm -qa | grep jenkins

rpm --import https://pkg.jenkins.io/redhat-stable/jenkins.io.key

위 설치가 끝나면 

/etc/sysconfig/jenkins

에서 port 번호 세팅

 

 

jenkins 실행

sudo systemctl start jenkins

 

failed to start jenkins.service : access denied
see system logs and 'systemctl status jenkins.service' for details.


job for jenkins.service failed because the control process exited with error code. See "systemctl status jenkins.service" and "journalctl -xe" for details

job for jenkins.service failed because the control process exited with error code. see "systemctl status jenkins.service" and "journalctl -xe" for details.

warning : jenkins.service changed on disk. run 'systemctl daemon-reload' to reload units

jenkins 실행 시 위와 같이 뜨는 경우 Java 가 없어서 에러일 확률이 큼

java 설치

yum install java-1.8.0-openjdk-devel.x86_64

 

jenkins 다시 실행

sudo systemctl start jenkins

 

jenkins가 잘 실행이 되었는지 확인

curl -X -L http://127.0.0.1:포트번호(위에서 세팅한 포트번호)

 

 

jenkins jobs 위치 변경

vi /var/lib/jenkins

<workspacedir> 변경

 

jenkins config 파일 위치

/etc/init.d/jenkins
/etc/sysconfig/jenkins
/var/lib/jenkins/config.xml

'CI CD' 카테고리의 다른 글

Jenkins [2] gitlab 서버 연동  (0) 2021.10.01

댓글