Reputation: 1062
I have a jenkins Pipeline that results with a build artifact which is a deb
file.
I was planning to use that deb file to fill in the Package option in the Bake Configuration Phase.
It doesn't work and results in
How should I go about doing this?
I guess I need to transfer artifact from the spinnaker pipeline's build trigger(the Jenkins pipeline) but I don't understand how to do that.
Is this of any use? I can't wrap my head around what they want me to do in order to send the file.
Any help is appreciated. Thanks.
Upvotes: 0
Views: 267
Reputation: 160
What you have done so far looks correct, so we need to debug why it fails.
You have to look at the source of the execution that fails (press the "source" link). This json structure is the execution context (you probably want to install a json formatter plugin in your browser or something to read it). Navigate to trigger.artifacts
and look for the artifact there. If you find it, please post the result here.
I think maybe the issue is the name of the deb file. It should have been named like simplenodeappinstaller_1.0-0_amd64.deb
. A simple solution is to add the jenkins build number or a timestamp as the release number.
You can also try to activate the artifact decorator (set artifact.decorator.enabled: true
in igor-local.yml
. This will cause Igor to parse deb and rpm files in a more sensible way, IMHO. See below for more info.
Another thing is that Jenkins sometimes puts all test results and other stuff into the artifacts list, and I think the default maximum number of artifacts returned are 20. This is however configurable under the key BuildArtifactFilter.maxArtifacts
(see https://github.com/spinnaker/igor/blob/master/igor-web/src/main/java/com/netflix/spinnaker/igor/build/BuildArtifactFilter.java). Reading the code, it also seems deb-files should already be prioritized over other kinds of artifacts, so I don't really think this is the issue.
Enabling the artifact decorator will convert this artifact:
fileName: "openmotif22-libs-2.2.4-192.1.3.x86_64.rpm"
displayPath: "openmotif22-libs-2.2.4-192.1.3.x86_64.rpm"
relativePath: "openmotif22-libs-2.2.4-192.1.3.x86_64.rpm"
into
fileName: "openmotif22-libs-2.2.4-192.1.3.x86_64.rpm"
displayPath: "openmotif22-libs-2.2.4-192.1.3.x86_64.rpm"
relativePath: "openmotif22-libs-2.2.4-192.1.3.x86_64.rpm"
reference: "openmotif22-libs-2.2.4-192.1.3.x86_64.rpm"
name: "openmotif22-libs"
type: "rpm"
version: "2.2.4-192.1.3.x86_64"
decorated: "true"
The built in decorator supports deb
and rpm
, but it can be extended using config like this:
artifact:
# This is a feature toggle for decoration of artifacts.
decorator:
enabled: true
fileDecorators:
- type: docker/image
decoratorRegex: '(.+):(.+)'
identifierRegex: '(.+\/.+:.+)'
Upvotes: 1