LegacyVersion class is removed from newer setuptools package. But
support for legacy versions is added in python-jenkins 1.8.2.
Switch to that implementation.
Fix broken plugin version comparison for legacy versions.
Assume latest plugin version if no plugin version is found.
Story: 2010990
Story: 2009943
Story: 2009819
Story: 2010842
Task: 49236
Task: 44852
Task: 44396
Task: 48448
Change-Id: Id7f0be1c42357454bd9bedcdee3fefb174943d81
'pre-scm-buildstep' wrapper has two modes:
1. Older: no 'buildsteps' element is specified. Build steps is a list under
wrapper name. For example:
- pre-scm-buildstep:
- shell: echo hello
- shell: echo bye
2. Newer: build steps specified inside 'buildsteps' mapping element:
- pre-scm-buildsteps:
buildsteps:
- shell: echo hello
- shell: echo bye
But, when 'preSCMbuildstep' plugin version is equal or higher 0.3, and first
mode is used, it fails.
Fix that.
Change-Id: I010d9f6c5e06ccd8c2723026aae2c60f79917ff4
For the ssh-user-private-key credential-wrapper, the "key-file-variable"
setting is mandatory, but the "username-variable" and
"passphrase-variable" settings are optional.
Prior to this commit, if a user omitted "username-variable" or
"passphrase-variable" settings, JJB would write empty
<usernameVariable/> or <passphraseVariable/> entries. When both were
empty, the credentials-binding plugin would crash with an error:
IllegalArgumentException("Cannot use the same key in both secretValues and publicValues")
To resolve this, do not write XML entries for these optional parameters
when the user does not specify them.
Add a minimal test case reproducer.
Change-Id: I94a4437eee6a8fdaf655c1a3bf69d46844b225bc
Rename credentials-binding example files to have a dash to correspond to
the YAML key that users will use.
Add the prefix "-full" to indicate that these are full examples where a
user specifies every variable.
Change-Id: Iae52c037b213c8f5511244ba075063e6b1a1f43a
There are cases when you want SSH Agent plugin to just start and stop
an SSH agent during the build, without adding any keys automatically.
One of such cases is when you want to use an SSH key stored on a
SmartCard -like device, such as NitroKey HSM.
So far, when the "users" property was set to an empty list then the
output XML markup didn't contain the <credentialIds/> tag and the plugin
was then crashing with NullPointerException.
Also, when the "users" property was set to a list with just one value
then the output XML markup was always generated in the "old style"
format (matching plugin versions < 1.5, so like almost 8 years old).
With this change, when using the "users" property the markup is
generated based on the actual plugin version installed in Jenkins. More
importantly, the generated markup is now properly handled by the plugin,
no matter if the input is an empty list or a list with one or more
entries.
Finally, fixed the parent of the <ignoreMissing> tag, which was wrongly
put under <credentialIds> tag when generating the "new style" markup
(1.5+), while it should simply be a top-level tag, laying next to
<credentialIds>, as in the corresponding implementation class [1].
This means the "ignore-missing-credentials" property was broken when the
"users" property was set to a list with more than one entry and it's now
fixed.
[1] https://github.com/jenkinsci/ssh-agent-plugin/blob/ssh-agent-1.5/src/main/java/com/cloudbees/jenkins/plugins/sshagent/SSHAgentBuildWrapper.java#L83
Change-Id: Ife5a08739da9ea1130f0ea7daa08c16675f6c75d
Jenkins Wiki has been fully taken off line, so update the remaining
links to reference either the relevant plugin page or the github repo.
Add extlink target for repo in jenkinsci github org.
The sonatype-clm plugin seems to be more-or-less completely deprecated,
so update the description to indicate this and link to the
nexus-artifact-uploader plugin.
Update the jjb sphinx plugin so that it generates references for the
yamlfunctions.
Change-Id: If2241e751d01a60a8cb4cbaea5b3176aeb92eab4
Signed-off-by: Pat Long <pllong@arista.com>
This patch adds the following options that are missing from JJB
but available in the UI:
- fail if path not found
- skip ssl verification
- k/v engine version
Change-Id: Id8e14d63c668a1ef826ae88ae3ce0360609bde99
Added the missing tags, also added a test case.
Change-Id: Ic1cb6c3991afe7ef99dd448e6ba49d510f54bd59
Signed-off-by: Eren ATAS <eatas.contractor@libertyglobal.com>
On version 1.17 of BuildTimeoutWrapper plugin, new option
called "AbortAndRestart" has been introduced. The plugin support
has been updated in order to support this option. A test case
also added.
Change-Id: I4bcbdbc45e177fc4d302baa68898e89463535f6f
Signed-off-by: Eren ATAS <eatas.contractor@libertyglobal.com>
The changes include:
- <concurrentBuild> should now be represented as
<org.jenkinsci.plugins.workflow.job.properties.DisableConcurrentBuildsJobProperty/>
property
- <triggers> should now be localed inside
<org.jenkinsci.plugins.workflow.job.properties.PipelineTriggersJobProperty>
property, in <properties> section
- unsupported XML elements got removed:
- <blockBuildWhenDownstreamBuilding>
- <blockBuildWhenUpstreamBuilding>
- <assignedNode>
- <canRoam>
- <customWorkspace>
- got rid of publishers from project_pipeline_template005.{xml,yaml} as
these are not supported in Pipeline jobs
The above changes align the produced XMLs with the ones from Jenkins 2.190.1
and Pipeline plugin v2.6.
Task: 39836
Story: 2007708
Change-Id: I650ef2ee60e872cce8f93de5f391933d68ec81f0
Python 3.8 changed things, so now the order of the attributes is not
alphabetic anymore but reflect the order they where added.
See this CPython commit for more details:
6367391646
This lets the testsuite pass with both CPython 3.8 as well as previous
versions.
Change-Id: I315abda0465d882d9673c9a7faac0990e38b6840
Signed-off-by: Mattia Rizzolo <mattia@mapreri.org>
The Jenkins Wiki page is deprecated and Jenkins community is expected
to migrate their documentation to plugins.jenkins.io URL. This patch
updates all plugins that have a relevant plugins.jenkins.io URL
documentation link.
Change-Id: Iba7df7eada7b8ca0bb9aad93f5499ac6365a9293
Signed-off-by: Thanh Ha <zxiiro@gmail.com>
This toxenv will allow us to flag URLs that no longer work. We
also switch from using old style setup.py build_sphinx to the
newer sphinx-build command.
Change-Id: I62f42918814fb6eea4876e0d22c6bccddf86a826
Signed-off-by: Thanh Ha <zxiiro@gmail.com>
Please review the following patch containing the code changes in
the repo. This patch is a transition patch and is the auto-generated
output of the python-black tool.
Change-Id: I2d2de71da8a105fb62b561899ae78441ddab4032
Signed-off-by: Thanh Ha <zxiiro@gmail.com>
rvm version greater than 0.5 requires
a different ruby-class. This patch handles
this case while maintaining backwards
compatibility.
Change-Id: I1fd03922e6125dd17c2bd41bf91560679edaeafc
Story: #2000857
Task: #3476
Adds support for groovy script option and sandbox option.
Updated new example YAML and XML files.
Story: #2000922
Task: #3553
Change-Id: Iad44f9a0a776060c6fb1acfc3ebb44fa3c5acef2