jenkins-fire-cli: simplify the usage of jenkins-cli and job-dsl commandl line

2022-09-14 Thread Weihong Xu
config set user.name john.doe jenkins-fire-cli config set user.token TOKEN_OR_PASSWORD jenkins-fire-cli init # to download jenkins-cli.jar and jenkins-job-dsl-core.jar And then you can run the command line jenkins-fire-cli run list-jobs More detail could be found here: https://github.com/link89

Re: Junit test : seed job to maven Job DSL

2020-12-17 Thread Charles Moulliard
FYI: I can, of course, create the job and build it using the `config.xml` generated on a jenkins instance running locally -> `java -jar jenkins-cli.jar -s http://localhost:8080 create-job maven-seed-job2 < seed-maven-job2.xml` So I suspect a problem with the Job DSL Plugin when the job

Junit test : seed job to maven Job DSL

2020-12-17 Thread Charles Moulliard
Hi I created a Junit test case which is available here: https://github.com/ch007m/jenkins-job-dsl/blob/31efa049a95c333a8dba9b01ff2aa281b3520e34/src/test/java/dev/snowdrop/MavenJobDSLTest.java#L25-L53 where a seed job is created to populate a mavenJob using the DSL groovy file provided But

Re: How to Import a java jar on jenkins to be used by Job DSL - Groovy Script ?

2020-12-14 Thread Charles Moulliard
14, 2020 at 10:55 AM Charles Moulliard > wrote: > >> Hi, >> >> How can we Import a java jar on jenkins in order to allow a Groovy Script >> part of a Job DSL to use java classes packaged within the jar file ? >> >> Example of groovy script using the Ja

Re: How to Import a java jar on jenkins to be used by Job DSL - Groovy Script ?

2020-12-14 Thread Charles Moulliard
020 at 4:55 PM Charles Moulliard > wrote: > >> Hi, >> >> How can we Import a java jar on jenkins in order to allow a Groovy Script >> part of a Job DSL to use java classes packaged within the jar file ? >> >> Example of groovy script using the Java class Hello

Re: How to Import a java jar on jenkins to be used by Job DSL - Groovy Script ?

2020-12-14 Thread Yeikel
/doc/book/pipeline/shared-libraries/ > > On Mon, Dec 14, 2020 at 10:55 AM Charles Moulliard > wrote: > >> Hi, >> >> How can we Import a java jar on jenkins in order to allow a Groovy Script >> part of a Job DSL to use java classes packaged within the jar file ? >&g

Re: How to Import a java jar on jenkins to be used by Job DSL - Groovy Script ?

2020-12-14 Thread Nick Stolwijk
Sorry, missed the part about JobDSL. I found a plugin which makes that possible: https://github.com/AOEpeople/gradle-jenkins-job-dsl-plugin With regards, Nick Stolwijk ~~~ Try to leave this world a little better than you found it and, when your turn comes to die, you can die happy in feeling

Re: How to Import a java jar on jenkins to be used by Job DSL - Groovy Script ?

2020-12-14 Thread Yeikel
How about shared libraries? https://www.jenkins.io/doc/book/pipeline/shared-libraries/ On Mon, Dec 14, 2020 at 10:55 AM Charles Moulliard wrote: > Hi, > > How can we Import a java jar on jenkins in order to allow a Groovy Script > part of a Job DSL to use java classes packaged wi

Re: How to Import a java jar on jenkins to be used by Job DSL - Groovy Script ?

2020-12-14 Thread Nick Stolwijk
~~~ Lord Baden-Powell On Mon, Dec 14, 2020 at 4:55 PM Charles Moulliard wrote: > Hi, > > How can we Import a java jar on jenkins in order to allow a Groovy Script > part of a Job DSL to use java classes packaged within the jar file ? > > Example of groovy script using the Java clas

How to Import a java jar on jenkins to be used by Job DSL - Groovy Script ?

2020-12-14 Thread Charles Moulliard
Hi, How can we Import a java jar on jenkins in order to allow a Groovy Script part of a Job DSL to use java classes packaged within the jar file ? Example of groovy script using the Java class Hello and method "message" package groovy import dev.snowdrop.jenkins.Hello; println

Re: Access to Gitlab Api Token via Credential Provider in a Job DSL Groovy Script

2020-03-30 Thread 'Sandra Parsick' via Jenkins Users
idea is to use Gitlab plugin and > Credential Plugin for storing the API token and the Job DSL plugin for > creating this bunch of jobs. At the moment, my seed job has only one build > step "Process Job DSLs". In this step, I call following D

Re: job-dsl: Dynamic DSL - gitscmsource - includes

