Re: Running a command before wiping the workspace

2015-11-26 Thread Björn Stabel
I don't want to run a build step pre-scm, but pre-wipe, i.e. when the 
user clicks "wipe workspace", but before the workspace is actually wiped.


On 11/24/2015 12:43 PM, Mark Waite wrote:
After you reviewed 
https://wiki.jenkins-ci.org/display/JENKINS/pre-scm-buildstep for the 
Pre-SCM Build Step?


You may also want to consider the advice in 
http://stackoverflow.com/questions/10123914/how-to-add-some-prebuild-steps-to-jenkins and 
see if there is a way to add that step to the build script itself, 
rather than making it part of the Jenkins job definition.


Mark Waite

On Tue, Nov 24, 2015 at 4:28 AM Björn Stabel 
> 
wrote:


I'm still having this problem. Is anyone aware of a solution, like a
pre-wipe action plugin?

On 10/22/2015 12:49 PM, Björn Stabel wrote:
> Hello,
>
> I have a job that constructs a Vagrant environment in the workspace
> directory.
> To that Vagrant environment belongs a VirtualBox VM, stored
elsewhere.
> Vagrant keeps track of which Vagrant environment belongs to which
> VirtualBox VM through a directory named ".vagrant" in the workspace
> directory.
>
> The problem is this:
> If a user wipes the workspace of that job, the .vagrant directory is
> gone, but the VirtualBox VM still exists.
> The next time the job is run, Vagrant cannot find the existing
VM, so
> a new VM is created, taking up extra disk space.
>
> Preparing the VM takes some time and involves creating a snapshot on
> which all future runs can base, so destroying the VM in a post-build
> step would significantly increase build times.
>
> Is there a way I could tell Jenkins to destroy the VM (by running
> "vagrant destroy -f", for example) before wiping the workspace?
>

--
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,
send an email to jenkinsci-users+unsubscr...@googlegroups.com
.
To view this discussion on the web visit

https://groups.google.com/d/msgid/jenkinsci-users/565449C7.1000400%40data-experts.de.
For more options, visit https://groups.google.com/d/optout.

--
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, send 
an email to jenkinsci-users+unsubscr...@googlegroups.com 
.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/CAO49JtF-W98KPv9%2Bh-_JFsZ8Rjo-CUE8Up1AchvDSZ8LHSZT4Q%40mail.gmail.com 
.

For more options, visit https://groups.google.com/d/optout.


--
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, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/5656C7A5.9080803%40data-experts.de.
For more options, visit https://groups.google.com/d/optout.


Re: How to hide AWS secret key in AWS elastic beanstalk plugin of Jenkins?

2015-11-26 Thread Amrita Kanungo
Thank you..But I am write now using AWS Elastic Beanstalk Publisher Plugin
in which I am declaring the credentials globally and in the job level its
hidden.

Thank you all for your answers..




On Wed, Nov 25, 2015 at 5:30 AM, Peter Lai 
wrote:

>
>
> 
> can you not treat it like a password and get it injected.
> Set a password called aws_key and in the key section "$aws_key"
> Jenkins will then mask it for you.
>
> On Monday, 23 November 2015 10:52:10 UTC, kanungo...@gmail.com wrote:
>>
>> I am unable to hide my AWS secret key in the AWS elastic beanstalk plugin
>> which helps in automatic deployment in Elastic beanstalkPlease
>> help
>>
>> Its urgent
>>
>>
>>
>>
>>
>>
>> Thanks
>> Amrita
>>
> --
> You received this message because you are subscribed to a topic in the
> Google Groups "Jenkins Users" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/jenkinsci-users/LECdqIGglyI/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> jenkinsci-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/jenkinsci-users/8c0dc646-6d89-4329-8dac-fcdfce719edc%40googlegroups.com
> 
> .
>
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/CAM583Ows7-YVnjUibz3%3DrspoPqsFstqkE%2Bp9A2YvJoMdh1Larg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: LDAP authentication problem for multiple OUs

2015-11-26 Thread James Nord
As you have country -> users. You need to have a common root.  
In your case that is dc=ca which given your root dn would be a blank entry.

-- 
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, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/7e58c381-cda6-4d24-a311-9bd5c758abb3%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: How to hide AWS secret key in AWS elastic beanstalk plugin of Jenkins?

2015-11-26 Thread Amrita Kanungo
Hii...Right now another issue am facing...In our pom.xml the version keeps
on changing for each war. We are actually increasing the pom version so our
war is also being generated by abc-0.1.16-SNAPSHOT.war. And this number
keeps on increasing. So how to declare the path in the AWS Deployment
plugin, in the root object(file/directory) value. I have to give the exact
name else its not taking target/abc-.*-war.

