Java Reference
In-Depth Information
Figure 1-13. Jenkins: Starting a new job
In the next few sections of the form, Jenkins uses dynamic HTML to make entry fields ap-
pear based on what you've checked. My demo project “TooSmallToFail” starts off with no
source code management (SCM) repository, but your real project is probably already in Git,
Subversion, or maybe even CVS or some other SCM. Don't worry if yours is not listed; there
are hundreds of plug-ins to handle almost any SCM. Once you've chosen your SCM, you
will enter the parameters to fetch the project's source from that SCM repository, using text
fields that ask for the specifics needed for that SCM: a URL for Git, a CVSROOT for CVS,
and so on.
You also have to tell Jenkins when and how to build (and package, test, deploy…) your pro-
ject. For the when , you have several choices such as building it after another Jenkins project,
building it every so often based on a cron-like schedule, or based on polling the SCM to see
if anything has changed (using the same cron-like scheduler). If your project is at GitHub
(not just a local Git server), or some other SCMs, you can have the project built whenever
somebody pushes changes up to the repository. It's all a matter of finding the right plug-ins
and following the documentation for them.
Then the how , or the build process. Again, a few build types are included with Jenkins, and
many more are available as plug-ins: I've used Apache Ant, Apache Maven, Gradle, the tra-
ditional Unix make tool, and even shell or command lines. As before, text fields specific to
your chosen tool will appear once you select the tool. In the toy example, TooSmallToFail , I
Search WWH ::




Custom Search