what are the steps to integrate JIRA and Jenkins? - jenkins

I want to integrate JIRA with Jenkins so as to update tickets automatically when a job is build successfully or failed.
I have established JIRA and Jenkins server separately both working properly.I have the following JIRA plugins in Jenkins installed:-
1) Jira Issue Updater
This plugin can update Jira issues by changing their workflow status and adding comments.
1.11
2) JIRA plugin
This plugin integrates Jenkins to Atlassian JIRA.
1.39
3) JIRA Plugin for Jenkins
This plugin implements the Application Link API to support integration with Atlassian JIRA
1.5.3
4) JiraTestResultReporter plugin
This plugin creates issues in Jira for failed unit tests.
Following add-on in JIRA server:-
1) JIRA Plugin to integrate Jenkins CI
Version: 1.5.3
Vendor: Marvelution
Add-on key: com.marvelution.jira.plugins.jenkins
2) JIRA Plugin to integrate Hudson CI
Version: 5.0.4
Vendor: Marvelution
Add-on key: com.marvelution.jira.plugins.hudson
I want to build a job in Jenkins and wants the issue to be generated automatically in JIRA if the build Passes/Fails.
Please let me know if you need more information.

Try with this plugin..it may helps you to get what you need..

Related

How to create new jira issue after jenkins run jobs

I want to create a new Jira issue after everytime Jenkins jobs running no matter the result is passed or failed. But my setting was no effect in Jenkins. It only created a Jira issue for the first time, then, it only added a comment to the old JIRA issue after running job finished.
Here is my setting:
"JIRA: Create issue" in Jenkins
Only updated JIRA Comments in the old Jira issue
BTW: Other related functions are OK. Likeļ¼š triggered Jenkins job after Jira issue status changed or added comments to jira after running job.
Versions:
Jenkins ver. 2.32.2
JIRA plugin: 2.5
JIRA Integration for Jenkins: 3.1.3
Jira Issue Updater: 1.18
JIRA Pipeline Steps: 1.3.1
JiraTestResultReporter plugin 2.0.6
JIRA Trigger Plugin: 0.5.1
jira-ext Plugin:0.7
JIRA: 7.5.0
Thanks in advance!

AbstractMethodError while running Pipeline

