-
Notifications
You must be signed in to change notification settings - Fork 23
/
Copy pathoperator-deployment.yaml
57 lines (57 loc) · 2.99 KB
/
operator-deployment.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
apiVersion: apps/v1
kind: Deployment
metadata:
labels:
{{- include "amazon-cloudwatch-observability.labels" . | nindent 4 }}
control-plane: controller-manager
name: {{ template "amazon-cloudwatch-observability.name" . }}-controller-manager
namespace: {{ .Release.Namespace }}
spec:
replicas: {{ .Values.replicaCount }}
selector:
matchLabels:
app.kubernetes.io/name: {{ template "amazon-cloudwatch-observability.name" . }}
control-plane: controller-manager
template:
metadata:
annotations:
{{- if .Values.manager.podAnnotations }}
{{- include "amazon-cloudwatch-observability.podAnnotations" . | nindent 8 }}
{{- end }}
labels:
app.kubernetes.io/name: {{ template "amazon-cloudwatch-observability.name" . }}
control-plane: controller-manager
{{- include "amazon-cloudwatch-observability.podLabels" . | nindent 8 }}
spec:
containers:
- image: {{ template "cloudwatch-agent-operator.image" . }}
args:
- {{ printf "--auto-instrumentation-config=%s" (dict "java" (merge .Values.manager.autoInstrumentationResources.java .Values.manager.autoInstrumentationConfiguration.java) "python" (merge .Values.manager.autoInstrumentationResources.python .Values.manager.autoInstrumentationConfiguration.python) "dotnet" (merge .Values.manager.autoInstrumentationResources.dotnet .Values.manager.autoInstrumentationConfiguration.dotnet) "nodejs" (.Values.manager.autoInstrumentationResources.nodejs) | toJson) | quote }}
- {{ printf "--auto-annotation-config=%s" (.Values.manager.autoAnnotateAutoInstrumentation | toJson) | quote }}
- "--auto-instrumentation-java-image={{ template "auto-instrumentation-java.image" . }}"
- "--auto-instrumentation-python-image={{ template "auto-instrumentation-python.image" . }}"
- "--auto-instrumentation-dotnet-image={{ template "auto-instrumentation-dotnet.image" . }}"
- "--auto-instrumentation-nodejs-image={{ template "auto-instrumentation-nodejs.image" . }}"
- "--target-allocator-image={{ template "target-allocator.modify-image" . }}"
- "--feature-gates=operator.autoinstrumentation.multi-instrumentation,operator.autoinstrumentation.multi-instrumentation.skip-container-validation"
command:
- /manager
name: manager
ports:
- containerPort: {{ .Values.manager.ports.containerPort }}
name: webhook-server
protocol: TCP
resources: {{ toYaml .Values.manager.resources | nindent 10 }}
volumeMounts:
- mountPath: /tmp/k8s-webhook-server/serving-certs
name: cert
readOnly: true
serviceAccountName: {{ template "amazon-cloudwatch-observability.managerServiceAccountName" . }}
terminationGracePeriodSeconds: 10
volumes:
- name: cert
secret:
defaultMode: 420
secretName: {{ template "amazon-cloudwatch-observability.certificateSecretName" . }}
nodeSelector:
kubernetes.io/os: linux