-
Bug
-
Resolution: Unresolved
-
Major
-
None
I have a multi-branch pipeline that should be triggered by another multi-branch pipeline. The trigger is configured at the end of the Jenkinsfile as follows:
{{ }}
properties([
pipelineTriggers([upstream({{upstreamProjects: "myproject/$
"}})]),
disableConcurrentBuilds()
])
update: the code above is being modified by this editor all the time... never mind those extra brackets etc. I didn't add them. See screenshot.
branchname is defined at the top of the file, as follows:
def branchName = "${BRANCH_NAME}".replace("/", "%2F")
To copy the artifacts I use:
step([$class: 'CopyArtifact', target: 'input/upstream', selector: [$class: 'TriggeredBuildSelector']])
The pipeline is triggered, but the copy artifact step fails with this error:
hudson.AbortException: Unable to find project for artifact copy: null This may be due to incorrect project name or permission settings; see help for project name in job configuration.
I tried to add the permissions property in the upstream pipeline, as follows:
properties([[$class: 'CopyArtifactPermissionProperty', projectNames: '*']])
But I get the same error. The expected behavior is of course to copy the artifacts from the upstream pipeline... if I'm doing something wrong then please let me know what it is so I can fix my pipeline.Thank you.
- is related to
-
JENKINS-40429 Copy artifacts from multi-branch pipeline project with project name as a build parameter fails with "Unable to find project for artifact copy"
- Open