I have a Jenkinsfile that runs a pipeline. The pipeline runs correctly on one instance of Jenkins, so I believe there isn't a problem with my script.
I am now trying to copy the job over to another instance, but I get the following error in the console output:
Started by user
[Pipeline] End of Pipeline
java.lang.AbstractMethodError: Method org/jenkinsci/plugins/workflow/cps/global/UserDefinedGlobalVariableList.iterator()Ljava/util/Iterator; is abstract
at org.jenkinsci.plugins.workflow.cps.global.UserDefinedGlobalVariableList.iterator(UserDefinedGlobalVariableList.java)
at org.jenkinsci.plugins.workflow.cps.GlobalVariable$1$1.expand(GlobalVariable.java:74)
at org.jenkinsci.plugins.workflow.cps.GlobalVariable$1$1.expand(GlobalVariable.java:71)
at hudson.util.Iterators$FlattenIterator.hasNext(Iterators.java:74)
at org.jenkinsci.plugins.workflow.cps.CpsScript.invokeMethod(CpsScript.java:100)
at org.codehaus.groovy.runtime.callsite.PogoMetaClassSite.call(PogoMetaClassSite.java:45)
at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:42)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:108)
at com.cloudbees.groovy.cps.sandbox.DefaultInvoker.methodCall(DefaultInvoker.java:15)
at WorkflowScript.run(WorkflowScript:3)
at ___cps.transform___(Native Method)
at com.cloudbees.groovy.cps.impl.ContinuationGroup.methodCall(ContinuationGroup.java:55)
at com.cloudbees.groovy.cps.impl.FunctionCallBlock$ContinuationImpl.dispatchOrArg(FunctionCallBlock.java:106)
at com.cloudbees.groovy.cps.impl.FunctionCallBlock$ContinuationImpl.fixArg(FunctionCallBlock.java:79)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:483)
at com.cloudbees.groovy.cps.impl.ContinuationPtr$ContinuationImpl.receive(ContinuationPtr.java:72)
at com.cloudbees.groovy.cps.impl.ClosureBlock.eval(ClosureBlock.java:40)
at com.cloudbees.groovy.cps.Next.step(Next.java:58)
at com.cloudbees.groovy.cps.Continuable.run0(Continuable.java:154)
at org.jenkinsci.plugins.workflow.cps.CpsThread.runNextChunk(CpsThread.java:164)
at org.jenkinsci.plugins.workflow.cps.CpsThreadGroup.run(CpsThreadGroup.java:297)
at org.jenkinsci.plugins.workflow.cps.CpsThreadGroup.access$000(CpsThreadGroup.java:78)
at org.jenkinsci.plugins.workflow.cps.CpsThreadGroup$2.call(CpsThreadGroup.java:206)
at org.jenkinsci.plugins.workflow.cps.CpsThreadGroup$2.call(CpsThreadGroup.java:204)
at org.jenkinsci.plugins.workflow.cps.CpsVmExecutorService$2.call(CpsVmExecutorService.java:47)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at hudson.remoting.SingleLaneExecutorService$1.run(SingleLaneExecutorService.java:112)
at jenkins.util.ContextResettingExecutorService$1.run(ContextResettingExecutorService.java:28)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
Finished: FAILURE
Jenkinsfile for reference:
#!/usr/bin/env groovy
node {
stage('build')
echo 'hello world'
}
I believe I've messed up a plugin, but not sure which one. Here's the list of installed plugins and also the installed version of Jenkins:
Jenkins v1.651.3
=========
Ant Plugin
Uses the OWASP Java HTML Sanitizer to allow safe-seeming HTML markup to be entered in project descriptions and the like.
1.2
Artifact Deployer Plug-in
This plug-in makes it possible to deploy artifacts from workspace to output directories.
0.33
Artifactory Plugin
This plugin allows deploying maven artifacts and build info to Artifactory.
2.4.7
Async Http Client
This plugin provides a shared dependency on the async-http-client library so that other plugins can co-operate when using this library.
1.7.24
Authentication Tokens API Plugin
This plugin provides an API for converting credentials into authentication tokens in Jenkins.
1.2
Branch API Plugin
This plugin provides an API for multiple branch based projects.
1.11
Build Authorization Token Root Plugin
Lets build and related REST build triggers be accessed even when anonymous users cannot see Jenkins.
1.4
Build Pipeline Plugin
This plugin renders upstream and downstream connected jobs that typically form a build pipeline. In addition, it offers the ability to define manual triggers for jobs that require intervention prior to execution, e.g. an approval process outside of Jenkins.
1.5.2
build timeout plugin
This plugin allows builds to be automatically terminated after the specified amount of time has elapsed.
1.16
Build Trigger Badge Plugin
This plugin displays an icon representing the cause of a construction.
2.2
Build With Parameters
Allows the user to provide parameters for a build in the url (similar to /job/JOBNAME/buildWithParameters), prompting for confirmation before triggering the job.
1.3
build-name-setter
This plug-in sets the display name of a build to something other than #1, #2, #3, ...
1.5.1
CCCC Plug-in
This plugin parses CCCC output files to produce project and build reports.
0.6
CloudBees Docker Build and Publish plugin
This plugin enables building Dockerfile based projects, as well as publishing of the built images/repos to the docker registry.
1.2.2
CloudBees Docker Hub/Registry Notification
Integrates Jenkins with DockerHub and Docker Registry
2.0
CloudBees Docker Traceability
Provides an ability to trace server deployments via fingerprints
1.2
Cobertura Plugin
This plugin integrates Cobertura coverage reports to Jenkins.
1.9.7
Config File Provider Plugin
Ability to provide configuration files (e.g. settings.xml for maven, XML, groovy, custom files,...) loaded through the UI which will be copied to the job workspace.
2.10.1
Confluence Publisher
This plugin allows you to publish build artifacts into a Confluence wiki page. Currently limited to uploading an artifact as an attachment to a page id.
1.8
Copy Artifact Plugin
Adds a build step to copy artifacts from another project.
1.37
Credentials Binding Plugin
Allows credentials to be bound to environment variables for use from miscellaneous build steps.
1.10
Credentials Plugin
This plugin allows you to store credentials in Jenkins.
2.1.1
Crowd 2 Integration
This plugin enables use of Atlassian Crowd as an authentication source. It uses Crowd's REST API (available since Crowd 2.1) to access the services and supports single-sign-on.
1.9-SNAPSHOT (private-04/03/2015 19:47-arnaud)
Cucumber Plugin
run cucumber tests under jenkins CI
0.0.2
Cucumber reports
This project provides pretty html reports for Cucumber. It works by generating html from the cucumber json report formatter. Can be used anywhere a json report is generated (Java, Ruby, JavaScript and other implementations).
3.6.0
CVS Plug-in
Integrates Jenkins with CVS version control system using a modified version of the Netbeans cvsclient.
2.12
Deploy to container Plugin
This plugin allows you to deploy a war to a container after a successful build.
Glassfish 3.x remote deployment
1.10
Deploy to Websphere container Plugin
1.0
deployment-notification
This plugin provides abstract common parts for integration with configuration management tools like Chef and Puppet.
1.4
Discard Old Build plugin
This plugin enables detail configuration to discard old builds like using logfile size / status / days/ intervals days / build num / logfile regular expression.
1.05
disk-usage plugin
This plugin counts disk usage.
0.28
Docker Commons Plugin
Provides the common shared functionality for various Docker-related plugins.
1.6
Docker Pipeline
Build and use Docker containers from pipelines.
1.6
Docker plugin
This plugin integrates Jenkins with Docker
0.16.0
docker-build-step
This plugin allows to add various docker commands to your job as build steps.
1.39
Durable Task Plugin
Library offering an extension point for processes which can run outside of Jenkins yet be monitored.
1.9
Dynamic Parameter Plug-in
This plugin allows build parameters with dynamically generated default values.
0.2.0
Email Ext Recipients Column Plugin
This plugin is a sample to explain how to write a Jenkins plugin.
1.0
Email Extension Plugin
This plugin is a replacement for Jenkins's email publisher
2.41.3
Email Extension Template Plugin
This plugin allows administrators to create global templates for the Extended Email Publisher.
0.4
Environment Dashboard Plugin
This plugin is used to generate the Environment Dashboard.
1.1.4
Environment File Plugin
This plugin can be used to set environment variables from a file.
1.2
Environment Injector Plugin
This plugin makes it possible to set an environment for the builds.
1.92.1
export dynamic job data
This plugin exports Jenkins runtime job parameters into a properties file.
0.4
Extended Choice Parameter Plug-In
Adds extended functionality to Choice parameter
0.74
Extensible Choice Parameter plugin
Extensible Choice Parameter provides several ways to retrieve choices, including the way to share choices among all jobs.
1.3.2
External Monitor Job Type Plugin
Adds the ability to monitor the result of externally executed jobs
1.4
Flexible Publish Plugin
Choose the order of publisher execution and make the execution conditional
0.15.2
Folders Plugin
This plugin allows users to create "folders" to organize jobs. Users can define custom taxonomies (like by project type, organization type etc). Folders are nestable and you can define views within folders. Maintained by CloudBees, Inc.
5.12
Gatling Jenkins Plugin
This plugin integrates Gatling simulation reports into Jenkins.
1.1.1
Git Changelog
Plugin creating JIRA filter URL based on commit messages containing JIRA ticket keys in the GIT history
1.2
Git client plugin
Utility plugin for Git support in Jenkins
1.19.6
Git Parameter Plug-In
Adds ability to choose from git repository revisions or tags
0.4.0
Git plugin
This plugin integrates Git with Jenkins.
2.5.2
GIT server Plugin
Allows Jenkins to act as a Git server.
1.6
Git Tag Message Plugin
Exports the message for a git tag as an environment variable during a build.
1.4
git-notes Plugin
Add git-notes with Jenkins build status!
0.0.4
Gitcolony Build Notification plugin
This plugin updates live branch build status in Gitcolony.
1.1
GitHub API Plugin
This plugin provides GitHub API for other plugins.
1.71
GitHub Authentication plugin
This is the an authentication plugin using github OAuth.
0.22.2
GitHub plugin
This plugin integrates GitHub to Jenkins.
1.16.0
Gradle Plugin
This plugin allows Jenkins to invoke Gradle build scripts directly.
1.24
Green Balls
Because green is better than blue! For color blind support configure user property.
1.15
Groovy
This plugin executes Groovy code.
1.3
HP Application Automation Tools
This plugin allows integration with HP ALM, HP Unified Functional Testing, HP LoadRunner and HP Performance cente
4.0.1
HPE Security Fortify Jenkins Plugin
HPE Security Fortify Jenkins Plugin, publish FPR result in Project page, upload FPR to Software Security Center (SSC), consider a build as fail if too many vulnerabilities
1.16.10
HTML Publisher plugin
This plugin publishes HTML reports.
1.11
HTTP Request Plugin
This plugin sends a http request to an url with some parameters. See the release notes for changes and compatibility https://github.com/jenkinsci/http-request-plugin/releases
1.8.11
Hudson SCP publisher plugin
This plugin uploads build artifacts to repository sites using SCP (SSH) protocol.
1.8
Icon Shim Plugin
Allows plugins make full use of the <l:icon> layout tag when running on newer versions of Jenkins, while still being compatible with older versions.
2.0.3
JaCoCo plugin
1.0.16
Javadoc Plugin
1.3
JavaScript GUI Lib: ACE Editor bundle plugin
JavaScript GUI Lib: ACE Editor bundle plugin.
1.1
JavaScript GUI Lib: Handlebars bundle plugin
JavaScript GUI Lib: Handlebars bundle plugin.
1.1
JavaScript GUI Lib: jQuery bundles (jQuery and jQuery UI) plugin
JavaScript GUI Lib: jQuery bundles (jQuery and jQuery UI) plugin.
1.2.1
JavaScript GUI Lib: Moment.js bundle plugin
JavaScript GUI Lib: Moment.js bundle plugin.
1.1
JIRA plugin
This plugin integrates Jenkins to Atlassian JIRA.
2.1
Job Configuration History Plugin
Job history plugin for Jenkins.
2.13
Job DSL
This plugin allows Jobs and Views to be defined via DSLs
1.45
Job Import Plugin
The Job Import Plugin lets you import jobs from another Jenkins instance.
1.3.1
Job/Queue/Slaves Monitoring Plugin
This plugin shows different information about the queue, slaves and jobs in jenkins.
1.4
jQuery plugin
This allows other plugins to use jQuery in UI.
1.11.2-0
jQuery UI plugin
This plugin allows you to use jQuery UI on view descriptions.
1.0.2
JUnit Plugin
Allows JUnit-format test results to be published.
1.10
Kubernetes plugin
Jenkins plugin to run dynamic slaves in a Kubernetes/Docker environment
0.7
LDAP Plugin
Adds LDAP authentication to Jenkins
1.11
Mailer Plugin
This plugin allows you to configure email notifications for build results
1.16
Managed Scripts
This plugin allows to centrally manage shell scripts and reference these as build steps in your builds.
1.2.1
MapDB API Plugin
This plugin provides a shared dependency on the MapDB library so that other plugins can co-operate when using this library.
1.0.6.0
Mask Passwords Plugin
This plugin allows masking passwords that may appear in the console.
2.8
Matrix Authorization Strategy Plugin
Offers matrix-based security authorization strategies (global and per-project).
1.2
Matrix Project Plugin
Multi-configuration (matrix) project type.
1.6
Maven Integration plugin
This plug-in provides, for better and for worse, a deep integration of Jenkins and Maven: Automatic triggers between projects depending on SNAPSHOTs, automated configuration of various Jenkins publishers (Junit, ...).
2.12.1
Maven Metadata Plugin for Jenkins CI server
Adds a build parameter that presents versions of an artifact from a maven repository as a drop down list.
1.5.0
Monitoring
Jenkins' monitoring with JavaMelody. Open report after installation.
1.59.0
Multiple SCMs plugin
This plugin enables the selection of multiple source code management systems for a build. For example, it enables checking out the source code from one SCM while checking out legacy or third-party code from another.
0.6
Next Build Number Plugin
Sets the build number Jenkins will use for a job's next build
1.4
NodeJS Plugin
NodeJS Plugin executes NodeJS script as a build step.
0.2.1
OpenShift Deployer Plugin
This plugin enable Jenkins jobs to create containers(gears) on OpenShift and deploy applications to it
1.2.0
OpenShift Pipeline Jenkins Plugin
This plugin facilitates the construction of jobs, pipelines, and workflows that operate on a Kubernetes based OpenShift server.
1.0.21
OpenShift Sync
Syncs OpenShift BuildConfigs with Jenkins jobs
0.0.11
OWASP Markup Formatter Plugin
Uses the OWASP Java HTML Sanitizer to allow safe-seeming HTML markup to be entered in project descriptions and the like.
1.3
PAM Authentication plugin
Adds Unix Pluggable Authentication Module (PAM) support to Jenkins
1.2
Parameterized Remote Trigger Plugin
This plugin triggers a job on a remote Jenkins host
2.2.2
Parameterized Trigger plugin
2.30
Performance Plugin
This plugin integrates JMeter reports, JUnit reports, wrk output, and Iago reports into Hudson.
1.13
Pipeline
A suite of plugins that lets you orchestrate automation, simple or complex. See Pipeline as Code with Jenkins for more details.
2.5
Pipeline Graph Analysis Plugin
Provides a REST API to access pipeline and pipeline run data.
1.3
Pipeline: API
Plugin that defines Pipeline API.
2.1
Pipeline: Basic Steps
Commonly used steps for Pipelines.
2.4
Pipeline: Build Step
Adds the Pipeline step build to trigger builds of other jobs.
2.4
Pipeline: Declarative Extension Points API
APIs for extension points used in Declarative Pipelines.
1.1.1
Pipeline: GitHub Groovy Libraries
Allows Pipeline Grrovy libraries to be loaded on the fly from GitHub.
1.0
Pipeline: Groovy
Pipeline execution engine based on continuation passing style transformation of Groovy scripts.
2.9
Pipeline: Input Step
Adds the Pipeline step input to wait for human input or approval.
2.5
Pipeline: Job
Defines a new job type for pipelines and provides their generic user interface.
2.3
Pipeline: Milestone Step
Plugin that provides the milestone step
1.3
Pipeline: Model API
Model API for Declarative Pipeline.
1.1.1
Pipeline: Model Definition
An opinionated, declarative Pipeline.
1.1.1
Pipeline: Multibranch
Enhances Pipeline plugin to handle branches better by automatically grouping builds from different branches.
2.9.2
Pipeline: Nodes and Processes
Pipeline steps locking agents and workspaces, and running external processes that may survive a Jenkins restart or slave reconnection.
2.10
Pipeline: REST API Plugin
Provides a REST API to access pipeline and pipeline run data.
1.5
Pipeline: SCM Step
Adds a Pipeline step to check out or update working sources from various SCMs (version control).
2.2
Pipeline: Shared Groovy Libraries
Shared libraries for Pipeline scripts.
2.7
Pipeline: Stage Step
Adds the Pipeline step stage to delineate portions of a build.
2.2
Pipeline: Stage Tags Metadata
Library plugin for Pipeline stage tag metadata.
1.1.1
Pipeline: Stage View Plugin
Pipeline Stage View Plugin.
2.6
Pipeline: Step API
API for asynchronous build step primitive.
2.9
Pipeline: Supporting APIs
Common utility implementations to build Pipeline Plugin
2.13
Plain Credentials Plugin
Allows use of plain strings and files as credentials.
1.1
Port Allocator Plug-in
This plugin allocates free ports as environment variables.
1.8
Post-Build Script Plug-in
No description available.
0.17
Promoted Builds (Simple)
Simpler version of Promoted Builds plugin, with only manual promotion of builds.
1.9
promoted builds plugin
This plugin implements a "promoted build" feature where a build of one job can be marked as "promoted" when it passes certain criteria.
2.27
Publish Over SSH
Send build artifacts over SSH
1.14
PWauth Security Realm
This plug-in adds authentication via pwauth and supports both *nix system users and groups through PAM.
0.4
ready-api-jenkins-plugin
The Ready! API Plugin can be used to start and stop ServiceV Virts during your builds.
1.8.5
Reverse Proxy Auth Plugin
1.4.0
Role-based Authorization Strategy
Enables authorization using a role-based strategy.
2.3.2
ruby-runtime
Hosts runtime for enabling pure-Ruby plugins
0.12
Run Condition Extras Plugin
Plugin provides extra run conditions and plugin integrations for Run Conditions Plugin.
0.2
Run Condition Plugin
Define conditions for the execution of build steps
1.0
Safe Restart Plugin
This plugin allows you to restart Jenkins safely.
0.3
sbt plugin
This plugin allows running SBT empowered scala projects in Hudson.
1.5
SCM API Plugin
This plugin provides a new enhanced API for interacting with SCM systems.
1.2
Scoverage Plugin
Scoverage Plugin
1.3.2
Script Security Plugin
Allows Jenkins administrators to control what in-process scripts can be run by less-privileged users.
1.21
Scriptler
Scriptler allows you to store/edit/execute groovy scripts on any of the slaves/nodes... no need for copy paste groovy code anymore. Beside administer your scripts, Scritpler also provides a way to share scripts between users via hosted script catalogs on the internet.
2.9
Security Realm by custom script
This plugin adds authentication via user-defined script, in additon to the orignal script-realm, this one also supports groups.
1.5
Selenium HTML report
This is an jenkins plugin to visualize the results of selenium tests
1.0
Shared Objects Plugin
This plugin makes it possible to populate as environment variables some objects such as public file paths, Clearcase objects, locations of installed tools and so on. This plugin contributes to the EnvInject plugin.
0.44
SonarQube Plugin
This plugin allows an easy integration of SonarQube, the open source platform for Continuous Inspection of code quality.
2.3
SSH Agent Plugin
1.9
SSH Credentials Plugin
Allows storage of SSH credentials in Jenkins
1.11
SSH plugin
This plugin executes shell commands remotely using SSH protocol.
2.4
SSH Slaves plugin
Allows to launch agents over SSH, using a Java implementation of the SSH protocol
1.10
Static Analysis Collector Plug-in
This plug-in is an add-on for the plug-ins Checkstyle, Dry, FindBugs, PMD, Tasks, and Warnings: the plug-in collects the different analysis results and shows the results in a combined trend graph. Additionally, the plug-in provides health reporting and build stability based on these combined results.
1.47
Static Analysis Utilities
This plug-in provides utilities for the static code analysis plug-ins.
1.76
Structs Plugin
Library plugin for DSL plugins that need names for Jenkins objects.
1.4
Subversion Plug-in
2.5.7
TestNG Results Plugin
This plugin integrates TestNG test reports to Jenkins.
1.13
ThinBackup
Backs up the most important global and job specific configuration files.
1.7.4
Timestamper
Adds timestamps to the Console Output
1.7.2
Token Macro Plugin
This plug-in adds reusable macro expansion capability for other plug-ins to use.
1.12.1
Translation Assistance plugin
1.12
Validating String Parameter Plugin
Adds a new parameter type called Validating String Parameter which supports regular expression validation of a user entered parameter.
2.3
WAS Builder Plugin
This plugin adds an "IBM WebSphere Application Server 6.x/7.x" builder which allows running wsadmin commands (or scripts) from a job.
1.6.1
WebSphere Deployer Plugin
Deploys your web artifacts automatically to IBM WebSphere Application Server and IBM WebSphere Liberty Profile
1.3.4
Windows Slaves Plugin
Allows you to connect to Windows machines and start slave agents on them.
1.1
Zentimestamp plugin
Plugin that allows the customization of the date and time pattern for the Jenkins BUILD_TIMESTAMP variable.
4.2
The following line gives the hint, where the error occurs in your pipeline script:
at WorkflowScript.run(WorkflowScript:3)
While line 3 in the pasted script is the node, I assume that something is odd with numbering and see an error in the parameters call (which would be line 3, if you start from the first line where the script starts.. not sure if this makes sense).
The reason, why this parameters would fail is that you copied this snippet from a Declarative Pipeline, but (as you don't have the pipeline wrapper, you're running a Scripted Pipeline.
For scripted pipelines, you have to use the build properties to define the parameters:
properties([
parameters([
string(name: 'dockerTag', defaultValue: '1.0', description: 'What is the docker tag?')
])
])
(as this is not obvious and not very well documented, I wrote a blog post a few months ago)
Yes
The following line gives the hint, where the error occurs in your pipeline script:
at WorkflowScript.run(WorkflowScript:3)
While line 3 in the pasted script is the node, I assume that something is odd with numbering and see an error in the parameters call (which would be line 3, if you start from the first line where the script starts.. not sure if this makes sense).
The reason, why this parameters would fail is that you copied this snippet from a Declarative Pipeline, but (as you don't have the pipeline wrapper, you're running a Scripted Pipeline.
For scripted pipelines, you have to use the build properties to define the parameters:
properties([
parameters([
string(name: 'dockerTag', defaultValue: '1.0', description: 'What is the docker tag?')
])
])
(as this is not obvious and not very well documented, I wrote a blog post a few months ago)

Jenkins integration for JIRA

I am looking for a documentation around Integrating JIRA with Jenkins. All I am trying to do is display the Jenkins build status in a dashboard in JIRA. I have installed Jenkins Plugin for JIRA and JIRA Plugin for Jenkins and went through the Atlassian marvelution documentation but it is not clear how to configure the Jobs.
It will be nice if I could get some instructions around integrating the Jobs to JIRA and how to configure the jobs to show up in JIRA dashboard/ Activity page for a JIRA Issue
The first step is try to configure JIRA and JENKINS server each working individually.
And then install the following Plugins in JENKINS and JIRA Separately
1) Jira Issue Updater:- This plugin can update Jira issues by changing their workflow status and adding comments. 1.11
2) JIRA plugin:- This plugin integrates Jenkins to Atlassian JIRA. 1.39
3) JIRA Plugin for Jenkins:- This plugin implements the Application Link API to support integration with Atlassian JIRA 1.5.3
4) JiraTestResultReporter plugin:- This plugin creates issues in Jira for failed unit tests.
Following add-on in JIRA server:-
1) JIRA Plugin to integrate Jenkins CI Version: 1.5.3 Vendor: Marvelution Add-on key: com.marvelution.jira.plugins.jenkins
2) JIRA Plugin to integrate Hudson CI Version: 5.0.4 Vendor: Marvelution Add-on key: com.marvelution.jira.plugins.hudson
After installing the above plugins in Jenkins go to Global configuration under Manage Jenkins and add JIRA site name.
Similarly go to JIRA Administration, Hudson/Jenkins, Servers, Add Server, configure there your Jenkins server.

