Passing build information to Octopus

When deploying a release, it’s useful to know which build produced the artifact, what commits it contained, and which work items it’s associated with. Build information allows you to upload these details from your build server, either manually or with the use of a plugin, to Octopus Deploy.

Build information is associated with a package and includes:

  • Build URL: A link to the build which produced the package.
  • Commits: Details of the source commits related to the build.
  • Work items: Issue references parsed from the commit messages.

Passing build information to Octopus

Build information is passed to Octopus as a file using a custom format. The recommended way to supply the build information is to add the build information step from the Octopus Deploy plugin to your build server.

Build server support

The build information step is currently available in the official Octopus Deploy plugins:

Check our downloads page for our latest build server plugins.

In addition to the official plugins, there are some community supported integrations available for:

Build information is independent of the packages that it relates to. You can pass build information to Octopus before the packages have been pushed to either the built-in repository or an external feed. You can also push build information manually using the Octopus REST API when you aren’t utilizing a build server.

Commit messages and deep links may not be shown if an unsupported VcsType is passed to Octopus as part of the build information call. Currently we support values of Git and TFVC (TFS / Azure DevOps). SVN (Subversion) is not supported.

Work items will not show unless you have one of the issue tracker integrations configured.

Build information step

All of the available plugins contain a build information step/task, the TeamCity version of the build information step is shown below.

TeamCity build information Step

The build information step requires

  • Octopus URL: URL of your Octopus server
  • API Key: API key to use for uploading
  • (Optional) Space name: Name of the space to upload the build information to
  • Package ID: List of package IDs to associate the build information to
  • Package version: The version of the packages

Verbose logging can be used to include more detail in the build logs. This includes a complete output of all of the build information being passed to Octopus, which can be useful when troubleshooting.

BuildInformationPush permission is required to push build information to Octopus. If Overwrite Mode is set to Overwrite Existing BuildInformationAdminister permission is also required.

Viewing build information

As of Octopus 2019.10.0, the build information for a package can be viewed by navigating to Library ➜ Build Information

Library Build information

The build information for a package can be viewed on any release which contains the package.

Build information on release page

For packages pushed to the Octopus built-in repository, the build information can also be viewed in the package version details by navigating to Library ➜ Packages and selecting the package.

Build information on package version page

Using build information in release notes

The build information associated with packages is available for use in release notes (and release notes templates) as Octopus variables.

See the system variable documentation for the available variables.

Using build information in deployments

Package build information associated with a release will be also captured in deployments of the release.

From Octopus 2024.2 build information can be viewed on deployments.

Deployment build information

Ensure you’re using pre-release versions for any releases that aren’t intended to be a production release. Any releases that aren’t a pre-release will be treated as a full release by Octopus, which can result in deployments containing a larger amount of build information than intended.

Help us continuously improve

Please let us know if you have any feedback about this page.

Send feedback

Page updated on Monday, May 20, 2024