From 9996dd40bb199b41f9a97f84ca384314d8cc9052 Mon Sep 17 00:00:00 2001 From: evazion Date: Wed, 7 Aug 2019 22:11:07 -0500 Subject: [PATCH] capistrano: only log newrelic deployment in production. Fix local development deployments getting logged in New Relic. --- Capfile | 2 -- config/deploy/production.rb | 4 +++- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Capfile b/Capfile index 0b7c7fce0..7c2f07157 100644 --- a/Capfile +++ b/Capfile @@ -17,5 +17,3 @@ require 'new_relic/recipes' # Load custom tasks from `lib/capistrano/tasks` if you have any defined Dir.glob('lib/capistrano/tasks/*.rake').each { |r| import r } - -after "deploy:updated", "newrelic:notice_deployment" diff --git a/config/deploy/production.rb b/config/deploy/production.rb index 697e1f9a9..f12369c93 100644 --- a/config/deploy/production.rb +++ b/config/deploy/production.rb @@ -6,4 +6,6 @@ server "saitou", :roles => %w(web app) server "oogaki", :roles => %w(worker) set :linked_files, fetch(:linked_files, []).push(".env.production") -set :rbenv_path, "/home/danbooru/.rbenv" \ No newline at end of file +set :rbenv_path, "/home/danbooru/.rbenv" + +after "deploy:finished", "newrelic:notice_deployment"