2020-01-21 Thread Alex
traits << > 'jenkins.plugins.git.traits.BranchDiscoveryTrait' {} > } >triggers { > periodic(5) >} > orphanedItemStrategy {

job-dsl: Dynamic DSL - gitscmsource - includes

2020-01-20 Thread Alex
} triggers { periodic(5) } orphanedItemStrategy { discardOldItems { daysToKeep(3) numToKeep(3) } }

Re: Jenkins job dsl- any way to dry run before affecting changes?

2020-01-02 Thread Lee Meador
;ve just seen your comment in the open PR regarding >>> https://issues.jenkins-ci.org/browse/JENKINS-27182 >>> >>> > What I want is for my seed job to first output what it's going to >>> change and wait for user input, then if the user confirms make the ch

Re: Jenkins job dsl- any way to dry run before affecting changes?

2019-12-30 Thread David Karr
er input, then if the user confirms make the changes >> IIUC, you would like to mimic a kind of code review similar to the GitHub >> Pull Request view process, if so, I'd say you can use the proposal from >> Daniel Spilker ( >> https://github.com/jenkinsci/job-dsl-plugin/pull/3

Re: Jenkins job dsl- any way to dry run before affecting changes?

2019-12-30 Thread red 888
> and wait for user input, then if the user confirms make the changes > IIUC, you would like to mimic a kind of code review similar to the GitHub > Pull Request view process, if so, I'd say you can use the proposal from > Daniel Spilker ( > https://github.com/jenkinsci/jo

Re: Jenkins job dsl- any way to dry run before affecting changes?

2019-12-30 Thread Victor Martinez
kind of code review similar to the GitHub Pull Request view process, if so, I'd say you can use the proposal from Daniel Spilker ( https://github.com/jenkinsci/job-dsl-plugin/pull/395#issuecomment-132346716) with https://github.com/jenkinsci/job-dsl-plugin/wiki/Testing-DSL-Scripts and the pi

Jenkins job dsl- any way to dry run before affecting changes?

2019-12-29 Thread red 888
I opened an SO post (that no one seems to be interested in) https://stackoverflow.com/questions/59314501/jenkins-job-dsl-some-way-to-do-a-dry-run I use the jenkins job dsl to create my multibranch pipeline jobs. It works great with one glaring issue- safely confirming changes _before_ applying

Re: BuildStrategies doesn't pick ignoreCommitterStrategy from multibranch generator job (i.e, job-dsl way)

2019-09-01 Thread SathyaNarayanan Kumaraswamy
Hi Team, > > I'm trying to implement BuildStrategies --> ignoreCommitterStrategy > approach via multibranch generator job (i.e, job-dsl way), since there are > many existing multibranch-pipeline jobs > > After running seed job (i.e., multibranch generator job) I could see

Re: Jenkins Ignore Committer Strategy Plugin and job DSL

2019-08-30 Thread SathyaNarayanan Kumaraswamy
Hi Neil; I'm trying to use below block in my multibranchpipeline generator under branchsources using job-dsl After building generator job upon checking on project config could see Build Strategy nothing but just an ADD button Even I tried with ignoredAuthors.add and ignoreCommitterStrateg

Re: Usage of Jenkins shared library in Job DSL

2019-08-10 Thread Tomas Bjerre
Not sure if this helps, but: I needed to share code between Pipeline and Job DSL and I solved it by using Job DSL from Pipeline. I found that easy because using shared library in Pipeline is well documented. Something like: ... stage("Create jobs") { jobDsl targets:

Re: Usage of Jenkins shared library in Job DSL

2019-08-03 Thread Nick Muzika
case shared libraries are placed in the same repository where the seed job dsl is sitting. вторник, 18 декабря 2018 г., 14:28:45 UTC-5 пользователь Philip Steiner написал: > > Thanks for the detailed followup! Lots to digest. It looks like you were > having trouble accessing th

Access to Gitlab Api Token via Credential Provider in a Job DSL Groovy Script

2019-03-15 Thread 'Sandra Parsick' via Jenkins Users
Hello, I'm currently programming a Seed Job that requests via REST API a list of repositories from a Gitlab instance. I want to iterate this list and create a pipeline job for each repository. My idea is to use Gitlab plugin and Credential Plugin for storing the API token and the Jo

Re: Usage of Jenkins shared library in Job DSL

2018-12-18 Thread Philip Steiner
Thanks for the detailed followup! Lots to digest. It looks like you were having trouble accessing the Shared Library from generated pipeline scripts, which is a little different from my problem: I want to reference YAML data files stored in the Jenkins Shared Library from inside a Job DSL

Re: Usage of Jenkins shared library in Job DSL

2018-12-18 Thread treneva
{ credentials('user') } } } scriptPath('Jenkinsfile') } } } ""&quo

