Skip to content

CLI tool does not return an error code when it says "War not found" #641

@ninjonxb

Description

@ninjonxb

Jenkins and plugins versions report

Environment
Paste the output here

What Operating System are you using (both controller, and any agents involved in the problem)?

Using https://hub.docker.com/r/jenkins/jenkins running on Amazon Linux 2
Being built within a jenkins job

Reproduction steps

Run jenkins-plugin-cli with a plugin file on a system with a non default jenkins.war
It gives an error
No exit code

Expected Results

any error code

Actual Results

No exit code

Anything else?

This is related to this raised issue: jenkinsci/docker#1803

The problem here is we are creating our own docker file from the image listed above, in the docker build we are installing the plugins and then deploying that.

This step does not stop the docker build since it does not error, so it continues with the build, in our case will deploy. This put us in a broken state. Since it tried to deploy an unknown plugin state and possibly upgrade some files, when it automatically downgraded Jenkins to the last working container it was not able to properly start up either.

Since there was no error, it also made tracking down exactly what happened that much harder.

Are you interested in contributing a fix?

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions