Jenkins+git Integration test (build, zip, curl)

Source: Internet
Author: User

Since the last article, "Jenkins + Git Build Continuous Integration environment", this configuration of the job has new requirements, but also stepped into a new pit. It is hereby recorded that the police have their own body.

Task Requirements:

These three steps add a build step to the build section of the Job Configuration page.

First add the "Package Build" command:

CD Buildscriptsbuild.bat

Dojo's build tools are automatically used in BUILD.bat.

To add a compression command:

CD Buildoutput//Copy the built-in folders and files to a directorymkdir webappbuilderforarcgismove Client Webappbuilderforarcgismove server Webappbuilderforarcgismove Startup.bat Webappbuilderforarcgis//copy Nodejs.exe to the directoryxcopy E:\youPath\nodejs webappbuilderforarcgis\server/y/E//call 7zip to generate a compressed package"C:\Program Files\7-zip\7z.exe" a wab.zip webappbuilderforarcgis\*//Copy the ZIP package to the target directorymkdir E:\yourPath\WebAppBuilderForArcGIS\%BUILD_NUMBER%copy wab.zip E:\xt-release\webappbuilderforarcgis\%build_number%Move Wab.zip E:\xt-release\webappbuilderforarcgis\

7zip and Nodejs are required during this step

Send zip:

Curl http://server:8080/job/project/build?token=build_wabsanity

In this step we use the Curl command to tell another remote server that our zip has been compressed. After the remote server accepts the command, it executes its own automation script.

In this process, Windows users need to install curl separately and configure Curl's directory in the global variable path to make Curl a global command.

The pits encountered in this configuration are: Although all script commands do not have asynchronous operations, if all of the commands are placed in a build step, the following command will not continue after the BUILD.bat is executed. The final conclusion is that the entire process is split and each part is placed in a single build step .

  

Jenkins+git Integration test (build, zip, curl)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.