How to install/run Jenkins on Apache Tomcat Serve

Total Steps:

  1. Step1, Download java 8 or 11 as Jenkins supports that
  2. Step2, Download Apache Tomcat Server
  3. Step3, Download Jenkins.war file
  4. Step4, Copy Jenkins.war to "webapps" folder of folder of Apache Tomcat Server
  5. Step5, Start Apache Tomcat Server
  6. Step6, Hit Tomcat URL
  7. Step7, Launch Jenkins from Apache URL
  8. Step8, Install plugins
  9. Step9, Shutdown running Tomcat server

Step1, Download java 8 or 11 as Jenkins supports that

Step2, Download Apache Tomcat Server

  • download:https://tomcat.apache.org/
  • select proper version and platform(windows or linux or mac)
  • if windows then could select core : "64-bit_windows_zip"


Step3, Download Jenkins.war file

  • download: https://www.jenkins.io/download/
  • select/choose "Generic Java package(.war)" to download in part "Long-term Support(LTS)"

Step4, Copy Jenkins.war to "webapps" folder of folder of Apache Tomcat Server

  • find "webapps" folder in Apache Tomcat (ex: apache-tomcat-9.0xxx-windows-x64)
  • copy "Jenkins.war" to "webapps" of Apache Tomcat (ex: apache-tomcat-9.0xxx-windows-x64)

Step5, Start Apache Tomcat Server

  • startup – To start tomcat server. By default it starts at 8080 port
  • shutdown – To shutdown running tomcat server
  • change default port 8080 to any port(ex:8010). if not change, it will conflict and prompt Error.
  • how to change port? solution is: 1) go to conf folder in Apache tomcat folder 2) find server.xml file,content like <Connector port="8080" protocol="HTTP/1.1" connectionTimeout="20000" redirectPort="8443" />. 3) only change port ="8080" to "8010"
  • click "startup.bat" to start server, and it will deploy Jenkins.war file as well. 
  • Note: as first setup Jenkins, an initial passord like "daf9aaxxxxxxxxxxxxx" will be provided to unlock jenkins in console(also include the password path stored), keep the password in mind. A new folder "jenkins" is created in "webapps"

Step6, Hit Tomcat URL - (localhost:8080)

  • Open a browser and input localhost:8080

Step7, Launch Jenkins from Apache URL

  • Unlock Jenkins page will be prompted. find initial password "daf9aaxxxxxxxxxxxxx" according to page prompted path OR get the information from Step5. Then Input it.

Step8, Install plugins

  • It will ask you to Customize jenkins by installing a good number of plugins. You can manually choose or install all suggested plugins. I will recommend to go for “Install suggested plugins
  • Plugin installation will take time. Let it be completed. Now it will ask you to create first admin user. Set Username and passowd then keep it in mind. then create and click on “Save and Continue” button.
  • Go through steps, then "Jenkins is ready!", click "Start using Jenkins", then "Welcome to Jenkins!" will be showed. 
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值