Skip to content

Commit

Permalink
feat: Add k8s auto attach support (#1130)
Browse files Browse the repository at this point in the history
* Add k8s auto attach

* Allow setting of false values
  • Loading branch information
dbudziwojskiNR authored Nov 5, 2024
1 parent 56937e6 commit f4b022b
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion recipes/newrelic/infrastructure/kubernetes.yml
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ install:
NR_CLI_KUBE_EVENTS="{{.NR_CLI_KUBE_EVENTS}}"
NR_CLI_LOGGING="{{.NR_CLI_LOGGING}}"
NR_CLI_LOGGING_LOW_DATA_MODE="{{.NR_CLI_LOGGING_LOW_DATA_MODE}}"
NR_CLI_AGENT_OPERATOR="{{.NR_CLI_AGENT_OPERATOR}}"
# Prometheus integrations
Expand Down Expand Up @@ -275,6 +276,7 @@ install:
NR_CLI_LOGGING_PERSISTENCE=${NR_CLI_LOGGING_PERSISTENCE:-""}
NR_CLI_LOGGING_PERSISTENCE_STORAGE_CLASS=${NR_CLI_LOGGING_PERSISTENCE_STORAGE_CLASS:-""}
NR_CLI_LOGGING_LINUX_MOUNT_PATH=${NR_CLI_LOGGING_LINUX_MOUNT_PATH:-""}
NR_CLI_AGENT_OPERATOR=${NR_CLI_AGENT_OPERATOR:-false}
# Prometheus integrations
Expand Down Expand Up @@ -576,6 +578,7 @@ install:
ARGS="${ARGS} --devel"
fi
ARGS="${ARGS} --set ksm.enabled=${NR_CLI_KSM}"
ARGS="${ARGS} --set k8s-agents-operator.enabled=${NR_CLI_AGENT_OPERATOR}"
# if installing in GKE Autopilot, we need to turn off controlPlane and pixie and set kubelet scheme and port
if [[ "{{.NR_CLI_GKE_AUTOPILOT}}" == "true" ]]; then
Expand Down Expand Up @@ -619,7 +622,7 @@ install:
if [[ -n "${NR_CLI_LOGGING_LINUX_MOUNT_PATH}" ]]; then
ARGS="${ARGS} --set newrelic-logging.fluentBit.linuxMountPath=${NR_CLI_LOGGING_LINUX_MOUNT_PATH}"
fi
if [[ "${NEW_RELIC_REGION}" == "STAGING" ]]; then
ARGS="${ARGS} --set global.nrStaging=true"
fi
Expand Down Expand Up @@ -691,6 +694,7 @@ install:
BODY="${BODY},\"newrelic-infrastructure.privileged\":\"${NR_CLI_PRIVILEGED}\""
BODY="${BODY},\"global.lowDataMode\":\"${NR_CLI_LOW_DATA_MODE}\""
BODY="${BODY},\"ksm.enabled\":\"${NR_CLI_KSM}\""
BODY="${BODY},\"k8s-agents-operator.enabled\":\"${NR_CLI_AGENT_OPERATOR}\""
# if installing in GKE Autopilot, turn off controlPlane and set kubelet scheme and port
if [[ "{{.NR_CLI_GKE_AUTOPILOT}}" == "true" ]]; then
Expand Down

0 comments on commit f4b022b

Please sign in to comment.