Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove two-deployment mode #159

Merged
merged 21 commits into from
Apr 13, 2022
Merged
Show file tree
Hide file tree
Changes from 6 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
15 changes: 11 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,13 @@ generate-examples:
EXAMPLES_DIR=charts/$${chart_name}/examples; \
EXAMPLES=$$(find $${EXAMPLES_DIR} -type d -maxdepth 1 -mindepth 1 -exec basename \{\} \;); \
for example in $${EXAMPLES}; do \
VALUES=$$(find $${EXAMPLES_DIR}/$${example} -name *values.yaml); \
rm -rf "$${EXAMPLES_DIR}/$${example}/rendered"; \
helm template example charts/$${chart_name} --values "$${EXAMPLES_DIR}/$${example}/values.yaml" --output-dir "$${EXAMPLES_DIR}/$${example}/rendered"; \
mv $${EXAMPLES_DIR}/$${example}/rendered/$${chart_name}/templates/* "$${EXAMPLES_DIR}/$${example}/rendered"; \
rm -rf $${EXAMPLES_DIR}/$${example}/rendered/$${chart_name}; \
for value in $${VALUES}; do \
helm template example charts/$${chart_name} --values $${value} --output-dir "$${EXAMPLES_DIR}/$${example}/rendered"; \
mv $${EXAMPLES_DIR}/$${example}/rendered/$${chart_name}/templates/* "$${EXAMPLES_DIR}/$${example}/rendered"; \
rm -rf $${EXAMPLES_DIR}/$${example}/rendered/$${chart_name}; \
done; \
done; \
done

Expand All @@ -21,7 +24,10 @@ check-examples:
EXAMPLES=$$(find $${EXAMPLES_DIR} -type d -maxdepth 1 -mindepth 1 -exec basename \{\} \;); \
for example in $${EXAMPLES}; do \
echo "Checking example: $${example}"; \
helm template example charts/$${chart_name} --values "$${EXAMPLES_DIR}/$${example}/values.yaml" --output-dir "${TMP_DIRECTORY}/$${example}"; \
VALUES=$$(find $${EXAMPLES_DIR}/$${example} -name *values.yaml); \
for value in $${VALUES}; do \
helm template example charts/$${chart_name} --values $${value} --output-dir "${TMP_DIRECTORY}/$${example}"; \
done; \
if diff "$${EXAMPLES_DIR}/$${example}/rendered" "${TMP_DIRECTORY}/$${example}/$${chart_name}/templates" > /dev/null; then \
echo "Passed $${example}"; \
else \
Expand All @@ -32,3 +38,4 @@ check-examples:
rm -rf ${TMP_DIRECTORY}; \
done; \
done

2 changes: 1 addition & 1 deletion charts/opentelemetry-collector/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
apiVersion: v2
name: opentelemetry-collector
version: 0.12.1
version: 0.13.0
description: OpenTelemetry Collector Helm chart for Kubernetes
type: application
home: https://opentelemetry.io/
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,2 @@
agentCollector:
containerLogs:
enabled: true
containerLogs:
enabled: true
standaloneCollector:
enabled: false
Original file line number Diff line number Diff line change
@@ -1,4 +0,0 @@
agentCollector:
enabled: true
standaloneCollector:
enabled: false
5 changes: 0 additions & 5 deletions charts/opentelemetry-collector/ci/clusterrole-values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,3 @@ clusterRole:
- 'watch'
clusterRoleBinding:
name: "testing-clusterrolebinding"

agentCollector:
enabled: true
standaloneCollector:
enabled: false
29 changes: 13 additions & 16 deletions charts/opentelemetry-collector/ci/config-override-values.yaml
Original file line number Diff line number Diff line change
@@ -1,16 +1,13 @@
agentCollector:
enabled: true
configOverride:
receivers:
hostmetrics:
scrapers:
cpu:
disk:
filesystem:
service:
pipelines:
metrics:
receivers: [prometheus, hostmetrics]

standaloneCollector:
enabled: false
config:
receivers:
jaeger: null
otlp: null
hostmetrics:
scrapers:
cpu:
disk:
filesystem:
service:
pipelines:
metrics:
receivers: [prometheus, hostmetrics]
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,3 @@ ports:
enabled: false
zipkin:
enabled: false

agentCollector:
enabled: true
standaloneCollector:
enabled: false

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,4 +1 @@
agentCollector:
enabled: false
standaloneCollector:
enabled: true
mode: deployment

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
config:
exporters:
otlp:
endpoint: example-opentelemetry-collector:4317
tls:
insecure: true
service:
pipelines:
logs:
exporters:
- otlp
- logging
metrics:
exporters:
- otlp
- logging
traces:
exporters:
- otlp
- logging
TylerHelmuth marked this conversation as resolved.
Show resolved Hide resolved
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
mode: deployment
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ kind: ConfigMap
metadata:
name: example-opentelemetry-collector-agent
labels:
helm.sh/chart: opentelemetry-collector-0.12.1
helm.sh/chart: opentelemetry-collector-0.13.0
app.kubernetes.io/name: opentelemetry-collector
app.kubernetes.io/instance: example
app.kubernetes.io/version: "0.47.0"
Expand All @@ -21,13 +21,13 @@ data:
extensions:
health_check: {}
memory_ballast:
size_mib: "204"
size_mib: "819"
processors:
batch: {}
memory_limiter:
check_interval: 5s
limit_mib: 409
spike_limit_mib: 128
limit_mib: 1638
spike_limit_mib: 512
receivers:
jaeger:
protocols:
Expand Down Expand Up @@ -61,6 +61,7 @@ data:
logs:
exporters:
- otlp
- logging
processors:
- memory_limiter
- batch
Expand All @@ -69,6 +70,7 @@ data:
metrics:
exporters:
- otlp
- logging
processors:
- memory_limiter
- batch
Expand All @@ -78,6 +80,7 @@ data:
traces:
exporters:
- otlp
- logging
processors:
- memory_limiter
- batch
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ kind: ConfigMap
metadata:
name: example-opentelemetry-collector
labels:
helm.sh/chart: opentelemetry-collector-0.12.1
helm.sh/chart: opentelemetry-collector-0.13.0
app.kubernetes.io/name: opentelemetry-collector
app.kubernetes.io/instance: example
app.kubernetes.io/version: "0.47.0"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ kind: DaemonSet
metadata:
name: example-opentelemetry-collector-agent
labels:
helm.sh/chart: opentelemetry-collector-0.12.1
helm.sh/chart: opentelemetry-collector-0.13.0
app.kubernetes.io/name: opentelemetry-collector
app.kubernetes.io/instance: example
app.kubernetes.io/version: "0.47.0"
Expand All @@ -19,11 +19,13 @@ spec:
template:
metadata:
annotations:
checksum/config: a4eaf97a54f468568eb69407489b2d1c3d4800fa22bee5c6b4fb593fc8eb2bfd
checksum/config: c9bc18bc466c9f91e528d3d493f4586709f65e49f52772145591db421401d9de

labels:
app.kubernetes.io/name: opentelemetry-collector
app.kubernetes.io/instance: example
component: agent-collector

spec:

serviceAccountName: example-opentelemetry-collector
Expand Down Expand Up @@ -79,8 +81,8 @@ spec:
port: 13133
resources:
limits:
cpu: 256m
memory: 512Mi
cpu: 1
memory: 2Gi
volumeMounts:
- mountPath: /conf
name: opentelemetry-collector-configmap
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,12 @@ kind: Deployment
metadata:
name: example-opentelemetry-collector
labels:
helm.sh/chart: opentelemetry-collector-0.12.1
helm.sh/chart: opentelemetry-collector-0.13.0
app.kubernetes.io/name: opentelemetry-collector
app.kubernetes.io/instance: example
app.kubernetes.io/version: "0.47.0"
app.kubernetes.io/managed-by: Helm

spec:
replicas: 1
selector:
Expand All @@ -20,11 +21,13 @@ spec:
template:
metadata:
annotations:
checksum/config: 16a2701362c0b0946768257cf9a681979ed9b6d6a274dd56cff0531cd938f4a0
checksum/config: b7652074334382cbe3cdb9599f0567efb9646e2d1897a4249a42638490a5a41b

labels:
app.kubernetes.io/name: opentelemetry-collector
app.kubernetes.io/instance: example
component: standalone-collector

spec:

serviceAccountName: example-opentelemetry-collector
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ kind: Service
metadata:
name: example-opentelemetry-collector
labels:
helm.sh/chart: opentelemetry-collector-0.12.1
helm.sh/chart: opentelemetry-collector-0.13.0
app.kubernetes.io/name: opentelemetry-collector
app.kubernetes.io/instance: example
app.kubernetes.io/version: "0.47.0"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ kind: ServiceAccount
metadata:
name: example-opentelemetry-collector
labels:
helm.sh/chart: opentelemetry-collector-0.12.1
helm.sh/chart: opentelemetry-collector-0.13.0
app.kubernetes.io/name: opentelemetry-collector
app.kubernetes.io/instance: example
app.kubernetes.io/version: "0.47.0"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ kind: ConfigMap
metadata:
name: example-opentelemetry-collector-agent
labels:
helm.sh/chart: opentelemetry-collector-0.12.1
helm.sh/chart: opentelemetry-collector-0.13.0
app.kubernetes.io/name: opentelemetry-collector
app.kubernetes.io/instance: example
app.kubernetes.io/version: "0.47.0"
Expand All @@ -17,13 +17,13 @@ data:
extensions:
health_check: {}
memory_ballast:
size_mib: "204"
size_mib: "819"
processors:
batch: {}
memory_limiter:
check_interval: 5s
limit_mib: 409
spike_limit_mib: 128
limit_mib: 1638
spike_limit_mib: 512
receivers:
jaeger:
protocols:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ kind: DaemonSet
metadata:
name: example-opentelemetry-collector-agent
labels:
helm.sh/chart: opentelemetry-collector-0.12.1
helm.sh/chart: opentelemetry-collector-0.13.0
app.kubernetes.io/name: opentelemetry-collector
app.kubernetes.io/instance: example
app.kubernetes.io/version: "0.47.0"
Expand All @@ -19,11 +19,13 @@ spec:
template:
metadata:
annotations:
checksum/config: c0169178595958e64fddb5217b2e37306cd486549e563db94d46cf2af0cb0930
checksum/config: c7fc12f295730f4ad30d5f31a97650360dcc6ef381cc9007e35a72332f7a3f4b

labels:
app.kubernetes.io/name: opentelemetry-collector
app.kubernetes.io/instance: example
component: agent-collector

spec:

serviceAccountName: example-opentelemetry-collector
Expand Down Expand Up @@ -79,8 +81,8 @@ spec:
port: 13133
resources:
limits:
cpu: 256m
memory: 512Mi
cpu: 1
memory: 2Gi
volumeMounts:
- mountPath: /conf
name: opentelemetry-collector-configmap
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ kind: ServiceAccount
metadata:
name: example-opentelemetry-collector
labels:
helm.sh/chart: opentelemetry-collector-0.12.1
helm.sh/chart: opentelemetry-collector-0.13.0
app.kubernetes.io/name: opentelemetry-collector
app.kubernetes.io/instance: example
app.kubernetes.io/version: "0.47.0"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ kind: ConfigMap
metadata:
name: example-opentelemetry-collector
labels:
helm.sh/chart: opentelemetry-collector-0.12.1
helm.sh/chart: opentelemetry-collector-0.13.0
app.kubernetes.io/name: opentelemetry-collector
app.kubernetes.io/instance: example
app.kubernetes.io/version: "0.47.0"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,12 @@ kind: Deployment
metadata:
name: example-opentelemetry-collector
labels:
helm.sh/chart: opentelemetry-collector-0.12.1
helm.sh/chart: opentelemetry-collector-0.13.0
app.kubernetes.io/name: opentelemetry-collector
app.kubernetes.io/instance: example
app.kubernetes.io/version: "0.47.0"
app.kubernetes.io/managed-by: Helm

spec:
replicas: 1
selector:
Expand All @@ -20,11 +21,13 @@ spec:
template:
metadata:
annotations:
checksum/config: 16a2701362c0b0946768257cf9a681979ed9b6d6a274dd56cff0531cd938f4a0
checksum/config: b7652074334382cbe3cdb9599f0567efb9646e2d1897a4249a42638490a5a41b

labels:
app.kubernetes.io/name: opentelemetry-collector
app.kubernetes.io/instance: example
component: standalone-collector

spec:

serviceAccountName: example-opentelemetry-collector
Expand Down
Loading