[Solved] How Add new ruby on rails application on New Relic? [closed]


you can look at a video here https://newrelic.com/docs/ruby/ruby-agent-installation

there are 3 simple steps to install newrelic

Installing the gem

New Relic recommends installing the Ruby gem in order to have better control over versions and dependencies. However, the gem is not supported for Rails versions prior to 2.0. If you are using Rails 1.2.6 and earlier, install the plugin.

Our gem is available on rubygems.org as enter code here newrelic_rpm:

 sudo gem install newrelic_rpm

For Rails 3 and installations using Bundler, simply add our gem to the Gemfile:

gem 'newrelic_rpm'

For Rails versions 2.1 to 2.3 without Bundler, edit environment.rb and add to the initializer block:

config.gem "newrelic_rpm" 

For Rails versions 2.0.*, edit environment.rb and add this statement after the initializer block:

require "newrelic_rpm"

*strong text*Installing the configuration file

After installing the agent, copy the newrelic.yml file into the config subdirectory of your application. You can download a fresh newrelic.yml that includes your license key from the Account Settings link when logged in to rpm.newrelic.com.

Updating the newrelic.yml file

Whenever you update the agent, double-check that your Agent configuration file (config/newrelic.yml) is up to date. To do this, you’ll need to do a visual inspection of the default newrelic.yml file that lives in the Agent plugin folder (vendor/plugins/newrelic_rpm/newrelic.yml). Look for new configuration options that aren’t in your config/newrelic.yml file.

Updating the agent

sudo gem update newrelic_rpm

Installing with the Bundler gem

In versions 2.13 and above, the New Relic Ruby agent will properly handle Bundler initialization under Rails 3 and Rails 2.3.

Add the gem specification to your Gemfile. Recommendation: Place the New Relic gem as low in the list as possible, allowing the frameworks above it to be instrumented when the gem initializes:

gem 'newrelic_rpm'

Note: This approach only works for Bundler versions starting with 1.0.0. For more information on the bundler gem, see the bundler github project.

If you still have problems, submit a support ticket (for fastest service) or email support @ New Relic. Also, you may be able to find support from the community at Stack Overflow. Tag your post with newrelic.

solved How Add new ruby on rails application on New Relic? [closed]