Jenkins matrix configuration artifacts
Asked Answered
L

2

9

I'm currently experimenting with a matrixed projected in jenkins. It is working well but I'm curious how to get the artifacts to show up on the main page under a Last Successful Artifacts link. Currently it looks like the artifacts are built in the target directory for each axis configuration.

Is there a way to aggregate the artifacts to a single spot through jenkins?

Locker answered 23/4, 2012 at 20:36 Comment(0)
B
4

Collector collects Matrix artifacts but is in fact a simple "FreeStyle" job. The build view shows all the artifacts, and after that is a hint as to how it's configured. Note the "flatten" and "optional" features allow platforms to be missing from a set, but the "delete workspace" first ensures you don't carry over stale artifacts.

Build view: collect_build_view

Config view:

collect_config_view

Brigitte answered 19/12, 2012 at 0:17 Comment(1)
You can collect artefacts from all axis by single call to copy artifacts. If they are called differently in each, they will be copied directly in the target directory, if they are called the same, they will be put in subdirectories called by the configurations.Biforate
B
2

I do not think so this is currently possible 'out of the box' (and I've worked with matrix projects for a while). You can use the following workaround: start your matrix job from another job (Collector) via Parameterized Trigger Plugin passing to it a location within Collector workspace where to put the artifacts. Matrix subjobs will put the artifacts there. Collector will wait for the matrix job to finish and publish them.

You then can use Sidebar-Link Plugin to put a link on your main job page that point to Last Successful Artifacts permalink for Collector.

Bowne answered 24/4, 2012 at 7:15 Comment(2)
Thanks. I also have not been able to find a way to publish the last successful without some sort of workaround. I am able to show the artifacts if I click into a one of the job configurations, but not aggregated on the main page.Locker
How can one do this if the workspaces don't all live on the same computer?Biforate

© 2022 - 2024 — McMap. All rights reserved.