Install Jenkins for Ubuntu operation system
文章目录
https://jenkins.io/zh/doc/boo...
- install java
wget -q -O - https://pkg.jenkins.io/debian-stable/jenkins.io.key | sudo apt-key add -- add the following entry in your
/etc/apt/sources.listdeb https://pkg.jenkins.io/debian-stable binary/ sudo apt-get updatesudo apt-get install jenkins- set environment path
export JAVA_HOME=/usr/lib/jvm/java-8-openjdk-amd64/
export JRE_HOME=/usr/lib/jvm/java-8-openjdk-amd64/jre/
export CLASSPATH=$JRE_HOME/lib:$CLASSPATH
export PATH=$JAVA_HOME/bin:$JRE_HOME/bin:$PATH
source /etc/profilejava -jar /usr/share/jenkins/jenkins.war --httpPort=1080- restart jenkins
/etc/init.d/jenkins restart - open in browser
127.0.0.1:1080 - login jenkins
- install recommended plugins
- create admin user
- config jenkins
- generate public key for git repositories
1).cd ~/.ssh
2).ssh-keygen// this will generate id_dsa and id_dsa.pub
3). copy the text in id_dsa.pub to git -> settings -> SSH Keys -> key - Set up new item -> source code management -> git -> repositories -> credentials -> add -> SSH Username with private key -> copy public key here.
评论
登录后参与技术讨论,分享你的经验与见解。
登录 / 注册暂无评论