Can you please help me in this..



On Thu, Nov 26, 2015 at 1:44 AM, Amrita Kanungo 
wrote:

> Thank you..But I am write now using AWS Elastic Beanstalk Publisher Plugin
> in which I am declaring the credentials globally and in the job level its
> hidden.
>
> Thank you all for your answers..
>
>
>
>
> On Wed, Nov 25, 2015 at 5:30 AM, Peter Lai 
> wrote:
>
>>
>>
>> 
>> can you not treat it like a password and get it injected.
>> Set a password called aws_key and in the key section "$aws_key"
>> Jenkins will then mask it for you.
>>
>> On Monday, 23 November 2015 10:52:10 UTC, kanungo...@gmail.com wrote:
>>>
>>> I am unable to hide my AWS secret key in the AWS elastic beanstalk
>>> plugin which helps in automatic deployment in Elastic
>>> beanstalkPlease help
>>>
>>> Its urgent
>>>
>>>
>>>
>>>
>>>
>>>
>>> Thanks
>>> Amrita
>>>
>> --
>> You received this message because you are subscribed to a topic in the
>> Google Groups "Jenkins Users" group.
>> To unsubscribe from this topic, visit
>> https://groups.google.com/d/topic/jenkinsci-users/LECdqIGglyI/unsubscribe
>> .
>> To unsubscribe from this group and all its topics, send an email to
>> jenkinsci-users+unsubscr...@googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/jenkinsci-users/8c0dc646-6d89-4329-8dac-fcdfce719edc%40googlegroups.com
>> 
>> .
>>
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>

-- 
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, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/CAM583Oz4vmg%3D3fXTAqrDq99f5mcazRFFGM57mpvC6mqBVyA-9Q%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


About Jenkins REST API

2015-11-26 Thread Sampath Bandara Liyanage


Hi,

 

This is regarding Jenkins REST API endpoints. We are using Jenkins REST 
API. We found documentation only for Jenkins Remote API. Please send us the 
rest of API endpoints and the parameters to work with API. Or else if there 
any reference documentation to use Jenkins API endpoints, please send us 
the documentation URL or the file.

 

Thanks and regards,
*Sampath Liyanage *OCPJP 6, OCPJWCD 5

-- 
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, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/de2c172f-91a4-49b8-95ef-82251afe4d59%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: LDAP authentication problem for multiple OUs

