Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions test/charts/nr_backend/Chart.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
apiVersion: v2
name: nrdot-nr-backend
description: A Helm chart for deploying an nrdot collector as a DaemonSet writing to New Relic
version: 0.2.0
appVersion: "1.0"
8 changes: 8 additions & 0 deletions test/charts/nr_backend/templates/collector-secrets.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
apiVersion: v1
kind: Secret
metadata:
name: collector-secrets
type: Opaque
data:
backendUrl: {{ .Values.secrets.nrBackendUrl | b64enc }}
nrIngestKey: {{ .Values.secrets.nrIngestKey | b64enc }}
40 changes: 40 additions & 0 deletions test/charts/nr_backend/templates/daemonset.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
---
apiVersion: apps/v1
kind: DaemonSet
metadata:
name: &app nrdot-collector-daemonset
labels:
app: *app
spec:
selector:
matchLabels:
app: *app
template:
metadata:
labels:
app: *app
spec:
containers:
- name: *app
image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}"
imagePullPolicy: "{{ .Values.image.pullPolicy }}"
ports:
- name: health
containerPort: 13133
env:
- name: OTEL_EXPORTER_OTLP_ENDPOINT
valueFrom:
secretKeyRef:
name: collector-secrets
key: backendUrl
- name: NEW_RELIC_LICENSE_KEY
valueFrom:
secretKeyRef:
name: collector-secrets
key: nrIngestKey
- name: KUBE_NODE_NAME
valueFrom:
fieldRef:
fieldPath: spec.nodeName
- name: OTEL_RESOURCE_ATTRIBUTES
value: "host.name={{ .Values.collector.hostname }}-$(KUBE_NODE_NAME)"
14 changes: 14 additions & 0 deletions test/charts/nr_backend/values.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
image:
repository: newrelic/nrdot-collector-host
tag: latest
# Avoid accidentally pulling remote images in CI
pullPolicy: Never

secrets:
nrBackendUrl: PLACEHOLDER
nrIngestKey: PLACEHOLDER

collector:
hostname: nrdot-collector-default-hostname

clusterName: default-cluster-name
2 changes: 1 addition & 1 deletion test/terraform/nightly/main.tf
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
locals {
test_spec = yamldecode(file("${path.module}/../../../distributions/${var.distro}/spec-nightly.yaml"))
test_spec = yamldecode(file("${path.module}/../../../distributions/${var.distro}/test/spec-nightly.yaml"))
ec2_enabled = local.test_spec.nightly.ec2.enabled
chart_name = local.test_spec.nightly.collectorChart.name
chart_version = local.test_spec.nightly.collectorChart.version
Expand Down
Loading