Jenkins integrate with JIRA - Couldn't add Outgoing authentication for Application links in JIRA version 6.4

I could't able to add Outgoing Authentication of following credentials Service Provider Name, Consumer Key, Shared Secret,Request Token URL, Authorize URL..etc, while the creating application links for Jenkins. Also I couldn't able to see Application links/Creating reciprocal links in Jenkins.
Jenkins ver. 1.580
JIRA version 6.4
JIRA plugin for jenkins 1.39
JiraTestResultReporter plugin for jenkins 1.0.4
I was able to integrate Jenkins and Jira successfully via the SOAP service of Jira
I did not create an application link for Jenkins. Application links in Jira are applicable only for Atlassian Suite of products and not external products like Jenkins.
Jenkins talks to Jira via SOAP service something looks like the URL below
yourjirahost:yourjiraport/rpc/soap/jirasoapservice-v2
Any username password that can connect to a particular issue

Jenkins Integration with Jira issue

I have installed Jenkins Plugin for JIRA on my JIRA installation and also JIRA Plugin for Jenkins on to my Jenkins installation. I have added an application link in JIRA settings.
I am facing below issue:
1) On Application Links page there is a warning that my Jenkins Application "seems to be offline". While Adding a jenkins link it gives me error : The host doesn't respond. Change the url or click next to confirm.
Jira Version - 6.0.5
Jenkins Version - 1.562
Jenkins-Jira Plugin Version - 1.4.3
Thanks to anybody who's willing to help me out on this.
You can follow four steps:
Install JIRA Plugin in Jenkins
In Jenkins:
Manage Jenkins > manager plugins > available
search and choose Jenkins JIRA plugin , Jenkins JiraTestResultReporter plugin and Jenkins JIRA Issue Updater
Install Jenkins Plugin in JIRA.
https://marketplace.atlassian.com/plugins/com.marvelution.jira.plugins.jenkins
see: Installation section.
Add Jenkins 's Application Links in JIRA
The integration between JIRA and Jenkins has Application Links as its base. This allows administrators to configure and manage the Jenkins
To get started, go to [JIRA_BASEURL]/plugins/servlet/applinks/listApplicationLinks and click on the Add Application Link button to add a new Application Link for Jenkins.
or administration > plugin > Application Link > add Application Link; do as instruction
note: Optionally, but required if Jenkins is secured,
configure Outgoing Authentication that JIRA should use.
To do this, click on the Edit link next to the Jenkins Application Link, and select OutGoing Authentication tab
Provide the Username of the user to use to authenticate against Jenkins with
Provide the Password of the use
Jenkins Configuration
After the installation of the Jenkins Plugin for JIRA, and the configuration of at-least one Application Link, administrators will be able to control which Jobs are included in the synchronisation process and which aren't.
in Administration > plugins (add-ons) >Jenkins Configuration
Download JIRA plugin for Jenkins and install this plugin in Jenkins
way 1: copy it to Jenkins's plugin folder. and restart Jenkins
way2: Manage Jenkins > manager plugins > advanced > Upload Plugin . Choose file and upload then restart Jenkins
Enable Jenkins job in JIRA
then just use a known JIRA Issue Key in a commit message of your source code repo
Jenkins will make all the change sets (commits) available to the JIRA plugin when syncing a build.
The sync process uses the change sets to look for JIRA Issue Keys. Once this process locates a link, then that build will be available in the CI Build Panels.
download jenkins-jira-plugin at http://mvnrepository.com/artifact/com.marvelution.jira.plugins/jenkins-jira-plugin

Resources