Travis-like Jenkins job generation using Job DSL plugin groovy scripts. Reads .travis.yml and generates a job in Jenkins.
The library API is also fully documented. To generate the
latest developer docs execute the following command.
./gradlew groovydoc
The documentation can be found in build/docs/groovydoc
.
lifecycles.yaml
,toolchains.yaml
, and platforms.yaml
.vars/
and resources/
Jervis is a combination of some letters in the words Jenkins and Travis: JEnkins
tRaVIS. Jenkins is a continuous integration tool which is
typically installed on premises. Travis is a hosted, distributed
continuous integration system used by many open source projects.
Both Jenkins and Travis have paid and enterprise offerings.
Jervis uses Travis-like job generation using the Job DSL
plugin and groovy scripts. It reads the .jervis.yml
file of a project and generates a job in Jenkins based on it. If .jervis.yml
doesn’t exist then it will fall back to using the .travis.yml
file.
For development planning and other documentation see the Jervis
wiki. If you wish to stay up to date with the latest Jervis news
then please feel free to watch this repository because I use the
issue tracking and wiki for planning.
What is Jervis attempting to scale? Let’s talk about some scale bottlenecks
that have been overcome by Jenkins (formerly Hudson) and its community.
The scaling issue is a main bullet. The solution for the issue is in a
sub-bullet.
To include this library for use in your Job DSL plugin scripts you only need
include it in your build tool.
<dependency>
<groupId>net.gleske</groupId>
<artifactId>jervis</artifactId>
<version>2.0</version>
<type>pom</type>
</dependency>
Your Job DSL scripts should have a build.gradle
file which has the following
contents.
apply plugin: 'maven'
repositories {
mavenCentral()
}
configurations {
libs
}
dependencies {
libs 'net.gleske:jervis:2.0'
libs 'org.yaml:snakeyaml:2.0'
}
task cleanLibs(type: Delete) {
delete 'lib'
}
task libs(type: Copy) {
into 'lib'
from configurations.libs
}
defaultTasks 'clean', 'libs'
clean.dependsOn cleanLibs
Then execute ./gradlew libs
to assemble dependencies into the lib
directory
of the Jenkins workspace. Don’t forget to add lib
to the classpath. This
must be done before you configure your Jenkins job to execute Job DSL scripts.
Groovy Console is built into the Gradle file.
./gradlew console
Generate code coverage reports.
./gradlew clean check jacocoTestReport
Build the jar file.
./gradlew clean jar
Sign build jars and sign archives.
./gradlew clean check signArchives
See also RELEASE.md.
See SonarQube README.
Copyright 2014-2024 Sam Gleske
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.