Configure New Relic Infrastructure with Puppet

This document explains how to use Puppet to install and configure New Relic Infrastructure using the newrelic-infra module. For an explanation of how to use Puppet, see Puppet documentation. This is a community-supported effort.

This document provides the basic information needed to use this configuration management tool. Detailed configuration will have to conform to the customer's standards.

Requirements

The Infrastructure Puppet module has these requirements:

Module description

Use the newrelic-infra module to:

  • Add the New Relic Infrastructure package repository source.
  • Install, configure, and manage the New Relic Infrastructure agent.

The New Relic Puppet module is available on Puppet Forge.

Run newrelic-infra module

To run the default newrelic-infra module, declare the main ::agent class.

Install the agent with the module

All interactions with newrelic-infra are done through the main agent class.

To install New Relic Infrastructure using Puppet, use:


class { 'newrelic_infra::agent':
    ensure      => 'latest',
    license_key => 'YOUR_LICENSE_KEY',
}

Puppet parameters

Here are the parameters for the newrelic_infra::agent public class:

Parameter Parameter description
custom_configs A hash of key-value pairs. Corresponds directly with the available general configuration settings.
ensure

Specifies the Infrastructure agent ensure status.

Valid values include:

  • 'latest' - (default) Installs the latest agent version
  • 'absent' - Uninstalls the agent
  • VERSION_STRING - A string containing a specific version to pin
license_key

Specifies the New Relic license key to use.

For more help

If you need additional help, file an issue at newrelic/infrastructure-agent-puppet on GitHub.

Recommendations for learning more: