Jenkins的下载与启动,插件安装,基础配置,

Posted daokeren

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了Jenkins的下载与启动,插件安装,基础配置,相关的知识,希望对你有一定的参考价值。

Jenkins网站下载Generic java package

技术图片

 

启动Jenkins  命令:java -jar jenkins.war

 

[[email protected] Jenkins]# java -jar jenkins.war
Running from: /home/gzp_tool/Jenkins/jenkins.war
webroot: $user.home/.jenkins
Mar 16, 2019 2:40:19 AM org.eclipse.jetty.util.log.Log initialized
INFO: Logging initialized @399ms to org.eclipse.jetty.util.log.JavaUtilLog
Mar 16, 2019 2:40:19 AM winstone.Logger logInternal
INFO: Beginning extraction from war file
Mar 16, 2019 2:40:21 AM org.eclipse.jetty.server.handler.ContextHandler setContextPath
WARNING: Empty contextPath
Mar 16, 2019 2:40:21 AM org.eclipse.jetty.server.Server doStart
INFO: jetty-9.4.z-SNAPSHOT; built: 2018-08-30T13:59:14.071Z; git: 27208684755d94a92186989f695db2d7b21ebc51; jvm 1.8.0_201-b09
Mar 16, 2019 2:40:21 AM org.eclipse.jetty.webapp.StandardDescriptorProcessor visitServlet
INFO: NO JSP Support for /, did not find org.eclipse.jetty.jsp.JettyJspServlet
Mar 16, 2019 2:40:21 AM org.eclipse.jetty.server.session.DefaultSessionIdManager doStart
INFO: DefaultSessionIdManager workerName=node0
Mar 16, 2019 2:40:21 AM org.eclipse.jetty.server.session.DefaultSessionIdManager doStart
INFO: No SessionScavenger set, using defaults
Mar 16, 2019 2:40:21 AM org.eclipse.jetty.server.session.HouseKeeper startScavenging
INFO: node0 Scavenging every 600000ms
Jenkins home directory: /root/.jenkins found at: $user.home/.jenkins
Mar 16, 2019 2:40:22 AM org.eclipse.jetty.server.handler.ContextHandler doStart
INFO: Started [email protected]{Jenkins v2.168,/,file:///root/.jenkins/war/,AVAILABLE}{/root/.jenkins/war}
Mar 16, 2019 2:40:22 AM org.eclipse.jetty.server.AbstractConnector doStart
INFO: Started [email protected]{HTTP/1.1,[http/1.1]}{0.0.0.0:8080}
Mar 16, 2019 2:40:22 AM org.eclipse.jetty.server.Server doStart
INFO: Started @4057ms
Mar 16, 2019 2:40:22 AM winstone.Logger logInternal
INFO: Winstone Servlet Engine v4.0 running: controlPort=disabled
Mar 16, 2019 2:40:24 AM jenkins.InitReactorRunner$1 onAttained
INFO: Started initialization
Mar 16, 2019 2:40:27 AM jenkins.InitReactorRunner$1 onAttained
INFO: Listed all plugins
Mar 16, 2019 2:40:33 AM jenkins.InitReactorRunner$1 onAttained
INFO: Prepared all plugins
Mar 16, 2019 2:40:33 AM jenkins.InitReactorRunner$1 onAttained
INFO: Started all plugins
Mar 16, 2019 2:40:36 AM hudson.ExtensionFinder$GuiceFinder$FaultTolerantScope$1 error
INFO: Failed to instantiate optional component hudson.plugins.build_timeout.operations.AbortAndRestartOperation$DescriptorImpl; skipping
Mar 16, 2019 2:40:36 AM jenkins.InitReactorRunner$1 onAttained
INFO: Augmented all extensions
Mar 16, 2019 2:40:36 AM jenkins.InitReactorRunner$1 onAttained
INFO: Loaded all jobs
Mar 16, 2019 2:40:36 AM hudson.model.AsyncPeriodicWork$1 run
INFO: Started Download metadata
Mar 16, 2019 2:40:36 AM hudson.model.AsyncPeriodicWork$1 run
INFO: Finished Download metadata. 21 ms
Mar 16, 2019 2:40:37 AM org.springframework.context.support.AbstractApplicationContext prepareRefresh
INFO: Refreshing org.[email protected]1b12f3f: display name [Root WebApplicationContext]; startup date [Sat Mar 16 02:40:37 PDT 2019]; root of context hierarchy
Mar 16, 2019 2:40:37 AM org.springframework.context.support.AbstractApplicationContext obtainFreshBeanFactory
INFO: Bean factory for application context [org.[email protected]1b12f3f]: org.s[email protected]83b00e
Mar 16, 2019 2:40:37 AM org.springframework.beans.factory.support.DefaultListableBeanFactory preInstantiateSingletons
INFO: Pre-instantiating singletons in org.s[email protected]83b00e: defining beans [authenticationManager]; root of factory hierarchy
Mar 16, 2019 2:40:37 AM org.springframework.context.support.AbstractApplicationContext prepareRefresh
INFO: Refreshing org.[email protected]1dff569: display name [Root WebApplicationContext]; startup date [Sat Mar 16 02:40:37 PDT 2019]; root of context hierarchy
Mar 16, 2019 2:40:37 AM org.springframework.context.support.AbstractApplicationContext obtainFreshBeanFactory
INFO: Bean factory for application context [org.[email protected]1dff569]: org.s[email protected]19cfd47
Mar 16, 2019 2:40:37 AM org.springframework.beans.factory.support.DefaultListableBeanFactory preInstantiateSingletons
INFO: Pre-instantiating singletons in org.s[email protected]19cfd47: defining beans [filter,legacy]; root of factory hierarchy
Mar 16, 2019 2:40:37 AM jenkins.InitReactorRunner$1 onAttained
INFO: Completed initialization
Mar 16, 2019 2:40:37 AM hudson.WebAppMain$3 run
INFO: Jenkins is fully up and running

 

启动后在浏览器窗口输入localhost 8080,进行插件等安装,我这里的localhost 是虚拟机的IP

账号:admin

密码:password

系统管理-可选插件-search rebuilder; search ‘safe restart‘ 安装两个插件

rebuilder:用于重新构建,每次构建都会输入很多参数

search ‘safe restart‘ :安全重启jenkins

 

基础配置(安全矩阵设置管理权限)

  1. 配置全局安全属性:系统管理-全局安全配置-安全矩阵-添加用户赋予权限

  2. 添加用户:系统管理-管理用户-新增用户,再赋予用户对应权限

 

以上是关于Jenkins的下载与启动,插件安装,基础配置,的主要内容,如果未能解决你的问题,请参考以下文章

jenkins自动构建需要安装哪些插件

war包管理启动jenkins安装插件失败解决办法

war包管理启动jenkins安装插件失败解决办法

CentOS中Jenkins的下载安装配置与启动(图文教程)

Jenkins实践之入门体验

Jenkins 安装(windows版本)