Skip to content

Commit

Permalink
feat: provide values file to nrdot agent type
Browse files Browse the repository at this point in the history
  • Loading branch information
DavSanchez committed Oct 24, 2023
1 parent 3459db4 commit f576ffc
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions recipes/newrelic/infrastructure/super-agent/debian.yml
Original file line number Diff line number Diff line change
Expand Up @@ -326,7 +326,7 @@ install:
fi
- |
if [ "{{.NEW_RELIC_REGION}}" = "STAGING" ]; then
echo 'OTEL_EXPORTER_OTLP_ENDPOINT=staging-otlp.nr-data.net:4317' >> /etc/newrelic-super-agent/newrelic-super-agent.conf
echo 'otel_exporter_otlp_endpoint: staging-otlp.nr-data.net:4317' >> /etc/newrelic-super-agent/nrdot-values.yaml
elif [ "{{.NEW_RELIC_REGION}}" = "EU" ]; then
echo 'OTEL_EXPORTER_OTLP_ENDPOINT=otlp.eu01.nr-data.net:4317' >> /etc/newrelic-super-agent/newrelic-super-agent.conf
else
Expand Down Expand Up @@ -356,6 +356,9 @@ install:
else
sed -i '/^\s*#\s*nr_otel_collector:/s/#//' /etc/newrelic-super-agent/config.yaml
sed -i '/^\s*#\s*agent_type: "newrelic\/io\.opentelemetry\.collector/s/#//' /etc/newrelic-super-agent/config.yaml
if [ "{{.NEW_RELIC_REGION}}" = "STAGING" ]; then
sed -i 's/nr_otel_collector:/nr_otel_collector:\n values_file: "\/etc\/newrelic-super-agent\/nrdot-values\.yaml"/' /etc/newrelic-super-agent/config.yaml
fi
fi
config_opamp:
Expand Down Expand Up @@ -427,4 +430,4 @@ install:
post_install:
info: |2
⚙️ The New Relic Super Agent configuration file can be found in /etc/newrelic-super-agent/config.yaml
⚙️ The New Relic Super Agent configuration file can be found in /etc/newrelic-super-agent/config.yaml

0 comments on commit f576ffc

Please sign in to comment.