Post deployment info the NewRelic
# New Relic deployment events | |
my $ua = LWP::UserAgent->new; | |
$response = $ua->request(POST 'https://api.newrelic.com/deployments.xml', | |
Content => [ | |
'deployment[application_id]' => $APPID, | |
'deployment[description]' => 'deployment message', | |
'deployment[revision]' => $RELEASE_VERSION, | |
'deployment[user]' => 'Jenkins' | |
], | |
'x-api-key' => $APIKEY | |
); | |
if ($response->is_success) { | |
print $response->decoded_content; | |
} else { | |
print $response->headers_as_string . "\n"; | |
die $response->status_line; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment