mirror of
https://github.com/deployphp/deployer.git
synced 2025-02-22 16:27:39 +01:00
* moved newrelic endpoint to config and used it when posting to api * ran bin/docgen for the commit * mentioned the new setting for documentation Co-authored-by: RobertOS <robert.simionescu@gmail.com>
1.5 KiB
1.5 KiB
Newrelic Recipe
require 'contrib/newrelic.php';
Configuration
newrelic_app_id
– newrelic's app idnewrelic_api_key
– newrelic's api keynewrelic_description
– message to sendnewrelic_endpoint
– newrelic's REST API endpoint
Usage
Since you should only notify New Relic of a successful deployment, the newrelic:notify
task should be executed right at the end.
after('deploy', 'newrelic:notify');
Configuration
newrelic_app_id
:::info Required Throws exception if not set. :::
newrelic_description
return runLocally('git log -n 1 --format="%an: %s" | tr \'"\' "\'"');
newrelic_revision
return runLocally('git log -n 1 --format="%h"');
newrelic_endpoint
'api.newrelic.com'
Tasks
newrelic:notify
Notifies New Relic of deployment.