Create a gist now

Instantly share code, notes, and snippets.

What would you like to do?
Jenkins Job
String app = "JobGitHUb"
folder("${app}") {
description "Semua jobs dari github"
}
job("${app}/Package") {
description "Ini adalah\nDeskripsi"
logRotator {
daysToKeep(7)
numToKeep(10)
}
label('slave')
scm {
git {
remote {
url('https://github.com/tuanpembual/jenkins-jobs.git')
credentials('jenkins')
}
branch('master')
}
}
steps {
gradle {
tasks('clean')
}
shell('''#!/bin/bash -e
echo "hello world"''')
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment