Keeping tagged builds

Chris Smart chris at distroguy.com
Fri Jun 24 17:18:21 AEST 2016


On Fri, Jun 24, 2016 at 04:26:38PM +0930, Joel Stanley wrote:
>Hi Chris,
>
>On Thu, Jun 23, 2016 at 5:24 PM, Cédric Le Goater <clg at kaod.org> wrote:
>> On 06/23/2016 09:24 AM, Joel Stanley wrote:
>>> On Tue, Jun 21, 2016 at 12:46 AM, Patrick Williams <patrick at stwcx.xyz> wrote:
>>>> I have just tagged v1.0 and uploaded it to Github.  This is meant as the
>>>> release to support Barreleye in production capacity.  Thank you to
>>>> everyone that contributed over the last year to get us to this point and
>>>> congrats on this major milestone!
>>>
>>> Thanks Patrick. It's rewarding to know our work has made it into a product.
>>
>> It would be great to keep images of this version available. Would that be
>> possible on https://openpower.xyz/ ?
>
>Do you have any suggestions for how to do this programmaticly? Can we
>get jenkins to realise that it's tagged and retain it?

Given that Jenkins knows the git commit that it is building, we could
check to see if that commit matches a tag, and if so, we could tell
Jenkins to always keep that build.

There is a Git Tag Message plugin[1] which will do that the tag
detection for us and export some new GIT_TAG environment variables.

Then it's a matter of telling Jenkins to "Keep this build forever"
if that environment variable is not empty. I expect that we can do this
via the Build Keeper Plugin [2].

We could also update the build number to include the tag name so that it
is easily visible in the job history.

>
>Or should we set up a separate build job that triggers off tags?
>

We can do that too, but if the above works then it's probably better to
do it there so that everything is in the same spot.

-c

[1] <https://wiki.jenkins-ci.org/display/JENKINS/Git+Tag+Message+Plugin>
[2] <https://wiki.jenkins-ci.org/display/JENKINS/Build+Keeper+Plugin>


More information about the openbmc mailing list