Create deployments from Atlassian Bamboo
Setting up elmah.io Deployment Tracking on Bamboo is easy using a bit of PowerShell.
-
Add a new Script Task and select Windows PowerShell in Interpreter.
-
Select Inline in Script location and add the following PowerShell to Script body:
$ProgressPreference = "SilentlyContinue"
Write-Host $bamboo_buildNumber
$url = "https://api.elmah.io/v3/deployments?api_key=API_KEY"
$body = @{
version = $Env:bamboo_buildNumber
logId = "LOG_ID"
}
[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12
Invoke-RestMethod -Method Post -Uri $url -Body $body
Replace API_KEY
and LOG_ID
and everything is configured. The script uses the build number of the current build as the version number ($Env:bamboo_buildNumber
). If you prefer another scheme, Bamboo offers a range of variables.
This article was brought to you by the elmah.io team. elmah.io is the best error management system for .NET web applications. We monitor your website, alert you when errors start happening, and help you fix errors fast.
See how we can help you monitor your website for crashes Monitor your website