Re: Usage of Jenkins shared library in Job DSL

2018-12-17 Thread Philip Steiner
Hi tre..., I know this thread is getting old, but did you ever get an answer or figure out how to use a Jenkins Shared Library in the Job DSL script, or some workaround? Thanks Philip -- You received this message because you are subscribed to the Google Groups "Jenkins Users"

Re: Jenkins Ignore Committer Strategy Plugin and job DSL

2018-11-22 Thread Neil Tingley
Thanks Victor! I will try this out. Cheers, Neil On Wed, 21 Nov 2018 at 19:23, Victor Martinez wrote: > You might need to refer to the trais sections in the branchSource > > - > /plugin/job-dsl/api-viewer/index.html#path/multibranchPipelineJob-branchSources-branchSource-sourc

Re: Jenkins Ignore Committer Strategy Plugin and job DSL

2018-11-21 Thread Victor Martinez
You might need to refer to the trais sections in the branchSource - /plugin/job-dsl/api-viewer/index.html#path/multibranchPipelineJob-branchSources-branchSource-source-git-traits-headWildcardFilter multibranchPipelineJob(buildName) { ... branchSources { branchSource

Jenkins Ignore Committer Strategy Plugin and job DSL

2018-11-20 Thread Neil T
HI All The 'Jenkins Ignore Committer Strategy Plugin ' does what I need with a multibranch pipeline but I can't find a way to configure it via the job DSL builder that works for me. Has anyone got some example DSL ? I can't stick the config in the branchSources block. ther

Re: Usage of Jenkins shared library in Job DSL

2018-08-26 Thread treneva
an add your shared library there. > > On Fri, Aug 17, 2018 at 11:05 > wrote: > >> Hey, >> >> I am looking for advice how to achieve usage of Jenkins shared library in >> Job DSL – >> I use this snipped to seed a job whose functionality is in Jen

Re: Usage of Jenkins shared library in Job DSL

2018-08-26 Thread Jan Monterrubio
Manage Jenkins -> configure system -> global libraries You can add your shared library there. On Fri, Aug 17, 2018 at 11:05 wrote: > Hey, > > I am looking for advice how to achieve usage of Jenkins shared library in > Job DSL – > I use this snipped to seed a job whos

Usage of Jenkins shared library in Job DSL

