Octopus Deploy for Jira

Hi,

I have installed the new Octopus Deploy for Jira from the Atlassian Marketplace, but I am not seeing any release notes generated or Jira tickets in an Octopus deployement.

I am also not seeing any Deployment information in our Jira tickets.

It looks like it’s not working, but I wanted to know where to start looking for the cause. I’ve checked the OctopusServer.txt log file and cannot see anything in there.

I followed the docs at https://octopus.com/docs/packaging-applications/build-servers/metadata/jira

Regards,
Ryan.

Hi Ryan,

Thanks for getting in touch, sorry to hear you’re having trouble with the integration. We’re currently working on updates to our documentation to address some common things that get missed in the setup, and to include some troubleshooting guides.

Something that probably doesn’t stand out enough is the link to this page about the build information and metadata. End-to-end the integration works based on you entering Jira work item references in your commit messages, the build server passing those on to Octopus (via the Octopus Metadata step), then Octopus making the information available during releases and deployments.

Which build server are you using? At the time of writing this, our TeamCity and Bamboo plugins have support for the new Metadata step. Azure DevOps is in the process of being released and Jenkins is under development.

To work through the chain for troubleshooting:

  • Do you have commit messages with Jira work item references?
  • Has the Octopus Metadata step been added to your build process?
    • Are the PackageId and Version values correctly aligned with the package you are pushing?
  • If the package is being pushed to Octopus, when you view the version in Library / Packages can you see the commit and work item data? If not then the packageId and Version likely aren’t aligned on the build step.
  • When you create a release, can you see the commit and work item information on the release page with the package(s)?
  • When you do a deployment, do you see the blocks related to pushing data to Jira? The list of work item references should appear in the messages, does that list look correct?

Hope that helps and please let me know how you go.

Regards
Shannon

Hi Shannon,

Thank for the reply.

I think the reason why it’s not working is due to the metadata step in the build server that you have highlighted and also the commit message convention.

I am using TeamCity and we have not yet setup the Octopus Metadata step. We are also currently not generating commit messages using the Jira work item either as we are following a modified version of https://www.conventionalcommits.org/en/v1.0.0-beta.2/

I’ll work with the team and see what we can do.

Thank you for updating the docs as well.

Regards,
Ryan.

I’ve just had a quick read and I think it’d work using conventional commits. If I’m understanding it right, the squashed commit when features get merged back on to master could include a Jira work item reference, similar to this example that includes a GitHub issue reference.

So a commit message along the lines of

fix: minor typos in code

see the issue for details on the typos fixed

fixes issue JIR-12

would get passed to Octopus and correctly parsed to recognise the reference to Jira work item JIR-12.

Again, please let me know how you go.

So I have setup the Octopus Metadata build step in one of our TeamCity Projects and have successfully published the metadata. I can see the metadata has hit the Octopus DB in the PackageMetadata table and can confirm that the PackageId and Version are correct.

I can see the metadata section in Octopus -> Library -> Packages -> Version that lists the Work Items, Commits etc.

However, I cannot see the Release Notes section when I click into the Release itself in Octopus.

I also cannot see the Release Notes section on the Jira ticket

Is there something that I am missing?

Do you see this collapsible section in the Packages section of the release?

We don’t generate release notes out of the box, so if that Metadata appears but there’s nothing in the Release Notes section you may not have a Release Notes template set on the Project Settings?

The following example from that docs page could be a good starting point

#{each workItem in Octopus.Release.WorkItems}
- [#{workItem.Id}](#{workItem.LinkUrl}) - #{workItem.Description}
#{/each}

There isn’t a Release Notes section on the Jira ticket itself, there’s a Deployments panel that should appear once you’ve successfully done a deployment and Octopus has pushed some data through. Did you see the blocks described here in the deployment’s task log?

I don’t see the “Metadata” section as part of the Packages section.

I’ve added the Release Notes template as well, but that doesn’t seem to change anything.

We have actually just asked Atlassian for a site-rename and they have come back with the following:

We have finished our internal checks and unfortunately we found that the following add-ons on your cloud site aren’t yet compatible with this new site-rename feature.

Incompatible add-ons

addon_name
Octopus Deploy

I’ll have to revisit this after our site-rename as we need to uninstall, have the site-rename done and then install this addon again.

Cheers

I just realised something that was missing from the checklist, if the metadata appears in the package library but not the on the release it can be because the metadata step in the build process is happening after the create release step. Could you check which order the steps are in in TeamCity?

Regarding the site-rename, that wasn’t a scenario we were aware until now. We’re looking in to what we need to do to support it. We think we should be able to update the Connect App to support the rename from the Jira end. There’d still be a manual update of the Jira instance Url in the Octopus configuration but we think the rest will work. Until we get that resolved uninstall and reinstall is the workaround.

Thanks for your help Shannon.

I think you’re right about the metadata step being in the wrong order. I had that as the last step after the create release step.

Once the site rename happens I’ll install the plugin again and confirm if everything is working.

Perfect, look forward to hearing from you then.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.