# SPDX-FileCopyrightText: 2021-present Open Networking Foundation <info@opennetworking.org> | |
# | |
# SPDX-License-Identifier: LicenseRef-ONF-Member-Only-1.0 | |
apiVersion: apps/v1 | |
kind: Deployment | |
metadata: | |
name: {{ template "chronos-exporter.fullname" . }} | |
namespace: {{ .Release.Namespace }} | |
labels: | |
name: {{ template "chronos-exporter.fullname" . }} | |
spec: | |
replicas: {{ .Values.replicaCount }} | |
selector: | |
matchLabels: | |
{{- include "chronos-exporter.selectorLabels" . | nindent 6 }} | |
template: | |
metadata: | |
labels: | |
name: {{ template "chronos-exporter.fullname" . }} | |
{{- include "chronos-exporter.selectorLabels" . | nindent 8 }} | |
spec: | |
{{- with .Values.imagePullSecrets }} | |
imagePullSecrets: | |
{{- toYaml . | nindent 6 }} | |
{{- end }} | |
securityContext: | |
{{- toYaml .Values.podSecurityContext | nindent 8 }} | |
containers: | |
- name: {{ .Chart.Name }} | |
image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}" | |
imagePullPolicy: {{ .Values.image.pullPolicy }} | |
env: | |
- name: POD_NAMESPACE | |
valueFrom: | |
fieldRef: | |
fieldPath: metadata.namespace | |
- name: POD_NAME | |
valueFrom: | |
fieldRef: | |
fieldPath: metadata.name | |
- name: NODE_NAME | |
valueFrom: | |
fieldRef: | |
fieldPath: spec.nodeName | |
args: | |
- "/usr/local/bin/chronos-exporter" | |
- "--config" | |
- {{ .Values.configfile }} | |
- "--alert" | |
- {{ .Values.alertfile }} | |
- "--aether" | |
- {{ .Values.aetherfile }} | |
ports: | |
- name: metrics | |
containerPort: 2112 | |
readinessProbe: | |
httpGet: | |
path: /metrics | |
port: 2112 | |
initialDelaySeconds: 5 | |
periodSeconds: 10 | |
livenessProbe: | |
httpGet: | |
path: /metrics | |
port: 2112 | |
initialDelaySeconds: 15 | |
periodSeconds: 20 | |
volumeMounts: | |
- name: exporter-config | |
mountPath: /etc/chronos-exporter/configs | |
readOnly: true | |
- name: exporter-images | |
mountPath: /opt/images | |
readOnly: true | |
- name: exporter-site-plans | |
mountPath: /opt/site-plans/fremont | |
readOnly: true | |
- name: exporter-alert | |
mountPath: /etc/chronos-exporter/alerts | |
readOnly: true | |
volumes: | |
- name: secret | |
secret: | |
secretName: {{ template "chronos-exporter.fullname" . }}-secret | |
- name: exporter-config | |
configMap: | |
name: {{ template "chronos-exporter.fullname" . }}-config | |
- name: exporter-images | |
configMap: | |
name: {{ template "chronos-exporter.fullname" . }}-images | |
- name: exporter-site-plans | |
configMap: | |
name: {{ template "chronos-exporter.fullname" . }}-site-plans | |
- name: exporter-alert | |
configMap: | |
name: {{ template "chronos-exporter.fullname" . }}-alert |