gradle-jenkins-dsl

This is a gradle plugin for programmatically configuring Jenkins jobs, using javaposse dsl dialect

License

License

Categories

Categories

Gradle Build Tools Jenkins Continuous Integration and Continuous Delivery
GroupId

GroupId

hu.rxd
ArtifactId

ArtifactId

gradle-jenkins-dsl
Last Version

Last Version

1.22.2
Release Date

Release Date

Type

Type

jar
Description

Description

gradle-jenkins-dsl
This is a gradle plugin for programmatically configuring Jenkins jobs, using javaposse dsl dialect
Project URL

Project URL

https://github.com/kgyrtkirk/gradle-jenkins-dsl
Source Code Management

Source Code Management

https://github.com/kgyrtkirk/gradle-jenkins-dsl.git

Download gradle-jenkins-dsl

How to add to project

<!-- https://jarcasting.com/artifacts/hu.rxd/gradle-jenkins-dsl/ -->
<dependency>
    <groupId>hu.rxd</groupId>
    <artifactId>gradle-jenkins-dsl</artifactId>
    <version>1.22.2</version>
</dependency>
// https://jarcasting.com/artifacts/hu.rxd/gradle-jenkins-dsl/
implementation 'hu.rxd:gradle-jenkins-dsl:1.22.2'
// https://jarcasting.com/artifacts/hu.rxd/gradle-jenkins-dsl/
implementation ("hu.rxd:gradle-jenkins-dsl:1.22.2")
'hu.rxd:gradle-jenkins-dsl:jar:1.22.2'
<dependency org="hu.rxd" name="gradle-jenkins-dsl" rev="1.22.2">
  <artifact name="gradle-jenkins-dsl" type="jar" />
</dependency>
@Grapes(
@Grab(group='hu.rxd', module='gradle-jenkins-dsl', version='1.22.2')
)
libraryDependencies += "hu.rxd" % "gradle-jenkins-dsl" % "1.22.2"
[hu.rxd/gradle-jenkins-dsl "1.22.2"]

Dependencies

compile (3)

Group / Artifact Type Version
org.codehaus.groovy.modules.http-builder : http-builder jar 0.5.2
xmlunit : xmlunit jar 1.3
hu.rxd : job-dsl-core jar 1.22-rxd-+

test (1)

Group / Artifact Type Version
org.spockframework : spock-core jar 0.7-groovy-1.8

Project Modules

There are no modules declared in this project.

in this fork:

  • merged functionality of original gradle-jenkins-plugin + jenkins/job-dsl-core
  • plugin available in mavencentral along with job-dsl-core
  • gradle declaration dialect for servers/jobs have been changed in 0.6
    • servers { a {B} ; b {B} } -> server('a') {B} ; server('b') {B}
    • template support has been removed temporarily
    • 'uri' declaration for servers
  • versioning scheme changed to start with base job-dsl-core version...from now on: 1.22.1
  • views are supported

by using this plugin enables the following:

apply plugin: 'jenkins'

buildscript {
	repositories { mavenCentral() }
	dependencies {
		classpath('hu.rxd:gradle-jenkins-dsl:1.22.+')
	}
}

jenkins {
	server('testing') {
		url 'http://localhost:8081'
		secure false
		//username "testuser" // optional
		//password "testpass" // optional
	}
	server('t1'){
		uri 'https://user:[email protected]'
	}

	defaultServer servers.testing // optional

	job('test'){
		server servers.testing
		steps { shell("ls -l") }
	}

	job('test2') {
		steps { shell("ls") }
	}
	
	view('view1') {
	   
	}
}

jenkins-job-dsl home: https://github.com/jenkinsci/job-dsl-plugin/wiki

This plugin started as a fork of ghale's gradle-jenkins-plugin (https://github.com/ghale/gradle-jenkins-plugin/wiki)

thank you for creating original plugin's :

gradle-jenkins-plugin

Gradle plugin to programmatically configure Jenkins jobs. This plugin allows you to maintain jenkins job configurations in source control and apply them to the server via gradle. Jobs can be stored as straight xml files, xml strings, or as markup builder closures. Job templates can be defined that can then be manipulated in Groovy XmlSlurper fashion such that multiple jobs can be generated off of a single template definition.

See https://github.com/ghale/gradle-jenkins-plugin/wiki for details on usage.

Versions

Version
1.22.2
0.6.0-3
0.5.0-2
0.5.0-1