From 6e75c32bd7901e0636ed8a3ed856d9a34bee39b5 Mon Sep 17 00:00:00 2001 From: Scott Idler Date: Fri, 11 Oct 2019 13:06:20 -0700 Subject: [PATCH] made small fixes to enable-streaming.sh --- bin/new-relic/enable-streaming.sh | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/bin/new-relic/enable-streaming.sh b/bin/new-relic/enable-streaming.sh index c179d39..a9b4552 100755 --- a/bin/new-relic/enable-streaming.sh +++ b/bin/new-relic/enable-streaming.sh @@ -1,6 +1,9 @@ #!/usr/bin/env bash -set -ex +if [ -n "$DEBUG" ]; then + PS4=':${LINENO}+' + set -x +fi source "env.sh" source "install.sh" @@ -11,8 +14,7 @@ function enable_streaming(){ echo "usage: $1, One of more function names to enable log streaming." fi if [ -d "$NR_LAMBDA_DIRECTORY" ]; then - cd nr-lambda - sh newrelic-cloud stream-lambda-logs $1 + (cd "$NR_LAMBDA_DIRECTORY" && ./newrelic-cloud stream-lambda-logs --regions "$AWS_REGION" --functions "$@") else echo "Please run install.sh first." fi