Opbeat is joining forces with Elastic – Learn more about Elastic APM

Release tracking with Deploybot

Fred Turkington (@z3ugma) figured out how to set up Opbeat release tracking with Deploybot and shared the solution with us.

1. Add a post-deployment command

There is a “Run commands after new version is uploaded” option in Deploybot, which will execute the shell commands you input.

Add the following snippet:

curl https://intake.opbeat.com/api/v1/organizations/<organization_id>/apps/<app_id>/releases/ \
    -H "Authorization: Bearer <secret_token>" \
    -d rev="%REVISION%" \
    -d branch="%BRANCH%" \
    -d status=completed

Make sure to replace the <organization_id>, <app_id> and <secret_token> with the credentials for your Opbeat app.

Requirement: cURL must be installed on the servers.

It should look like this in the Deploybot interface:

deploybot interface

2. Deploy your app

Next time you deploy your application the release and the related git information should show up in in Opbeat.

opbeat interface

Thanks for sharing the solution, Fred!