New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Double URL encoding issue with Jenkins jobs #6949
Comments
I've found that this problem is present regardless of whether the jenkins job produces an artifact or not. Spinnaker calls the igor endpoint for |
@dprangnell as a workaround until the fix is released you can disable in the orca profile:
This change however will affect the artifact retrieval if you have jobs that have a forward / (like multibranch Jenkins projects etc) |
Thanks, disabling the |
Issue Summary:
When Spinnaker goes to retrieve an artifact from a jenkins job, orca url encodes the job name and requests the artifact from igor. This works if the job does not have a space in it. If the job name has a space in it, then jenkins already url encodes it, then spinnaker/orca url encodes it again and queries igor, igor then returns a 404.
Environment:
1.32.4
Feature Area:
Executing external jenkins jobs that both:
Description:
I have two example jobs, both produce an artifact build.properties that is greater than 0 bytes.
When I call the jenkins job
artifact-test-temporary
it worksWhen I call the jenkins job
promote docker image
it gets a 404:Steps to Reproduce:
promote docker image
the other calledartifactory-test-temporary
. Put this in the job definition/Jenkinsfile:Additional Details:
I believe this is the problem, orca is blindly encoding the job:
Either remove that or have igor try url decoding the job name more intelligently (or stop trying to get the artifact from jenkins entirely).
The orca logs are telling (I've added some newlines and tabs for readability). See
context.buildInfo.url=https://build.example.org/job/Promote%20Docker%20Image/30993/
whereas the request from orca to igor iscontext.exception.details.url=http://spin-igor.spinnaker:8088/builds/artifacts/30993/build.example.org?job=Promote%2520Docker%2520Image
:My manual curls from inside clouddriver shows this:
For the really observant, you'll notice another bug, the successful curl returns an empty json string
[]
, but I don't really care about getting the artifact from Jenkins to spinnaker, I just don't want the stage to fail.This is reflected in the job getting 404's trying to retrieve the artifact:
The text was updated successfully, but these errors were encountered: