Skip to content
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

[RELENG-2812] Add jenkins-cli support for current and next version. Draft for feedback #27

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

manuelruizetc
Copy link

@manuelruizetc manuelruizetc commented Oct 14, 2021

This PR adds functionality to support different versions Jenkins in TryLib.

To issue remote commands, the jenkins-cli version must match the server version. Each version requires different options.

In version, 2.303.1 both protocol and authentication options come into play.

Currently, the jenkins-cli jar path is specified as an argument to JenkinRunner instances without taking into account the server version. Likewise, the options to the cli command were fixed and do not match the 2.3 version requirements.

The JenkinsCli class provides methods for getting server info and for building cli commands that take into account the version-specific options.

It is assumed tar the jars to be used have been deployed to /ust/etsy with the following convention:

jenkins-cli.jar : the default version in production
jenkins-cli-2.303.1.jar : a specific version is given as part of the name, in this case for jenkins 2.303.1

It is assumed for now that we are going to use the ssh protocol.

try-next is an example of how to use the JenkinsCli class.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant