Re: how to get access to the data for the job being promoted?

2012-04-12 Thread Brian J. Murrell
On 12-04-10 04:54 PM, Sami Tikka wrote:
> You do not exactly come clean on what kind of "data" it is you are looking 
> for.

Well, specifically, I was looking to know in the executed job which job
was being promoted.

> If you want access to promoted build artifacts, Copy Artifacts plugin
> gives that in the triggered build in Specific build -> Last promoted

This sounds racy, but moot in any case since there is no mention of
anything to do with promoted builds in the list of artifacts available
for copying.  But that's ok, see below...

> If it is something else you want, you could maybe send it over as a
> parameter.

Yes, this is what I was looking for!

> Use the parameterized trigger in the promotion action to
> send what ever "data" you want to pass to the triggered job.

Yeah.  I hadn't realized that any action plugin that I add would be
available as a promotion action.  Simply installing the parameterized
trigger plugin I was able to send the PROMOTED_* variables to the
downstream job.

Thanks much!

b.



signature.asc
Description: OpenPGP digital signature


Re: how to get access to the data for the job being promoted?

2012-04-10 Thread Sami Tikka
You do not exactly come clean on what kind of "data" it is you are looking for.

If you want access to promoted build artifacts, Copy Artifacts plugin
gives that in the triggered build in Specific build -> Last promoted
(from memory, might not be 100% correct, but I did use it a few weeks
ago.)

If it is something else you want, you could maybe send it over as a
parameter. Use the parameterized trigger in the promotion action to
send what ever "data" you want to pass to the triggered job.

-- Sami

2012/4/10 Brian J. Murrell :
> On 12-04-10 11:44 AM, Brian J. Murrell wrote:
>> Using the Promoted Builds Plugin, I'm choosing to execute another job as
>> an action of the promotion.  How do I get information on the job and
>> build that's being promoted in the job steps of the job that the
>> promotion action starts?
>
> Still wondering, but that's not the point of my followup here...
>
>> I've seen hints about a $PROMOTED_URL variable (i.e. TODO: Talk about
>> PROMOTED_URL in
>> https://wiki.jenkins-ci.org/display/JENKINS/Promoted+Builds+Plugin) but
>> that doesn't seem to be set in my promotion action job.
>
> That variable seems available to the job steps one writes directly in a
> promotion's own "Execute shell" action but doesn't seem to be given to
> any jobs that a promotion starts with the "Build other projects" actions.
>
> So is there really no way for a job to know that it's being executed as
> an action of a promotion of another job and which job it's being built for?
>
> Cheers,
> b.
>


Re: how to get access to the data for the job being promoted?

2012-04-10 Thread Brian J. Murrell
On 12-04-10 11:44 AM, Brian J. Murrell wrote:
> Using the Promoted Builds Plugin, I'm choosing to execute another job as
> an action of the promotion.  How do I get information on the job and
> build that's being promoted in the job steps of the job that the
> promotion action starts?

Still wondering, but that's not the point of my followup here...

> I've seen hints about a $PROMOTED_URL variable (i.e. TODO: Talk about
> PROMOTED_URL in
> https://wiki.jenkins-ci.org/display/JENKINS/Promoted+Builds+Plugin) but
> that doesn't seem to be set in my promotion action job.

That variable seems available to the job steps one writes directly in a
promotion's own "Execute shell" action but doesn't seem to be given to
any jobs that a promotion starts with the "Build other projects" actions.

So is there really no way for a job to know that it's being executed as
an action of a promotion of another job and which job it's being built for?

Cheers,
b.



signature.asc
Description: OpenPGP digital signature


how to get access to the data for the job being promoted?

2012-04-10 Thread Brian J. Murrell
Using the Promoted Builds Plugin, I'm choosing to execute another job as
an action of the promotion.  How do I get information on the job and
build that's being promoted in the job steps of the job that the
promotion action starts?

I've dumped the environment in the job steps of the job the action
starts and there is no sign of any information about the particular
build that is being promoted.

I've seen hints about a $PROMOTED_URL variable (i.e. TODO: Talk about
PROMOTED_URL in
https://wiki.jenkins-ci.org/display/JENKINS/Promoted+Builds+Plugin) but
that doesn't seem to be set in my promotion action job.

Cheers,
b.



signature.asc
Description: OpenPGP digital signature