UrbanCode Deploy & JIRA Integration Part Two

In the first part of “UrbanCode Deploy & JIRA Integration” post we left us with an unsolved question.

How to pass a Jira issue nr. (issue_id) to the application process flow?

Application Process Properties is the solution.

Go to Applications -> “Your Application” -> Processes -> “Your Application Process” -> Configuration -> Application Process Properties

Create the property: issue_id

Now run the process:

What can we see?

Exactly our issue_id.

Now before running the process you will have to indicate the Jira issue_id.

The value of the issue_id key is passed to our processes as described in the first part of the post.

PS Someone could ask: Ok I can put in “Start Progress” a Jira issue, then put in “Done” status at the end of my process but what about the assignation? How can I assign the Jira issue?

You can use the JIRA REST API

Create a Shell Step and put it before the Transition Issue Step, like in figure:

Write it down the REST command:

curl -D- -u ${p:system/jira_user}:${p:system/jira_pwd} -p -H "Content-Type: application/json" -X PUT -d '{"name":"${p:request.user.name}"}' ${p:system/jira_url}rest/api/2/issue/${p:issue_id}/assignee

The variable “request.user.name” is the UrbanCode Deploy user who will start the process. It must exists as Jira user too obviously.

Have a nice day!

Operations Engineer working with Cloud Infrastructure, Containers, Kubernetes, CI/CD pipelines, CDRA processes, GitOps.