如何配置Jenkins构建服务器

In the previous chapter, we studied the on the details about what is Jenkins, its usage and best practices to be made while working with Jenkins. Now, let us see configuring Jenkins in our local machines.

在上一章中,我们详细研究了什么是Jenkins,其用法以及与Jenkins合作时应采取的最佳做法。 现在,让我们看看在本地计算机中配置Jenkins。

Note : The below steps shows how to install and configure Jenkins a windows environment and using Apache Tomcat web server.

注意:以下步骤显示了如何在Windows环境中安装和配置Jenkins以及如何使用Apache Tomcat Web服务器。

詹金斯设置 (Jenkins Setup)

  1. Download the latest Jenkins.war from https://jenkins-ci.org/. Towards the right top click on the link latest and greatest to download the latest war file.

    https://jenkins-ci.org/下载最新的Jenkins.war。 在右上方,单击最新和最重要的链接以下载最新的war文件。

  2. Deploy the Jenkins.war file in the local web server of our machine. E.g. Tomcat

    在我们机器的本地Web服务器上部署Jenkins.war文件。 例如Tomcat

  3. Start the server and open the browser and hit the URL http://localhost:8080/jenkins

    启动服务器并打开浏览器,然后单击URL http:// localhost:8080 / jenkins

    Configuring Jenkins


  4. Click on the create new jobs link to configure a project for build automation. Enter the details of the project as shown below and click OK.

    单击“ 创建新作业”链接以配置用于构建自动化的项目。 输入项目的详细信息,如下所示,然后单击“确定”。

    Configuring Jenkins


  5. In the next page, fill all the required details like - description, path of the project's pom.xml and other details and click save.

    在下一页中,填写所有必需的详细信息,例如-描述,项目的pom.xml的路径以及其他详细信息,然后单击“保存”。

    Configuring Jenkins
    Configuring Jenkins
    Configuring Jenkins


  6. A project/job is created in Jenkins. As shown below:

    在詹金斯中创建了一个项目/职位。 如下所示:

    Configuring Jenkins
  7. Click on the Build now option as shown above. This will read the pom.xml and pull out the latest code and executes a build process and generates the jar/war file accordingly.

    单击上面所示的“立即构建”选项。 这将读取pom.xml并提取最新代码,并执行构建过程并相应地生成jar / war文件。

    Configuring Jenkins
  8. Click on the build number link and it opens up the build details. Click on the console output to see the logs of the build.

    单击内部版本号链接,它会打开内部版本详细信息。 单击控制台输出以查看生成的日志。

    Configuring Jenkins
    Configuring Jenkins
    Configuring Jenkins
    Configuring Jenkins

翻译自: https://www.studytonight.com/jenkins/configuring-jenkins

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值