Reputation: 668
let's say we have got the following scenario:
How can i solve this problem WITHOUT copy all the data to my master. I know i can copy the data of BJ-1 on S-1 to my master server, once the job is done and i also know i can download the data to S-2 before BJ-2 runs. But as you see i have to copy them to my Master.
The question: Is there a way to directly copy the data from S-1 to S-2?
Upvotes: 8
Views: 8025
Reputation: 3119
Best way to achieve this is to archive your generated data in the post build steps in BJ-1 and copy then artifact to BJ-2 workspace.
BJ-1
Archiving artifacts is built in to Jenkins and allows you to define a file set to be available as part of the build results. Extend BJ-1 to configure what data should be archived . With that the archived data is available for further use.
BJ-2
In order to pick up the archived artifacts from another job you will need to install the Copy Artifact Plugin. In BJ-2 you add a new build step to copy artifact from a named build - with that any files matching the configured pattern will be copied into the current job's workspace. With that you can access any kind of artifacts across jobs/slave nodes etc.
Upvotes: 9