-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathparametrizadoDSL-V2.groovy
40 lines (40 loc) · 1.21 KB
/
parametrizadoDSL-V2.groovy
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
job('ejemplo-job-DSL-version-2') {
description('job dsl de ejemplo para el curso de jenkins-02-jun-2024')
scm {
git('https://github.com/josebaezae/jenkins.job.parametrizado.git', 'main') { node ->
node / gitConfigName('josebaeza')
node / gitConfigEmail('josebaezae@gmail.com')
}
}
parameters {
stringParam('nombre', defaultValue = 'Julian', description = 'Parametro de cadena para el Job Booleano')
choiceParam('planeta', ['Mercurio', 'Venus', 'Tierrra', 'Marte', 'Jupiter', 'Saturno', 'Urano', 'Neptuno'])
booleanParam('agente', false)
}
triggers {
cron('H/7 * * * *')
}
steps {
shell("bash jobscript.sh")
}
publishers {
mailer('josebaezae@gmail.com', true, true)
slackNotifier {
notifyAborted(true)
notifyEveryFailure(true)
notifyNotBuilt(false)
notifyUnstable(false)
notifyBackToNormal(true)
notifySuccess(false)
notifyRepeatedFailure(false)
startNotification(false)
includeTestSummary(false)
includeCustomMessage(false)
customMessage(null)
sendAs(null)
commitInfoChoice('NONE')
teamDomain(null)
authToken(null)
}
}
}