Skip to content

Commit

Permalink
fix: newrelic license key cd (#473)
Browse files Browse the repository at this point in the history
  • Loading branch information
gmbronco authored Oct 7, 2023
1 parent f608946 commit 0b0ceb2
Showing 1 changed file with 4 additions and 9 deletions.
13 changes: 4 additions & 9 deletions .ebextensions/newrelic.config
Original file line number Diff line number Diff line change
Expand Up @@ -7,22 +7,17 @@ files:
commands:
# Extract password from env
"01-setup-license-key":
env:
NEW_RELIC_LICENSE_KEY:
"Fn::GetOptionSetting":
Namespace: "aws:elasticbeanstalk:application:environment"
OptionName: NEW_RELIC_LICENSE_KEY
command: |
sudo echo "license_key: $NEW_RELIC_LICENSE_KEY" > /etc/newrelic-infra.yml

echo "license_key: $(/opt/elasticbeanstalk/bin/get-config environment -k NEW_RELIC_LICENSE_KEY)"
# Create the agent’s yum repository
"02-agent-repository":
command: sudo curl -o /etc/yum.repos.d/newrelic-infra.repo https://download.newrelic.com/infrastructure_agent/linux/yum/amazonlinux/2/x86_64/newrelic-infra.repo
#
# Update your yum cache
"03-update-yum-cache":
"04-update-yum-cache":
command: yum -q makecache -y --disablerepo='*' --enablerepo='newrelic-infra'
#
# Run the installation script
"04-run-installation-script":
"05-run-installation-script":
command: sudo yum install newrelic-infra -y

0 comments on commit 0b0ceb2

Please sign in to comment.