2018-08-17 Thread treneva
Hey, I am looking for advice how to achieve usage of Jenkins shared library in Job DSL – I use this snipped to seed a job whose functionality is in Jenkins file: job('my-small-test-job') { parameters { stringParam('branch', '${branch}') } removedJobActi

Re: how get copy of environment variable - groovy job-dsl

2018-05-08 Thread Victor Martinez
Just in case, this thread is already followed up in the job-dsl-plugin mailinglist: - https://groups.google.com/d/msg/job-dsl-plugin/451Jp9EtErI/H0JIGQswAwAJ -- You received this message because you are subscribed to the Google Groups "Jenkins Users" group. To unsubscribe from this

how edit copy of environment variable - job-dsl groovy

2018-05-04 Thread Josh Olson
hello, I have the slack <https://plugins.jenkins.io/slack> & job-dsl <https://plugins.jenkins.io/job-dsl> plugins installed & configured in my jenkins instance. I run the seed job for the following my-slack.groovy file: job("myfolder/myjob") { steps { s

how get copy of environment variable - groovy job-dsl

2018-05-04 Thread joshua . olson
hello, I have the slack <https://plugins.jenkins.io/slack> & job-dsl <https://plugins.jenkins.io/job-dsl> plugins installed & configured in my jenkins instance. I run the seed job for the following my-slack.groovy file: job("myfolder/myjob") { steps { s

How can I configure an organization folder to use Github with Jenkins job DSL?

2018-03-01 Thread evan
When I try to create an organization folder with the following Jenkins job DSL: organizationFolder("folderName").with { organizations { github { repoOwner("bar") credentialsId('baz') checkoutCredentialsId(&#

Re: Does Job DSL plugin support Hidden Parameter and Extensible Choice Parameter?

2018-01-03 Thread Vicki Kozel
Many thanks! On Wednesday, January 3, 2018 at 1:55:43 PM UTC-8, Victor Martinez wrote: > > JobDSL supports mostly all the plugins, further details: > Automatically-Generated-DSL > <https://github.com/jenkinsci/job-dsl-plugin/wiki/Automatically-Generated-DSL> > > You

Re: Does Job DSL plugin support Hidden Parameter and Extensible Choice Parameter?

2018-01-03 Thread Victor Martinez
JobDSL supports mostly all the plugins, further details: Automatically-Generated-DSL <https://github.com/jenkinsci/job-dsl-plugin/wiki/Automatically-Generated-DSL> You can find its api details below: - /plugin/job-dsl/api-viewer/index.html#plugin/extensible-choice-par

Does Job DSL plugin support Hidden Parameter and Extensible Choice Parameter?

2018-01-03 Thread Vicki Kozel
Hello, I need to write a job DSL that supports Hidden Parameter and Extensible Choice Parameter . Are these parameters supported in Job DSL plugin? Thanks! Vicki -- You received this message because you are subscribed to the Google Groups "Jenkins Users" group. To unsubscribe

Jenkins Pipeline / Job DSL Problem

2018-01-02 Thread khmarbaise
Hi, I currently have a simple Pipeline Script which looks more or less like this (reduced to the important parts) node { stage ('First') { // Creating a list of names names = [ "a", "b", "c" ] Job.create(this, names) } } Furthermore I have create a global pipeline lib which contai

Using Jenkins Job DSL API with declarative pipeline syntax

2017-09-07 Thread Sharon Grubner
while avoiding using a harcoded pipeline script. Does anyone have any suggestions how to approach this problem? Thanks! Sharon pipelineJob API: https://jenkinsci.github.io/job-dsl-plugin/#method/javaposse.jobdsl.dsl.DslFactory.pipelineJob <https://jenkinsci.github.io/job-dsl-plugin/#me

Job DSL issue with Parameterized Trigger and AllNodesForLabelBuildParameterFactory

2017-09-06 Thread JD
Hi, I am writing a job-dsl for parameterized trigger and the code snippet is like below: steps{ downstreamParameterized { trigger('AAA') { block { buildStepFailure('never')

Re: Job DSL: How to Use Credentials Store for authenticationToken

2017-08-25 Thread Matthias Fuchs
Thanks for the idea! In the meantime I also thought of a different idea: 1. having global properties for the auth token, e.g. Name: MY_TOKEN Value: 123 2. Access the token directly from the job dsl, e.g. authenticationToken(MY_TOKEN) Since the seed-job has access to the

Re: Job DSL: How to Use Credentials Store for authenticationToken

2017-08-25 Thread Steffen Elste
> > Hi, > to a certain extent it depends on how paranoid You allow yourself to get ;-) One solution could be to use indirection, e.g. via the Config File Provider Plugin. Use an arbitrary token in your job description, and in an additional build step access a configuration file to read the actu

Job DSL: How to Use Credentials Store for authenticationToken

2017-08-25 Thread Matthias Fuchs
Hi, I store the job specifications via job DSL on github. For one job I need an authentication token. The docu of authenticationToken mentions: "... For security reasons, do not use a hard-coded token. See Handling Credentials <https://github.com/jenkinsci/job-dsl-plugin/wiki/

Re: [EXTERNAL] - Job DSL and isDirectory does not work, any ideas?

2017-03-29 Thread Dirk Heinrichs
Am 29.03.2017 um 13:04 schrieb thomas.lehm...@teamaol.com: > I need a way to iterate files in a folder to load configuration > (multiple files) from it. > Following code does not work using *Job DSL*: > > a) you need WORKSPACE to build absolute path > The normal Groovy code

Job DSL and isDirectory does not work, any ideas?

2017-03-29 Thread thomas . lehmann
Hi, I have (locally) Jenkins 2.49 and Job DSL 1.58 and Groovy version 2.4.8 I need a way to iterate files in a folder to load configuration (multiple files) from it. Following code does not work using *Job DSL*: a) you need WORKSPACE to build absolute path The normal Groovy code *new

Re: Cannot set Git executable using Job DSL

2017-01-16 Thread shaneoh1980 McP
0 McP > > *Date: *Friday, January 6, 2017 at 2:35 AM > *To: *Jenkins Users > > *Cc: *"Indra Gunawan (ingunawa)" > > *Subject: *Re: Cannot set Git executable using Job DSL > > > > I should add that if I create a job using this as a seed job, the default >

Re: Cannot set Git executable using Job DSL

2017-01-06 Thread Indra Gunawan (ingunawa)
From: shaneoh1980 McP Date: Friday, January 6, 2017 at 2:35 AM To: Jenkins Users Cc: "Indra Gunawan (ingunawa)" Subject: Re: Cannot set Git executable using Job DSL I should add that if I create a job using this as a seed job, the default option is still selected. On Friday

Re: Cannot set Git executable using Job DSL

2017-01-06 Thread shaneoh1980 McP
} //configure >> >> } //job >> >> >> >> >> >> *From: * on behalf of shaneoh1980 McP < >> shane.do...@gmail.com> >> *Reply-To: *"jenkins...@googlegroups.com" >> *Date: *Thursday, January 5, 2017 at 8:16 AM >> *

Re: Cannot set Git executable using Job DSL

2017-01-05 Thread shaneoh1980 McP
m: *> on behalf of > shaneoh1980 McP > > *Reply-To: *"jenkins...@googlegroups.com " < > jenkins...@googlegroups.com > > *Date: *Thursday, January 5, 2017 at 8:16 AM > *To: *Jenkins Users > > *Subject: *Cannot set Git executable using Job DSL > > >

Re: Cannot set Git executable using Job DSL

2017-01-05 Thread Indra Gunawan (ingunawa)
ect } //configure } //job From: on behalf of shaneoh1980 McP Reply-To: "jenkinsci-users@googlegroups.com" Date: Thursday, January 5, 2017 at 8:16 AM To: Jenkins Users Subject: Cannot set Git executable using Job DSL I'm converting all of our Jenkins jobs to DSL scripts and I&#

Cannot set Git executable using Job DSL

2017-01-05 Thread shaneoh1980 McP
configure block. I've tried hundreds of ways but the way I most expected to work is below. Note that I am new to using the configure block. This is starting to drive me spare - does anyone know what is wrong in this configure block that I have? Or, am I somehow missing that this is actua

Re: JOB DSL and Github Organisation

2016-12-21 Thread Omeka
Thank you for the hint, it worked Le mercredi 30 novembre 2016 23:50:29 UTC+1, Victor Martinez a écrit : > > Hi there, > > Pipeline is fully supported by JobDSL ( > https://jenkinsci.github.io/job-dsl-plugin/#method/javaposse.jobdsl.dsl.DslFactory.pipelineJob) > > and also

Re: JOB DSL and Github Organisation

2016-11-30 Thread Victor Martinez
Hi there, Pipeline is fully supported by JobDSL (https://jenkinsci.github.io/job-dsl-plugin/#method/javaposse.jobdsl.dsl.DslFactory.pipelineJob) and also Multi Branch Pipeline Job https://jenkinsci.github.io/job-dsl-plugin/#method/javaposse.jobdsl.dsl.DslFactory.multibranchPipelineJob but

JOB DSL and Github Organisation

2016-11-30 Thread Eddard
I would like to automate the creation of Github Organisation that regroups a number of repositories for different teams in my company. I would like to use job-dsl-plugin to do that, so the question is does the job-dsl-plugin support github organisation? regards -- You received this message

JOB DSL timeout function

2016-11-30 Thread Danny Wong
Hi Jenkins users, When creating a new job using “Build Flow” options, the build environment section is missing, so I can’t add a timeout to the job. How can I add a timeout logic (in groovy?) to the “ Define build flow using flow DSL Section? Thanks!

Re: Integrating promoted-builds DSL to a job-dsl-gradle-example project

2016-08-23 Thread Wisen Tanasa
each job/view. Tested > here and it works. > > But I have good news for you, JenkinsJobManagement is no longer final > thanks to a recent commit (see > https://github.com/jenkinsci/job-dsl-plugin/commit/930aa4818a3ff74494696b14c241a521bc75c0a9). > > We have to wait for the next release

Re: Integrating promoted-builds DSL to a job-dsl-gradle-example project

2016-06-18 Thread Thomas Zoratto
each job/view. Tested here and it works. But I have good news for you, JenkinsJobManagement is no longer final thanks to a recent commit (see https://github.com/jenkinsci/job-dsl-plugin/commit/930aa4818a3ff74494696b14c241a521bc75c0a9 <https://github.com/jenkinsci/job-dsl-plugin/com

Re: Integrating promoted-builds DSL to a job-dsl-gradle-example project

2016-06-07 Thread Thomas Zoratto
been very unpleasant, but > subclassing it is really pretty) > Anyway, here is an example outputting XML if you run 'gradlew test'. > https://github.com/franknarf8/job-dsl-gradle-example/tree/03524daa83851a544106cc514591026a99f3ee64 > > <https://github.com/franknarf8/

Re: Integrating promoted-builds DSL to a job-dsl-gradle-example project

2016-06-07 Thread François Genois
dd logging logic to some of the calls of JenkinsJobManagement (wraping JenkinsJobManagement would have been very unpleasant, but subclassing it is really pretty) Anyway, here is an example outputting XML if you run 'gradlew test'. https://github.com/franknarf8/job-dsl

Re: Integrating promoted-builds DSL to a job-dsl-gradle-example project

2016-06-01 Thread François Genois
in a context running an > instance of the promoted-builds plugin. > > Do you have an idea of how I could get the XML generated from the scripts? > > Thank you again and have a nice day! > > - Frank > > > On Wednesday, June 1, 2016 at 12:20:01 PM UTC-4, Thomas Zoratto wrote:

Re: Integrating promoted-builds DSL to a job-dsl-gradle-example project

2016-06-01 Thread Thomas Zoratto
a context running an instance > of the promoted-builds plugin. > > Do you have an idea of how I could get the XML generated from the scripts? > > Thank you again and have a nice day! > > - Frank > > > On Wednesday, June 1, 2016 at 12:20:01 PM UTC-4, Thomas Zorat

Re: Integrating promoted-builds DSL to a job-dsl-gradle-example project

2016-06-01 Thread François Genois
idea of how I could get the XML generated from the scripts? Thank you again and have a nice day! - Frank On Wednesday, June 1, 2016 at 12:20:01 PM UTC-4, Thomas Zoratto wrote: > > Hello Frank, > > I guess the promoted builds plugin is not directly compatible with the job > DSL p

Re: Integrating promoted-builds DSL to a job-dsl-gradle-example project

2016-06-01 Thread Thomas Zoratto
Hello Frank, I guess the promoted builds plugin is not directly compatible with the job DSL plugin. I mean you can’t find DSL methods relative to the promoted builds plugin in the online API https://github.com/franknarf8/job-dsl-gradle-example/commit/f15b7fbf698d7be29b8527043d8649ab15559842

Integrating promoted-builds DSL to a job-dsl-gradle-example project

2016-06-01 Thread François Genois
Good morning everyone, I'm currently using a project based on https://github.com/sheehan/job-dsl-gradle-example and I am trying to get the promoted-builds plugin to work with this project (https://wiki.jenkins-ci.org/display/JENKINS/Promoted+Builds+Plugin). Everything works fine on my Je

Re: How to use Job DSL with Accurev SCM??

2016-02-23 Thread Victor Martinez
You can use the configure block: - https://github.com/jenkinsci/job-dsl-plugin/wiki/The-Configure-Block On Tuesday, 23 February 2016 12:15:48 UTC, khmarbaise wrote: > > Hi, > > first this is a question more specific for the job-dsl-plugin list > <https://groups.google.com/for

Re: How to use Job DSL with Accurev SCM??

2016-02-23 Thread khmarbaise
Hi, first this is a question more specific for the job-dsl-plugin list <https://groups.google.com/forum/#!forum/job-dsl-plugin> apart from that based on the docs there is no support for accurev at the moment... https://jenkinsci.github.io/job-dsl-plugin/#path/job-scm Kind regards Karl

How to use Job DSL with Accurev SCM??

2016-02-22 Thread Hemant Gupta
I am using the following script to create a Job DSL using accurev. Please let me know how should the correct script look like. job('payer-server') { scm { accurev { /**What to insert here **/ } } triggers { scm('H/15 * * * *') } steps { mav

Re: Generate pipeline jobs like with job-dsl

2016-02-09 Thread geoffroy . jabouley
peline jobs *with* Job DSL - look for the > "workflow" stuff in the Job DSL API Viewer - > https://jenkinsci.github.io/job-dsl-plugin/#path/workflowJob > > A. > > On Tue, Feb 9, 2016 at 3:27 AM, Carlos Lucas > wrote: > >> Hi, >> >> Nowadays, we a

Re: Generate pipeline jobs like with job-dsl

2016-02-09 Thread Andrew Bayer
You can actually generate Pipeline jobs *with* Job DSL - look for the "workflow" stuff in the Job DSL API Viewer - https://jenkinsci.github.io/job-dsl-plugin/#path/workflowJob A. On Tue, Feb 9, 2016 at 3:27 AM, Carlos Lucas wrote: > Hi, > > Nowadays, we are using a Jenkins

Generate pipeline jobs like with job-dsl

2016-02-09 Thread Carlos Lucas
Hi, Nowadays, we are using a Jenkins with more than 300 different jobs. Most of them are generated using jobdsl plugin automatically from a config file. Now, I would like to migrate some of them from classic projects to pipeline projects. What is the best way to generate pipeline jobs like job

Re: Job DSL Extracting into Groovy Script

2015-10-13 Thread Gergely Brautigam
Thanks! Sorry, didn't knew there was such a list. I'll take it there as well. Thank you! I'll try your suggestion once I'm in. -- You received this message because you are subscribed to the Google Groups "Jenkins Users" group. To unsubscribe from this group and stop receiving emails from it

Re: Job DSL Extracting into Groovy Script

2015-10-13 Thread milki milk
This is more appropriate for the job-dsl-plugin mailing list. readFileFromWorkspace is part of DslFactory. You can pass in a DslFactory through the call to addEmailTemplate or maybe import DslFactory and use it directly. -- You received this message because you are subscribed to the Google

Job DSL Extracting into Groovy Script

2015-10-13 Thread Gergely Brautigam
Hi guys. I'm trying to extract some common stuff from a JOB DSL file into some scripts which I can then use to augment my jobs to insert some common stuff. So I'm doing it like the example showed it => package utilities class MyUtilities { static void addMyFe

Re: Conditional configuration with the Job DSL

2015-10-06 Thread Victor Martinez
Nick, There is also another google group you might find useful: - https://groups.google.com/forum/#!forum/job-dsl-plugin Cheers On Tuesday, 6 October 2015 10:26:44 UTC+2, Nick Stolwijk wrote: > > Doh... that is simpler than I thought. :D I couldn't find any examples in > t

Re: Conditional configuration with the Job DSL

2015-10-06 Thread Nick Stolwijk
Doh... that is simpler than I thought. :D I couldn't find any examples in the various Job DSL configurations I had found. Thanks for the help! Nick Stolwijk ~~~ Try to leave this world a little better than you found it and, when your turn comes to die, you can die happy in feeling that a

Re: Conditional configuration with the Job DSL

2015-10-06 Thread Baptiste Mathus
Well, Job DSL is actually Groovy code. So something like the following should work: scm { if(data.git_url) { git { remote { url(data.git_url) credentials('x-') } createTag(false) } } else if(data.svn-url) {

Conditional configuration with the Job DSL

2015-10-06 Thread Nick Stolwijk
I'm trying to rebuild my Jenkins jobs through the Job DSL. I have found a lot of documentation and examples, but none about conditional configuration. I have the following job input: projects { componentA { svn-url = 'https://svn.localhost/componenta/trunk/' } component

Re: Approve workflow script from Job DSL plugin

2015-09-22 Thread Kanstantsin Shautsou
When i'm adding script manually in job it approved, when converting to dsl - it requires approval. This is not very convenient. On Sunday, August 16, 2015 at 11:29:46 AM UTC+3, David Resnick wrote: > > I've set the script to be sandboxed in the Job DSL script, though it look

Re: job dsl problem: groovyScriptFile statement does not create a build step

2015-09-15 Thread Slide
I find it is easier to debug these issues if you go in and create a normal Free Style Job with a groovy step and all the parameters that you want and then look at the XML that is created when you save the job. Then you can compare something that works to what is being generated by job dsl. On Tue

Re: job dsl problem: groovyScriptFile statement does not create a build step

2015-09-15 Thread Simon Haegler
On Tuesday, 15 September 2015 13:58:30 UTC+2, Daniel Beck wrote: > > Anything interesting in Old Data Monitor saying something cannot be > loaded? > nope, the ODM is empty. best, simon -- You received this message because you are subscribed to the Google Groups "Jenkins Users" group. To unsu

Re: job dsl problem: groovyScriptFile statement does not create a build step

2015-09-15 Thread Daniel Beck
Anything interesting in Old Data Monitor saying something cannot be loaded? On 15.09.2015, at 13:25, Simon Haegler wrote: > - Play area: http://job-dsl.herokuapp.com/ > - Docs refererence: > https://jenkinsci.github.io/job-dsl-plugi

Re: job dsl problem: groovyScriptFile statement does not create a build step

2015-09-15 Thread Simon Haegler
> > - Play area: http://job-dsl.herokuapp.com/ > <http://www.google.com/url?q=http%3A%2F%2Fjob-dsl.herokuapp.com%2F&sa=D&sntz=1&usg=AFQjCNEyJpn3QNQ8GSpBiLm_JWtngEighA> > - Docs refererence: > https://jenkinsci

Re: job dsl problem: groovyScriptFile statement does not create a build step

2015-09-14 Thread Victor Martinez
Hi Simon, A few suggestions in case you haven't checked them yet: - Play area: http://job-dsl.herokuapp.com/ - Docs refererence: https://jenkinsci.github.io/job-dsl-plugin/#method/javaposse.jobdsl.dsl.helpers.step.StepContext.groovyScriptFile - Can you check your config.xml

Re: job dsl problem: groovyScriptFile statement does not create a build step

2015-09-14 Thread Simon Haegler
apologies, forgot the versions: - jenkins 1.609.3 - job dsl plugin 1.38 - groovy plugin 1.27 On Monday, 14 September 2015 19:54:47 UTC+2, Simon Haegler wrote: > > hi jenkins users, > > i am working on our in-house 3rd-party dependency build system and ran > into an issue t

job dsl problem: groovyScriptFile statement does not create a build step

2015-09-14 Thread Simon Haegler
hi jenkins users, i am working on our in-house 3rd-party dependency build system and ran into an issue that the JOB DSL statement "groovyScriptFile" does not create the corresponding build step. here is the relevant snippet from the seed job groovy script: steps { groovy

Re: High Memory Usage with Job DSL

2015-09-13 Thread Slide
So far, upgrading to 1.38 seems a lot better on memory. I will continue to monitor and see how it goes. Thanks very much for the tip! On Sun, Sep 13, 2015 at 12:32 PM Guenther, Marc(AWF) wrote: > Hi, > > we had quite some severe memory problems with Job DSL Plugin, but then, we >

Re: High Memory Usage with Job DSL

2015-09-13 Thread Guenther, Marc(AWF)
Hi, we had quite some severe memory problems with Job DSL Plugin, but then, we were running it quite often (like, all the time...). In the end, it didn't even survive one working day. Using the JavaMelody Monitoring Plugin, we saw an ever increasing sawtooth in the "Used non-heap m

Re: High Memory Usage with Job DSL

2015-09-10 Thread Daniel Beck
On 11.09.2015, at 01:51, Slide wrote: > I would also like to know if anyone can help me figure out how to profile > Jenkins (while running under Tomcat) so I can determine where the memory > issues are coming from. Anything interesting in the heap dump? (Does /computer/(master)/heapDump work

Re: High Memory Usage with Job DSL

2015-09-10 Thread Slide
Anyone have any ideas on this one? I haven't been able to track down what is going on. On Wed, Jun 17, 2015 at 7:33 AM Slide wrote: > I just noticed an issue after upgrading the version of Job DSL recently > (1.34) that the memory consumption has gone up significantly. I have t

Re: Approve workflow script from Job DSL plugin

2015-08-16 Thread David Resnick
I've set the script to be sandboxed in the Job DSL script, though it looks link only a marginal improvement because of the need to approve missing method signatures. What would the Job DSL plugin need to do to automatically approve the non-sandboxed script it sets in a job? As you me

Re: Approve workflow script from Job DSL plugin

2015-08-12 Thread Jesse Glick
On Tuesday, July 21, 2015 at 4:17:51 PM UTC-4, David Resnick wrote: > > How can I have the workflow job script updated via Job DSL without having > to approve the script each time it changes? > If the Job DSL plugin supports setting sandbox=true here, use that. However it wou

Approve workflow script from Job DSL plugin

2015-07-21 Thread David Resnick
I have a workflow script that I set in the workflow job Groovy CPS DSL textbox via Job DSL. The problem is that though security on the server is set to "logged in users can do anything", apparently the script is not set as "Jenkins administrator". How can I have the workflo

High Memory Usage with Job DSL

2015-06-17 Thread Slide
I just noticed an issue after upgrading the version of Job DSL recently (1.34) that the memory consumption has gone up significantly. I have to restart Tomcat to free up the memory. I am using some custom, monkey patched methods to make the DSL a little friendlier for my HW engineers, so it could

Re: Gradle Artifactory Integration with Jenkins Job DSL

2015-04-28 Thread sravan bala
I got the some problem. I passed through this error by giving artifactory name, the numbered name. Just create a fake job/ or check already existing config.xml`s "artifactory-name" tag for a job. You will find the name with numbers(eg:16789834@566678). If you give that, ur parameters are being s

Gradle Artifactory Integration with Jenkins Job DSL

2015-02-17 Thread goodav
We are using the Jenkins DSL to define our jobs and have had very good success with it. However, when writing a job for our projects that use Gradle, where a successful build publishes to Artifactory, we have to manually configure Artifactory on the jobs first run even though we defined all

Re: Job DSL plugin problem with deactivation of customWorkspace

2015-02-06 Thread Rolf Geuenich
Hi, if someone else has the same problem: I've created this issue: https://issues.jenkins-ci.org/browse/JENKINS-26825 Best regards, Rolf -- You received this message because you are subscribed to the Google Groups "Jenkins Users" group. To unsubscribe from this group and stop receiving emails

Job DSL plugin problem with deactivation of customWorkspace

2015-02-05 Thread Rolf Geuenich
Hi, I'm unable to deactivate a customWorkspace with JoBDSL plugin. Once a job had an active customWorkspace it won't be deactivated. If I delete customWorkspace() from the job defenition the setting is not changed. customWorkspace( '' ) change only the text field and the check box is still acti

Re: Job DSL - Multijob iteration?

2015-01-28 Thread Jordan Spiker
I figured this out. jobs = [] f.eachLine { line -> jobs += job(type: Matrix) { ... } } job(type: Multijob) { steps { phase('build') { jobs.each { j -> job(j.name) } } } } On Tuesday, January 27, 2015 at 6:43:24 PM

  1   2   >