Skip to content

Commit

Permalink
Allow specifying STATSD_NAMESPACE (mastodon#5700)
Browse files Browse the repository at this point in the history
  • Loading branch information
Gargron authored and cobodo committed Dec 6, 2017
1 parent c097785 commit 4f1b045
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion config/initializers/statsd.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
host, port = ENV['STATSD_ADDR'].split(':')

statsd = ::Statsd.new(host, port)
statsd.namespace = ['Mastodon', Rails.env].join('.')
statsd.namespace = ENV.fetch('STATSD_NAMESPACE') { ['Mastodon', Rails.env].join('.') }

::NSA.inform_statsd(statsd) do |informant|
informant.collect(:action_controller, :web)
Expand Down

0 comments on commit 4f1b045

Please sign in to comment.