Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [jakartaee-spec-project-leads] Release to maven central job

Yes, but we need some sort of subclassing or delegation for a Jenkinsfile
so all the magic isn't copied into every project.  Maybe it's all possible
through the magic of Groovy, but I haven't climbed that mountain yet!

David Blevins wrote on 8/30/19 3:44 PM:
>> On Aug 30, 2019, at 3:28 PM, Bill Shannon <bill.shannon@xxxxxxxxxx> wrote:
>>
>> Romain is planning to do something similar with all the scripts used for the GlassFish jobs, which could then be shared by other implementation projects.
>>
>> Having more commonality between all these jobs would definitely be an improvement!  I just wish there was a way to share Jenkins job configuration so we didn't have to use images as below to explain how to configure a job.
> 
> There is a way to do it with a Jenkinsfile.
> 
>  - https://jenkins.io/doc/book/pipeline/jenkinsfile/
> 
> I tried to get that to work for the promotion job I setup, but ran into a DocumentationTooVagueException on the proper configuration to handle exposing the keyring and passphrase Eclipse gives.
> 
> However, if someone is extremely persistent and has the time for trial-and-error, 100% of the steps configured in the UI for a Job can be done via a Jenkinsfile.
> 
> Very hard to create them, but the reward is that to setup a job you just point a the Jenkinsfile in a git repo and 100% of everything else is taken care of and will automatically update when the file is updated.
> 
> 
> -David
> 
> 
>>
>> David Blevins wrote on 8/30/19 2:49 PM:
>>> That's awesome.  I suggest you commit it in this directory or a new sibling directory:
>>>
>>>  - https://github.com/jakartaee/specification-tools/tree/master/promotion
>>>
>>> What I discovered in creating the TCK promotion scripts is that 99% of the scripts we have in Jenkins can simply be committed to git and checked out/executed by Jenkins.  We would each need our own job, however, the script itself could be shared.
>>>
>>> Here's the relevant job configuration details to do that.
>>>
>>> 1. Checkout the specification-tools project
>>>
>>> <PastedGraphic-1.png>
>>>
>>>
>>> 2. Run the desired script
>>>
>>> Point to the script you want to execute.
>>>
>>> <PastedGraphic-2.png>
>>>
>>> 3. Handling Job Parameters
>>>
>>> If you look at the top of the promote-release.sh, there's a function that can be used to make the script fail unless specific Jenkins job parameters are specified.  The function is defined in "utils.sh", so you just need to copy line 5 into your script and you're set.  Lines 10-16 would be w
>>>
>>> https://github.com/jakartaee/specification-tools/blob/master/promotion/promote-release.sh#L10-L16
>>>
>>> <PastedGraphic-3.png>
>>>
>>> -- 
>>> David Blevins
>>> http://twitter.com/dblevins
>>> http://www.tomitribe.com
>>>
>>>> On Aug 30, 2019, at 2:26 PM, Scott Stark <starksm64@xxxxxxxxx> wrote:
>>>>
>>>> I was having trouble finding the staging repo for jakarta.inject using the Nexus interface, so I created a paired down Jenkins freestyle job to list/release a staging repo to maven central. The script is documented here:
>>>> https://wiki.eclipse.org/MavenReleaseScript#Sample_Maven_Central_Release_Script
>>>>
>>>> That includes a pdf of the job configuration so you should be able to see how everything is setup. If you have an api to release to maven central but do not have a release job currently in your project CI you can try using that script.
>>>>
>>>> _______________________________________________
>>>> jakartaee-spec-project-leads mailing list
>>>> jakartaee-spec-project-leads@xxxxxxxxxxx
>>>> To change your delivery options, retrieve your password, or unsubscribe from this list, visit
>>>> https://www.eclipse.org/mailman/listinfo/jakartaee-spec-project-leads
>>>
>>>
>>>
>>> _______________________________________________
>>> jakartaee-spec-project-leads mailing list
>>>
>>> jakartaee-spec-project-leads@xxxxxxxxxxx
>>>
>>> To change your delivery options, retrieve your password, or unsubscribe from this list, visit
>>>
>>> https://www.eclipse.org/mailman/listinfo/jakartaee-spec-project-leads
>>
>> _______________________________________________
>> jakartaee-spec-project-leads mailing list
>> jakartaee-spec-project-leads@xxxxxxxxxxx
>> To change your delivery options, retrieve your password, or unsubscribe from this list, visit
>> https://www.eclipse.org/mailman/listinfo/jakartaee-spec-project-leads
> 
> _______________________________________________
> jakartaee-spec-project-leads mailing list
> jakartaee-spec-project-leads@xxxxxxxxxxx
> To change your delivery options, retrieve your password, or unsubscribe from this list, visit
> https://www.eclipse.org/mailman/listinfo/jakartaee-spec-project-leads
> 


Back to the top