added repo
This commit is contained in:
@@ -0,0 +1,23 @@
|
||||
# Patterns to ignore when building packages.
|
||||
# This supports shell glob matching, relative path matching, and
|
||||
# negation (prefixed with !). Only one pattern per line.
|
||||
.DS_Store
|
||||
# Common VCS dirs
|
||||
.git/
|
||||
.gitignore
|
||||
.bzr/
|
||||
.bzrignore
|
||||
.hg/
|
||||
.hgignore
|
||||
.svn/
|
||||
# Common backup files
|
||||
*.swp
|
||||
*.bak
|
||||
*.tmp
|
||||
*.orig
|
||||
*~
|
||||
# Various IDEs
|
||||
.project
|
||||
.idea/
|
||||
*.tmproj
|
||||
.vscode/
|
||||
@@ -0,0 +1,6 @@
|
||||
apiVersion: v2
|
||||
name: node-agent
|
||||
description: A Prometheus exporter based on eBPF that gathers comprehensive container metrics.
|
||||
type: application
|
||||
version: 0.2.21
|
||||
appVersion: "1.25.3"
|
||||
@@ -0,0 +1,61 @@
|
||||
{{/*
|
||||
Expand the name of the chart.
|
||||
*/}}
|
||||
{{- define "node-agent.name" -}}
|
||||
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Create a default fully qualified app name.
|
||||
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
|
||||
If release name contains chart name it will be used as a full name.
|
||||
*/}}
|
||||
{{- define "node-agent.fullname" -}}
|
||||
{{- if .Values.fullnameOverride }}
|
||||
{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" }}
|
||||
{{- else }}
|
||||
{{- $name := default .Chart.Name .Values.nameOverride }}
|
||||
{{- if contains $name .Release.Name }}
|
||||
{{- .Release.Name | trunc 63 | trimSuffix "-" }}
|
||||
{{- else }}
|
||||
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Create chart name and version as used by the chart label.
|
||||
*/}}
|
||||
{{- define "node-agent.chart" -}}
|
||||
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Common labels
|
||||
*/}}
|
||||
{{- define "node-agent.labels" -}}
|
||||
helm.sh/chart: {{ include "node-agent.chart" . }}
|
||||
{{ include "node-agent.selectorLabels" . }}
|
||||
{{- if .Chart.AppVersion }}
|
||||
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
|
||||
{{- end }}
|
||||
app.kubernetes.io/managed-by: {{ .Release.Service }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Selector labels
|
||||
*/}}
|
||||
{{- define "node-agent.selectorLabels" -}}
|
||||
app.kubernetes.io/name: {{ include "node-agent.name" . }}
|
||||
app.kubernetes.io/instance: {{ .Release.Name }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Affinity for pod assignment
|
||||
*/}}
|
||||
{{- define "node-agent.affinity" -}}
|
||||
{{- with .Values.affinity }}
|
||||
affinity:
|
||||
{{- toYaml . | nindent 2 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
@@ -0,0 +1,105 @@
|
||||
apiVersion: apps/v1
|
||||
kind: DaemonSet
|
||||
metadata:
|
||||
name: {{ include "node-agent.fullname" . }}
|
||||
labels:
|
||||
{{- include "node-agent.labels" . | nindent 4 }}
|
||||
spec:
|
||||
{{- with .Values.updateStrategy }}
|
||||
updateStrategy:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
selector:
|
||||
matchLabels:
|
||||
{{- include "node-agent.selectorLabels" . | nindent 6 }}
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
{{- include "node-agent.selectorLabels" . | nindent 8 }}
|
||||
app: coroot-node-agent
|
||||
annotations:
|
||||
prometheus.io/scrape: '{{ .Values.scrape | default true}}'
|
||||
prometheus.io/port: '{{ .Values.port }}'
|
||||
{{- if .Values.podAnnotations }}
|
||||
{{- toYaml .Values.podAnnotations | nindent 8 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
{{- with .Values.imagePullSecrets }}
|
||||
imagePullSecrets:
|
||||
{{- toYaml . | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- include "node-agent.affinity" . | nindent 6 }}
|
||||
{{- if .Values.tolerations }}
|
||||
tolerations: {{ toYaml .Values.tolerations | nindent 8 }}
|
||||
{{- end }}
|
||||
priorityClassName: {{ .Values.priorityClassName }}
|
||||
hostPID: true
|
||||
containers:
|
||||
- name: {{ .Chart.Name }}
|
||||
image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}"
|
||||
command: ["coroot-node-agent", "--listen=0.0.0.0:{{ .Values.port }}", "--cgroupfs-root", "/host/sys/fs/cgroup"]
|
||||
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
||||
resources:
|
||||
{{- toYaml .Values.resources | nindent 12 }}
|
||||
env:
|
||||
{{- if .Values.collectorEndpoint }}
|
||||
- name: COLLECTOR_ENDPOINT
|
||||
value: "{{ .Values.collectorEndpoint }}"
|
||||
{{- end }}
|
||||
{{- if .Values.apiKey }}
|
||||
- name: API_KEY
|
||||
value: "{{ .Values.apiKey }}"
|
||||
{{- end }}
|
||||
{{- if .Values.tracesEndpoint }}
|
||||
- name: TRACES_ENDPOINT
|
||||
value: "{{ .Values.tracesEndpoint }}"
|
||||
{{- end }}
|
||||
{{- if .Values.logsEndpoint }}
|
||||
- name: LOGS_ENDPOINT
|
||||
value: "{{ .Values.logsEndpoint }}"
|
||||
{{- end }}
|
||||
{{- if .Values.profilesEndpoint }}
|
||||
- name: PROFILES_ENDPOINT
|
||||
value: "{{ .Values.profilesEndpoint }}"
|
||||
{{- end }}
|
||||
{{- if .Values.metricsEndpoint }}
|
||||
- name: METRICS_ENDPOINT
|
||||
value: "{{ .Values.metricsEndpoint }}"
|
||||
{{- end }}
|
||||
{{- if .Values.scrapeInterval }}
|
||||
- name: SCRAPE_INTERVAL
|
||||
value: "{{ .Values.scrapeInterval }}"
|
||||
{{- end }}
|
||||
{{- with .Values.env }}
|
||||
{{- . | toYaml | nindent 12 }}
|
||||
{{- end }}
|
||||
ports:
|
||||
- containerPort: {{ .Values.port }}
|
||||
name: http
|
||||
securityContext:
|
||||
privileged: true
|
||||
volumeMounts:
|
||||
- mountPath: /host/sys/fs/cgroup
|
||||
name: cgroupfs
|
||||
readOnly: true
|
||||
- mountPath: /sys/kernel/tracing
|
||||
name: tracefs
|
||||
readOnly: false
|
||||
- mountPath: /sys/kernel/debug
|
||||
name: debugfs
|
||||
readOnly: false
|
||||
- mountPath: /tmp
|
||||
name: tmp
|
||||
readOnly: false
|
||||
volumes:
|
||||
- hostPath:
|
||||
path: /sys/fs/cgroup
|
||||
name: cgroupfs
|
||||
- hostPath:
|
||||
path: /sys/kernel/tracing
|
||||
name: tracefs
|
||||
- hostPath:
|
||||
path: /sys/kernel/debug
|
||||
name: debugfs
|
||||
- emptyDir: {}
|
||||
name: tmp
|
||||
@@ -0,0 +1,51 @@
|
||||
image:
|
||||
repository: asia-southeast1-docker.pkg.dev/meesho-devops-admin-0622/admin/coroot-node-agent
|
||||
pullPolicy: IfNotPresent
|
||||
tag: "1.27.0"
|
||||
|
||||
imagePullSecrets: []
|
||||
nameOverride: ""
|
||||
fullnameOverride: ""
|
||||
updateStrategy:
|
||||
type: RollingUpdate
|
||||
rollingUpdate:
|
||||
maxUnavailable: 1
|
||||
podAnnotations: {}
|
||||
|
||||
priorityClassName: ""
|
||||
|
||||
resources:
|
||||
requests:
|
||||
cpu: "100m"
|
||||
memory: "50Mi"
|
||||
limits:
|
||||
cpu: "1"
|
||||
memory: "1Gi"
|
||||
|
||||
port: 80
|
||||
scrape: "true"
|
||||
|
||||
env: []
|
||||
|
||||
collectorEndpoint: ""
|
||||
apiKey: ""
|
||||
|
||||
metricsEndpoint: ""
|
||||
scrapeInterval: ""
|
||||
|
||||
tracesEndpoint: ""
|
||||
logsEndpoint: ""
|
||||
profilesEndpoint: ""
|
||||
|
||||
tolerations:
|
||||
- operator: Exists
|
||||
|
||||
affinity: {}
|
||||
# nodeAffinity:
|
||||
# requiredDuringSchedulingIgnoredDuringExecution:
|
||||
# nodeSelectorTerms:
|
||||
# - matchExpressions:
|
||||
# - key: eks.amazonaws.com/compute-type
|
||||
# operator: NotIn
|
||||
# values:
|
||||
# - fargate
|
||||
Reference in New Issue
Block a user