2015-11-26 Thread Rama
I tried keeping User search base (and also tried with User search
filter as well) as blank, but that failed.
I also tried with blank root DN, that also failed. :(

On 11/26/15, James Nord  wrote:
> As you have country -> users. You need to have a common root.
> In your case that is dc=ca which given your root dn would be a blank entry.
>
> --
> You received this message because you are subscribed to a topic in the
> Google Groups "Jenkins Users" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/jenkinsci-users/RP78og8cRcw/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> jenkinsci-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/jenkinsci-users/7e58c381-cda6-4d24-a311-9bd5c758abb3%40googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/CANWvqY6tFdTRpj5cg4vV%3DFObLdjrcjF898ovpwcvE9Ms6Fyhaw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Groovy triggering build with both default and new parameters

2015-11-26 Thread Sverre Moe
Groovy Code for triggering a build with a parameter
def params = 
[
new StringParameterValue('UPSTREAM_TRIGGER_CAUSE', 'true')
]
def paramsAction = new ParametersAction(params)

def cause = new UpstreamCause(build)
def futureTask = project.scheduleBuild2(project.quietPeriod, cause, 
paramsAction)

I have configured parameters for each projects with default values. When I 
supply this one extra parameter with scheduleBuild2 the other configured 
parameters are not set. Thus getting:

 > git rev-parse ${BUILD_BRANCH}^{commit} # timeout=10
ERROR: Couldn't find any revision to build. Verify the repository and branch 
configuration for this job.


I reckon I have to first get the configured parameters from the project, 
then add the new one. 
Just not sure how. I can read the properties with
def property = project.getProperty(ParametersDefinitionProperty.class)
But that will not give me a map of key/value for each property.


-- 
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, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/6ff0dd20-dff9-4215-bbab-1176210d81fb%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: LDAP plugin, warning after Jenkins upgrade v1.638

2015-11-26 Thread Daniel Beck
Click the plugin name and then scroll down.

On 26.11.2015, at 08:57, Lavr L  wrote:

> Hi
> 
> I upgraded Jenkins to last release 1.638 and now I have the following warning 
> for LDAP plugin:
> Warning: the new version of this plugin claims to use a different settings 
> format than the installed version. Jobs using this plugin may need to be 
> reconfigured, and/or you may not be able to cleanly revert to the prior 
> version without manually restoring old settings. Consult the plugin release 
> notes for details.
> 
> Ldap works ok for my Jenkins. 
> Where to find these release notes that was mentioned in warning and should I 
> downgrade if LDAP works for me?what the impact expected after plugin 
> downgrade?
> 
> Thanks in advance for support and ideas,
> 
> Best regards, 
> Lavr
> 
> -- 
> 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, send an 
> email to jenkinsci-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/jenkinsci-users/3187dc1f-74e7-4717-951e-4a81cc521b92%40googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

-- 
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, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/028ADE0C-D4D7-4FD9-B7D7-DCFD1C451188%40beckweb.net.
For more options, visit https://groups.google.com/d/optout.


Re: Groovy triggering build with both default and new parameters

2015-11-26 Thread Sverre Moe
I have tried the following solution:
def property = project.getProperty(ParametersDefinitionProperty.class)
def jobParams = property.getParameterDefinitions();

def newParam = new StringParameterValue('UPSTREAM_TRIGGER_CAUSE', 'true')
jobParams.add(newParam)

def parametersAction = new ParametersAction(jobParams)
def cause = new UpstreamCause(build)
def futureTask = project.scheduleBuild2(project.quietPeriod, cause, 
parametersAction)
However it gets stuck on scheduleBuild2 and does not return.


torsdag 26. november 2015 12.38.06 UTC+1 skrev Sverre Moe følgende:
>
> Groovy Code for triggering a build with a parameter
> def params = 
> [
> new StringParameterValue('UPSTREAM_TRIGGER_CAUSE', 'true')
> ]
> def paramsAction = new ParametersAction(params)
>
> def cause = new UpstreamCause(build)
> def futureTask = project.scheduleBuild2(project.quietPeriod, cause, 
> paramsAction)
>
> I have configured parameters for each projects with default values. When I 
> supply this one extra parameter with scheduleBuild2 the other configured 
> parameters are not set. Thus getting:
>
>  > git rev-parse ${BUILD_BRANCH}^{commit} # timeout=10
> ERROR: Couldn't find any revision to build. Verify the repository and branch 
> configuration for this job.
>
>
> I reckon I have to first get the configured parameters from the project, 
> then add the new one. 
> Just not sure how. I can read the properties with
> def property = project.getProperty(ParametersDefinitionProperty.class)
> But that will not give me a map of key/value for each property.
>
>
>

-- 
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, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/720e0854-3239-4c31-953d-1787b7db35de%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Groovy triggering build with both default and new parameters

2015-11-26 Thread Sverre Moe
Seems that was totally wrong.
My latest attempt seems to work:
def params = []
def extraParameterValue = new 
BooleanParameterValue('UPSTREAM_TRIGGER_CAUSE', true)
params.add(extraParameterValue)

def parametersDefProp = 
project.getProperty(ParametersDefinitionProperty.class)
parametersDefProp.getParameterDefinitions().each { param ->
def parameterValue = param.getDefaultParameterValue()
params.add(parameterValue)
}

def parametersAction = new ParametersAction(params)
def cause = new UpstreamCause(build)
def futureTask = project.scheduleBuild2(project.quietPeriod, cause, 
parametersAction)



torsdag 26. november 2015 13.13.54 UTC+1 skrev Sverre Moe følgende:
>
> I have tried the following solution:
> def property = project.getProperty(ParametersDefinitionProperty.class)
> def jobParams = property.getParameterDefinitions();
>
> def newParam = new StringParameterValue('UPSTREAM_TRIGGER_CAUSE', 'true')
> jobParams.add(newParam)
>
> def parametersAction = new ParametersAction(jobParams)
> def cause = new UpstreamCause(build)
> def futureTask = project.scheduleBuild2(project.quietPeriod, cause, 
> parametersAction)
> However it gets stuck on scheduleBuild2 and does not return.
>
>
> torsdag 26. november 2015 12.38.06 UTC+1 skrev Sverre Moe følgende:
>>
>> Groovy Code for triggering a build with a parameter
>> def params = 
>> [
>> new StringParameterValue('UPSTREAM_TRIGGER_CAUSE', 'true')
>> ]
>> def paramsAction = new ParametersAction(params)
>>
>> def cause = new UpstreamCause(build)
>> def futureTask = project.scheduleBuild2(project.quietPeriod, cause, 
>> paramsAction)
>>
>> I have configured parameters for each projects with default values. When 
>> I supply this one extra parameter with scheduleBuild2 the other configured 
>> parameters are not set. Thus getting:
>>
>>  > git rev-parse ${BUILD_BRANCH}^{commit} # timeout=10
>> ERROR: Couldn't find any revision to build. Verify the repository and branch 
>> configuration for this job.
>>
>>
>> I reckon I have to first get the configured parameters from the project, 
>> then add the new one. 
>> Just not sure how. I can read the properties with
>> def property = project.getProperty(ParametersDefinitionProperty.class)
>> But that will not give me a map of key/value for each property.
>>
>>
>>

-- 
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, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/43f97351-fcfa-4eb3-beeb-4d0546128ebb%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: LDAP plugin, warning after Jenkins upgrade v1.638

2015-11-26 Thread Stephen Connolly
In case you are having difficulty the change in question was:

Turned the group membership lookup into a strategy.

That changed the configuration format of the LDAP security realm. This is
normally not a big deal... as long as you do not roll back the plugin... if
you roll the plugin back to version 1.9 or earlier, then those versions
will no longer be able to read the new configuration format and you may get
locked out.

All Jenkins plugins can set a flag: compatibleSinceVersion

If set, then you get the standard boilerplate warning text if you are
upgrading from an older version of the plugin than the
`compatibleSinceVersion`

Plugin authors are supposed to set this version to the oldest version of
the plugin that you can revert to without breaking the ability to parse the
data on disk using the older plugin's parser.

Because the message has to be generic, it is typically more scary than it
needs to be, but we only have one flag and a speed-bump is better than just
having people upgrade unthinkingly, find a bug, revert the plugin to the
old version and *BOOM* you are locked out of Jenkins because after the
upgrade your configuration was updated to the new format and the downgraded
plugin cannot read the new format.

On 26 November 2015 at 12:14, Daniel Beck  wrote:

> Click the plugin name and then scroll down.
>
> On 26.11.2015, at 08:57, Lavr L  wrote:
>
> > Hi
> >
> > I upgraded Jenkins to last release 1.638 and now I have the following
> warning for LDAP plugin:
> > Warning: the new version of this plugin claims to use a different
> settings format than the installed version. Jobs using this plugin may need
> to be reconfigured, and/or you may not be able to cleanly revert to the
> prior version without manually restoring old settings. Consult the plugin
> release notes for details.
> >
> > Ldap works ok for my Jenkins.
> > Where to find these release notes that was mentioned in warning and
> should I downgrade if LDAP works for me?what the impact expected after
> plugin downgrade?
> >
> > Thanks in advance for support and ideas,
> >
> > Best regards,
> > Lavr
> >
> > --
> > 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, send
> an email to jenkinsci-users+unsubscr...@googlegroups.com.
> > To view this discussion on the web visit
> https://groups.google.com/d/msgid/jenkinsci-users/3187dc1f-74e7-4717-951e-4a81cc521b92%40googlegroups.com
> .
> > For more options, visit https://groups.google.com/d/optout.
>
> --
> 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, send an
> email to jenkinsci-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/jenkinsci-users/028ADE0C-D4D7-4FD9-B7D7-DCFD1C451188%40beckweb.net
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/CA%2BnPnMzhZ1zkxo%2BG0jmS8xMaM9a9nJ4S_1qZLVGNCFU-kNswnQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: How to use Throttle Concurrent in WorkFlow

2015-11-26 Thread sebastien . barthelemy

Hello, 

Le lundi 16 novembre 2015 19:00:32 UTC+1, Dave Lawrence a écrit :
>
> I am looking to use Throttle Concurrent Builds in a WorkFlow.
>

Concurrency can be limited using "stages", have a look at :
https://github.com/jenkinsci/workflow-plugin/blob/master/TUTORIAL.md#creating-stages
 

> I've also ready about people using a workflow stage, but this also doesn't 
> work because of the user-initiated jobs that are outside of the WorkFlow.
>

ok. This works for me since in my case, the user-initiated job is also a 
workflow one.
Maybe you could do the same?
 

> I've seen a presentation by CloudBees that states that a WorkFlow can be 
> used with _any_ plugin, even if the plugin does not have native workflow 
> support. I'm hoping someone here knows how to do that for TCB.
>

I personally don't know about that sorry.

Cheers

-- 
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, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/3438706b-ea73-4dcd-8f27-a98ccbb97087%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.