[OpenStack-Infra] jenkins-job-builder: passing lists as variables / YAML anchors and aliases?

Clark Boylan clark.boylan at gmail.com
Sat Feb 15 18:09:23 UTC 2014


On Sat, Feb 15, 2014 at 6:29 AM, Michael Prokop
<openstack.org at michael-prokop.at> wrote:
> * Michael Prokop [Tue Feb 11, 2014 at 11:14:35AM +0100]:
>
>> in my jenkins-job-builder configurations I would like to have one
>> single place where I specify global defaults, then overwrite values
>> only as needed in the according projects/jobs.
>
>> This somewhat works with YAML anchors and aliases (see
>> http://pyyaml.org/wiki/PyYAMLDocumentation#Aliases - thanks to
>> Antoine Musso for pointing me there!), where you can use for example
>> "&repos" for assigning a new variable and then "*repos" for
>> referring to it:
> [...]
>> Any ideas how to properly pass a list of values down to the job-template?
>
> My friend and working colleague Victor came up with a patch which
> implements exactly what I need (and I consider *very* useful for
> inclusion in upstream):
>
>   https://github.com/linuxmaniac/jenkins-job-builder/commit/3ca77a761fde77c383625d13d531455bdebf3fb8
>
> With this patch you can use a configuration file like this (which
> does exactly what I was talking about in my initial mail):
>
>   https://github.com/sipwise/kamailio-deb-jenkins/blob/master/jjb/kamailio.yaml
>
> Any comments from your side what you think about this patch?
> If there are no objections we plan to submit it for official
> review.
>
> regards,
> -mika-
>
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.9 (GNU/Linux)
>
> iEYEARECAAYFAlL/ebAACgkQ2N9T+zficuhsWwCfQbxNFkBFpXgZNXCLJHVqBUy6
> 4wsAniN8+bZSzv3FB31gvgorHk5wMLjr
> =EoQl
> -----END PGP SIGNATURE-----
>

No objections here to proposing this change to JJB via Gerrit. Might
want to use a term other than 'list' though as the interpolation
appears to be type independent.

Clark



More information about the OpenStack-Infra mailing list