Reputation: 383
I have tried to use the Copy Artifact Plugin in a Jenkinsfile as this:
copyArtifacts(projectName: 'myProject', selector: lastSuccessful(), filter: '*.png*', target: 'Figures');
The code is working but I also need to the the permission of 'myProject' to use the plugin. Via Jenkins it's a tic-box like this:
I can only check the ticbox if I don't use a Jenkins file in the Jenkins job.
Question: How can I set the permission in the jenkins file directly instead of using the ticbox?
Upvotes: 0
Views: 3067
Reputation: 3161
Declarative pipeline:
pipeline {
agent any;
options {
copyArtifactPermission('job1,job2,...');
}
stages{...}
}
Upvotes: 2