AETHER-1585 Chart for edge-maintenance-agent
Change-Id: Ic5166bfca3eccbb6725befbda386aba99e25ddb9
diff --git a/monitoring/edge-maintenance-agent/templates/deployment.yaml b/monitoring/edge-maintenance-agent/templates/deployment.yaml
new file mode 100644
index 0000000..f555add
--- /dev/null
+++ b/monitoring/edge-maintenance-agent/templates/deployment.yaml
@@ -0,0 +1,67 @@
+# Copyright 2020-present Open Networking Foundation
+# SPDX-License-Identifier: LicenseRef-ONF-Member-Only-1.0
+
+apiVersion: apps/v1
+kind: Deployment
+metadata:
+ name: {{ include "edge-maintenance-agent.fullname" . }}
+ labels:
+ {{- include "edge-maintenance-agent.labels" . | nindent 4 }}
+spec:
+ replicas: {{ .Values.replicaCount }}
+ selector:
+ matchLabels:
+ {{- include "edge-maintenance-agent.selectorLabels" . | nindent 6 }}
+ template:
+ metadata:
+ {{- with .Values.podAnnotations }}
+ annotations:
+ {{- toYaml . | nindent 8 }}
+ {{- end }}
+ labels:
+ {{- include "edge-maintenance-agent.selectorLabels" . | nindent 8 }}
+ spec:
+ {{- with .Values.imagePullSecrets }}
+ imagePullSecrets:
+ {{- toYaml . | nindent 8 }}
+ {{- end }}
+ securityContext:
+ {{- toYaml .Values.podSecurityContext | nindent 8 }}
+ containers:
+ - name: {{ .Chart.Name }}
+ securityContext:
+ {{- toYaml .Values.securityContext | nindent 12 }}
+ image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}"
+ imagePullPolicy: {{ .Values.image.pullPolicy }}
+ ports:
+ - name: http
+ containerPort: 8080
+ protocol: TCP
+ command: ["python", "edge_maintenance_agent.py"]
+ env:
+ - name: AETHER_EDGE_STATUS_URL
+ value: "{{ .Values.edgeMonitoringServerURL }}/{{ .Values.edgeName }}"
+ livenessProbe:
+ httpGet:
+ path: /healthz
+ port: http
+ initialDelaySeconds: 3
+ periodSeconds: 3
+ readinessProbe:
+ httpGet:
+ path: /metrics
+ port: http
+ resources:
+ {{- toYaml .Values.resources | nindent 12 }}
+ {{- with .Values.nodeSelector }}
+ nodeSelector:
+ {{- toYaml . | nindent 8 }}
+ {{- end }}
+ {{- with .Values.affinity }}
+ affinity:
+ {{- toYaml . | nindent 8 }}
+ {{- end }}
+ {{- with .Values.tolerations }}
+ tolerations:
+ {{- toYaml . | nindent 8 }}
+ {{- end }}