diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml deleted file mode 100644 index fef28e09a..000000000 --- a/.github/workflows/ci.yaml +++ /dev/null @@ -1,31 +0,0 @@ -name: Helm Charts - -on: - push: - branches: - - "!*" - tags: - - "v*" - -jobs: - release: - name: Release - runs-on: ubuntu-latest - steps: - - name: Set up Cloud SDK - uses: google-github-actions/setup-gcloud@v0 - with: - project_id: ${{ secrets.GCP_PROJECT_ID }} - service_account_key: ${{ secrets.GCLOUD_SERVICE_ACCOUNT_KEY }} - export_default_credentials: true - - name: Checkout - uses: actions/checkout@v2 - with: - fetch-depth: 2 - - name: Deploy Helm Charts - run: ./scripts/chart.sh - - uses: sarisia/actions-status-discord@v1 - if: always() - with: - webhook: ${{ secrets.DISCORD_WEBHOOK }} - title: "Release" diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml new file mode 100644 index 000000000..62d958ebe --- /dev/null +++ b/.github/workflows/release.yaml @@ -0,0 +1,45 @@ +name: Helm Charts Release + +on: + push: + branches: + - "!*" + tags: + - "v*" + +jobs: + release: + permissions: + contents: write + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v3 + with: + fetch-depth: 0 + + - name: Configure Git + run: | + git config user.name "$GITHUB_ACTOR" + git config user.email "$GITHUB_ACTOR@users.noreply.github.com" + + - name: Install Helm + uses: azure/setup-helm@v3 + + - name: Helm Dependencies + run: | + for dir in $(ls -d charts/*); do + helm dependency update $dir; + done + helm repo add bitnami https://charts.bitnami.com/bitnami + + - name: Publish Helm chart + uses: stefanprodan/helm-gh-pages@v1.7.0 + with: + token: ${{ secrets.BOT_TOKEN }} + charts_dir: charts + charts_url: https://nethermindeth.github.io/helm-charts + repository: helm-charts + branch: gh-pages + target_dir: charts + index_dir: . diff --git a/README.md b/README.md index f767abf7b..b47bac6f2 100644 --- a/README.md +++ b/README.md @@ -1,19 +1,19 @@ -# The StakeWise Charts for Kubernetes +# The Charts for Kubernetes -The curated list of StakeWise helm charts. Every chart is located in a separate folder and has the configuration parameters located in `values.yaml` file. +The list of helm charts forked and reworked from [StakeWise helm repository](https://github.com/stakewise/helm-charts), maintained and further developed by Nethermind team. Every chart is located in a separate folder and has the configuration parameters located in `values.yaml` file. ## TL;DR ```bash -$ helm repo add stakewise https://charts.stakewise.io -$ helm install my-release stakewise/ +$ helm repo add nethermindeth https://charts.nethermind.io +$ helm install my-release nethermindeth/ ``` ## Before you begin ### Prerequisites -- Kubernetes 1.18+ +- Kubernetes 1.23+ - Helm 3 - PV provisioner support in the underlying infrastructure for some charts diff --git a/charts/backend/Chart.lock b/charts/backend/Chart.lock deleted file mode 100644 index 598ef187e..000000000 --- a/charts/backend/Chart.lock +++ /dev/null @@ -1,15 +0,0 @@ -dependencies: -- name: common - repository: file://../common - version: 1.0.0 -- name: postgresql - repository: https://charts.bitnami.com/bitnami/ - version: 11.6.0 -- name: rabbitmq - repository: https://charts.bitnami.com/bitnami/ - version: 9.0.0 -- name: memcached - repository: https://charts.bitnami.com/bitnami/ - version: 6.0.21 -digest: sha256:8de1598dfd521d2059f4380340d538899b5306a8ec1e8f891a2701c482a33463 -generated: "2022-06-02T18:06:25.795689015+03:00" diff --git a/charts/backend/Chart.yaml b/charts/backend/Chart.yaml deleted file mode 100644 index 8ca0b81e3..000000000 --- a/charts/backend/Chart.yaml +++ /dev/null @@ -1,33 +0,0 @@ -apiVersion: v2 -name: backend -version: 2.4.12 -appVersion: v2.4.12 -kubeVersion: "^1.18.0-0" -description: The StakeWise backend application. -type: application -keywords: - - ethereum - - blockchain - - staking -home: https://stakewise.io/ -sources: - - https://github.com/tsudmi/backend/ -dependencies: - - name: common - version: 1.x.x - repository: "file://../common" - - name: postgresql - version: 11.6.0 - repository: https://charts.bitnami.com/bitnami/ - condition: postgresql.enabled - - name: rabbitmq - version: 9.0.0 - repository: https://charts.bitnami.com/bitnami/ - condition: rabbitmq.enabled - - name: memcached - version: 6.0.21 - repository: https://charts.bitnami.com/bitnami/ - condition: memcached.enabled -maintainers: - - name: Dmitri Tsumak - email: dmitri@stakewise.io diff --git a/charts/backend/templates/admin-deployment.yaml b/charts/backend/templates/admin-deployment.yaml deleted file mode 100644 index 0f8f0db4a..000000000 --- a/charts/backend/templates/admin-deployment.yaml +++ /dev/null @@ -1,126 +0,0 @@ -{{- if .Values.admin.enabled }} -kind: Deployment -apiVersion: {{ include "common.capabilities.deployment.apiVersion" . }} -metadata: - name: {{ include "common.names.fullname" . }}-admin - labels: - {{- include "common.labels.standard" . | nindent 4 }} - component: "admin" -spec: - replicas: {{ default 1 .Values.admin.replicas }} - minReadySeconds: 15 - strategy: - type: RollingUpdate - rollingUpdate: - maxSurge: 1 - maxUnavailable: 0 - selector: - matchLabels: - {{- include "common.labels.matchLabels" . | nindent 6 }} - component: "admin" - template: - metadata: - labels: - {{- include "common.labels.matchLabels" . | nindent 8 }} - component: "admin" - annotations: - checksum/common-secret: {{ include (print $.Template.BasePath "/common-secret.yaml") . | sha256sum }} - checksum/common-configmap: {{ include (print $.Template.BasePath "/common-configmap.yaml") . | sha256sum }} - checksum/admin-secret: {{ include (print $.Template.BasePath "/admin-secret.yaml") . | sha256sum }} - spec: - {{- with .Values.admin.affinity }} - affinity: - {{- toYaml . | nindent 8 }} - {{- end }} - {{- with .Values.admin.tolerations }} - tolerations: - {{- toYaml . | nindent 8 }} - {{- end }} - {{- with .Values.admin.securityContext }} - securityContext: - {{ toYaml . | nindent 8 }} - {{- end }} - serviceAccountName: {{ include "common.names.serviceAccountName" . }} - priorityClassName: {{ .Values.admin.priorityClassName | quote }} - initContainers: - - name: initdb - image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}" - imagePullPolicy: {{ .Values.image.pullPolicy }} - command: ["python", "manage.py", "migrate", "--no-input"] - envFrom: - - secretRef: - name: {{ include "common.names.fullname" . }} - - configMapRef: - name: {{ include "common.names.fullname" . }} - env: - - name: DJANGO_SETTINGS_MODULE - value: "config.settings.admin_settings" - - name: ALLOWED_HOSTS - value: {{ .Values.admin.conf.allowedHosts | quote }} - {{- if .Values.admin.user.create }} - - name: init-admin - image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}" - imagePullPolicy: {{ .Values.image.pullPolicy }} - command: ["/bin/sh", "-c", "python manage.py create_superuser"] - envFrom: - - configMapRef: - name: {{ include "common.names.fullname" . }} - - secretRef: - name: {{ include "common.names.fullname" . }} - - secretRef: - name: {{ include "common.names.fullname" . }}-admin - env: - - name: DJANGO_SETTINGS_MODULE - value: "config.settings.admin_settings" - - name: ALLOWED_HOSTS - value: {{ .Values.admin.conf.allowedHosts | quote }} - {{- end }} - containers: - - name: {{ .Chart.Name }} - image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}" - imagePullPolicy: {{ .Values.image.pullPolicy }} - envFrom: - - configMapRef: - name: {{ include "common.names.fullname" . }} - - secretRef: - name: {{ include "common.names.fullname" . }} - env: - - name: DJANGO_SETTINGS_MODULE - value: "config.settings.admin_settings" - - name: ALLOWED_HOSTS - value: {{ .Values.admin.conf.allowedHosts | quote }} - ports: - - name: http - containerPort: {{ .Values.admin.servicePort }} - protocol: TCP - {{- with .Values.admin.resources }} - resources: - {{ toYaml . | nindent 12 | trim }} - {{- end }} - livenessProbe: - httpGet: - path: "/admin/login/" - port: http - {{- if .Values.admin.probesHostHeader }} - httpHeaders: - - name: Host - value: {{ .Values.admin.probesHostHeader | quote }} - {{- end }} - initialDelaySeconds: 15 - timeoutSeconds: 30 - failureThreshold: 5 - periodSeconds: 60 - readinessProbe: - httpGet: - path: "/admin/login/" - port: http - {{- if .Values.admin.probesHostHeader }} - httpHeaders: - - name: Host - value: {{ .Values.admin.probesHostHeader | quote }} - {{- end }} - initialDelaySeconds: 15 - timeoutSeconds: 30 - failureThreshold: 5 - periodSeconds: 60 -{{- end }} diff --git a/charts/backend/templates/admin-ingress.yaml b/charts/backend/templates/admin-ingress.yaml deleted file mode 100644 index d71be9dfb..000000000 --- a/charts/backend/templates/admin-ingress.yaml +++ /dev/null @@ -1,46 +0,0 @@ -{{- if and .Values.admin.enabled .Values.admin.ingress.enabled }} -{{ $fullName := include "common.names.fullname" . }} -{{ $ingressPath := .Values.admin.ingress.path }} -apiVersion: {{ include "common.capabilities.ingress.apiVersion" . }} -kind: Ingress -metadata: - name: {{ include "common.names.fullname" . }}-admin - labels: - {{- include "common.labels.standard" . | nindent 4 }} - component: "admin" - {{- with .Values.admin.ingress.labels }} - {{ toYaml . | nindent 4 | trim }} - {{- end }} - {{- with .Values.admin.ingress.annotations }} - annotations: - {{ toYaml . | nindent 4 | trim }} - {{- end }} -spec: - {{- if and .Values.admin.ingress.className (semverCompare ">=1.18-0" .Capabilities.KubeVersion.GitVersion) }} - ingressClassName: {{ .Values.admin.ingress.className }} - {{- end }} - {{- with .Values.admin.ingress.tls }} - tls: - {{ toYaml . | nindent 4 | trim }} - {{- end }} - rules: - {{- range .Values.admin.ingress.hosts }} - - host: {{ . }} - http: - paths: - - pathType: ImplementationSpecific - path: {{ $ingressPath }} - backend: - service: - name: {{ $fullName }}-admin - port: - name: http - - pathType: ImplementationSpecific - path: /service/prometheus - backend: - service: - name: {{ $fullName }}-admin - port: - name: http - {{- end }} -{{- end }} diff --git a/charts/backend/templates/admin-pdb.yaml b/charts/backend/templates/admin-pdb.yaml deleted file mode 100644 index b23395689..000000000 --- a/charts/backend/templates/admin-pdb.yaml +++ /dev/null @@ -1,20 +0,0 @@ -{{- if and .Values.admin.enabled .Values.admin.podDisruptionBudget.enabled }} -apiVersion: {{ include "common.capabilities.policy.apiVersion" . }} -kind: PodDisruptionBudget -metadata: - name: {{ include "common.names.fullname" . }}-admin - labels: - {{- include "common.labels.standard" . | nindent 4 }} - component: "admin" -spec: - {{- if .Values.admin.podDisruptionBudget.minAvailable }} - minAvailable: {{ .Values.admin.podDisruptionBudget.minAvailable }} - {{- end }} - {{- if .Values.admin.podDisruptionBudget.maxUnavailable }} - maxUnavailable: {{ .Values.admin.podDisruptionBudget.maxUnavailable }} - {{- end }} - selector: - matchLabels: - {{- include "backend.selectorLabels" . | nindent 6 }} - component: "admin" -{{- end }} diff --git a/charts/backend/templates/admin-secret.yaml b/charts/backend/templates/admin-secret.yaml deleted file mode 100644 index 4dfce097d..000000000 --- a/charts/backend/templates/admin-secret.yaml +++ /dev/null @@ -1,14 +0,0 @@ -{{- if and .Values.admin.enabled .Values.admin.user.create }} -apiVersion: v1 -kind: Secret -metadata: - name: {{ include "common.names.fullname" . }}-admin - labels: - {{- include "common.labels.standard" . | nindent 4 }} - component: "admin" -type: Opaque -data: - DJANGO_SUPERUSER_USERNAME: {{ .Values.admin.user.username | b64enc | quote }} - DJANGO_SUPERUSER_PASSWORD: {{ .Values.admin.user.password | b64enc | quote }} - DJANGO_SUPERUSER_EMAIL: {{ .Values.admin.user.email | b64enc | quote }} -{{- end }} diff --git a/charts/backend/templates/admin-service.yaml b/charts/backend/templates/admin-service.yaml deleted file mode 100644 index d2360b961..000000000 --- a/charts/backend/templates/admin-service.yaml +++ /dev/null @@ -1,19 +0,0 @@ -{{- if .Values.admin.enabled }} -apiVersion: v1 -kind: Service -metadata: - name: {{ include "common.names.fullname" . }}-admin - labels: - {{- include "common.labels.standard" . | nindent 4 }} - component: "admin" -spec: - type: {{ .Values.admin.serviceType | default "ClusterIP" }} - ports: - - name: http - port: {{ .Values.admin.servicePort }} - protocol: TCP - targetPort: http - selector: - {{- include "common.labels.matchLabels" . | nindent 4 }} - component: "admin" -{{- end }} diff --git a/charts/backend/templates/api-deployment.yaml b/charts/backend/templates/api-deployment.yaml deleted file mode 100644 index e58e51e18..000000000 --- a/charts/backend/templates/api-deployment.yaml +++ /dev/null @@ -1,108 +0,0 @@ -{{- if .Values.api.enabled }} -kind: Deployment -apiVersion: {{ include "common.capabilities.deployment.apiVersion" . }} -metadata: - name: {{ include "common.names.fullname" . }}-api - labels: - {{- include "common.labels.standard" . | nindent 4 }} - component: "api" -spec: - replicas: {{ default 1 .Values.api.replicas }} - minReadySeconds: 15 - strategy: - type: RollingUpdate - rollingUpdate: - maxSurge: 1 - maxUnavailable: 0 - selector: - matchLabels: - {{- include "common.labels.matchLabels" . | nindent 6 }} - component: "api" - template: - metadata: - labels: - {{- include "common.labels.matchLabels" . | nindent 8 }} - component: "api" - annotations: - checksum/common-secret: {{ include (print $.Template.BasePath "/common-secret.yaml") . | sha256sum }} - checksum/common-configmap: {{ include (print $.Template.BasePath "/common-configmap.yaml") . | sha256sum }} - checksum/api-secret: {{ include (print $.Template.BasePath "/api-secret.yaml") . | sha256sum }} - spec: - {{- with .Values.api.affinity }} - affinity: - {{- toYaml . | nindent 8 }} - {{- end }} - {{- with .Values.api.tolerations }} - tolerations: - {{- toYaml . | nindent 8 }} - {{- end }} - {{- with .Values.api.securityContext }} - securityContext: - {{ toYaml . | nindent 8 }} - {{- end }} - serviceAccountName: {{ include "common.names.serviceAccountName" . }} - priorityClassName: {{ .Values.api.priorityClassName | quote }} - initContainers: - - name: migrate-db - image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}" - imagePullPolicy: {{ .Values.image.pullPolicy }} - command: ["python", "manage.py", "migrate", "--no-input"] - envFrom: - - secretRef: - name: {{ include "common.names.fullname" . }} - - configMapRef: - name: {{ include "common.names.fullname" . }} - - secretRef: - name: {{ include "common.names.fullname" . }}-api - env: - - name: DJANGO_SETTINGS_MODULE - value: "config.settings.api_settings" - containers: - - name: {{ .Chart.Name }} - image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}" - imagePullPolicy: {{ .Values.image.pullPolicy }} - envFrom: - - secretRef: - name: {{ include "common.names.fullname" . }} - - configMapRef: - name: {{ include "common.names.fullname" . }} - - secretRef: - name: {{ include "common.names.fullname" . }}-api - env: - - name: DJANGO_SETTINGS_MODULE - value: "config.settings.api_settings" - {{- with .Values.api.resources }} - resources: - {{ toYaml . | nindent 12 | trim }} - {{- end }} - ports: - - name: http - containerPort: {{ .Values.api.servicePort }} - protocol: TCP - livenessProbe: - httpGet: - path: /healthz/ - port: http - {{- if .Values.api.probesHostHeader }} - httpHeaders: - - name: Host - value: {{ .Values.api.probesHostHeader | quote }} - {{- end }} - initialDelaySeconds: 15 - timeoutSeconds: 30 - failureThreshold: 5 - periodSeconds: 60 - readinessProbe: - httpGet: - path: /healthz/ - port: http - {{- if .Values.api.probesHostHeader }} - httpHeaders: - - name: Host - value: {{ .Values.api.probesHostHeader | quote }} - {{- end }} - initialDelaySeconds: 15 - timeoutSeconds: 30 - failureThreshold: 5 - periodSeconds: 60 -{{- end }} diff --git a/charts/backend/templates/api-ingress.yaml b/charts/backend/templates/api-ingress.yaml deleted file mode 100644 index c1620a049..000000000 --- a/charts/backend/templates/api-ingress.yaml +++ /dev/null @@ -1,39 +0,0 @@ -{{- if and .Values.api.enabled .Values.api.ingress.enabled }} -{{ $fullName := include "common.names.fullname" . }} -{{ $ingressPath := .Values.api.ingress.path }} -apiVersion: {{ include "common.capabilities.ingress.apiVersion" . }} -kind: Ingress -metadata: - name: {{ include "common.names.fullname" . }}-api - labels: - {{- include "common.labels.standard" . | nindent 4 }} - component: "api" - {{- with .Values.api.ingress.labels }} - {{ toYaml . | nindent 4 | trim }} - {{- end }} - {{- with .Values.api.ingress.annotations }} - annotations: - {{ toYaml . | nindent 4 | trim }} - {{- end }} -spec: - {{- if and .Values.api.ingress.className (semverCompare ">=1.18-0" .Capabilities.KubeVersion.GitVersion) }} - ingressClassName: {{ .Values.api.ingress.className }} - {{- end }} - {{- with .Values.api.ingress.tls }} - tls: - {{ toYaml . | nindent 4 | trim }} - {{- end }} - rules: - {{- range .Values.api.ingress.hosts }} - - host: {{ . }} - http: - paths: - - pathType: ImplementationSpecific - path: {{ $ingressPath }} - backend: - service: - name: {{ $fullName }}-api - port: - name: http - {{- end }} -{{- end }} diff --git a/charts/backend/templates/api-pdb.yaml b/charts/backend/templates/api-pdb.yaml deleted file mode 100644 index f6acf9dee..000000000 --- a/charts/backend/templates/api-pdb.yaml +++ /dev/null @@ -1,20 +0,0 @@ -{{- if and .Values.api.enabled .Values.api.podDisruptionBudget.enabled }} -apiVersion: {{ include "common.capabilities.policy.apiVersion" . }} -kind: PodDisruptionBudget -metadata: - name: {{ include "common.names.fullname" . }}-api - labels: - {{- include "common.labels.standard" . | nindent 4 }} - component: "api" -spec: - {{- if .Values.api.podDisruptionBudget.minAvailable }} - minAvailable: {{ .Values.api.podDisruptionBudget.minAvailable }} - {{- end }} - {{- if .Values.api.podDisruptionBudget.maxUnavailable }} - maxUnavailable: {{ .Values.api.podDisruptionBudget.maxUnavailable }} - {{- end }} - selector: - matchLabels: - {{- include "common.labels.matchLabels" . | nindent 6 }} - component: "api" -{{- end }} diff --git a/charts/backend/templates/api-secret.yaml b/charts/backend/templates/api-secret.yaml deleted file mode 100644 index 61a039e99..000000000 --- a/charts/backend/templates/api-secret.yaml +++ /dev/null @@ -1,22 +0,0 @@ -{{- if .Values.api.enabled }} -apiVersion: v1 -kind: Secret -metadata: - name: {{ include "common.names.fullname" . }}-api - labels: - {{- include "common.labels.standard" . | nindent 4 }} - component: "api" -type: Opaque -data: - ALLOWED_HOSTS: {{ .Values.api.conf.allowedHosts | b64enc | quote }} - CORS_ORIGIN_WHITELIST: {{ .Values.api.conf.corsOriginWhitelist | b64enc | quote }} - CORS_ALLOW_ALL_ORIGINS: {{ .Values.api.conf.corsAllowAllOrigins | b64enc | quote }} - SKIP_RECAPTCHA_VERIFICATION: {{ .Values.api.conf.skipRecaptchaVerification | b64enc | quote }} - RECAPTCHA_URL: {{ .Values.api.conf.recaptchaUrl | b64enc | quote }} - RECAPTCHA_SECRET: {{ .Values.api.conf.recaptchaSecret | b64enc | quote }} - RECAPTCHA_HOSTNAME: {{ .Values.api.conf.recaptchaHostname | b64enc | quote }} - RECAPTCHA_CONTACT_ACTION: {{ .Values.api.conf.recaptchaContactAction | b64enc | quote }} - RECAPTCHA_CONTACT_SCORE: {{ .Values.api.conf.recaptchaContactScore | b64enc | quote }} - RECAPTCHA_PROFILE_ACTION: {{ .Values.api.conf.recaptchaProfileAction | b64enc | quote }} - RECAPTCHA_PROFILE_SCORE: {{ .Values.api.conf.recaptchaProfileScore | b64enc | quote }} -{{- end }} diff --git a/charts/backend/templates/api-service.yaml b/charts/backend/templates/api-service.yaml deleted file mode 100644 index 947902afd..000000000 --- a/charts/backend/templates/api-service.yaml +++ /dev/null @@ -1,19 +0,0 @@ -{{- if .Values.api.enabled }} -apiVersion: v1 -kind: Service -metadata: - name: {{ include "common.names.fullname" . }}-api - labels: - {{- include "common.labels.standard" . | nindent 4 }} - component: "api" -spec: - type: {{ .Values.api.serviceType | default "ClusterIP" }} - ports: - - name: http - port: {{ .Values.api.servicePort }} - protocol: TCP - targetPort: http - selector: - {{- include "common.labels.matchLabels" . | nindent 4 }} - component: "api" -{{- end }} diff --git a/charts/backend/templates/celery-beat.yaml b/charts/backend/templates/celery-beat.yaml deleted file mode 100644 index 16c90f2da..000000000 --- a/charts/backend/templates/celery-beat.yaml +++ /dev/null @@ -1,53 +0,0 @@ -kind: Deployment -apiVersion: {{ include "common.capabilities.deployment.apiVersion" . }} -metadata: - name: {{ include "common.names.fullname" . }}-celery-beat - labels: - {{- include "common.labels.standard" . | nindent 4 }} - component: "celery-beat" -spec: - replicas: {{ default 1 .Values.celery.beatReplicaCount }} - selector: - matchLabels: - {{- include "common.labels.matchLabels" . | nindent 6 }} - component: "celery-beat" - template: - metadata: - labels: - {{- include "common.labels.matchLabels" . | nindent 8 }} - component: "celery-beat" - annotations: - checksum/common-secret: {{ include (print $.Template.BasePath "/common-secret.yaml") . | sha256sum }} - checksum/common-configmap: {{ include (print $.Template.BasePath "/common-configmap.yaml") . | sha256sum }} - checksum/celery-configmap: {{ include (print $.Template.BasePath "/celery-configmap.yaml") . | sha256sum }} - spec: - {{- with .Values.celery.affinity }} - affinity: - {{- toYaml . | nindent 8 }} - {{- end }} - {{- with .Values.celery.tolerations }} - tolerations: - {{- toYaml . | nindent 8 }} - {{- end }} - {{- with .Values.celery.securityContext }} - securityContext: - {{ toYaml . | nindent 8 }} - {{- end }} - serviceAccountName: {{ include "common.names.serviceAccountName" . }} - priorityClassName: {{ .Values.admin.priorityClassName | quote }} - containers: - - name: {{ .Chart.Name }} - image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}" - imagePullPolicy: {{ .Values.image.pullPolicy }} - command: ["/start-celerybeat"] - envFrom: - - secretRef: - name: {{ include "common.names.fullname" . }} - - configMapRef: - name: {{ include "common.names.fullname" . }} - - configMapRef: - name: {{ include "common.names.fullname" . }}-celery - {{- with .Values.celery.beatResources }} - resources: - {{ toYaml . | nindent 12 | trim }} - {{- end }} diff --git a/charts/backend/templates/celery-configmap.yaml b/charts/backend/templates/celery-configmap.yaml deleted file mode 100644 index 03b0f4a2d..000000000 --- a/charts/backend/templates/celery-configmap.yaml +++ /dev/null @@ -1,10 +0,0 @@ -apiVersion: v1 -kind: ConfigMap -metadata: - name: {{ include "common.names.fullname" . }}-celery - labels: - {{- include "common.labels.standard" . | nindent 4 }} - component: "celery" -data: - ENVIRONMENT: {{ .Values.commonConf.environment | quote }} - SENTRY_DSN: {{ .Values.commonConf.sentryDsn | quote }} diff --git a/charts/backend/templates/celery-flower-ingress.yaml b/charts/backend/templates/celery-flower-ingress.yaml deleted file mode 100644 index eba4a5fd3..000000000 --- a/charts/backend/templates/celery-flower-ingress.yaml +++ /dev/null @@ -1,33 +0,0 @@ -{{ $fullName := include "common.names.fullname" . }} -apiVersion: {{ include "common.capabilities.ingress.apiVersion" . }} -kind: Ingress -metadata: - name: {{ include "common.names.fullname" . }}-celery-flower - labels: - {{- include "common.labels.standard" . | nindent 4 }} - component: "celery-flower" - {{- with .Values.celery.flower.ingress.annotations }} - annotations: - {{ toYaml . | nindent 4 | trim }} - {{- end }} -spec: - {{- if and .Values.celery.flower.ingress.className (semverCompare ">=1.18-0" .Capabilities.KubeVersion.GitVersion) }} - ingressClassName: {{ .Values.celery.flower.ingress.className }} - {{- end }} - {{- with .Values.celery.flower.ingress.tls }} - tls: - {{ toYaml . | nindent 4 | trim }} - {{- end }} - rules: - {{- range .Values.celery.flower.ingress.hosts }} - - host: {{ . }} - http: - paths: - - pathType: ImplementationSpecific - path: / - backend: - service: - name: {{ $fullName }}-celery-flower - port: - name: http - {{- end }} diff --git a/charts/backend/templates/celery-flower-service.yaml b/charts/backend/templates/celery-flower-service.yaml deleted file mode 100644 index 9a8d9bb5b..000000000 --- a/charts/backend/templates/celery-flower-service.yaml +++ /dev/null @@ -1,17 +0,0 @@ -apiVersion: v1 -kind: Service -metadata: - name: {{ include "common.names.fullname" . }}-celery-flower - labels: - {{- include "common.labels.standard" . | nindent 4 }} - component: "celery-flower" -spec: - type: ClusterIP - ports: - - name: http - port: {{ .Values.celery.flower.port }} - protocol: TCP - targetPort: http - selector: - {{- include "common.labels.matchLabels" . | nindent 4 }} - component: "celery-flower" diff --git a/charts/backend/templates/celery-flower.yaml b/charts/backend/templates/celery-flower.yaml deleted file mode 100644 index 3938df2d6..000000000 --- a/charts/backend/templates/celery-flower.yaml +++ /dev/null @@ -1,57 +0,0 @@ -kind: Deployment -apiVersion: {{ include "common.capabilities.deployment.apiVersion" . }} -metadata: - name: {{ include "common.names.fullname" . }}-celery-flower - labels: - {{- include "common.labels.standard" . | nindent 4 }} - component: "celery-flower" -spec: - replicas: {{ default 1 .Values.celery.flower.replicaCount }} - selector: - matchLabels: - {{- include "common.labels.matchLabels" . | nindent 6 }} - component: "celery-flower" - template: - metadata: - labels: - {{- include "common.labels.matchLabels" . | nindent 8 }} - component: "celery-flower" - annotations: - checksum/common-secret: {{ include (print $.Template.BasePath "/common-secret.yaml") . | sha256sum }} - checksum/common-configmap: {{ include (print $.Template.BasePath "/common-configmap.yaml") . | sha256sum }} - checksum/celery-configmap: {{ include (print $.Template.BasePath "/celery-configmap.yaml") . | sha256sum }} - spec: - {{- with .Values.celery.affinity }} - affinity: - {{- toYaml . | nindent 8 }} - {{- end }} - {{- with .Values.celery.tolerations }} - tolerations: - {{- toYaml . | nindent 8 }} - {{- end }} - {{- with .Values.celery.securityContext }} - securityContext: - {{ toYaml . | nindent 8 }} - {{- end }} - serviceAccountName: {{ include "common.names.serviceAccountName" . }} - priorityClassName: {{ .Values.admin.priorityClassName | quote }} - containers: - - name: {{ .Chart.Name }} - image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}" - imagePullPolicy: {{ .Values.image.pullPolicy }} - command: ["/start-flower"] - envFrom: - - secretRef: - name: {{ include "common.names.fullname" . }} - - configMapRef: - name: {{ include "common.names.fullname" . }} - - configMapRef: - name: {{ include "common.names.fullname" . }}-celery - ports: - - name: http - containerPort: {{ .Values.celery.flower.port }} - protocol: TCP - {{- with .Values.celery.flower.resources }} - resources: - {{ toYaml . | nindent 12 | trim }} - {{- end }} diff --git a/charts/backend/templates/celery-worker.yaml b/charts/backend/templates/celery-worker.yaml deleted file mode 100644 index 78de854dc..000000000 --- a/charts/backend/templates/celery-worker.yaml +++ /dev/null @@ -1,53 +0,0 @@ -kind: Deployment -apiVersion: {{ include "common.capabilities.deployment.apiVersion" . }} -metadata: - name: {{ include "common.names.fullname" . }}-celery-worker - labels: - {{- include "common.labels.standard" . | nindent 4 }} - component: "celery-worker" -spec: - replicas: {{ default 1 .Values.celery.workerReplicaCount }} - selector: - matchLabels: - {{- include "common.labels.matchLabels" . | nindent 6 }} - component: "celery-worker" - template: - metadata: - labels: - {{- include "common.labels.matchLabels" . | nindent 8 }} - component: "celery-worker" - annotations: - checksum/common-secret: {{ include (print $.Template.BasePath "/common-secret.yaml") . | sha256sum }} - checksum/common-configmap: {{ include (print $.Template.BasePath "/common-configmap.yaml") . | sha256sum }} - checksum/celery-configmap: {{ include (print $.Template.BasePath "/celery-configmap.yaml") . | sha256sum }} - spec: - {{- with .Values.celery.affinity }} - affinity: - {{- toYaml . | nindent 8 }} - {{- end }} - {{- with .Values.celery.tolerations }} - tolerations: - {{- toYaml . | nindent 8 }} - {{- end }} - {{- with .Values.celery.securityContext }} - securityContext: - {{ toYaml . | nindent 8 }} - {{- end }} - serviceAccountName: {{ include "common.names.serviceAccountName" . }} - priorityClassName: {{ .Values.admin.priorityClassName | quote }} - containers: - - name: {{ .Chart.Name }} - image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}" - imagePullPolicy: {{ .Values.image.pullPolicy }} - command: ["/start-celeryworker"] - envFrom: - - secretRef: - name: {{ include "common.names.fullname" . }} - - configMapRef: - name: {{ include "common.names.fullname" . }} - - configMapRef: - name: {{ include "common.names.fullname" . }}-celery - {{- with .Values.celery.workerResources }} - resources: - {{ toYaml . | nindent 12 | trim }} - {{- end }} diff --git a/charts/backend/templates/cloudsql-proxy-secret.yaml b/charts/backend/templates/cloudsql-proxy-secret.yaml deleted file mode 100644 index 1eb19ed9c..000000000 --- a/charts/backend/templates/cloudsql-proxy-secret.yaml +++ /dev/null @@ -1,13 +0,0 @@ -{{- if .Values.cloudsqlProxy.enabled }} -apiVersion: v1 -kind: Secret -metadata: - name: {{ include "common.names.fullname" . }}-cloudsql - labels: - {{- include "common.labels.standard" . | nindent 4 }} - component: "cloudsqlproxy" -type: Opaque -data: - cloudsql.json: |- - {{ .Values.cloudsqlProxy.serviceAccountKey }} -{{- end -}} \ No newline at end of file diff --git a/charts/backend/templates/cloudsql-proxy-service.yaml b/charts/backend/templates/cloudsql-proxy-service.yaml deleted file mode 100644 index 07bd8912f..000000000 --- a/charts/backend/templates/cloudsql-proxy-service.yaml +++ /dev/null @@ -1,17 +0,0 @@ -{{- if .Values.cloudsqlProxy.enabled }} -apiVersion: v1 -kind: Service -metadata: - name: {{ include "common.names.fullname" . }}-cloudsql - labels: - {{- include "common.labels.standard" . | nindent 4 }} - component: "cloudsqlproxy" -spec: - selector: - {{- include "common.labels.matchLabels" . | nindent 4 }} - component: "cloudsqlproxy" - clusterIP: None - ports: - - port: 5432 - targetPort: 5432 -{{- end }} diff --git a/charts/backend/templates/cloudsql-proxy-statefulset.yaml b/charts/backend/templates/cloudsql-proxy-statefulset.yaml deleted file mode 100644 index e726dc0af..000000000 --- a/charts/backend/templates/cloudsql-proxy-statefulset.yaml +++ /dev/null @@ -1,56 +0,0 @@ -{{- if .Values.cloudsqlProxy.enabled }} -apiVersion: {{ include "common.capabilities.statefulset.apiVersion" . }} -kind: StatefulSet -metadata: - name: {{ include "common.names.fullname" . }}-cloudsql - labels: - {{- include "common.labels.standard" . | nindent 4 }} - component: "cloudsqlproxy" -spec: - replicas: {{ .Values.cloudsqlProxy.replicaCount }} - serviceName: cloudsqlproxy - selector: - matchLabels: - {{- include "common.labels.matchLabels" . | nindent 6 }} - component: "cloudsqlproxy" - updateStrategy: - type: RollingUpdate - template: - metadata: - labels: - {{- include "common.labels.matchLabels" . | nindent 8 }} - component: "cloudsqlproxy" - spec: - affinity: - podAntiAffinity: - preferredDuringSchedulingIgnoredDuringExecution: - - weight: 100 - podAffinityTerm: - labelSelector: - matchExpressions: - - key: name - operator: In - values: - - cloudsqlproxy - topologyKey: "kubernetes.io/hostname" - containers: - - name: cloudsql-proxy - image: gcr.io/cloudsql-docker/gce-proxy:latest - ports: - - containerPort: 5432 - resources: - requests: - cpu: 0.01 - memory: 100Mi - command: ["/cloud_sql_proxy", - "-instances={{ .Values.cloudsqlProxy.instance }}=tcp:0.0.0.0:5432", - "-credential_file=/secrets/cloudsql/cloudsql.json"] - volumeMounts: - - name: service-account-key - mountPath: /secrets/cloudsql - readOnly: true - volumes: - - name: service-account-key - secret: - secretName: {{ include "common.names.fullname" . }}-cloudsql -{{- end }} diff --git a/charts/backend/templates/common-configmap.yaml b/charts/backend/templates/common-configmap.yaml deleted file mode 100644 index 140bcb34f..000000000 --- a/charts/backend/templates/common-configmap.yaml +++ /dev/null @@ -1,84 +0,0 @@ -{{- if or .Values.admin.enabled .Values.api.enabled }} -apiVersion: v1 -kind: ConfigMap -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -data: - ENVIRONMENT: {{ .Values.commonConf.environment | quote }} - CELERY_FLOWER_USER: {{ .Values.celery.flower.user | quote }} - # https://github.com/notifiers/notifiers/issues/328 - USERNAME: user - ENABLED_NETWORKS: {{ .Values.commonConf.enabledNetworks | quote }} - SENTRY_DSN: {{ .Values.commonConf.sentryDsn | quote }} - MEMCACHED_URL: {{ .Values.commonConf.memcachedUrl | quote }} - - POOL_PAGE: {{ .Values.commonConf.poolPage | quote }} - SOLO_PAGE: {{ .Values.commonConf.soloPage | quote }} - - SEND_EMAILS: {{ .Values.commonConf.sendEmails | quote }} - MAILGUN_SENDER_DOMAIN: {{ .Values.commonConf.mailgunSenderDomain | quote }} - MAILGUN_API_URL: {{ .Values.commonConf.mailgunApiUrl | quote }} - DEFAULT_FROM_EMAIL: {{ .Values.commonConf.defaultFromEmail | quote }} - - MANAGERS: {{ .Values.commonConf.managers | quote }} - STATIC_URL: {{ .Values.commonConf.staticUrl | quote }} - STAKING_APR_SAMPLES_COUNT: {{ .Values.commonConf.stakingAprSamplesCount | quote }} - - VALIDATOR_MAX_PENALTY_COUNT: {{ .Values.commonConf.validatorMaxPenaltyCount | quote }} - - MAINNET_SEND_TELEGRAM_NOTIFICATIONS: {{ .Values.commonConf.sendTelegramNotifications.mainnet | quote }} - GOERLI_SEND_TELEGRAM_NOTIFICATIONS: {{ .Values.commonConf.sendTelegramNotifications.goerli | quote }} - GNOSIS_SEND_TELEGRAM_NOTIFICATIONS: {{ .Values.commonConf.sendTelegramNotifications.gnosis | quote }} - HARBOUR_GOERLI_SEND_TELEGRAM_NOTIFICATIONS: {{ .Values.commonConf.sendTelegramNotifications.harbourGoerli | quote }} - HARBOUR_MAINNET_SEND_TELEGRAM_NOTIFICATIONS: {{ .Values.commonConf.sendTelegramNotifications.harbourMainnet | quote }} - - {{- if or (contains "mainnet" .Values.commonConf.enabledNetworks) (contains "goerli" .Values.commonConf.enabledNetworks) (contains "perm_goerli" .Values.commonConf.enabledNetworks) }} - MAINNET_ETH1_ENDPOINTS: {{ .Values.celery.conf.eth1Endpoints.mainnet | quote }} - {{- end }} - - {{- if contains "mainnet" .Values.commonConf.enabledNetworks }} - MAINNET_ETH2_ENDPOINTS: {{ .Values.celery.conf.eth2Endpoints.mainnet | quote }} - MAINNET_STAKEWISE_SUBGRAPH_URLS: {{ .Values.celery.conf.stakewiseSubgraphUrls.mainnet | quote }} - MAINNET_ETHEREUM_SUBGRAPH_URLS: {{ .Values.celery.conf.ethereumSubgraphUrls.mainnet | quote }} - MAINNET_UNISWAP_V3_SUBGRAPH_URLS: {{ .Values.celery.conf.uniswapV3SubgraphUrls.mainnet | quote }} - {{- end }} - - {{- if contains "goerli" .Values.commonConf.enabledNetworks }} - GOERLI_ETH1_ENDPOINTS: {{ .Values.celery.conf.eth1Endpoints.goerli | quote }} - GOERLI_ETH2_ENDPOINTS: {{ .Values.celery.conf.eth2Endpoints.goerli | quote }} - GOERLI_STAKEWISE_SUBGRAPH_URLS: {{ .Values.celery.conf.stakewiseSubgraphUrls.goerli | quote }} - GOERLI_ETHEREUM_SUBGRAPH_URLS: {{ .Values.celery.conf.ethereumSubgraphUrls.goerli | quote }} - GOERLI_UNISWAP_V3_SUBGRAPH_URLS: {{ .Values.celery.conf.uniswapV3SubgraphUrls.goerli | quote }} - {{- end }} - - {{- if contains "perm_goerli" .Values.commonConf.enabledNetworks }} - PERM_GOERLI_ETH1_ENDPOINTS: {{ .Values.celery.conf.eth1Endpoints.permGoerli | quote }} - PERM_GOERLI_ETH2_ENDPOINTS: {{ .Values.celery.conf.eth2Endpoints.permGoerli | quote }} - PERM_GOERLI_STAKEWISE_SUBGRAPH_URLS: {{ .Values.celery.conf.stakewiseSubgraphUrls.permGoerli | quote }} - PERM_GOERLI_ETHEREUM_SUBGRAPH_URLS: {{ .Values.celery.conf.ethereumSubgraphUrls.permGoerli | quote }} - {{- end }} - - {{- if contains "gnosis" .Values.commonConf.enabledNetworks }} - GNOSIS_ETH1_ENDPOINTS: {{ .Values.celery.conf.eth1Endpoints.gnosis | quote }} - GNOSIS_ETH2_ENDPOINTS: {{ .Values.celery.conf.eth2Endpoints.gnosis | quote }} - GNOSIS_STAKEWISE_SUBGRAPH_URLS: {{ .Values.celery.conf.stakewiseSubgraphUrls.gnosis | quote }} - GNOSIS_ETHEREUM_SUBGRAPH_URLS: {{ .Values.celery.conf.ethereumSubgraphUrls.gnosis | quote }} - {{- end }} - - {{- if contains "harbour_goerli" .Values.commonConf.enabledNetworks }} - HARBOUR_GOERLI_ETH1_ENDPOINTS: {{ .Values.celery.conf.eth1Endpoints.harbourGoerli | quote }} - HARBOUR_GOERLI_ETH2_ENDPOINTS: {{ .Values.celery.conf.eth2Endpoints.harbourGoerli | quote }} - HARBOUR_GOERLI_STAKEWISE_SUBGRAPH_URLS: {{ .Values.celery.conf.stakewiseSubgraphUrls.harbourGoerli | quote }} - HARBOUR_GOERLI_ETHEREUM_SUBGRAPH_URLS: {{ .Values.celery.conf.ethereumSubgraphUrls.harbourGoerli | quote }} - {{- end }} - - {{- if contains "harbour_mainnet" .Values.commonConf.enabledNetworks }} - HARBOUR_MAINNET_ETH1_ENDPOINTS: {{ .Values.celery.conf.eth1Endpoints.harbourMainnet | quote }} - HARBOUR_MAINNET_ETH2_ENDPOINTS: {{ .Values.celery.conf.eth2Endpoints.harbourMainnet | quote }} - HARBOUR_MAINNET_STAKEWISE_SUBGRAPH_URLS: {{ .Values.celery.conf.stakewiseSubgraphUrls.harbourMainnet | quote }} - HARBOUR_MAINNET_ETHEREUM_SUBGRAPH_URLS: {{ .Values.celery.conf.ethereumSubgraphUrls.harbourMainnet | quote }} - {{- end }} - -{{- end }} diff --git a/charts/backend/templates/common-secret.yaml b/charts/backend/templates/common-secret.yaml deleted file mode 100644 index 864529e0b..000000000 --- a/charts/backend/templates/common-secret.yaml +++ /dev/null @@ -1,23 +0,0 @@ -{{- if or .Values.admin.enabled .Values.api.enabled }} -apiVersion: v1 -kind: Secret -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -type: Opaque -data: - SECRET_KEY: {{ .Values.commonConf.secretKey | b64enc | quote }} - {{- with .Values.rabbitmq.auth }} - CELERY_BROKER_URL: {{ printf "amqp://%s:%s@%s-rabbitmq:5672" .username .password $.Release.Name | b64enc | quote }} - {{- end }} - CELERY_FLOWER_PASSWORD: {{ .Values.celery.flower.password | b64enc | quote }} - {{- with .Values.postgresql }} - DATABASE_URL: {{ printf "postgres://%s:%s@%s:%g/%s" .postgresqlUsername .postgresqlPassword .postgresqlHost .postgresqlPort .postgresqlDatabase | b64enc | quote }} - {{- end }} - NOTIFIERS_TELEGRAM_TOKEN: {{ .Values.commonConf.telegramToken | b64enc | quote }} - NOTIFIERS_TELEGRAM_CHAT_ID: {{ .Values.commonConf.telegramChatId | b64enc | quote }} - MULTISIG_OWNERS_TELEGRAM_TOKEN: {{ .Values.commonConf.multisigOwnersTelegramToken | b64enc | quote }} - MULTISIG_OWNERS_TELEGRAM_CHAT_ID: {{ .Values.commonConf.multisigOwnersTelegramChatId | b64enc | quote }} - MAILGUN_API_KEY: {{ .Values.commonConf.mailgunApiKey | b64enc | quote }} -{{- end }} diff --git a/charts/backend/templates/serviceaccount.yaml b/charts/backend/templates/serviceaccount.yaml deleted file mode 100644 index 16410635a..000000000 --- a/charts/backend/templates/serviceaccount.yaml +++ /dev/null @@ -1,15 +0,0 @@ -{{- if or .Values.global.serviceAccount.create .Values.serviceAccount.create -}} -apiVersion: v1 -kind: ServiceAccount -{{- if .Values.image.pullSecrets }} -imagePullSecrets: {{ toYaml .Values.image.pullSecrets | nindent 2 }} -{{- end }} -metadata: - name: {{ include "common.names.serviceAccountName" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} - {{- with .Values.serviceAccount.annotations }} - annotations: - {{- toYaml . | nindent 4 }} - {{- end }} -{{- end }} diff --git a/charts/backend/values.yaml b/charts/backend/values.yaml deleted file mode 100644 index 5d2900193..000000000 --- a/charts/backend/values.yaml +++ /dev/null @@ -1,392 +0,0 @@ -global: - serviceAccount: - create: true - -## Common configuration for all the containers (server.common_conf) -## -commonConf: - environment: "staging" - secretKey: "" - ## Possible values: goerli, perm_goerli, gnosis, mainnet, harbour_goerli, harbour_mainnet - ## - enabledNetworks: "goerli,perm_goerli,gnosis,mainnet,harbour_goerli,harbour_mainnet" - - poolPage: "https://app.stakewise.io" - soloPage: "https://app.stakewise.io/solo" - stakingAprSamplesCount: "3" - - validatorMaxPenaltyCount: "2" - - sendEmails: "False" - ## Change to https://api.mailgun.net/v3 - ## if you are using Mailgun’s US region - ## - mailgunApiUrl: "https://api.eu.mailgun.net/v3" - mailgunApiKey: "" - mailgunSenderDomain: "mail.stakewise.io" - defaultFromEmail: '"Stakewise" ' - managers: "" - - sentryDsn: "" - memcachedUrl: "" - - staticUrl: "https://static.stakewise.io/" - - sendTelegramNotifications: - mainnet: "False" - goerli: "False" - permGoerli: "False" - gnosis: "False" - harbourGoerli: "False" - harbourMainnet: "False" - - telegramToken: "" - telegramChatId: "" - multisigOwnersTelegramToken: "" - multisigOwnersTelegramChatId: "" - -image: - repository: "europe-west4-docker.pkg.dev/stakewiselabs/private/backend" - tag: "v2.4.12" - pullPolicy: IfNotPresent - pullSecrets: [ ] - -serviceAccount: - ## Annotations to add to the service account - ## - annotations: {} - -admin: - ## Whether to deploy admin or not. - ## - enabled: true - - ## Admin configuration parameters. - ## - conf: - allowedHosts: "" - - ## How many admin pods to run simultaneously. - ## - replicas: 1 - - ## Enable pod disruption budget. - ## ref: https://kubernetes.io/docs/concepts/workloads/pods/disruptions/ - podDisruptionBudget: - enabled: false - maxUnavailable: 1 - - ## Create an admin user if needed. - ## - user: - create: false - username: "username" - password: "password" - email: "user@example.com" - - ## "Host" Header value to pass with the request for Host verification. - ## - probesHostHeader: "" - - serviceType: ClusterIP - servicePort: "8000" - - ## Configure ingress - ## ref: https://kubernetes.io/docs/concepts/services-networking/ingress/ - ## - ingress: - enabled: false - className: "" - annotations: {} - tls: [] - path: "/admin" - hosts: [] - - ## Configure resource requests and limits. - ## ref: http://kubernetes.io/docs/user-guide/compute-resources/ - ## - resources: - requests: - cpu: 100m - memory: 512Mi - limits: - cpu: 300m - memory: 1024Mi - - ## Pod Security Context - ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/ - ## - securityContext: - fsGroup: 65534 - runAsUser: 65534 - - ## Tolerations for pod assignment - ## ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/ - ## - tolerations: [] - - ## Affinity for pod assignment - ## ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity - ## - affinity: {} - - ## used to assign priority to pods - ## ref: https://kubernetes.io/docs/concepts/configuration/pod-priority-preemption/ - ## - priorityClassName: "" - -api: - ## Whether to deploy api or not. - ## - enabled: true - - ## API configuration parameters. - ## - conf: - allowedHosts: "" - corsOriginWhitelist: "" - corsAllowAllOrigins: "False" - - skipRecaptchaVerification: "False" - recaptchaUrl: "https://www.google.com/recaptcha/api/siteverify" - recaptchaSecret: "" - recaptchaHostname: "" - recaptchaContactAction: "contact" - recaptchaContactScore: "0.5" - recaptchaProfileAction: "profile" - recaptchaProfileScore: "0.5" - - ## How many api pods to run simultaneously. - ## - replicas: 2 - - ## Enable pod disruption budget. - ## ref: https://kubernetes.io/docs/concepts/workloads/pods/disruptions/ - ## - podDisruptionBudget: - enabled: true - maxUnavailable: 1 - - ## "Host" Header value to pass with the request for Host verification. - ## - probesHostHeader: "api.stakewise.io" - - serviceType: ClusterIP - servicePort: "8000" - - ## Configure ingress - ## ref: https://kubernetes.io/docs/concepts/services-networking/ingress/ - ## - ingress: - enabled: true - className: "" - annotations: {} - tls: [] - path: "/" - hosts: [] - - ## Configure resource requests and limits. - ## ref: http://kubernetes.io/docs/user-guide/compute-resources/ - ## - resources: - requests: - cpu: 100m - memory: 512Mi - limits: - cpu: 1000m - memory: 1024Mi - - ## Pod Security Context - ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/ - ## - securityContext: - fsGroup: 65534 - runAsUser: 65534 - - ## Tolerations for pod assignment - ## ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/ - ## - tolerations: [] - - ## Affinity for pod assignment - ## ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity - ## - affinity: {} - - ## used to assign priority to pods - ## ref: https://kubernetes.io/docs/concepts/configuration/pod-priority-preemption/ - ## - priorityClassName: "" - -celery: - priorityClassName: "" - - ## Pod Security Context - ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/ - ## - securityContext: - fsGroup: 65534 - runAsUser: 65534 - - ## Tolerations for pod assignment - ## ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/ - ## - tolerations: [] - - ## Affinity for pod assignment - ## ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity - ## - affinity: {} - - ## How many celery worker pods to run simultaneously. - ## - workerReplicaCount: 3 - - ## Configure resource requests and limits. - ## ref: http://kubernetes.io/docs/user-guide/compute-resources/ - ## - workerResources: - requests: - cpu: 1000m - memory: 512Mi - limits: - cpu: 1000m - memory: 1024Mi - - ## How many celery beat pods to run simultaneously. - ## - beatReplicaCount: 1 - - ## Configure resource requests and limits. - ## ref: http://kubernetes.io/docs/user-guide/compute-resources/ - ## - beatResources: - requests: - cpu: 50m - memory: 256Mi - limits: - cpu: 250m - memory: 512Mi - - flower: - ## How many celery flower pods to run simultaneously. - ## - replicaCount: 1 - - ## Configure ingress - ## ref: https://kubernetes.io/docs/concepts/services-networking/ingress/ - ## - ingress: - enabled: true - className: "" - annotations: {} - tls: [] - hosts: [] - port: "5555" - user: "" - password: "" - - ## Configure resource requests and limits. - ## ref: http://kubernetes.io/docs/user-guide/compute-resources/ - ## - resources: - requests: - cpu: 50m - memory: 256Mi - limits: - cpu: 250m - memory: 512Mi - - conf: - eth1Endpoints: - ## Must also be provided in case goerli or perm_goerli network is enabled - ## - mainnet: "" - goerli: "" - permGoerli: "" - gnosis: "" - harbourGoerli: "" - harbourMainnet: "" - - ## NB! only prysm client currently works - ## - eth2Endpoints: - mainnet: "" - goerli: "" - permGoerli: "" - gnosis: "" - harbourGoerli: "" - harbourMainnet: "" - - ## Graph - ## - stakewiseSubgraphUrls: - mainnet: "https://api.thegraph.com/subgraphs/name/stakewise/stakewise-mainnet" - goerli: "https://api.thegraph.com/subgraphs/name/stakewise/stakewise-goerli" - permGoerli: "https://api.thegraph.com/subgraphs/name/stakewise/stakewise-perm-goerli" - gnosis: "https://api.thegraph.com/subgraphs/name/stakewise/stakewise-gnosis" - harbourMainnet: "https://api.thegraph.com/subgraphs/name/stakewise/stakewise-harbour-mainnet" - harbourGoerli: "https://api.thegraph.com/subgraphs/name/stakewise/stakewise-perm-goerli" - uniswapV3SubgraphUrls: - mainnet: "https://api.thegraph.com/subgraphs/name/stakewise/uniswap-v3-mainnet" - goerli: "https://api.thegraph.com/subgraphs/name/stakewise/uniswap-v3-goerli" - ethereumSubgraphUrls: - mainnet: "https://api.thegraph.com/subgraphs/name/stakewise/ethereum-mainnet" - goerli: "https://api.thegraph.com/subgraphs/name/stakewise/ethereum-goerli" - permGoerli: "https://api.thegraph.com/subgraphs/name/stakewise/ethereum-goerli" - gnosis: "https://api.thegraph.com/subgraphs/name/stakewise/ethereum-gnosis" - harbourMainnet: "https://api.thegraph.com/subgraphs/name/stakewise/ethereum-mainnet" - harbourGoerli: "https://api.thegraph.com/subgraphs/name/stakewise/ethereum-goerli" - -## Prometheus Service Monitor -## ref: https://github.com/coreos/prometheus-operator -## https://github.com/coreos/prometheus-operator/blob/master/Documentation/api.md#endpoint -## -serviceMonitor: - ## Create ServiceMonitor resource(s) for scraping metrics using PrometheusOperator - ## - enabled: false - ## The namespace in which the ServiceMonitor will be created - ## - namespace: "" - ## The interval at which metrics should be scraped - ## - interval: 30s - ## The timeout after which the scrape is ended - ## - scrapeTimeout: "" - ## Metrics RelabelConfigs to apply to samples before scraping. - ## - relabelings: [] - ## Metrics RelabelConfigs to apply to samples before ingestion. - ## - metricRelabelings: [] - ## Specify honorLabels parameter to add the scrape endpoint - ## - honorLabels: false - ## Additional labels that can be used so ServiceMonitor resource(s) can be discovered by Prometheus - ## - additionalLabels: {} - -cloudsqlProxy: - enabled: false - replicaCount: 1 - instance: "" - serviceAccountKey: "" - -postgresql: - enabled: false - -rabbitmq: - enabled: true - auth: - username: "rabbitmq" - password: "rabbitmq" - persistence: - enabled: false - -memcached: - enabled: true - architecture: standalone - auth: - enabled: false \ No newline at end of file diff --git a/charts/besu/.helmignore b/charts/balval/.helmignore similarity index 100% rename from charts/besu/.helmignore rename to charts/balval/.helmignore diff --git a/charts/lighthouse/Chart.lock b/charts/balval/Chart.lock similarity index 76% rename from charts/lighthouse/Chart.lock rename to charts/balval/Chart.lock index cbec578c5..365356b87 100644 --- a/charts/lighthouse/Chart.lock +++ b/charts/balval/Chart.lock @@ -3,4 +3,4 @@ dependencies: repository: file://../common version: 1.0.0 digest: sha256:07cebde439abe4ba19bb28e844b7419dab83c7f613886416aaf3ec08e8059144 -generated: "2022-03-07T12:30:36.31435635+03:00" +generated: "2024-03-17T01:44:51.25393669+01:00" diff --git a/charts/balval/Chart.yaml b/charts/balval/Chart.yaml new file mode 100644 index 000000000..fa38452e0 --- /dev/null +++ b/charts/balval/Chart.yaml @@ -0,0 +1,20 @@ +apiVersion: v2 +name: validator-balval +description: A Helm chart for installing and configuring Lido's validator-balval +type: application +version: 1.0.0 +appVersion: "v4.6.0" + +keywords: + - ethereum + - lido + - validators + - monitoring + - balval + +home: https://nethermind.io/ + +dependencies: +- name: common + repository: file://../common + version: 1.0.0 \ No newline at end of file diff --git a/charts/contract-watcher/templates/_helpers.tpl b/charts/balval/templates/_helpers.tpl similarity index 72% rename from charts/contract-watcher/templates/_helpers.tpl rename to charts/balval/templates/_helpers.tpl index 702db2893..318275f4e 100644 --- a/charts/contract-watcher/templates/_helpers.tpl +++ b/charts/balval/templates/_helpers.tpl @@ -1,7 +1,7 @@ {{/* Expand the name of the chart. */}} -{{- define "contract-watcher.name" -}} +{{- define "balval.name" -}} {{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" }} {{- end }} @@ -10,7 +10,7 @@ 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 "contract-watcher.fullname" -}} +{{- define "balval.fullname" -}} {{- if .Values.fullnameOverride }} {{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" }} {{- else }} @@ -26,16 +26,16 @@ If release name contains chart name it will be used as a full name. {{/* Create chart name and version as used by the chart label. */}} -{{- define "contract-watcher.chart" -}} +{{- define "balval.chart" -}} {{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }} {{- end }} {{/* Common labels */}} -{{- define "contract-watcher.labels" -}} -helm.sh/chart: {{ include "contract-watcher.chart" . }} -{{ include "contract-watcher.selectorLabels" . }} +{{- define "balval.labels" -}} +helm.sh/chart: {{ include "balval.chart" . }} +{{ include "balval.selectorLabels" . }} {{- if .Chart.AppVersion }} app.kubernetes.io/version: {{ .Chart.AppVersion | quote }} {{- end }} @@ -45,17 +45,17 @@ app.kubernetes.io/managed-by: {{ .Release.Service }} {{/* Selector labels */}} -{{- define "contract-watcher.selectorLabels" -}} -app.kubernetes.io/name: {{ include "contract-watcher.name" . }} +{{- define "balval.selectorLabels" -}} +app.kubernetes.io/name: {{ include "balval.name" . }} app.kubernetes.io/instance: {{ .Release.Name }} {{- end }} {{/* Create the name of the service account to use */}} -{{- define "contract-watcher.serviceAccountName" -}} +{{- define "balval.serviceAccountName" -}} {{- if .Values.serviceAccount.create }} -{{- default (include "contract-watcher.fullname" .) .Values.serviceAccount.name }} +{{- default (include "balval.fullname" .) .Values.serviceAccount.name }} {{- else }} {{- default "default" .Values.serviceAccount.name }} {{- end }} diff --git a/charts/balval/templates/configmap.yaml b/charts/balval/templates/configmap.yaml new file mode 100644 index 000000000..3a4c758f0 --- /dev/null +++ b/charts/balval/templates/configmap.yaml @@ -0,0 +1,13 @@ +--- +apiVersion: v1 +kind: ConfigMap +metadata: + name: {{ include "common.names.fullname" . }} + labels: + {{- include "common.labels.standard" . | nindent 4 }} +data: + custom_mainnet.yaml: | + operators: + - name: Test + keys: + - "0xb1294eeeab227054786e3da41566f0472c581e4dc74834fca7287817a64edb4a4a4e912c7ae8ae703d417fe43a221cdb" \ No newline at end of file diff --git a/charts/balval/templates/external-secret.yaml b/charts/balval/templates/external-secret.yaml new file mode 100644 index 000000000..8adf62f98 --- /dev/null +++ b/charts/balval/templates/external-secret.yaml @@ -0,0 +1,18 @@ +{{- if .Values.global.externalSecrets.enabled }} +apiVersion: external-secrets.io/v1beta1 +kind: ExternalSecret +metadata: + name: eso-{{ include "common.names.fullname" . }} + labels: + {{- include "common.labels.standard" . | nindent 4 }} +spec: + refreshInterval: 10m + secretStoreRef: + name: {{ .Values.global.externalSecrets.secretStoreRef.name }} + kind: {{ .Values.global.externalSecrets.secretStoreRef.kind }} + target: + name: eso-{{ include "common.names.fullname" . }} + creationPolicy: Owner + data: + {{- .Values.global.externalSecrets.data | toYaml | trim | nindent 2 }} +{{- end }} \ No newline at end of file diff --git a/charts/balval/templates/prometheusrules.yaml b/charts/balval/templates/prometheusrules.yaml new file mode 100644 index 000000000..a7b6e3b00 --- /dev/null +++ b/charts/balval/templates/prometheusrules.yaml @@ -0,0 +1,124 @@ +{{- if .Values.prometheusRule.enabled }} +--- +apiVersion: monitoring.coreos.com/v1 +kind: PrometheusRule +metadata: + name: {{ include "common.names.fullname" . }} + {{- if .Values.prometheusRule.namespace }} + namespace: {{ .Values.prometheusRule.namespace }} + {{- else }} + namespace: {{ .Release.Namespace | quote }} + {{- end }} + labels: + {{- include "common.labels.standard" . | nindent 4 }} + {{- if .Values.prometheusRule.additionalLabels }} + {{- toYaml .Values.prometheusRule.additionalLabels | nindent 4 }} + {{- end }} +spec: + groups: + {{- with .Values.prometheusRule.rules }} + - name: {{ include "common.names.fullname" $ }} + rules: {{- tpl (toYaml .) $ | nindent 8 }} + {{- end }} + {{- if .Values.prometheusRule.default }} + - name: {{ include "common.names.fullname" $ }}-default + rules: + - alert: UserSlashedValidators + expr: (ethereum_validators_monitoring_user_validators{status="slashed"} - ethereum_validators_monitoring_user_validators{status="slashed"} offset 1m) > 0 + labels: + severity: critical + annotations: + emoji: 🔪 + summary: "Operators have slashed validators" + description: 'Number of slashed validators per operator' + - alert: DataActuality + expr: absent(ethereum_validators_monitoring_data_actuality) OR (ethereum_validators_monitoring_data_actuality / 1000 > 3600) + for: 1m + labels: + severity: critical + annotations: + emoji: ⏳ + summary: "Data actuality greater then 1 hour" + resolved_summary: "Data actuality is back to normal and now less then 1 hour" + description: "It's not OK. Please, check app health" + - alert: NumValidatorsWithNegativeDelta + expr: ethereum_validators_monitoring_validator_count_with_negative_balances_delta > 0 AND ON() changes(ethereum_validators_monitoring_epoch_number[1m]) > 0 + labels: + severity: critical + annotations: + emoji: 💸 + summary: 'Operators have a negative balance delta' + resolved_summary: 'Operators have a positive balance delta' + description: 'Number of validators per operator who have a negative balance delta.' + - alert: NumValidatorsWithMissAttestationLastNEpoch + expr: ethereum_validators_monitoring_validator_count_miss_attestation_last_n_epoch > 0 AND ON() changes(ethereum_validators_monitoring_epoch_number[1m]) > 0 + labels: + severity: critical + annotations: + emoji: 📝❌ + summary: 'Operators have missed attestation in last {{ printf "{{ $labels.epoch_interval }}" }} finalized epochs' + resolved_summary: 'Operators not have missed attestation in last {{ printf "{{ $labels.epoch_interval }}" }} finalized epochs' + description: 'Number of validators per operator who have missed attestations.' + - alert: NumValidatorsWithHighIncDelayAttestationLastNEpoch + expr: ethereum_validators_monitoring_validator_count_high_inc_delay_last_n_epoch > 0 AND ON() changes(ethereum_validators_monitoring_epoch_number[1m]) > 0 + labels: + severity: critical + annotations: + emoji: 📝🐢 + summary: 'Operators have attestation inc. delay greater than 2 in last {{ printf "{{ $labels.epoch_interval }}" }} finalized epochs' + description: 'Number of validators per operator who have attestation with high inc. delay.' + - alert: NumValidatorsWithInvalidPropertyAttestationLastNEpoch + expr: ethereum_validators_monitoring_validator_count_invalid_attestation_property_last_n_epoch > 0 AND ON() changes(ethereum_validators_monitoring_epoch_number[1m]) > 0 + labels: + severity: critical + annotations: + emoji: '📝🏷️' + summary: 'Operators have invalid attestation property in last {{ printf "{{ $labels.epoch_interval }}" }} finalized epochs' + description: 'Number of validators per operator who have invalid attestation property.' + - alert: NumValidatorsWithMissPropose + expr: ethereum_validators_monitoring_validator_count_miss_propose > 0 AND ON() changes(ethereum_validators_monitoring_epoch_number[1m]) > 0 + labels: + severity: critical + annotations: + emoji: 📥 + summary: 'Operators missed block propose in the last finalized epoch' + resolved_summary: 'Operators not missed block propose in the last finalized epoch' + description: 'Number of validators per operator who missed block propose.' + - alert: NumValidatorsWithSyncParticipationLessAvgLastNEpoch + expr: ethereum_validators_monitoring_validator_count_with_sync_participation_less_avg_last_n_epoch > 0 AND ON() changes(ethereum_validators_monitoring_epoch_number[1m]) > 0 + labels: + severity: critical + annotations: + emoji: 🔄 + summary: 'Operators sync participation less than average in last {{ printf "{{ $labels.epoch_interval }}" }} finalized epochs' + resolved_summary: 'Operators sync participation higher or equal than average in last {{ printf "{{ $labels.epoch_interval }}" }} finalized epochs' + description: 'Number of validators per operator whose sync participation less than average.' + - alert: HighRewardNumValidatorsWithSyncParticipationLessAvgLastNEpoch + expr: ethereum_validators_monitoring_high_reward_validator_count_with_sync_participation_less_avg_last_n_epoch > 0 AND ON() changes(ethereum_validators_monitoring_epoch_number[1m]) > 0 + labels: + severity: critical + annotations: + emoji: '📈🔄' + summary: 'Operators may get high rewards in the future, but sync participation less than average in last {{ printf "{{ $labels.epoch_interval }}" }} finalized epochs!' + resolved_summary: 'Operators sync participation higher or equal than average in last {{ printf "{{ $labels.epoch_interval }}" }} finalized epoch. Now may get high rewards in the future!' + description: 'Number of validators per operator whose sync participation less than average.' + - alert: HighRewardNumValidatorsWithMissAttestationLastNEpoch + expr: ethereum_validators_monitoring_high_reward_validator_count_miss_attestation_last_n_epoch > 0 AND ON() changes(ethereum_validators_monitoring_epoch_number[1m]) > 0 + labels: + severity: critical + annotations: + emoji: '📈📝❌' + summary: 'Operators may get high rewards in the future, but missed attestation in last {{ printf "{{ $labels.epoch_interval }}" }} finalized epochs!' + resolved_summary: 'Operators not have missed attestation in last {{ printf "{{ $labels.epoch_interval }}" }} finalized epochs. Now may get high rewards in the future!' + description: 'Number of validators per operator who have missed attestations.' + - alert: HighRewardNumValidatorsWithMissPropose + expr: ethereum_validators_monitoring_high_reward_validator_count_miss_propose > 0 AND ON() changes(ethereum_validators_monitoring_epoch_number[1m]) > 0 + labels: + severity: critical + annotations: + emoji: '📈📥' + summary: 'Operators may get high rewards in the future, but missed block propose in the last finalized epoch!' + resolved_summary: 'Operators not missed block propose in the last finalized epoch. Now may get high rewards in the future!' + description: 'Number of validators per operator who missed block propose.' + {{- end }} +{{- end }} \ No newline at end of file diff --git a/charts/balval/templates/service.yaml b/charts/balval/templates/service.yaml new file mode 100644 index 000000000..3b4ea88f7 --- /dev/null +++ b/charts/balval/templates/service.yaml @@ -0,0 +1,15 @@ +apiVersion: v1 +kind: Service +metadata: + name: {{ include "balval.fullname" . }} + labels: + {{- include "balval.labels" . | nindent 4 }} +spec: + type: ClusterIP + ports: + - port: {{ .Values.balval.httpPort }} + targetPort: metrics + protocol: TCP + name: metrics + selector: + {{- include "balval.selectorLabels" . | nindent 4 }} diff --git a/charts/besu/templates/serviceaccount.yaml b/charts/balval/templates/serviceaccount.yaml similarity index 100% rename from charts/besu/templates/serviceaccount.yaml rename to charts/balval/templates/serviceaccount.yaml diff --git a/charts/graph-node/templates/servicemonitor.yaml b/charts/balval/templates/servicemonitor.yaml similarity index 98% rename from charts/graph-node/templates/servicemonitor.yaml rename to charts/balval/templates/servicemonitor.yaml index 99556ad80..bd99c3387 100644 --- a/charts/graph-node/templates/servicemonitor.yaml +++ b/charts/balval/templates/servicemonitor.yaml @@ -16,6 +16,7 @@ metadata: spec: endpoints: - port: metrics + path: /metrics {{- if .Values.serviceMonitor.interval }} interval: {{ .Values.serviceMonitor.interval }} {{- end }} diff --git a/charts/balval/templates/statefulset.yaml b/charts/balval/templates/statefulset.yaml new file mode 100644 index 000000000..923b5f9b9 --- /dev/null +++ b/charts/balval/templates/statefulset.yaml @@ -0,0 +1,158 @@ +apiVersion: {{ include "common.capabilities.statefulset.apiVersion" . }} +kind: StatefulSet +metadata: + name: {{ include "common.names.fullname" . }} + labels: + {{- include "common.labels.standard" . | nindent 4 }} +spec: + replicas: {{ .Values.global.replicaCount }} + selector: + matchLabels: + {{- include "common.labels.matchLabels" . | nindent 6 }} + serviceName: {{ include "common.names.fullname" . }} + template: + metadata: + {{- with .Values.podAnnotations }} + annotations: + {{- toYaml . | nindent 8 }} + {{- end }} + labels: + {{- include "common.labels.matchLabels" . | nindent 8 }} + spec: + {{- with .Values.nodeSelector }} + nodeSelector: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with .Values.affinity }} + affinity: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with .Values.tolerations }} + tolerations: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with .Values.global.imagePullSecrets }} + imagePullSecrets: + {{- toYaml . | nindent 8 }} + {{- end }} + serviceAccountName: {{ include "balval.serviceAccountName" . }} + securityContext: + {{- toYaml .Values.global.podSecurityContext | nindent 8 }} + initContainers: + - name: init + image: "{{ .Values.initImage.repository }}:{{ .Values.initImage.tag }}" + imagePullPolicy: {{ .Values.initImage.pullPolicy }} + securityContext: + {{- toYaml .Values.global.securityContext | nindent 12 }} + command: + - sh + - -ac + - > + mkdir -p {{ .Values.balval.dataDir }}; + cp /config/custom_mainnet.yaml {{ .Values.balval.dataDir }}/; + chown -R {{ .Values.global.podSecurityContext.runAsUser }}:{{ .Values.global.podSecurityContext.fsGroup }} {{ .Values.balval.dataDir }}; + cat {{ .Values.balval.dataDir }}/custom_mainnet.yaml + volumeMounts: + - name: data + mountPath: /data + - name: config + mountPath: /config + containers: + - name: {{ .Chart.Name }} + securityContext: + readOnlyRootFilesystem: false + runAsNonRoot: true + runAsUser: 10000 + image: "{{ .Values.global.image.repository }}:{{ .Values.global.image.tag | default .Chart.AppVersion }}" + imagePullPolicy: {{ .Values.global.image.pullPolicy }} + env: + - name: WORKING_MODE + value: "{{ .Values.balval.workingMode }}" + - name: NODE_ENV + value: "{{ .Values.balval.env }}" + - name: DRY_RUN + value: "{{ .Values.balval.dryRun }}" + - name: LOG_LEVEL + value: "{{ .Values.balval.logLevel }}" + - name: LOG_FORMAT + value: "{{ .Values.balval.logFormat }}" + - name: HTTP_PORT + value: "{{ .Values.balval.httpPort }}" + {{- with .Values.clickhouse }} + - name: DB_NAME + value: "{{ .auth.database }}" + - name: DB_HOST + value: "{{ .hostname }}" + - name: DB_USER + value: "{{ .auth.username }}" + - name: DB_PASSWORD + value: "{{ .auth.password }}" + - name: DB_PORT + value: "{{ .service.ports.http }}" + {{- end }} + - name: DB_MAX_RETRIES + value: "{{ .Values.balval.dbMaxRetries }}" + - name: DB_MIN_BACKOFF_SEC + value: "{{ .Values.balval.dbMinBackoffSec }}" + - name: DB_MAX_BACKOFF_SEC + value: "{{ .Values.balval.dbMaxBackoffSec }}" + - name: START_EPOCH + value: "{{ .Values.balval.startEpoch }}" + - name: ETH_NETWORK + value: "{{ .Values.balval.network }}" + - name: VALIDATOR_REGISTRY_SOURCE + value: "{{ .Values.balval.validatorRegistrySource }}" + - name: VALIDATOR_REGISTRY_FILE_SOURCE_PATH + value: "{{ .Values.balval.validatorRegistryFileSourcePath }}" + - name: VALIDATOR_REGISTRY_LIDO_SOURCE_SQLITE_CACHE_PATH + value: "{{ .Values.balval.validatorRegistryLidoSourceSqliteCachePath }}" + - name: EL_RPC_URLS + value: "{{ .Values.balval.elRpcUrls }}" + - name: CL_API_URLS + value: "{{ .Values.balval.clRpcUrls }}" + - name: CL_API_RETRY_DELAY_MS + value: "{{ .Values.balval.clApiRetryDelayMs }}" + - name: CL_API_GET_RESPONSE_TIMEOUT + value: "{{ .Values.balval.clApiGetResponseTimeout }}" + - name: CL_API_MAX_RETRIES + value: "{{ .Values.balval.clApiMaxRetries }}" + - name: CL_API_GET_BLOCK_INFO_MAX_RETRIES + value: "{{ .Values.balval.clApiGetBlockInfoMaxRetries }}" + - name: FETCH_INTERVAL_SLOTS + value: "{{ .Values.balval.fetchIntervalSlots }}" + - name: CHAIN_SLOT_TIME_SECONDS + value: "{{ .Values.balval.chainSlotTimeSeconds }}" + - name: SYNC_PARTICIPATION_DISTANCE_DOWN_FROM_CHAIN_AVG + value: "{{ .Values.balval.syncParticipationDistanceDownFromChainAvg }}" + - name: SYNC_PARTICIPATION_EPOCHS_LESS_THAN_CHAIN_AVG + value: "{{ .Values.balval.syncParticipationEpochsLessThanChainAvg }}" + - name: BAD_ATTESTATION_EPOCHS + value: "{{ .Values.balval.badAttestationEpochs }}" + - name: CRITICAL_ALERTS_ALERTMANAGER_URL + value: "{{ .Values.balval.alertmanagerUrl }}" + - name: CRITICAL_ALERTS_MIN_VAL_COUNT + value: "{{ .Values.balval.minValCount }}" + {{- if .Values.global.externalSecrets.enabled }} + envFrom: + - secretRef: + name: eso-{{ include "common.names.fullname" . }} + {{- end }} + ports: + - name: metrics + containerPort: {{ .Values.balval.httpPort }} + protocol: TCP + resources: + {{- toYaml .Values.resources | nindent 12 }} + volumeMounts: + - name: data + mountPath: /data + - name: config + mountPath: /config + volumes: + - name: config + configMap: + name: {{ include "common.names.fullname" . }} + - name: data + emptyDir: + medium: Memory + sizeLimit: 128Mi \ No newline at end of file diff --git a/charts/balval/values.yaml b/charts/balval/values.yaml new file mode 100644 index 000000000..d508627a3 --- /dev/null +++ b/charts/balval/values.yaml @@ -0,0 +1,214 @@ +# Default values for web3signer. +# This is a YAML-formatted file. +# Declare variables to be passed into your templates. + +global: + serviceAccount: + create: true + imagePullSecrets: [] + ## Pod Security Context + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/ + ## + podSecurityContext: + runAsNonRoot: true + runAsUser: 10000 + fsGroup: 10000 + + securityContext: + readOnlyRootFilesystem: true + runAsNonRoot: true + runAsUser: 10000 + capabilities: + drop: + - ALL + + replicaCount: 1 + + externalSecrets: + enabled: false + secretStoreRef: secretStoreRef + data: + - secretKey: DB_NAME + remoteRef: + key: validatorBalvalSecrets + property: dbName + - secretKey: DB_PORT + remoteRef: + key: validatorBalvalSecrets + property: dbPort + - secretKey: DB_HOST + remoteRef: + key: validatorBalvalSecrets + property: dbHost + - secretKey: DB_USER + remoteRef: + key: validatorBalvalSecrets + property: dbUser + - secretKey: DB_PASSWORD + remoteRef: + key: validatorBalvalSecrets + property: dbPassword + + image: + repository: lidofinance/ethereum-validators-monitoring + pullPolicy: IfNotPresent + tag: "4.6.0" + +nameOverride: "" +fullnameOverride: "" + +## Init image is used to chown data volume, etc. +## +initImage: + repository: busybox + tag: "1.36" + pullPolicy: IfNotPresent + +balval: + env: "production" + workingMode: "head" + dryRun: false + logLevel: "debug" + logFormat: "json" + httpPort: 8080 + dbMaxRetries: 10 + dbMinBackoffSec: 1 + dbMaxBackoffSec: 120 + startEpoch: 270292 + network: 1 + validatorRegistrySource: "file" + dataDir: "/data/balval" + validatorRegistryFileSourcePath: "/data/balval/custom_mainnet.yaml" + validatorRegistryLidoSourceSqliteCachePath: "/data/balval/lido_mainnet.db" + elRpcUrls: "http://localhost:8545" + clRpcUrls: "http://localhost:5052" + clApiRetryDelayMs: 500 + clApiGetResponseTimeout: 30000 + clApiMaxRetries: 2 + clApiGetBlockInfoMaxRetries: 2 + fetchIntervalSlots: 32 + chainSlotTimeSeconds: 12 + syncParticipationDistanceDownFromChainAvg: 0 + syncParticipationEpochsLessThanChainAvg: 3 + badAttestationEpochs: 3 + alertmanagerUrl: "http://localhost:9093" + minValCount: 100 + +## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ +## +serviceAccount: + # Annotations to add to the service account + annotations: {} + # The name of the service account to use. + # If not set and create is true, a name is generated using the fullname template + name: "" + +podAnnotations: {} + +clickhouse: + enabled: true + hostname: clickhouse + auth: + username: default + password: "" + database: default + existingSecret: "" + existingSecretKey: "" + service: + ports: + http: 8123 + +## Configure resource requests and limits. +## ref: http://kubernetes.io/docs/user-guide/compute-resources/ +## +resources: {} + # We usually recommend not to specify default resources and to leave this as a conscious + # choice for the user. This also increases chances charts run on environments with little + # resources, such as Minikube. If you do want to specify resources, uncomment the following + # lines, adjust them as necessary, and remove the curly braces after 'resources:'. + # limits: + # cpu: 100m + # memory: 128Mi + # requests: + # cpu: 100m + # memory: 128Mi + +## Node labels for pod assignment +## ref: https://kubernetes.io/docs/user-guide/node-selection/ +## +nodeSelector: {} + +## Tolerations for pod assignment +## ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/ +## +tolerations: {} + +## Affinity for pod assignment +## ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity +## +affinity: {} + +## Prometheus Service Monitor +## ref: https://github.com/coreos/prometheus-operator +## https://github.com/coreos/prometheus-operator/blob/master/Documentation/api.md#endpoint +## +serviceMonitor: + ## @param metrics.serviceMonitor.enabled Create ServiceMonitor resource(s) for scraping metrics using PrometheusOperator + ## + enabled: false + ## @param metrics.serviceMonitor.namespace The namespace in which the ServiceMonitor will be created + ## + namespace: "" + ## @param metrics.serviceMonitor.interval The interval at which metrics should be scraped + ## + interval: 30s + ## @param metrics.serviceMonitor.scrapeTimeout The timeout after which the scrape is ended + ## + scrapeTimeout: "" + ## @param metrics.serviceMonitor.relabellings Metrics RelabelConfigs to apply to samples before scraping. + ## + relabelings: [] + ## @param metrics.serviceMonitor.metricRelabelings Metrics RelabelConfigs to apply to samples before ingestion. + ## + metricRelabelings: [] + ## @param metrics.serviceMonitor.honorLabels Specify honorLabels parameter to add the scrape endpoint + ## + honorLabels: false + ## @param metrics.serviceMonitor.additionalLabels Additional labels that can be used so ServiceMonitor resource(s) can be discovered by Prometheus + ## + additionalLabels: {} + +prometheusRule: + ## @param metrics.prometheusRule.enabled Create a custom prometheusRule Resource for scraping metrics using PrometheusOperator + ## + enabled: false + ## @param metrics.prometheusRule.default Create a default set of Alerts + ## + default: true + ## @param metrics.prometheusRule.namespace The namespace in which the prometheusRule will be created + ## + namespace: "" + ## @param metrics.prometheusRule.additionalLabels Additional labels for the prometheusRule + ## + additionalLabels: {} + ## @param metrics.prometheusRule.rules Custom Prometheus rules + ## e.g: + ## rules: + ## - alert: PrysmValidatorHourlyEarningLessOrEqual0 + ## expr: sum(validator_balance) - sum(validator_balance offset 1h) - count(validator_balance > 16)*32 + count(validator_balance offset 1h > 0)*32 + ## for: 5m + ## labels: + ## severity: critical + ## annotations: + ## summary: Prysm validator hourly earning <= 0 + ## description: Check validators immediately. Pod - {{ printf "{{ $labels.pod }}" }}. Namespace - {{ printf "{{ $labels.namespace }}" }} + ## - alert: PrysmValidatorAlotOfErrorsLastHour + ## expr: sum(delta(log_entries_total{job='{{ include "operator.fullname" . }}-validator', level="error"}[1h]) > 0) + ## for: 5m + ## labels: + ## severity: warning + ## annotations: + ## summary: Many validator errors or warnings last hour + ## description: Check validator {{ printf "{{ $labels.pod }}" }}. Namespace - {{ printf "{{ $labels.namespace }}" }} + ## + rules: {} diff --git a/charts/besu/Chart.yaml b/charts/besu/Chart.yaml deleted file mode 100644 index 12ad8498c..000000000 --- a/charts/besu/Chart.yaml +++ /dev/null @@ -1,39 +0,0 @@ -apiVersion: v2 -name: besu -description: An enterprise-grade Java-based, Apache 2.0 licensed Ethereum client. -icon: https://raw.githubusercontent.com/ethereum/ethereum-org/master/public/images/logos/ETHEREUM-ICON_Black.png -home: https://stakewise.io/ -sources: - - https://github.com/hyperledger/besu - -# A chart can be either an 'application' or a 'library' chart. -# -# Application charts are a collection of templates that can be packaged into versioned archives -# to be deployed. -# -# Library charts provide useful utilities or functions for the chart developer. They're included as -# a dependency of application charts to inject those utilities and functions into the rendering -# pipeline. Library charts do not define any templates and therefore cannot be deployed. -type: application - -# This is the chart version. This version number should be incremented each time you make changes -# to the chart and its templates, including the app version. -# Versions are expected to follow Semantic Versioning (https://semver.org/) -version: 2.0.6 - -# This is the version number of the application being deployed. This version number should be -# incremented each time you make changes to the application. Versions are not expected to -# follow Semantic Versioning. They should reflect the version the application is using. -# It is recommended to use it with quotes. -appVersion: "22.7.6" - -keywords: - - ethereum - - blockchain - - besu - - p2p - -dependencies: -- name: common - repository: file://../common - version: 1.0.0 diff --git a/charts/besu/templates/_helpers.yaml b/charts/besu/templates/_helpers.yaml deleted file mode 100644 index a149140d6..000000000 --- a/charts/besu/templates/_helpers.yaml +++ /dev/null @@ -1,3 +0,0 @@ -{{- define "besu.p2pPort" -}} -{{- printf "9000" -}} -{{- end -}} diff --git a/charts/besu/templates/pdb.yaml b/charts/besu/templates/pdb.yaml deleted file mode 100644 index 4ef63f0ff..000000000 --- a/charts/besu/templates/pdb.yaml +++ /dev/null @@ -1,18 +0,0 @@ -{{- if .Values.podDisruptionBudget.enabled }} -apiVersion: {{ include "common.capabilities.policy.apiVersion" . }} -kind: PodDisruptionBudget -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -spec: -{{- if .Values.podDisruptionBudget.minAvailable }} - minAvailable: {{ .Values.podDisruptionBudget.minAvailable }} -{{- end }} -{{- if .Values.podDisruptionBudget.maxUnavailable }} - maxUnavailable: {{ .Values.podDisruptionBudget.maxUnavailable }} -{{- end }} - selector: - matchLabels: - {{- include "common.labels.matchLabels" . | nindent 6 }} -{{- end }} diff --git a/charts/besu/templates/prometheusrules.yaml b/charts/besu/templates/prometheusrules.yaml deleted file mode 100644 index 958aa9c5a..000000000 --- a/charts/besu/templates/prometheusrules.yaml +++ /dev/null @@ -1,23 +0,0 @@ -{{- if and (or .Values.global.metrics.enabled .Values.metrics.enabled) - (or .Values.global.metrics.prometheusRule.enabled .Values.metrics.prometheusRule.enabled) }} -apiVersion: monitoring.coreos.com/v1 -kind: PrometheusRule -metadata: - name: {{ include "common.names.fullname" . }} - {{- if .Values.metrics.prometheusRule.namespace }} - namespace: {{ .Values.metrics.prometheusRule.namespace }} - {{- else }} - namespace: {{ .Release.Namespace | quote }} - {{- end }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.metrics.prometheusRule.additionalLabels }} - {{- toYaml .Values.metrics.prometheusRule.additionalLabels | nindent 4 }} - {{- end }} -spec: - groups: - {{- with .Values.metrics.prometheusRule.rules }} - - name: {{ include "common.names.fullname" $ }} - rules: {{- tpl (toYaml .) $ | nindent 8 }} - {{- end }} -{{- end }} \ No newline at end of file diff --git a/charts/besu/templates/secret.yaml b/charts/besu/templates/secret.yaml deleted file mode 100644 index 5a3f66bb5..000000000 --- a/charts/besu/templates/secret.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: v1 -kind: Secret -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -type: Opaque -data: - jwtsecret: {{ .Values.global.JWTSecret | b64enc | quote }} diff --git a/charts/besu/templates/service-p2p.yaml b/charts/besu/templates/service-p2p.yaml deleted file mode 100644 index 3afd3284f..000000000 --- a/charts/besu/templates/service-p2p.yaml +++ /dev/null @@ -1,42 +0,0 @@ -{{- if .Values.p2pNodePort.enabled -}} -{{- range $i, $e := until (int .Values.global.replicaCount) }} -{{- $port := add $.Values.p2pNodePort.startAt $i -}} -{{- if hasKey $.Values.p2pNodePort.replicaToNodePort ($i | toString) -}} - {{ $port = index $.Values.p2pNodePort.replicaToNodePort ($i | toString) }} -{{- end }} - ---- -apiVersion: v1 -kind: Service -metadata: - name: {{ include "common.names.fullname" $ }}-{{ $i }} - labels: - {{- include "common.labels.standard" $ | nindent 4 }} - pod: "{{ include "common.names.fullname" $ }}-{{ $i }}" - type: p2p - {{- with $.Values.p2pNodePort.annotations }} - annotations: - {{- toYaml . | nindent 4 }} - {{- end }} -spec: - type: {{ $.Values.p2pNodePort.type }} - externalTrafficPolicy: Local - ports: - - name: p2p-tcp - port: {{ include "besu.p2pPort" $ }} - protocol: TCP - targetPort: p2p-tcp - nodePort: {{ $port }} - {{- if eq $.Values.p2pNodePort.type "NodePort" }} - - name: p2p-udp - port: {{ include "besu.p2pPort" $ }} - protocol: UDP - targetPort: p2p-udp - nodePort: {{ $port }} - {{- end }} - selector: - {{- include "common.labels.matchLabels" $ | nindent 4 }} - statefulset.kubernetes.io/pod-name: "{{ include "common.names.fullname" $ }}-{{ $i }}" - -{{- end }} -{{- end }} diff --git a/charts/besu/templates/service.yaml b/charts/besu/templates/service.yaml deleted file mode 100644 index ad16bafde..000000000 --- a/charts/besu/templates/service.yaml +++ /dev/null @@ -1,41 +0,0 @@ -{{- if or .Values.restApi.enabled .Values.global.metrics.enabled }} ---- -apiVersion: v1 -kind: Service -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -spec: - type: {{ .Values.service.type }} -{{- if .Values.svcHeadless }} - clusterIP: None -{{- end }} -{{- if .Values.sessionAffinity.enabled }} - sessionAffinity: ClientIP - sessionAffinityConfig: - clientIP: - timeoutSeconds: {{ .Values.sessionAffinity.timeoutSeconds }} -{{- end }} - ports: - {{- if .Values.restApi.enabled }} - - port: {{ .Values.restApi.port }} - targetPort: {{ .Values.restApi.portName }} - protocol: TCP - name: {{ .Values.restApi.portName }} - {{- end }} - {{- if .Values.engineRpc.enabled }} - - port: {{ .Values.engineRpc.port }} - targetPort: {{ .Values.engineRpc.portName }} - protocol: TCP - name: {{ .Values.engineRpc.portName }} - {{- end }} - {{- if .Values.global.metrics.enabled }} - - port: {{ .Values.metrics.port }} - targetPort: metrics - protocol: TCP - name: metrics - {{- end }} - selector: - {{- include "common.labels.matchLabels" . | nindent 4 }} -{{- end }} diff --git a/charts/besu/templates/servicemonitor.yaml b/charts/besu/templates/servicemonitor.yaml deleted file mode 100644 index 9ecffc6ca..000000000 --- a/charts/besu/templates/servicemonitor.yaml +++ /dev/null @@ -1,42 +0,0 @@ -{{- if and (or .Values.global.metrics.enabled .Values.metrics.enabled) - (or .Values.global.metrics.serviceMonitor.enabled .Values.metrics.serviceMonitor.enabled) }} -apiVersion: monitoring.coreos.com/v1 -kind: ServiceMonitor -metadata: - name: {{ template "common.names.fullname" . }} - {{- if .Values.metrics.serviceMonitor.namespace }} - namespace: {{ .Values.metrics.serviceMonitor.namespace }} - {{- else }} - namespace: {{ .Release.Namespace | quote }} - {{- end }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.metrics.serviceMonitor.additionalLabels }} - {{- toYaml .Values.metrics.serviceMonitor.additionalLabels | nindent 4 }} - {{- end }} -spec: - endpoints: - - port: metrics - path: /metrics - {{- if .Values.metrics.serviceMonitor.interval }} - interval: {{ .Values.metrics.serviceMonitor.interval }} - {{- end }} - {{- if .Values.metrics.serviceMonitor.scrapeTimeout }} - scrapeTimeout: {{ .Values.metrics.serviceMonitor.scrapeTimeout }} - {{- end }} - {{- if .Values.metrics.serviceMonitor.honorLabels }} - honorLabels: {{ .Values.metrics.serviceMonitor.honorLabels }} - {{- end }} - {{- if .Values.metrics.serviceMonitor.relabelings }} - relabelings: {{- toYaml .Values.metrics.serviceMonitor.relabelings | nindent 6 }} - {{- end }} - {{- if .Values.metrics.serviceMonitor.metricRelabelings }} - metricRelabelings: {{- toYaml .Values.metrics.serviceMonitor.metricRelabelings | nindent 6 }} - {{- end }} - namespaceSelector: - matchNames: - - {{ .Release.Namespace }} - selector: - matchLabels: - {{- include "common.labels.matchLabels" . | nindent 6 }} -{{- end }} diff --git a/charts/besu/templates/statefulset.yaml b/charts/besu/templates/statefulset.yaml deleted file mode 100644 index 464c1a741..000000000 --- a/charts/besu/templates/statefulset.yaml +++ /dev/null @@ -1,216 +0,0 @@ ---- -kind: StatefulSet -apiVersion: {{ include "common.capabilities.statefulset.apiVersion" . }} -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.statefulset" . | nindent 4 }} -spec: - replicas: {{ .Values.global.replicaCount }} - podManagementPolicy: "Parallel" - selector: - matchLabels: - {{- include "common.labels.matchLabels" . | nindent 6 }} - serviceName: {{ include "common.names.fullname" . }} - template: - metadata: - labels: - {{- include "common.labels.matchLabels" . | nindent 8 }} - spec: - {{- with (concat .Values.imagePullSecrets .Values.global.imagePullSecrets) }} - imagePullSecrets: - {{- toYaml . | nindent 8 }} - {{- end }} - {{- with .Values.nodeSelector }} - nodeSelector: - {{- toYaml . | nindent 8 }} - {{- end }} - {{- with .Values.affinity }} - affinity: - {{- toYaml . | nindent 8 }} - {{- end }} - {{- with .Values.tolerations }} - tolerations: - {{- toYaml . | nindent 8 }} - {{- end }} - {{- if .Values.terminationGracePeriodSeconds }} - terminationGracePeriodSeconds: {{ .Values.terminationGracePeriodSeconds }} - {{- end }} - serviceAccountName: {{ include "common.names.serviceAccountName" . }} - priorityClassName: {{ .Values.priorityClassName | quote }} - securityContext: - {{- toYaml .Values.securityContext | nindent 8 }} - initContainers: - - name: init - image: "{{ .Values.initImage.repository }}:{{ .Values.initImage.tag }}" - imagePullPolicy: {{ .Values.initImage.pullPolicy }} - securityContext: - runAsNonRoot: false - runAsUser: 0 - env: - - name: POD_IP - valueFrom: - fieldRef: - fieldPath: status.podIP - - name: POD_NAME - valueFrom: - fieldRef: - fieldPath: metadata.name - - name: POD_NAMESPACE - valueFrom: - fieldRef: - fieldPath: metadata.namespace - - name: NODE_NAME - valueFrom: - fieldRef: - fieldPath: spec.nodeName - command: - - sh - - -c - - > - echo "Namespace: ${POD_NAMESPACE} Pod: ${POD_NAME}"; - {{- if .Values.p2pNodePort.enabled }} - {{- if eq .Values.p2pNodePort.type "LoadBalancer" }} - until [ -n "$(kubectl -n ${POD_NAMESPACE} get svc/${POD_NAME} -o jsonpath='{.status.loadBalancer.ingress[0].ip}')" ]; do echo "Waiting for load balancer gets an IP" && sleep 10; done; - export EXTERNAL_PORT=$(kubectl -n ${POD_NAMESPACE} get services -l "pod in (${POD_NAME}), type in (p2p)" -o jsonpath='{.items[0].spec.ports[0].nodePort}'); - export EXTERNAL_IP=$(kubectl -n ${POD_NAMESPACE} get svc/${POD_NAME} -o jsonpath='{.status.loadBalancer.ingress[0].ip}'); - {{- else }} - export EXTERNAL_PORT=$(kubectl get services -l "pod in (${POD_NAME}), type in (p2p)" -o jsonpath='{.items[0].spec.ports[0].nodePort}'); - export EXTERNAL_IP=$(kubectl get nodes "${NODE_NAME}" -o jsonpath='{.status.addresses[?(@.type=="ExternalIP")].address}'); - {{- end }} - echo "BESU_P2P_HOST=$EXTERNAL_IP" > /env/init; - echo "BESU_P2P_PORT=$EXTERNAL_PORT" >> /env/init; - {{- else }} - echo "BESU_P2P_HOST=$(POD_IP)" > /env/init; - echo "BESU_P2P_PORT={{ include "besu.p2pPort" . }}" >> /env/init; - {{- end }} - cat /env/init; - {{- if and .Values.persistence.enabled .Values.initChownData }} - mkdir -p /data && chown -R {{ .Values.securityContext.runAsUser }}:{{ .Values.securityContext.runAsUser }} /data; - {{- end }} - volumeMounts: - - name: env - mountPath: /env - - name: data - mountPath: /data - containers: - - name: {{ .Chart.Name }} - image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}" - imagePullPolicy: {{ .Values.image.pullPolicy }} - command: - - sh - - -ac - - > - . /env/init; - exec /opt/besu/bin/besu - --network={{ .Values.global.network }} - --data-path=/data - --sync-mode={{ .Values.syncMode }} - --p2p-enabled=true - --host-allowlist={{ .Values.restApi.hostAllowList | join "," }} - {{- if .Values.restApi.enabled }} - --rpc-http-enabled={{ .Values.restApi.enabled }} - --rpc-http-host={{ .Values.restApi.host }} - --rpc-http-port={{ .Values.restApi.port }} - --rpc-http-cors-origins={{ .Values.restApi.corsOrigins | join "," }} - {{- end }} - {{- if .Values.engineRpc.enabled }} - --engine-rpc-enabled={{ .Values.engineRpc.enabled }} - --engine-host-allowlist={{ .Values.engineRpc.hostAllowList }} - --engine-jwt-secret={{ .Values.global.JWTSecret }} - --engine-rpc-port={{ .Values.engineRpc.port | join "," }} - {{- end }} - {{- if .Values.global.metrics.enabled }} - --metrics-enabled={{ .Values.global.metrics.enabled }} - --metrics-host={{ .Values.metrics.host }} - --metrics-port={{ .Values.metrics.port }} - {{- end }} - {{- range .Values.extraFlags }} - {{ . | quote }} - {{- end }} - {{- if or .Values.restApi.enabled .Values.global.metrics.enabled }} - ports: - {{- if .Values.restApi.enabled }} - - name: {{ .Values.restApi.portName }} - containerPort: {{ .Values.restApi.port }} - protocol: TCP - {{- end }} - {{- if .Values.engineRpc.enabled }} - - name: {{ .Values.engineRpc.portName }} - containerPort: {{ .Values.engineRpc.port }} - protocol: TCP - {{- end }} - {{- if .Values.global.metrics.enabled }} - - name: metrics - containerPort: {{ .Values.metrics.port }} - protocol: TCP - {{- end }} - {{- if .Values.p2pNodePort.enabled }} - - name: p2p-tcp - containerPort: {{ include "besu.p2pPort" . }} - protocol: TCP - - name: p2p-udp - containerPort: {{ include "besu.p2pPort" . }} - protocol: UDP - {{- end }} - {{- end }} - volumeMounts: - - name: data - mountPath: /data - - name: jwtsecret - mountPath: /secret - readOnly: true - - name: env - mountPath: /env - resources: - {{- toYaml .Values.resources | nindent 12 }} - {{- if or .Values.global.livenessProbe.enabled .Values.livenessProbe.enabled }} - livenessProbe: - initialDelaySeconds: {{ .Values.livenessProbe.initialDelaySeconds }} - timeoutSeconds: {{ .Values.livenessProbe.timeoutSeconds }} - periodSeconds: {{ .Values.livenessProbe.periodSeconds }} - failureThreshold: {{ .Values.livenessProbe.failureThreshold }} - successThreshold: {{ .Values.livenessProbe.successThreshold }} - httpGet: - path: /liveness - port: {{ .Values.restApi.portName }} - scheme: HTTP - {{- end }} - {{- if or .Values.global.readinessProbe.enabled .Values.readinessProbe.enabled }} - readinessProbe: - initialDelaySeconds: {{ .Values.readinessProbe.initialDelaySeconds }} - timeoutSeconds: {{ .Values.readinessProbe.timeoutSeconds }} - periodSeconds: {{ .Values.readinessProbe.periodSeconds }} - failureThreshold: {{ .Values.readinessProbe.failureThreshold }} - successThreshold: {{ .Values.readinessProbe.successThreshold }} - httpGet: - path: /readiness?minPeers=15&maxBlocksBehind=10 - port: {{ .Values.restApi.portName }} - scheme: HTTP - {{- end }} - volumes: - - name: jwtsecret - secret: - secretName: {{ include "common.names.fullname" . }} - - name: env - emptyDir: {} - {{- if (not .Values.persistence.enabled) }} - - name: data - emptyDir: {} - {{- else }} - volumeClaimTemplates: - - metadata: - name: data - labels: - {{- include "common.labels.statefulset" . | nindent 10 }} - {{- with .Values.persistence.annotations }} - annotations: - {{ toYaml . | nindent 10 | trim }} - {{- end }} - spec: - accessModes: {{ .Values.persistence.accessModes }} - storageClassName: {{ .Values.persistence.storageClassName }} - resources: - requests: - storage: {{ .Values.persistence.size | quote }} - {{- end }} diff --git a/charts/besu/templates/tests/test-connection.yaml b/charts/besu/templates/tests/test-connection.yaml deleted file mode 100644 index 9a90c3fe5..000000000 --- a/charts/besu/templates/tests/test-connection.yaml +++ /dev/null @@ -1,17 +0,0 @@ -{{ if .Values.restApi.enabled }} -apiVersion: v1 -kind: Pod -metadata: - name: "{{ include "common.names.fullname" . }}-test-connection" - labels: - {{- include "common.labels.standard" . | nindent 4 }} - annotations: - "helm.sh/hook": test -spec: - containers: - - name: wget - image: busybox - command: ['wget'] - args: ['{{ include "common.names.fullname" . }}:{{ .Values.restApi.port }}'] - restartPolicy: Never -{{ end }} diff --git a/charts/besu/templates/validate.yaml b/charts/besu/templates/validate.yaml deleted file mode 100644 index 4322a60d4..000000000 --- a/charts/besu/templates/validate.yaml +++ /dev/null @@ -1,3 +0,0 @@ -{{- if not .Values.global.JWTSecret }} -{{- fail ".Values.global.JWTSecret is required" }} -{{- end }} diff --git a/charts/besu/values.yaml b/charts/besu/values.yaml deleted file mode 100644 index 68f8c6fac..000000000 --- a/charts/besu/values.yaml +++ /dev/null @@ -1,379 +0,0 @@ -# Default values for besu. -# This is a YAML-formatted file. -# Declare variables to be passed into your templates. - -global: - replicaCount: 1 - - ## Eth2 network ID - ## - network: mainnet - - ## JSON Web Token (JWT) authentication is used to secure the communication - ## between the beacon node and execution client. You can generate a JWT using - ## a command line tool, for example: - ## openssl rand -hex 32 > token.txt - ## - JWTSecret: "" - - ## Server endpoints for an execution layer jwt authenticated HTTP JSON-RPC connection. - ## Uses the same endpoint to populate the deposit cache. - ## A separate Statefulset will be created for each specified address - ## - executionEndpoints: [] - - ## Credentials to fetch images from private registry - ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/ - ## - imagePullSecrets: [] - - ## Service account - ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ - ## Additional settings could be made in non-global section. - ## - serviceAccount: - # Specifies whether a service account should be created - create: true - - ## RBAC configuration. - ## ref: https://kubernetes.io/docs/reference/access-authn-authz/rbac/ - ## Additional settings could be made in non-global section. - ## - rbac: - ## Specifies whether RBAC resources are to be created - ## - create: true - - ## Monitoring - ## Additional settings could be made in non-global section. - ## - metrics: - ## Whether to enable metrics collection or not - ## - enabled: true - - ## Prometheus Service Monitor - ## ref: https://github.com/coreos/prometheus-operator - ## https://github.com/coreos/prometheus-operator/blob/master/Documentation/api.md#endpoint - ## - serviceMonitor: - ## Create ServiceMonitor resource(s) for scraping metrics using PrometheusOperator - ## - enabled: false - - ## Custom PrometheusRule to be defined - ## ref: https://github.com/coreos/prometheus-operator#customresourcedefinitions - ## - prometheusRule: - ## Create a custom prometheusRule Resource for scraping metrics using PrometheusOperator - ## - enabled: false - - ## Configure liveness and readiness probes - ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/ - ## NB! readinessProbe and livenessProbe must be disabled before fully synced - ## Additional settings could be made in non-global section. - ## - livenessProbe: - enabled: true - - readinessProbe: - enabled: true - -## Init image is used to chown data volume, initialise genesis, etc. -## -initImage: - repository: "bitnami/kubectl" - tag: "1.24" - pullPolicy: IfNotPresent - -## Besu image -## -image: - repository: hyperledger/besu - pullPolicy: IfNotPresent - # Overrides the image tag whose default is the chart appVersion. - tag: "22.7.6" - -imagePullSecrets: [] -nameOverride: "" -fullnameOverride: "" - -serviceAccount: - # Annotations to add to the service account - annotations: {} - # The name of the service account to use. - # If not set and create is true, a name is generated using the fullname template - name: "" - -## Additional labels for all resources -## -additionalLabels: - client-type: "execution" - -## Termination Grace Period -## ref: https://kubernetes.io/docs/tasks/run-application/force-delete-stateful-set-pod/#delete-pods -## -terminationGracePeriodSeconds: 300 - -## Pod Security Context -## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/ -## -securityContext: - fsGroup: 1000 - runAsUser: 1000 - -## RBAC configuration. -## ref: https://kubernetes.io/docs/reference/access-authn-authz/rbac/ -## -rbac: - # The name of the cluster role to use. - # If not set and create is true, a name is generated using the fullname template - name: "" - ## Required ClusterRole rules - ## - clusterRules: - ## Required to obtain the nodes external IP - ## - - apiGroups: [""] - resources: - - "nodes" - verbs: - - "get" - - "list" - - "watch" - ## Required Role rules - ## - rules: - ## Required to get information about the serices nodePort. - ## - - apiGroups: [""] - resources: - - "services" - verbs: - - "get" - - "list" - - "watch" - -service: - type: ClusterIP - -## Defines whether the service must be headless -## -svcHeadless: true - -## Configure session affinity for validator clients to hit the same beacon node -## for the period specified in `timeoutSeconds` -## ref: https://kubernetes.io/docs/concepts/services-networking/service/#proxy-mode-userspace -## -sessionAffinity: - # Whether to enable session affinity or not - enabled: false - # The session duration in seconds - timeoutSeconds: 86400 - -## When p2pNodePort is enabled, your P2P port will be exposed via service type NodePort/LoadBalancer. -## This will generate a service for each replica, with a port binding via NodePort/LoadBalancer. -## This is useful if you want to expose and announce your node to the Internet. -## -p2pNodePort: - ## @param p2pNodePort.enabled Expose P2P port via NodePort - ## - enabled: false - ## @param p2pNodePort.annotations - ## - annotations: {} - ## @param p2pNodePort.type - ## Options: NodePort, LoadBalancer - type: NodePort - ## @param p2pNodePort.startAt The ports allocation will start from this value - ## - startAt: 31500 - ## @param p2pNodePort.replicaToNodePort Overwrite a port for specific replicas - ## @default -- See `values.yaml` for example - replicaToNodePort: {} - # "0": 32345 - # "3": 32348 - -resources: {} - # We usually recommend not to specify default resources and to leave this as a conscious - # choice for the user. This also increases chances charts run on environments with little - # resources, such as Minikube. If you do want to specify resources, uncomment the following - # lines, adjust them as necessary, and remove the curly braces after 'resources:'. - # limits: - # cpu: 100m - # memory: 128Mi - # requests: - # cpu: 100m - # memory: 128Mi - -## Used to assign priority to pods -## ref: https://kubernetes.io/docs/concepts/configuration/pod-priority-preemption/ -## -priorityClassName: "" - -## Enable pod disruption budget -## ref: https://kubernetes.io/docs/tasks/run-application/configure-pdb -## -podDisruptionBudget: - enabled: true - maxUnavailable: 1 - -## Node labels for pod assignment -## ref: https://kubernetes.io/docs/user-guide/node-selection/ -## -nodeSelector: {} - -## Tolerations for pod assignment -## ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/ -## -tolerations: {} - -## Affinity for pod assignment -## ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity -## -## Example: -## affinity: -## podAntiAffinity: -## requiredDuringSchedulingIgnoredDuringExecution: -## - labelSelector: -## matchExpressions: -## - key: app.kubernetes.io/name -## operator: In -## values: -## - besu -## topologyKey: kubernetes.io/hostname -## -affinity: {} - -## Configure liveness and readiness probes -## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/ -## NB! readinessProbe and livenessProbe must be disabled before genesis -## -livenessProbe: - initialDelaySeconds: 60 - timeoutSeconds: 3 - periodSeconds: 30 - failureThreshold: 3 - successThreshold: 1 - -readinessProbe: - initialDelaySeconds: 60 - timeoutSeconds: 3 - periodSeconds: 30 - failureThreshold: 30 - successThreshold: 2 - -## If false, data ownership will not be reset at startup -## This allows the node to be run with an arbitrary user -## -initChownData: true - -## Whether or not to allocate persistent volume disk for the data directory. -## In case of pod failure, the pod data directory will still persist. -## -persistence: - enabled: true - storageClassName: "" - accessModes: - - ReadWriteOnce - size: 300Gi - annotations: {} - - -## Besu Settings - -## Sync Mode -## ref: https://besu.hyperledger.org/en/stable/public-networks/how-to/connect/sync-node -## -syncMode: "X_SNAP" - -## Extra flags for besu node -## -extraFlags: [] - -# Engine RPC Settings -engineRpc: - # Enables Engine RPC - enabled: true - # Comma-separated list of hostnames to allow, or * - # to allow any host - hostAllowList: - - "*" - # Port number of Engine RPC - port: "8551" - # Port name for the respective k8s service - portName: "engine-api" - # Comma separated list of origins to allow, or * to - # allow any origin - corsOrigins: - - "*" - -# Rest API Settings -restApi: - # Enables Beacon Rest API - enabled: true - # Comma-separated list of hostnames to allow, or * - # to allow any host - hostAllowList: - - "*" - # Host of Beacon Rest API - host: "0.0.0.0" - # Port number of Beacon Rest API - port: "5051" - # Port name for the respective k8s service - portName: "rest-api" - # Comma separated list of origins to allow, or * to - # allow any origin - corsOrigins: - - "*" - -## Monitoring -## -metrics: - # Metrics network host to expose metrics for Prometheus - host: "0.0.0.0" - - ## Metrics port to expose metrics for Prometheus - ## - port: 8008 - - ## Prometheus Service Monitor - ## ref: https://github.com/coreos/prometheus-operator - ## https://github.com/coreos/prometheus-operator/blob/master/Documentation/api.md#endpoint - ## - serviceMonitor: - ## The namespace in which the ServiceMonitor will be created - ## - namespace: "" - ## The interval at which metrics should be scraped - ## - interval: 30s - ## The timeout after which the scrape is ended - ## - scrapeTimeout: "" - ## Metrics RelabelConfigs to apply to samples before scraping. - ## - relabellings: [] - ## Metrics RelabelConfigs to apply to samples before ingestion. - ## - metricRelabelings: [] - ## Specify honorLabels parameter to add the scrape endpoint - ## - honorLabels: false - ## Additional labels that can be used so ServiceMonitor resource(s) can be discovered by Prometheus - ## - additionalLabels: {} - ## Custom PrometheusRule to be defined - ## ref: https://github.com/coreos/prometheus-operator#customresourcedefinitions - ## - prometheusRule: - ## The namespace in which the prometheusRule will be created - ## - namespace: "" - ## Additional labels for the prometheusRule - ## - additionalLabels: {} - ## Custom Prometheus rules - ## - rules: [] diff --git a/charts/prysm/.helmignore b/charts/clickhouse/.helmignore similarity index 94% rename from charts/prysm/.helmignore rename to charts/clickhouse/.helmignore index 0e8a0eb36..fb56657ab 100644 --- a/charts/prysm/.helmignore +++ b/charts/clickhouse/.helmignore @@ -14,10 +14,10 @@ *.swp *.bak *.tmp -*.orig *~ # Various IDEs .project .idea/ *.tmproj -.vscode/ +# img folder +img/ diff --git a/charts/clickhouse/Chart.lock b/charts/clickhouse/Chart.lock new file mode 100644 index 000000000..617994105 --- /dev/null +++ b/charts/clickhouse/Chart.lock @@ -0,0 +1,9 @@ +dependencies: +- name: zookeeper + repository: oci://registry-1.docker.io/bitnamicharts + version: 12.12.1 +- name: common + repository: oci://registry-1.docker.io/bitnamicharts + version: 2.19.0 +digest: sha256:92742d7cab086ee69ec5087e9ed723cc5387b8f434b6e503f04e57bd1c3e8040 +generated: "2024-03-15T10:52:50.842593241Z" diff --git a/charts/clickhouse/Chart.yaml b/charts/clickhouse/Chart.yaml new file mode 100644 index 000000000..28443608d --- /dev/null +++ b/charts/clickhouse/Chart.yaml @@ -0,0 +1,38 @@ +# Copyright VMware, Inc. +# SPDX-License-Identifier: APACHE-2.0 + +annotations: + category: Database + licenses: Apache-2.0 + images: | + - name: clickhouse + image: docker.io/bitnami/clickhouse:24.2.2-debian-12-r0 + - name: os-shell + image: docker.io/bitnami/os-shell:12-debian-12-r16 + - name: zookeeper + image: docker.io/bitnami/zookeeper:3.8.4-debian-12-r0 +apiVersion: v2 +appVersion: 24.2.2 +dependencies: +- condition: zookeeper.enabled + name: zookeeper + repository: oci://registry-1.docker.io/bitnamicharts + version: 12.x.x +- name: common + repository: oci://registry-1.docker.io/bitnamicharts + tags: + - bitnami-common + version: 2.x.x +description: ClickHouse is an open-source column-oriented OLAP database management system. Use it to boost your database performance while providing linear scalability and hardware efficiency. +home: https://bitnami.com +icon: https://bitnami.com/assets/stacks/clickhouse/img/clickhouse-stack-220x234.png +keywords: +- database +- sharding +maintainers: +- name: VMware, Inc. + url: https://github.com/bitnami/charts +name: clickhouse +sources: +- https://github.com/bitnami/charts/tree/main/bitnami/clickhouse +version: 5.3.1 diff --git a/charts/clickhouse/README.md b/charts/clickhouse/README.md new file mode 100644 index 000000000..caecae708 --- /dev/null +++ b/charts/clickhouse/README.md @@ -0,0 +1,614 @@ + + +# Bitnami package for ClickHouse + +ClickHouse is an open-source column-oriented OLAP database management system. Use it to boost your database performance while providing linear scalability and hardware efficiency. + +[Overview of ClickHouse](https://clickhouse.com/) + +Trademarks: This software listing is packaged by Bitnami. The respective trademarks mentioned in the offering are owned by the respective companies, and use of them does not imply any affiliation or endorsement. + +## TL;DR + +```console +helm install my-release oci://registry-1.docker.io/bitnamicharts/clickhouse +``` + +Looking to use ClickHouse in production? Try [VMware Tanzu Application Catalog](https://bitnami.com/enterprise), the enterprise edition of Bitnami Application Catalog. + +## Introduction + +Bitnami charts for Helm are carefully engineered, actively maintained and are the quickest and easiest way to deploy containers on a Kubernetes cluster that are ready to handle production workloads. + +This chart bootstraps a [ClickHouse](https://github.com/clickhouse/clickhouse) Deployment in a [Kubernetes](https://kubernetes.io) cluster using the [Helm](https://helm.sh) package manager. + +Bitnami charts can be used with [Kubeapps](https://kubeapps.dev/) for deployment and management of Helm Charts in clusters. + +## Prerequisites + +- Kubernetes 1.23+ +- Helm 3.8.0+ +- PV provisioner support in the underlying infrastructure +- ReadWriteMany volumes for deployment scaling + +> If you are using Kubernetes 1.18, the following code needs to be commented out. +> seccompProfile: +> type: "RuntimeDefault" + +## Installing the Chart + +To install the chart with the release name `my-release`: + +```console +helm install my-release oci://REGISTRY_NAME/REPOSITORY_NAME/clickhouse +``` + +> Note: You need to substitute the placeholders `REGISTRY_NAME` and `REPOSITORY_NAME` with a reference to your Helm chart registry and repository. For example, in the case of Bitnami, you need to use `REGISTRY_NAME=registry-1.docker.io` and `REPOSITORY_NAME=bitnamicharts`. + +The command deploys ClickHouse on the Kubernetes cluster in the default configuration. The [Parameters](#parameters) section lists the parameters that can be configured during installation. + +> **Tip**: List all releases using `helm list` + +## Configuration and installation details + +### Resource requests and limits + +Bitnami charts allow setting resource requests and limits for all containers inside the chart deployment. These are inside the `resources` value (check parameter table). Setting requests is essential for production workloads and these should be adapted to your specific use case. + +To make this process easier, the chart contains the `resourcesPreset` values, which automatically sets the `resources` section according to different presets. Check these presets in [the bitnami/common chart](https://github.com/bitnami/charts/blob/main/bitnami/common/templates/_resources.tpl#L15). However, in production workloads using `resourcePreset` is discouraged as it may not fully adapt to your specific needs. Find more information on container resource management in the [official Kubernetes documentation](https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/). + +### [Rolling VS Immutable tags](https://docs.bitnami.com/tutorials/understand-rolling-tags-containers) + +It is strongly recommended to use immutable tags in a production environment. This ensures your deployment does not change automatically if the same tag is updated with a different image. + +Bitnami will release a new chart updating its containers if a new version of the main container, significant changes, or critical vulnerabilities exist. + +### ClickHouse keeper support + +You can set `keeper.enabled` to use ClickHouse keeper. If `keeper.enabled=true`, Zookeeper settings will not be ignore. + +### External Zookeeper support + +You may want to have ClickHouse connect to an external zookeeper rather than installing one inside your cluster. Typical reasons for this are to use a managed database service, or to share a common database server for all your applications. To achieve this, the chart allows you to specify credentials for an external database with the [`externalZookeeper` parameter](#parameters). You should also disable the Zookeeper installation with the `zookeeper.enabled` option. Here is an example: + +```console +zookeper.enabled=false +externalZookeeper.host=myexternalhost +externalZookeeper.user=myuser +externalZookeeper.password=mypassword +externalZookeeper.database=mydatabase +externalZookeeper.port=3306 +``` + +### Ingress without TLS + +For using ingress (example without TLS): + +```yaml +ingress: + ## If true, ClickHouse server Ingress will be created + ## + enabled: true + + ## ClickHouse server Ingress annotations + ## + annotations: {} + # kubernetes.io/ingress.class: nginx + # kubernetes.io/tls-acme: 'true' + + ## ClickHouse server Ingress hostnames + ## Must be provided if Ingress is enabled + ## + hosts: + - clickhouse.domain.com +``` + +### Ingress TLS + +If your cluster allows automatic creation/retrieval of TLS certificates (e.g. [kube-lego](https://github.com/jetstack/kube-lego)), please refer to the documentation for that mechanism. + +To manually configure TLS, first create/retrieve a key & certificate pair for the address(es) you wish to protect. Then create a TLS secret (named `clickhouse-server-tls` in this example) in the namespace. Include the secret's name, along with the desired hostnames, in the Ingress TLS section of your custom `values.yaml` file: + +```yaml +ingress: + ## If true, ClickHouse server Ingress will be created + ## + enabled: true + + ## ClickHouse server Ingress annotations + ## + annotations: {} + # kubernetes.io/ingress.class: nginx + # kubernetes.io/tls-acme: 'true' + + ## ClickHouse server Ingress hostnames + ## Must be provided if Ingress is enabled + ## + hosts: + - clickhouse.domain.com + + ## ClickHouse server Ingress TLS configuration + ## Secrets must be manually created in the namespace + ## + tls: + - secretName: clickhouse-server-tls + hosts: + - clickhouse.domain.com +``` + +### TLS secrets + +This chart facilitates the creation of TLS secrets for use with the Ingress controller (although this is not mandatory). There are several common use cases: + +- Generate certificate secrets based on chart parameters. +- Enable externally generated certificates. +- Manage application certificates via an external service (like [cert-manager](https://github.com/jetstack/cert-manager/)). +- Create self-signed certificates within the chart (if supported). + +In the first two cases, a certificate and a key are needed. Files are expected in `.pem` format. + +Here is an example of a certificate file: + +> NOTE: There may be more than one certificate if there is a certificate chain. + +```text +-----BEGIN CERTIFICATE----- +MIID6TCCAtGgAwIBAgIJAIaCwivkeB5EMA0GCSqGSIb3DQEBCwUAMFYxCzAJBgNV +... +jScrvkiBO65F46KioCL9h5tDvomdU1aqpI/CBzhvZn1c0ZTf87tGQR8NK7v7 +-----END CERTIFICATE----- +``` + +Here is an example of a certificate key: + +```text +-----BEGIN RSA PRIVATE KEY----- +MIIEogIBAAKCAQEAvLYcyu8f3skuRyUgeeNpeDvYBCDcgq+LsWap6zbX5f8oLqp4 +... +wrj2wDbCDCFmfqnSJ+dKI3vFLlEz44sAV8jX/kd4Y6ZTQhlLbYc= +-----END RSA PRIVATE KEY----- +``` + +- If using Helm to manage the certificates based on the parameters, copy these values into the `certificate` and `key` values for a given `*.ingress.secrets` entry. +- If managing TLS secrets separately, it is necessary to create a TLS secret with name `INGRESS_HOSTNAME-tls` (where INGRESS_HOSTNAME is a placeholder to be replaced with the hostname you set using the `*.ingress.hostname` parameter). +- If your cluster has a [cert-manager](https://github.com/jetstack/cert-manager) add-on to automate the management and issuance of TLS certificates, add to `*.ingress.annotations` the [corresponding ones](https://cert-manager.io/docs/usage/ingress/#supported-annotations) for cert-manager. +- If using self-signed certificates created by Helm, set both `*.ingress.tls` and `*.ingress.selfSigned` to `true`. + +### Additional environment variables + +In case you want to add extra environment variables (useful for advanced operations like custom init scripts), you can use the `extraEnvVars` property. + +```yaml +clickhouse: + extraEnvVars: + - name: LOG_LEVEL + value: error +``` + +Alternatively, you can use a ConfigMap or a Secret with the environment variables. To do so, use the `extraEnvVarsCM` or the `extraEnvVarsSecret` values. + +### Sidecars + +If additional containers are needed in the same pod as ClickHouse (such as additional metrics or logging exporters), they can be defined using the `sidecars` parameter. + +```yaml +sidecars: +- name: your-image-name + image: your-image + imagePullPolicy: Always + ports: + - name: portname + containerPort: 1234 +``` + +If these sidecars export extra ports, extra port definitions can be added using the `service.extraPorts` parameter (where available), as shown in the example below: + +```yaml +service: + extraPorts: + - name: extraPort + port: 11311 + targetPort: 11311 +``` + +> NOTE: This Helm chart already includes sidecar containers for the Prometheus exporters (where applicable). These can be activated by adding the `--enable-metrics=true` parameter at deployment time. The `sidecars` parameter should therefore only be used for any extra sidecar containers. + +If additional init containers are needed in the same pod, they can be defined using the `initContainers` parameter. Here is an example: + +```yaml +initContainers: + - name: your-image-name + image: your-image + imagePullPolicy: Always + ports: + - name: portname + containerPort: 1234 +``` + +Learn more about [sidecar containers](https://kubernetes.io/docs/concepts/workloads/pods/) and [init containers](https://kubernetes.io/docs/concepts/workloads/pods/init-containers/). + +### Using custom scripts + +For advanced operations, the Bitnami ClickHouse chart allows using custom init and start scripts that will be mounted in `/docker-entrypoint.initdb.d` and `/docker-entrypoint.startdb.d` . The `init` scripts will be run on the first boot whereas the `start` scripts will be run on every container start. For adding the scripts directly as values use the `initdbScripts` and `startdbScripts` values. For using Secrets use the `initdbScriptsSecret` and `startdbScriptsSecret`. + +```yaml +initdbScriptsSecret: init-scripts-secret +startdbScriptsSecret: start-scripts-secret +``` + +### Pod affinity + +This chart allows you to set your custom affinity using the `affinity` parameter. Find more information about Pod affinity in the [kubernetes documentation](https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity). + +As an alternative, use one of the preset configurations for pod affinity, pod anti-affinity, and node affinity available at the [bitnami/common](https://github.com/bitnami/charts/tree/main/bitnami/common#affinities) chart. To do so, set the `podAffinityPreset`, `podAntiAffinityPreset`, or `nodeAffinityPreset` parameters. + +## Persistence + +The [Bitnami ClickHouse](https://github.com/bitnami/containers/tree/main/bitnami/clickhouse) image stores the ClickHouse data and configurations at the `/bitnami` path of the container. Persistent Volume Claims are used to keep the data across deployments. This is known to work in GCE, AWS, and minikube. + +## Parameters + +### Global parameters + +| Name | Description | Value | +| ----------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------- | +| `global.imageRegistry` | Global Docker image registry | `""` | +| `global.imagePullSecrets` | Global Docker registry secret names as an array | `[]` | +| `global.storageClass` | Global StorageClass for Persistent Volume(s) | `""` | +| `global.compatibility.openshift.adaptSecurityContext` | Adapt the securityContext sections of the deployment to make them compatible with Openshift restricted-v2 SCC: remove runAsUser, runAsGroup and fsGroup and let the platform use their allowed default IDs. Possible values: auto (apply if the detected running cluster is Openshift), force (perform the adaptation always), disabled (do not perform adaptation) | `disabled` | + +### Common parameters + +| Name | Description | Value | +| ------------------------ | --------------------------------------------------------------------------------------- | --------------- | +| `kubeVersion` | Override Kubernetes version | `""` | +| `nameOverride` | String to partially override common.names.name | `""` | +| `fullnameOverride` | String to fully override common.names.fullname | `""` | +| `namespaceOverride` | String to fully override common.names.namespace | `""` | +| `commonLabels` | Labels to add to all deployed objects | `{}` | +| `commonAnnotations` | Annotations to add to all deployed objects | `{}` | +| `clusterDomain` | Kubernetes cluster domain name | `cluster.local` | +| `extraDeploy` | Array of extra objects to deploy with the release | `[]` | +| `diagnosticMode.enabled` | Enable diagnostic mode (all probes will be disabled and the command will be overridden) | `false` | +| `diagnosticMode.command` | Command to override all containers in the deployment | `["sleep"]` | +| `diagnosticMode.args` | Args to override all containers in the deployment | `["infinity"]` | + +### ClickHouse Parameters + +| Name | Description | Value | +| --------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------- | +| `image.registry` | ClickHouse image registry | `REGISTRY_NAME` | +| `image.repository` | ClickHouse image repository | `REPOSITORY_NAME/clickhouse` | +| `image.digest` | ClickHouse image digest in the way sha256:aa.... Please note this parameter, if set, will override the tag | `""` | +| `image.pullPolicy` | ClickHouse image pull policy | `IfNotPresent` | +| `image.pullSecrets` | ClickHouse image pull secrets | `[]` | +| `image.debug` | Enable ClickHouse image debug mode | `false` | +| `shards` | Number of ClickHouse shards to deploy | `2` | +| `replicaCount` | Number of ClickHouse replicas per shard to deploy | `3` | +| `distributeReplicasByZone` | Schedules replicas of the same shard to different availability zones | `false` | +| `containerPorts.http` | ClickHouse HTTP container port | `8123` | +| `containerPorts.https` | ClickHouse HTTPS container port | `8443` | +| `containerPorts.tcp` | ClickHouse TCP container port | `9000` | +| `containerPorts.tcpSecure` | ClickHouse TCP (secure) container port | `9440` | +| `containerPorts.keeper` | ClickHouse keeper TCP container port | `2181` | +| `containerPorts.keeperSecure` | ClickHouse keeper TCP (secure) container port | `3181` | +| `containerPorts.keeperInter` | ClickHouse keeper interserver TCP container port | `9444` | +| `containerPorts.mysql` | ClickHouse MySQL container port | `9004` | +| `containerPorts.postgresql` | ClickHouse PostgreSQL container port | `9005` | +| `containerPorts.interserver` | ClickHouse Interserver container port | `9009` | +| `containerPorts.metrics` | ClickHouse metrics container port | `8001` | +| `livenessProbe.enabled` | Enable livenessProbe on ClickHouse containers | `true` | +| `livenessProbe.initialDelaySeconds` | Initial delay seconds for livenessProbe | `10` | +| `livenessProbe.periodSeconds` | Period seconds for livenessProbe | `10` | +| `livenessProbe.timeoutSeconds` | Timeout seconds for livenessProbe | `1` | +| `livenessProbe.failureThreshold` | Failure threshold for livenessProbe | `3` | +| `livenessProbe.successThreshold` | Success threshold for livenessProbe | `1` | +| `readinessProbe.enabled` | Enable readinessProbe on ClickHouse containers | `true` | +| `readinessProbe.initialDelaySeconds` | Initial delay seconds for readinessProbe | `10` | +| `readinessProbe.periodSeconds` | Period seconds for readinessProbe | `10` | +| `readinessProbe.timeoutSeconds` | Timeout seconds for readinessProbe | `1` | +| `readinessProbe.failureThreshold` | Failure threshold for readinessProbe | `3` | +| `readinessProbe.successThreshold` | Success threshold for readinessProbe | `1` | +| `startupProbe.enabled` | Enable startupProbe on ClickHouse containers | `false` | +| `startupProbe.initialDelaySeconds` | Initial delay seconds for startupProbe | `10` | +| `startupProbe.periodSeconds` | Period seconds for startupProbe | `10` | +| `startupProbe.timeoutSeconds` | Timeout seconds for startupProbe | `1` | +| `startupProbe.failureThreshold` | Failure threshold for startupProbe | `3` | +| `startupProbe.successThreshold` | Success threshold for startupProbe | `1` | +| `customLivenessProbe` | Custom livenessProbe that overrides the default one | `{}` | +| `customReadinessProbe` | Custom readinessProbe that overrides the default one | `{}` | +| `customStartupProbe` | Custom startupProbe that overrides the default one | `{}` | +| `resourcesPreset` | Set container resources according to one common preset (allowed values: none, nano, small, medium, large, xlarge, 2xlarge). This is ignored if resources is set (resources is recommended for production). | `none` | +| `resources` | Set container requests and limits for different resources like CPU or memory (essential for production workloads) | `{}` | +| `podSecurityContext.enabled` | Enabled ClickHouse pods' Security Context | `true` | +| `podSecurityContext.fsGroupChangePolicy` | Set filesystem group change policy | `Always` | +| `podSecurityContext.sysctls` | Set kernel settings using the sysctl interface | `[]` | +| `podSecurityContext.supplementalGroups` | Set filesystem extra groups | `[]` | +| `podSecurityContext.fsGroup` | Set ClickHouse pod's Security Context fsGroup | `1001` | +| `containerSecurityContext.enabled` | Enable containers' Security Context | `true` | +| `containerSecurityContext.seLinuxOptions` | Set SELinux options in container | `nil` | +| `containerSecurityContext.runAsUser` | Set containers' Security Context runAsUser | `1001` | +| `containerSecurityContext.runAsGroup` | Set containers' Security Context runAsGroup | `0` | +| `containerSecurityContext.runAsNonRoot` | Set containers' Security Context runAsNonRoot | `true` | +| `containerSecurityContext.readOnlyRootFilesystem` | Set read only root file system pod's | `false` | +| `containerSecurityContext.privileged` | Set contraller container's Security Context privileged | `false` | +| `containerSecurityContext.allowPrivilegeEscalation` | Set contraller container's Security Context allowPrivilegeEscalation | `false` | +| `containerSecurityContext.capabilities.drop` | List of capabilities to be droppedn | `["ALL"]` | +| `containerSecurityContext.seccompProfile.type` | Set container's Security Context seccomp profile | `RuntimeDefault` | +| `auth.username` | ClickHouse Admin username | `default` | +| `auth.password` | ClickHouse Admin password | `""` | +| `auth.existingSecret` | Name of a secret containing the Admin password | `""` | +| `auth.existingSecretKey` | Name of the key inside the existing secret | `""` | +| `logLevel` | Logging level | `information` | + +### ClickHouse keeper configuration parameters + +| Name | Description | Value | +| ------------------------------- | ------------------------------------------------------------------------------------------------------------------------ | ----------------------- | +| `keeper.enabled` | Deploy ClickHouse keeper. Support is experimental. | `false` | +| `defaultConfigurationOverrides` | Default configuration overrides (evaluated as a template) | `""` | +| `existingOverridesConfigmap` | The name of an existing ConfigMap with your custom configuration for ClickHouse | `""` | +| `extraOverrides` | Extra configuration overrides (evaluated as a template) apart from the default | `""` | +| `extraOverridesConfigmap` | The name of an existing ConfigMap with extra configuration for ClickHouse | `""` | +| `extraOverridesSecret` | The name of an existing ConfigMap with your custom configuration for ClickHouse | `""` | +| `usersExtraOverrides` | Users extra configuration overrides (evaluated as a template) apart from the default | `""` | +| `usersExtraOverridesConfigmap` | The name of an existing ConfigMap with users extra configuration for ClickHouse | `""` | +| `usersExtraOverridesSecret` | The name of an existing ConfigMap with your custom users configuration for ClickHouse | `""` | +| `initdbScripts` | Dictionary of initdb scripts | `{}` | +| `initdbScriptsSecret` | ConfigMap with the initdb scripts (Note: Overrides `initdbScripts`) | `""` | +| `startdbScripts` | Dictionary of startdb scripts | `{}` | +| `startdbScriptsSecret` | ConfigMap with the startdb scripts (Note: Overrides `startdbScripts`) | `""` | +| `command` | Override default container command (useful when using custom images) | `["/scripts/setup.sh"]` | +| `args` | Override default container args (useful when using custom images) | `[]` | +| `automountServiceAccountToken` | Mount Service Account token in pod | `false` | +| `hostAliases` | ClickHouse pods host aliases | `[]` | +| `podLabels` | Extra labels for ClickHouse pods | `{}` | +| `podAnnotations` | Annotations for ClickHouse pods | `{}` | +| `podAffinityPreset` | Pod affinity preset. Ignored if `affinity` is set. Allowed values: `soft` or `hard` | `""` | +| `podAntiAffinityPreset` | Pod anti-affinity preset. Ignored if `affinity` is set. Allowed values: `soft` or `hard` | `soft` | +| `nodeAffinityPreset.type` | Node affinity preset type. Ignored if `affinity` is set. Allowed values: `soft` or `hard` | `""` | +| `nodeAffinityPreset.key` | Node label key to match. Ignored if `affinity` is set | `""` | +| `nodeAffinityPreset.values` | Node label values to match. Ignored if `affinity` is set | `[]` | +| `affinity` | Affinity for ClickHouse pods assignment | `{}` | +| `nodeSelector` | Node labels for ClickHouse pods assignment | `{}` | +| `tolerations` | Tolerations for ClickHouse pods assignment | `[]` | +| `updateStrategy.type` | ClickHouse statefulset strategy type | `RollingUpdate` | +| `podManagementPolicy` | Statefulset Pod management policy, it needs to be Parallel to be able to complete the cluster join | `Parallel` | +| `priorityClassName` | ClickHouse pods' priorityClassName | `""` | +| `topologySpreadConstraints` | Topology Spread Constraints for pod assignment spread across your cluster among failure-domains. Evaluated as a template | `[]` | +| `schedulerName` | Name of the k8s scheduler (other than default) for ClickHouse pods | `""` | +| `terminationGracePeriodSeconds` | Seconds Redmine pod needs to terminate gracefully | `""` | +| `lifecycleHooks` | for the ClickHouse container(s) to automate configuration before or after startup | `{}` | +| `extraEnvVars` | Array with extra environment variables to add to ClickHouse nodes | `[]` | +| `extraEnvVarsCM` | Name of existing ConfigMap containing extra env vars for ClickHouse nodes | `""` | +| `extraEnvVarsSecret` | Name of existing Secret containing extra env vars for ClickHouse nodes | `""` | +| `extraVolumes` | Optionally specify extra list of additional volumes for the ClickHouse pod(s) | `[]` | +| `extraVolumeMounts` | Optionally specify extra list of additional volumeMounts for the ClickHouse container(s) | `[]` | +| `extraVolumeClaimTemplates` | Optionally specify extra list of additional volumeClaimTemplates for the ClickHouse container(s) | `[]` | +| `sidecars` | Add additional sidecar containers to the ClickHouse pod(s) | `[]` | +| `initContainers` | Add additional init containers to the ClickHouse pod(s) | `[]` | +| `tls.enabled` | Enable TLS traffic support | `false` | +| `tls.autoGenerated` | Generate automatically self-signed TLS certificates | `false` | +| `tls.certificatesSecret` | Name of an existing secret that contains the certificates | `""` | +| `tls.certFilename` | Certificate filename | `""` | +| `tls.certKeyFilename` | Certificate key filename | `""` | +| `tls.certCAFilename` | CA Certificate filename | `""` | + +### Traffic Exposure Parameters + +| Name | Description | Value | +| ------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------- | ------------------------ | +| `service.type` | ClickHouse service type | `ClusterIP` | +| `service.ports.http` | ClickHouse service HTTP port | `8123` | +| `service.ports.https` | ClickHouse service HTTPS port | `443` | +| `service.ports.tcp` | ClickHouse service TCP port | `9000` | +| `service.ports.tcpSecure` | ClickHouse service TCP (secure) port | `9440` | +| `service.ports.keeper` | ClickHouse keeper TCP container port | `2181` | +| `service.ports.keeperSecure` | ClickHouse keeper TCP (secure) container port | `3181` | +| `service.ports.keeperInter` | ClickHouse keeper interserver TCP container port | `9444` | +| `service.ports.mysql` | ClickHouse service MySQL port | `9004` | +| `service.ports.postgresql` | ClickHouse service PostgreSQL port | `9005` | +| `service.ports.interserver` | ClickHouse service Interserver port | `9009` | +| `service.ports.metrics` | ClickHouse service metrics port | `8001` | +| `service.nodePorts.http` | Node port for HTTP | `""` | +| `service.nodePorts.https` | Node port for HTTPS | `""` | +| `service.nodePorts.tcp` | Node port for TCP | `""` | +| `service.nodePorts.tcpSecure` | Node port for TCP (with TLS) | `""` | +| `service.nodePorts.keeper` | ClickHouse keeper TCP container port | `""` | +| `service.nodePorts.keeperSecure` | ClickHouse keeper TCP (secure) container port | `""` | +| `service.nodePorts.keeperInter` | ClickHouse keeper interserver TCP container port | `""` | +| `service.nodePorts.mysql` | Node port for MySQL | `""` | +| `service.nodePorts.postgresql` | Node port for PostgreSQL | `""` | +| `service.nodePorts.interserver` | Node port for Interserver | `""` | +| `service.nodePorts.metrics` | Node port for metrics | `""` | +| `service.clusterIP` | ClickHouse service Cluster IP | `""` | +| `service.loadBalancerIP` | ClickHouse service Load Balancer IP | `""` | +| `service.loadBalancerSourceRanges` | ClickHouse service Load Balancer sources | `[]` | +| `service.externalTrafficPolicy` | ClickHouse service external traffic policy | `Cluster` | +| `service.annotations` | Additional custom annotations for ClickHouse service | `{}` | +| `service.extraPorts` | Extra ports to expose in ClickHouse service (normally used with the `sidecars` value) | `[]` | +| `service.sessionAffinity` | Control where client requests go, to the same pod or round-robin | `None` | +| `service.sessionAffinityConfig` | Additional settings for the sessionAffinity | `{}` | +| `service.headless.annotations` | Annotations for the headless service. | `{}` | +| `externalAccess.enabled` | Enable Kubernetes external cluster access to ClickHouse | `false` | +| `externalAccess.service.type` | Kubernetes Service type for external access. It can be NodePort, LoadBalancer or ClusterIP | `LoadBalancer` | +| `externalAccess.service.ports.http` | ClickHouse service HTTP port | `80` | +| `externalAccess.service.ports.https` | ClickHouse service HTTPS port | `443` | +| `externalAccess.service.ports.tcp` | ClickHouse service TCP port | `9000` | +| `externalAccess.service.ports.tcpSecure` | ClickHouse service TCP (secure) port | `9440` | +| `externalAccess.service.ports.keeper` | ClickHouse keeper TCP container port | `2181` | +| `externalAccess.service.ports.keeperSecure` | ClickHouse keeper TCP (secure) container port | `3181` | +| `externalAccess.service.ports.keeperInter` | ClickHouse keeper interserver TCP container port | `9444` | +| `externalAccess.service.ports.mysql` | ClickHouse service MySQL port | `9004` | +| `externalAccess.service.ports.postgresql` | ClickHouse service PostgreSQL port | `9005` | +| `externalAccess.service.ports.interserver` | ClickHouse service Interserver port | `9009` | +| `externalAccess.service.ports.metrics` | ClickHouse service metrics port | `8001` | +| `externalAccess.service.loadBalancerIPs` | Array of load balancer IPs for each ClickHouse . Length must be the same as replicaCount | `[]` | +| `externalAccess.service.loadBalancerAnnotations` | Array of load balancer annotations for each ClickHouse . Length must be the same as shards multiplied by replicaCount | `[]` | +| `externalAccess.service.loadBalancerSourceRanges` | Address(es) that are allowed when service is LoadBalancer | `[]` | +| `externalAccess.service.nodePorts.http` | Node port for HTTP | `[]` | +| `externalAccess.service.nodePorts.https` | Node port for HTTPS | `[]` | +| `externalAccess.service.nodePorts.tcp` | Node port for TCP | `[]` | +| `externalAccess.service.nodePorts.tcpSecure` | Node port for TCP (with TLS) | `[]` | +| `externalAccess.service.nodePorts.keeper` | ClickHouse keeper TCP container port | `[]` | +| `externalAccess.service.nodePorts.keeperSecure` | ClickHouse keeper TCP container port (with TLS) | `[]` | +| `externalAccess.service.nodePorts.keeperInter` | ClickHouse keeper interserver TCP container port | `[]` | +| `externalAccess.service.nodePorts.mysql` | Node port for MySQL | `[]` | +| `externalAccess.service.nodePorts.postgresql` | Node port for PostgreSQL | `[]` | +| `externalAccess.service.nodePorts.interserver` | Node port for Interserver | `[]` | +| `externalAccess.service.nodePorts.metrics` | Node port for metrics | `[]` | +| `externalAccess.service.labels` | Service labels for external access | `{}` | +| `externalAccess.service.annotations` | Service annotations for external access | `{}` | +| `externalAccess.service.extraPorts` | Extra ports to expose in the ClickHouse external service | `[]` | +| `ingress.enabled` | Enable ingress record generation for ClickHouse | `false` | +| `ingress.pathType` | Ingress path type | `ImplementationSpecific` | +| `ingress.apiVersion` | Force Ingress API version (automatically detected if not set) | `""` | +| `ingress.hostname` | Default host for the ingress record | `clickhouse.local` | +| `ingress.ingressClassName` | IngressClass that will be be used to implement the Ingress (Kubernetes 1.18+) | `""` | +| `ingress.path` | Default path for the ingress record | `/` | +| `ingress.annotations` | Additional annotations for the Ingress resource. To enable certificate autogeneration, place here your cert-manager annotations. | `{}` | +| `ingress.tls` | Enable TLS configuration for the host defined at `ingress.hostname` parameter | `false` | +| `ingress.selfSigned` | Create a TLS secret for this ingress record using self-signed certificates generated by Helm | `false` | +| `ingress.extraHosts` | An array with additional hostname(s) to be covered with the ingress record | `[]` | +| `ingress.extraPaths` | An array with additional arbitrary paths that may need to be added to the ingress under the main host | `[]` | +| `ingress.extraTls` | TLS configuration for additional hostname(s) to be covered with this ingress record | `[]` | +| `ingress.secrets` | Custom TLS certificates as secrets | `[]` | +| `ingress.extraRules` | Additional rules to be covered with this ingress record | `[]` | + +### Persistence Parameters + +| Name | Description | Value | +| --------------------------- | ----------------------------------------------------------------------- | ------------------- | +| `persistence.enabled` | Enable persistence using Persistent Volume Claims | `true` | +| `persistence.existingClaim` | Name of an existing PVC to use | `""` | +| `persistence.storageClass` | Storage class of backing PVC | `""` | +| `persistence.labels` | Persistent Volume Claim labels | `{}` | +| `persistence.annotations` | Persistent Volume Claim annotations | `{}` | +| `persistence.accessModes` | Persistent Volume Access Modes | `["ReadWriteOnce"]` | +| `persistence.size` | Size of data volume | `8Gi` | +| `persistence.selector` | Selector to match an existing Persistent Volume for ClickHouse data PVC | `{}` | +| `persistence.dataSource` | Custom PVC data source | `{}` | + +### Init Container Parameters + +| Name | Description | Value | +| ----------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------- | +| `volumePermissions.enabled` | Enable init container that changes the owner/group of the PV mount point to `runAsUser:fsGroup` | `false` | +| `volumePermissions.image.registry` | OS Shell + Utility image registry | `REGISTRY_NAME` | +| `volumePermissions.image.repository` | OS Shell + Utility image repository | `REPOSITORY_NAME/os-shell` | +| `volumePermissions.image.pullPolicy` | OS Shell + Utility image pull policy | `IfNotPresent` | +| `volumePermissions.image.pullSecrets` | OS Shell + Utility image pull secrets | `[]` | +| `volumePermissions.resourcesPreset` | Set container resources according to one common preset (allowed values: none, nano, small, medium, large, xlarge, 2xlarge). This is ignored if volumePermissions.resources is set (volumePermissions.resources is recommended for production). | `none` | +| `volumePermissions.resources` | Set container requests and limits for different resources like CPU or memory (essential for production workloads) | `{}` | +| `volumePermissions.containerSecurityContext.seLinuxOptions` | Set SELinux options in container | `nil` | +| `volumePermissions.containerSecurityContext.runAsUser` | Set init container's Security Context runAsUser | `0` | + +### Other Parameters + +| Name | Description | Value | +| --------------------------------------------- | ------------------------------------------------------------------------------------------------------ | ------- | +| `serviceAccount.create` | Specifies whether a ServiceAccount should be created | `true` | +| `serviceAccount.name` | The name of the ServiceAccount to use. | `""` | +| `serviceAccount.annotations` | Additional Service Account annotations (evaluated as a template) | `{}` | +| `serviceAccount.automountServiceAccountToken` | Automount service account token for the server service account | `false` | +| `metrics.enabled` | Enable the export of Prometheus metrics | `false` | +| `metrics.podAnnotations` | Annotations for metrics scraping | `{}` | +| `metrics.serviceMonitor.enabled` | if `true`, creates a Prometheus Operator ServiceMonitor (also requires `metrics.enabled` to be `true`) | `false` | +| `metrics.serviceMonitor.namespace` | Namespace in which Prometheus is running | `""` | +| `metrics.serviceMonitor.annotations` | Additional custom annotations for the ServiceMonitor | `{}` | +| `metrics.serviceMonitor.labels` | Extra labels for the ServiceMonitor | `{}` | +| `metrics.serviceMonitor.jobLabel` | The name of the label on the target service to use as the job name in Prometheus | `""` | +| `metrics.serviceMonitor.honorLabels` | honorLabels chooses the metric's labels on collisions with target labels | `false` | +| `metrics.serviceMonitor.interval` | Interval at which metrics should be scraped. | `""` | +| `metrics.serviceMonitor.scrapeTimeout` | Timeout after which the scrape is ended | `""` | +| `metrics.serviceMonitor.metricRelabelings` | Specify additional relabeling of metrics | `[]` | +| `metrics.serviceMonitor.relabelings` | Specify general relabeling | `[]` | +| `metrics.serviceMonitor.selector` | Prometheus instance selector labels | `{}` | +| `metrics.prometheusRule.enabled` | Create a PrometheusRule for Prometheus Operator | `false` | +| `metrics.prometheusRule.namespace` | Namespace for the PrometheusRule Resource (defaults to the Release Namespace) | `""` | +| `metrics.prometheusRule.additionalLabels` | Additional labels that can be used so PrometheusRule will be discovered by Prometheus | `{}` | +| `metrics.prometheusRule.rules` | PrometheusRule definitions | `[]` | + +### External Zookeeper paramaters + +| Name | Description | Value | +| --------------------------- | ----------------------------------------- | ------ | +| `externalZookeeper.servers` | List of external zookeeper servers to use | `[]` | +| `externalZookeeper.port` | Port of the Zookeeper servers | `2888` | + +### Zookeeper subchart parameters + +| Name | Description | Value | +| -------------------------------- | ----------------------------- | --------------------------- | +| `zookeeper.enabled` | Deploy Zookeeper subchart | `true` | +| `zookeeper.replicaCount` | Number of Zookeeper instances | `3` | +| `zookeeper.service.ports.client` | Zookeeper client port | `2181` | +| `zookeeper.image.registry` | Zookeeper image registry | `REGISTRY_NAME` | +| `zookeeper.image.repository` | Zookeeper image repository | `REPOSITORY_NAME/zookeeper` | +| `zookeeper.image.pullPolicy` | Zookeeper image pull policy | `IfNotPresent` | + +### Network Policies + +| Name | Description | Value | +| --------------------------------------- | --------------------------------------------------------------- | ------ | +| `networkPolicy.enabled` | Specifies whether a NetworkPolicy should be created | `true` | +| `networkPolicy.allowExternal` | Don't require client label for connections | `true` | +| `networkPolicy.allowExternalEgress` | Allow the pod to access any range of port and all destinations. | `true` | +| `networkPolicy.extraIngress` | Add extra ingress rules to the NetworkPolice | `[]` | +| `networkPolicy.extraEgress` | Add extra ingress rules to the NetworkPolicy | `[]` | +| `networkPolicy.ingressNSMatchLabels` | Labels to match to allow traffic from other namespaces | `{}` | +| `networkPolicy.ingressNSPodMatchLabels` | Pod labels to match to allow traffic from other namespaces | `{}` | + +See to create the table. + +The above parameters map to the env variables defined in [bitnami/clickhouse](https://github.com/bitnami/containers/tree/main/bitnami/clickhouse). For more information please refer to the [bitnami/clickhouse](https://github.com/bitnami/containers/tree/main/bitnami/clickhouse) image documentation. + +Specify each parameter using the `--set key=value[,key=value]` argument to `helm install`. For example, + +```console +helm install my-release \ + --set auth.username=admin \ + --set auth.password=password \ + oci://REGISTRY_NAME/REPOSITORY_NAME/clickhouse +``` + +> Note: You need to substitute the placeholders `REGISTRY_NAME` and `REPOSITORY_NAME` with a reference to your Helm chart registry and repository. For example, in the case of Bitnami, you need to use `REGISTRY_NAME=registry-1.docker.io` and `REPOSITORY_NAME=bitnamicharts`. + +The above command sets the ClickHouse administrator account username and password to `admin` and `password` respectively. + +> NOTE: Once this chart is deployed, it is not possible to change the application's access credentials, such as usernames or passwords, using Helm. To change these application credentials after deployment, delete any persistent volumes (PVs) used by the chart and re-deploy it, or use the application's built-in administrative tools if available. + +Alternatively, a YAML file that specifies the values for the above parameters can be provided while installing the chart. For example, + +```console +helm install my-release -f values.yaml oci://REGISTRY_NAME/REPOSITORY_NAME/clickhouse +``` + +> Note: You need to substitute the placeholders `REGISTRY_NAME` and `REPOSITORY_NAME` with a reference to your Helm chart registry and repository. For example, in the case of Bitnami, you need to use `REGISTRY_NAME=registry-1.docker.io` and `REPOSITORY_NAME=bitnamicharts`. +> **Tip**: You can use the default [values.yaml](https://github.com/bitnami/charts/tree/main/bitnami/clickhouse/values.yaml) + +## Troubleshooting + +Find more information about how to deal with common errors related to Bitnami's Helm charts in [this troubleshooting guide](https://docs.bitnami.com/general/how-to/troubleshoot-helm-chart-issues). + +## Upgrading + +### To 2.0.0 + +This major updates the Zookeeper subchart to it newest major, 11.0.0. For more information on this subchart's major, please refer to [zookeeper upgrade notes](https://github.com/bitnami/charts/tree/main/bitnami/zookeeper#to-1100). + +## License + +Copyright © 2024 Broadcom. The term "Broadcom" refers to Broadcom Inc. and/or its subsidiaries. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. \ No newline at end of file diff --git a/charts/clickhouse/templates/NOTES.txt b/charts/clickhouse/templates/NOTES.txt new file mode 100644 index 000000000..5bbc1f431 --- /dev/null +++ b/charts/clickhouse/templates/NOTES.txt @@ -0,0 +1,59 @@ +CHART NAME: {{ .Chart.Name }} +CHART VERSION: {{ .Chart.Version }} +APP VERSION: {{ .Chart.AppVersion }} + +** Please be patient while the chart is being deployed ** + +{{- if .Values.diagnosticMode.enabled }} +The chart has been deployed in diagnostic mode. All probes have been disabled and the command has been overwritten with: + + command: {{- include "common.tplvalues.render" (dict "value" .Values.diagnosticMode.command "context" $) | nindent 4 }} + args: {{- include "common.tplvalues.render" (dict "value" .Values.diagnosticMode.args "context" $) | nindent 4 }} + +Get the list of pods by executing: + + kubectl get pods --namespace {{ include "common.names.namespace" . | quote }} -l app.kubernetes.io/instance={{ .Release.Name }} + +Access the pod you want to debug by executing + + kubectl exec --namespace {{ include "common.names.namespace" . | quote }} -ti -- bash + +In order to replicate the container startup scripts execute this command: + + /opt/bitnami/scripts/clickhouse/entrypoint.sh /opt/bitnami/scripts/clickhouse/run.sh + +{{- else }} + +ClickHouse is available in the following address: + +{{- if .Values.externalAccess.enabled }} + +NOTE: It may take a few minutes for the LoadBalancer IP to be available. + + kubectl get svc --namespace {{ template "common.names.namespace" . }} -l "app.kubernetes.io/name={{ template "common.names.fullname" . }},app.kubernetes.io/instance={{ .Release.Name }},app.kubernetes.io/component=clickhouse" -w + +{{- else if (eq "LoadBalancer" .Values.service.type) }} + + export SERVICE_IP=$(kubectl get svc --namespace {{ template "common.names.namespace" . }} {{ template "common.names.fullname" . }} --template "{{ "{{ range (index .status.loadBalancer.ingress 0) }}{{ . }}{{ end }}" }}") + +{{- else if (eq "NodePort" .Values.service.type)}} + + export NODE_IP=$(kubectl get nodes --namespace {{ template "common.names.namespace" . }} -o jsonpath="{.items[0].status.addresses[0].address}") + export NODE_PORT=$(kubectl get --namespace {{ template "common.names.namespace" . }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ template "common.names.fullname" . }}) + +{{- else if (eq "ClusterIP" .Values.service.type)}} + + kubectl port-forward --namespace {{ template "common.names.namespace" . }} svc/{{ template "common.names.fullname" . }} {{ .Values.service.ports.tcp }}:9000 & + +{{- end }} + +Credentials: + + echo "Username : {{ .Values.auth.username }}" + echo "Password : $(kubectl get secret --namespace {{ .Release.Namespace }} {{ include "clickhouse.secretName" . }} -o jsonpath="{.data.{{ include "clickhouse.secretKey" .}}}" | base64 -d)" + +{{- end }} + +{{- include "common.warnings.rollingTag" .Values.image }} +{{- include "clickhouse.validateValues" . }} +{{- include "common.warnings.resources" (dict "sections" (list "" "volumePermissions") "context" $) }} diff --git a/charts/clickhouse/templates/_helpers.tpl b/charts/clickhouse/templates/_helpers.tpl new file mode 100644 index 000000000..b52435267 --- /dev/null +++ b/charts/clickhouse/templates/_helpers.tpl @@ -0,0 +1,219 @@ +{{/* +Copyright VMware, Inc. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{/* +Return the proper ClickHouse image name +*/}} +{{- define "clickhouse.image" -}} +{{ include "common.images.image" (dict "imageRoot" .Values.image "global" .Values.global) }} +{{- end -}} + +{{/* +Return the proper image name (for the init container volume-permissions image) +*/}} +{{- define "clickhouse.volumePermissions.image" -}} +{{- include "common.images.image" ( dict "imageRoot" .Values.volumePermissions.image "global" .Values.global ) -}} +{{- end -}} + +{{/* +Return the proper Docker Image Registry Secret Names +*/}} +{{- define "clickhouse.imagePullSecrets" -}} +{{- include "common.images.pullSecrets" (dict "images" (list .Values.image .Values.volumePermissions.image) "global" .Values.global) -}} +{{- end -}} + +{{/* +Return true if a TLS credentials secret object should be created +*/}} +{{- define "clickhouse.createTlsSecret" -}} +{{- if and .Values.tls.autoGenerated (not .Values.tls.certificatesSecret) }} + {{- true -}} +{{- end -}} +{{- end -}} + +{{/* +Return the path to the CA cert file. +*/}} +{{- define "clickhouse.tlsSecretName" -}} +{{- if .Values.tls.autoGenerated }} + {{- printf "%s-crt" (include "common.names.fullname" .) -}} +{{- else -}} + {{ required "A secret containing TLS certificates is required when TLS is enabled" .Values.tls.certificatesSecret }} +{{- end -}} +{{- end -}} + +{{/* +Return the path to the cert file. +*/}} +{{- define "clickhouse.tlsCert" -}} +{{- if .Values.tls.autoGenerated }} + {{- printf "/opt/bitnami/clickhouse/certs/tls.crt" -}} +{{- else -}} + {{- required "Certificate filename is required when TLS in enabled" .Values.tls.certFilename | printf "/opt/bitnami/clickhouse/certs/%s" -}} +{{- end -}} +{{- end -}} + +{{/* +Return the path to the cert key file. +*/}} +{{- define "clickhouse.tlsCertKey" -}} +{{- if .Values.tls.autoGenerated }} + {{- printf "/opt/bitnami/clickhouse/certs/tls.key" -}} +{{- else -}} +{{- required "Certificate Key filename is required when TLS in enabled" .Values.tls.certKeyFilename | printf "/opt/bitnami/clickhouse/certs/%s" -}} +{{- end -}} +{{- end -}} + +{{/* +Return the path to the CA cert file. +*/}} +{{- define "clickhouse.tlsCACert" -}} +{{- if .Values.tls.autoGenerated }} + {{- printf "/opt/bitnami/clickhouse/certs/ca.crt" -}} +{{- else -}} + {{- printf "/opt/bitnami/clickhouse/certs/%s" .Values.tls.certCAFilename -}} +{{- end -}} +{{- end -}} + +{{/* +Get the ClickHouse configuration configmap. +*/}} +{{- define "clickhouse.configmapName" -}} +{{- if .Values.existingOverridesConfigmap -}} + {{- .Values.existingOverridesConfigmap -}} +{{- else }} + {{- printf "%s" (include "common.names.fullname" . ) -}} +{{- end -}} +{{- end -}} + +{{/* +Get the ClickHouse configuration configmap. +*/}} +{{- define "clickhouse.extraConfigmapName" -}} +{{- if .Values.extraOverridesConfigmap -}} + {{- .Values.extraOverridesConfigmap -}} +{{- else }} + {{- printf "%s-extra" (include "common.names.fullname" . ) -}} +{{- end -}} +{{- end -}} + + +{{/* +Get the ClickHouse configuration users configmap. +*/}} +{{- define "clickhouse.usersExtraConfigmapName" -}} +{{- if .Values.usersExtraOverridesConfigmap -}} + {{- .Values.usersExtraOverridesConfigmap -}} +{{- else }} + {{- printf "%s-users-extra" (include "common.names.fullname" . ) -}} +{{- end -}} +{{- end -}} + +{{/* +Get the Clickhouse password secret name +*/}} +{{- define "clickhouse.secretName" -}} +{{- if .Values.auth.existingSecret -}} + {{- .Values.auth.existingSecret -}} +{{- else }} + {{- printf "%s" (include "common.names.fullname" . ) -}} +{{- end -}} +{{- end -}} + +{{/* +Get the ClickHouse password key inside the secret +*/}} +{{- define "clickhouse.secretKey" -}} +{{- if .Values.auth.existingSecret -}} + {{- .Values.auth.existingSecretKey -}} +{{- else }} + {{- print "admin-password" -}} +{{- end -}} +{{- end -}} + +{{/* +Get the startialization scripts Secret name. +*/}} +{{- define "clickhouse.startdbScriptsSecret" -}} +{{- if .Values.startdbScriptsSecret -}} + {{- printf "%s" (tpl .Values.startdbScriptsSecret $) -}} +{{- else -}} + {{- printf "%s-start-scripts" (include "common.names.fullname" .) -}} +{{- end -}} +{{- end -}} + +{{/* +Get the initialization scripts Secret name. +*/}} +{{- define "clickhouse.initdbScriptsSecret" -}} +{{- if .Values.initdbScriptsSecret -}} + {{- printf "%s" (tpl .Values.initdbScriptsSecret $) -}} +{{- else -}} + {{- printf "%s-init-scripts" (include "common.names.fullname" .) -}} +{{- end -}} +{{- end -}} + +{{/* +Return the path to the CA cert file. +*/}} +{{- define "clickhouse.headlessServiceName" -}} +{{- printf "%s-headless" (include "common.names.fullname" .) -}} +{{- 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). +*/}} +{{- define "clickhouse.zookeeper.fullname" -}} +{{- include "common.names.dependency.fullname" (dict "chartName" "zookeeper" "chartValues" .Values.zookeeper "context" $) -}} +{{- end -}} + +{{/* +Return the path to the CA cert file. +*/}} +{{- define "clickhouse.zookeeper.headlessServiceName" -}} +{{- printf "%s-headless" (include "clickhouse.zookeeper.fullname" .) -}} +{{- end -}} + +{{/* +Create the name of the service account to use +*/}} +{{- define "clickhouse.serviceAccountName" -}} +{{- if .Values.serviceAccount.create -}} + {{ default (include "common.names.fullname" .) .Values.serviceAccount.name }} +{{- else -}} + {{ default "default" .Values.serviceAccount.name }} +{{- end -}} +{{- end -}} + +{{/* +Compile all warnings into a single message. +*/}} +{{- define "clickhouse.validateValues" -}} +{{- $messages := list -}} +{{- $messages := append $messages (include "clickhouse.validateValues.zookeeper" .) -}} +{{- $messages := without $messages "" -}} +{{- $message := join "\n" $messages -}} + +{{- if $message -}} +{{- printf "\nVALUES VALIDATION:\n%s" $message -}} +{{- end -}} +{{- end -}} + +{{/* Validate values of ClickHouse - [Zoo]keeper */}} +{{- define "clickhouse.validateValues.zookeeper" -}} +{{- if or (and .Values.keeper.enabled .Values.zookeeper.enabled) (and .Values.keeper.enabled .Values.externalZookeeper.servers) (and .Values.zookeeper.enabled .Values.externalZookeeper.servers) -}} +clickhouse: Multiple [Zoo]keeper + You can only use one [zoo]keeper + Please choose use ClickHouse keeper or + installing a Zookeeper chart (--set zookeeper.enabled=true) or + using an external instance (--set zookeeper.servers ) +{{- end -}} +{{- if and (not .Values.keeper.enabled) (not .Values.zookeeper.enabled) (not .Values.externalZookeeper.servers) (ne (int .Values.shards) 1) (ne (int .Values.replicaCount) 1) -}} +clickhouse: No [Zoo]keeper + If you are deploying more than one ClickHouse instance, you need to enable [Zoo]keeper. Please choose installing a [Zoo]keeper (--set keeper.enabled=true) or (--set zookeeper.enabled=true) or + using an external instance (--set zookeeper.servers ) +{{- end -}} +{{- end -}} diff --git a/charts/clickhouse/templates/configmap-extra.yaml b/charts/clickhouse/templates/configmap-extra.yaml new file mode 100644 index 000000000..153cf4d50 --- /dev/null +++ b/charts/clickhouse/templates/configmap-extra.yaml @@ -0,0 +1,20 @@ +{{- /* +Copyright VMware, Inc. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if and .Values.extraOverrides (not .Values.extraOverridesConfigmap) }} +apiVersion: v1 +kind: ConfigMap +metadata: + name: {{ printf "%s-extra" (include "common.names.fullname" .) }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/component: clickhouse + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +data: + 01_extra_overrides.xml: | + {{- include "common.tplvalues.render" (dict "value" .Values.extraOverrides "context" $) | nindent 4 }} +{{- end }} diff --git a/charts/clickhouse/templates/configmap-users-extra.yaml b/charts/clickhouse/templates/configmap-users-extra.yaml new file mode 100644 index 000000000..056d2d026 --- /dev/null +++ b/charts/clickhouse/templates/configmap-users-extra.yaml @@ -0,0 +1,20 @@ +{{- /* +Copyright VMware, Inc. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if and .Values.usersExtraOverrides (not .Values.usersExtraOverridesConfigmap) }} +apiVersion: v1 +kind: ConfigMap +metadata: + name: {{ printf "%s-users-extra" (include "common.names.fullname" .) }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/component: clickhouse + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +data: + 01_users_extra_overrides.xml: | + {{- include "common.tplvalues.render" (dict "value" .Values.usersExtraOverrides "context" $) | nindent 4 }} +{{- end }} diff --git a/charts/clickhouse/templates/configmap.yaml b/charts/clickhouse/templates/configmap.yaml new file mode 100644 index 000000000..2462712b5 --- /dev/null +++ b/charts/clickhouse/templates/configmap.yaml @@ -0,0 +1,20 @@ +{{- /* +Copyright VMware, Inc. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if not .Values.existingOverridesConfigmap }} +apiVersion: v1 +kind: ConfigMap +metadata: + name: {{ template "common.names.fullname" . }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/component: clickhouse + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +data: + 00_default_overrides.xml: | + {{- include "common.tplvalues.render" (dict "value" .Values.defaultConfigurationOverrides "context" $) | nindent 4 }} +{{- end }} diff --git a/charts/clickhouse/templates/extra-list.yaml b/charts/clickhouse/templates/extra-list.yaml new file mode 100644 index 000000000..2d35a580e --- /dev/null +++ b/charts/clickhouse/templates/extra-list.yaml @@ -0,0 +1,9 @@ +{{- /* +Copyright VMware, Inc. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- range .Values.extraDeploy }} +--- +{{ include "common.tplvalues.render" (dict "value" . "context" $) }} +{{- end }} diff --git a/charts/clickhouse/templates/ingress-tls-secrets.yaml b/charts/clickhouse/templates/ingress-tls-secrets.yaml new file mode 100644 index 000000000..6ef20e36a --- /dev/null +++ b/charts/clickhouse/templates/ingress-tls-secrets.yaml @@ -0,0 +1,44 @@ +{{- /* +Copyright VMware, Inc. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if .Values.ingress.enabled }} +{{- if .Values.ingress.secrets }} +{{- range .Values.ingress.secrets }} +apiVersion: v1 +kind: Secret +metadata: + name: {{ .name }} + namespace: {{ $.Release.Namespace | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" $.Values.commonLabels "context" $ ) | nindent 4 }} + {{- if $.Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" $.Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +type: kubernetes.io/tls +data: + tls.crt: {{ .certificate | b64enc }} + tls.key: {{ .key | b64enc }} +--- +{{- end }} +{{- end }} +{{- if and .Values.ingress.tls .Values.ingress.selfSigned }} +{{- $secretName := printf "%s-tls" .Values.ingress.hostname }} +{{- $ca := genCA "clickhouse-ca" 365 }} +{{- $cert := genSignedCert .Values.ingress.hostname nil (list .Values.ingress.hostname) 365 $ca }} +apiVersion: v1 +kind: Secret +metadata: + name: {{ $secretName }} + namespace: {{ .Release.Namespace | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +type: kubernetes.io/tls +data: + tls.crt: {{ include "common.secrets.lookup" (dict "secret" $secretName "key" "tls.crt" "defaultValue" $cert.Cert "context" $) }} + tls.key: {{ include "common.secrets.lookup" (dict "secret" $secretName "key" "tls.key" "defaultValue" $cert.Key "context" $) }} + ca.crt: {{ include "common.secrets.lookup" (dict "secret" $secretName "key" "ca.crt" "defaultValue" $ca.Cert "context" $) }} +{{- end }} +{{- end }} diff --git a/charts/clickhouse/templates/ingress.yaml b/charts/clickhouse/templates/ingress.yaml new file mode 100644 index 000000000..7000ecebf --- /dev/null +++ b/charts/clickhouse/templates/ingress.yaml @@ -0,0 +1,59 @@ +{{- /* +Copyright VMware, Inc. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if .Values.ingress.enabled }} +apiVersion: {{ include "common.capabilities.ingress.apiVersion" . }} +kind: Ingress +metadata: + name: {{ include "common.names.fullname" . }} + namespace: {{ .Release.Namespace | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + {{- if or .Values.ingress.annotations .Values.commonAnnotations }} + {{- $annotations := include "common.tplvalues.merge" ( dict "values" ( list .Values.ingress.annotations .Values.commonAnnotations ) "context" . ) }} + annotations: {{- include "common.tplvalues.render" ( dict "value" $annotations "context" $) | nindent 4 }} + {{- end }} +spec: + {{- if and .Values.ingress.ingressClassName (eq "true" (include "common.ingress.supportsIngressClassname" .)) }} + ingressClassName: {{ .Values.ingress.ingressClassName | quote }} + {{- end }} + rules: + {{- if .Values.ingress.hostname }} + - host: {{ .Values.ingress.hostname | quote }} + http: + paths: + {{- if .Values.ingress.extraPaths }} + {{- toYaml .Values.ingress.extraPaths | nindent 10 }} + {{- end }} + - path: {{ .Values.ingress.path }} + {{- if eq "true" (include "common.ingress.supportsPathType" .) }} + pathType: {{ .Values.ingress.pathType }} + {{- end }} + backend: {{- include "common.ingress.backend" (dict "serviceName" (include "common.names.fullname" .) "servicePort" "http" "context" $) | nindent 14 }} + {{- end }} + {{- range .Values.ingress.extraHosts }} + - host: {{ .name | quote }} + http: + paths: + - path: {{ default "/" .path }} + {{- if eq "true" (include "common.ingress.supportsPathType" $) }} + pathType: {{ default "ImplementationSpecific" .pathType }} + {{- end }} + backend: {{- include "common.ingress.backend" (dict "serviceName" (include "common.names.fullname" $) "servicePort" "http" "context" $) | nindent 14 }} + {{- end }} + {{- if .Values.ingress.extraRules }} + {{- include "common.tplvalues.render" (dict "value" .Values.ingress.extraRules "context" $) | nindent 4 }} + {{- end }} + {{- if or (and .Values.ingress.tls (or (include "common.ingress.certManagerRequest" ( dict "annotations" .Values.ingress.annotations )) .Values.ingress.selfSigned)) .Values.ingress.extraTls }} + tls: + {{- if and .Values.ingress.tls (or (include "common.ingress.certManagerRequest" ( dict "annotations" .Values.ingress.annotations )) .Values.ingress.selfSigned) }} + - hosts: + - {{ .Values.ingress.hostname | quote }} + secretName: {{ printf "%s-tls" .Values.ingress.hostname }} + {{- end }} + {{- if .Values.ingress.extraTls }} + {{- include "common.tplvalues.render" (dict "value" .Values.ingress.extraTls "context" $) | nindent 4 }} + {{- end }} + {{- end }} +{{- end }} diff --git a/charts/clickhouse/templates/init-scripts-secret.yaml b/charts/clickhouse/templates/init-scripts-secret.yaml new file mode 100644 index 000000000..323670930 --- /dev/null +++ b/charts/clickhouse/templates/init-scripts-secret.yaml @@ -0,0 +1,19 @@ +{{- /* +Copyright VMware, Inc. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if and .Values.initdbScripts (not .Values.initdbScriptsSecret) }} +apiVersion: v1 +kind: Secret +metadata: + name: {{ printf "%s-init-scripts" (include "common.names.fullname" .) }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/component: clickhouse + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +stringData: +{{- include "common.tplvalues.render" (dict "value" .Values.initdbScripts "context" .) | nindent 2 }} +{{- end }} diff --git a/charts/clickhouse/templates/networkpolicy.yaml b/charts/clickhouse/templates/networkpolicy.yaml new file mode 100644 index 000000000..68635e094 --- /dev/null +++ b/charts/clickhouse/templates/networkpolicy.yaml @@ -0,0 +1,136 @@ +{{- /* +Copyright VMware, Inc. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if .Values.networkPolicy.enabled }} +kind: NetworkPolicy +apiVersion: {{ include "common.capabilities.networkPolicy.apiVersion" . }} +metadata: + name: {{ include "common.names.fullname" . }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/component: clickhouse + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +spec: + {{- $podLabels := include "common.tplvalues.merge" ( dict "values" ( list .Values.podLabels .Values.commonLabels ) "context" . ) }} + podSelector: + matchLabels: {{- include "common.labels.matchLabels" ( dict "customLabels" $podLabels "context" $ ) | nindent 6 }} + app.kubernetes.io/component: clickhouse + policyTypes: + - Ingress + - Egress + {{- if .Values.networkPolicy.allowExternalEgress }} + egress: + - {} + {{- else }} + egress: + # Allow dns resolution + - ports: + - port: 53 + protocol: UDP + - port: 53 + protocol: TCP + # Allow outbound connections to other cluster pods + - ports: + - port: {{ .Values.service.ports.http }} + {{- if .Values.tls.enabled }} + - port: {{ .Values.service.ports.https }} + {{- end }} + - port: {{ .Values.service.ports.tcp }} + {{- if .Values.tls.enabled }} + - port: {{ .Values.service.ports.tcpSecure }} + {{- end }} + {{- if .Values.keeper.enabled }} + - port: {{ .Values.service.ports.keeper }} + - port: {{ .Values.service.ports.keeperInter }} + {{- if .Values.tls.enabled }} + - port: {{ .Values.service.ports.keeperSecure }} + {{- end }} + {{- end }} + - port: {{ .Values.service.ports.mysql }} + - port: {{ .Values.service.ports.postgresql }} + - port: {{ .Values.service.ports.interserver }} + {{- if .Values.metrics.enabled }} + - port: {{ .Values.service.ports.metrics }} + {{- end }} + {{- if $.Values.externalAccess.enabled }} + - port: {{ $.Values.externalAccess.service.ports.http }} + {{- if $.Values.tls.enabled }} + - port: {{ $.Values.externalAccess.service.ports.https }} + {{- end }} + {{- if $.Values.metrics.enabled }} + - port: {{ $.Values.externalAccess.service.ports.metrics }} + {{- end }} + - port: {{ $.Values.externalAccess.service.ports.tcp }} + {{- if $.Values.tls.enabled }} + - port: {{ $.Values.externalAccess.service.ports.tcpSecure }} + {{- end }} + {{- if $.Values.keeper.enabled }} + - port: {{ $.Values.externalAccess.service.ports.keeper }} + - port: {{ $.Values.externalAccess.service.ports.keeperInter }} + {{- if $.Values.tls.enabled }} + - port: {{ $.Values.externalAccess.service.ports.keeperSecure }} + {{- end }} + {{- end }} + - port: {{ $.Values.externalAccess.service.ports.mysql }} + - port: {{ $.Values.externalAccess.service.ports.postgresql }} + - port: {{ $.Values.externalAccess.service.ports.interserver }} + {{- end }} + to: + - podSelector: + matchLabels: {{- include "common.labels.matchLabels" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 14 }} + {{- if .Values.networkPolicy.extraEgress }} + {{- include "common.tplvalues.render" ( dict "value" .Values.networkPolicy.extraEgress "context" $ ) | nindent 4 }} + {{- end }} + {{- end }} + ingress: + - ports: + - port: {{ $.Values.containerPorts.http }} + - port: {{ $.Values.containerPorts.tcp }} + - port: {{ $.Values.containerPorts.mysql }} + - port: {{ $.Values.containerPorts.postgresql }} + - port: {{ $.Values.containerPorts.interserver }} + {{- if $.Values.tls.enabled }} + - port: {{ $.Values.containerPorts.tcpSecure }} + - port: {{ $.Values.containerPorts.https }} + {{- end }} + {{- if $.Values.keeper.enabled }} + - port: {{ $.Values.containerPorts.keeper }} + - port: {{ $.Values.containerPorts.keeperInter }} + {{- if $.Values.tls.enabled }} + - port : {{ $.Values.containerPorts.keeperSecure }} + {{- end }} + {{- end }} + {{- if $.Values.metrics.enabled }} + - port: {{ $.Values.containerPorts.metrics }} + {{- end }} + {{- if not .Values.networkPolicy.allowExternal }} + from: + - podSelector: + matchLabels: {{- include "common.labels.matchLabels" ( dict "customLabels" $podLabels "context" $ ) | nindent 14 }} + app.kubernetes.io/component: clickhouse + - podSelector: + matchLabels: + {{ include "common.names.fullname" . }}-client: "true" + {{- if .Values.networkPolicy.ingressNSMatchLabels }} + - namespaceSelector: + matchLabels: + {{- range $key, $value := .Values.networkPolicy.ingressNSMatchLabels }} + {{ $key | quote }}: {{ $value | quote }} + {{- end }} + {{- if .Values.networkPolicy.ingressNSPodMatchLabels }} + podSelector: + matchLabels: + {{- range $key, $value := .Values.networkPolicy.ingressNSPodMatchLabels }} + {{ $key | quote }}: {{ $value | quote }} + {{- end }} + {{- end }} + {{- end }} + {{- end }} + {{- if .Values.networkPolicy.extraIngress }} + {{- include "common.tplvalues.render" ( dict "value" .Values.networkPolicy.extraIngress "context" $ ) | nindent 4 }} + {{- end }} +{{- end }} diff --git a/charts/clickhouse/templates/prometheusrule.yaml b/charts/clickhouse/templates/prometheusrule.yaml new file mode 100644 index 000000000..dc2d05d3a --- /dev/null +++ b/charts/clickhouse/templates/prometheusrule.yaml @@ -0,0 +1,24 @@ +{{- /* +Copyright VMware, Inc. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if and .Values.metrics.enabled .Values.metrics.prometheusRule.enabled .Values.metrics.prometheusRule.rules }} +apiVersion: monitoring.coreos.com/v1 +kind: PrometheusRule +metadata: + name: {{ include "common.names.fullname" . }} + namespace: {{ default .Release.Namespace .Values.metrics.prometheusRule.namespace | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/component: metrics + {{- if .Values.metrics.prometheusRule.additionalLabels }} + {{- include "common.tplvalues.render" ( dict "value" .Values.metrics.prometheusRule.additionalLabels "context" $ ) | nindent 4 }} + {{- end }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +spec: + groups: + - name: {{ include "common.names.fullname" . }} + rules: {{- toYaml .Values.metrics.prometheusRule.rules | nindent 8 }} +{{- end }} diff --git a/charts/clickhouse/templates/scripts-configmap.yaml b/charts/clickhouse/templates/scripts-configmap.yaml new file mode 100644 index 000000000..86aa34dcd --- /dev/null +++ b/charts/clickhouse/templates/scripts-configmap.yaml @@ -0,0 +1,34 @@ +{{- /* +Copyright VMware, Inc. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +apiVersion: v1 +kind: ConfigMap +metadata: + name: {{ printf "%s-scripts" (include "common.names.fullname" .) }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/component: clickhouse + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +data: + setup.sh: |- + #!/bin/bash + + # Execute entrypoint as usual after obtaining KEEPER_SERVER_ID + # check KEEPER_SERVER_ID in persistent volume via myid + # if not present, set based on POD hostname + if [[ -f "/bitnami/clickhouse/keeper/data/myid" ]]; then + export KEEPER_SERVER_ID="$(cat /bitnami/clickhouse/keeper/data/myid)" + else + HOSTNAME="$(hostname -s)" + if [[ $HOSTNAME =~ (.*)-([0-9]+)$ ]]; then + export KEEPER_SERVER_ID=${BASH_REMATCH[2]} + else + echo "Failed to get index from hostname $HOST" + exit 1 + fi + fi + exec /opt/bitnami/scripts/clickhouse/entrypoint.sh /opt/bitnami/scripts/clickhouse/run.sh -- --listen_host=0.0.0.0 diff --git a/charts/clickhouse/templates/secret.yaml b/charts/clickhouse/templates/secret.yaml new file mode 100644 index 000000000..16068010a --- /dev/null +++ b/charts/clickhouse/templates/secret.yaml @@ -0,0 +1,20 @@ +{{- /* +Copyright VMware, Inc. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if not .Values.auth.existingSecret }} +apiVersion: v1 +kind: Secret +metadata: + name: {{ template "common.names.fullname" . }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/component: clickhouse + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +type: Opaque +data: + admin-password: {{ include "common.secrets.passwords.manage" (dict "secret" (include "common.names.fullname" .) "key" "admin-password" "providedValues" (list "auth.password") "context" $) }} +{{- end }} diff --git a/charts/clickhouse/templates/service-account.yaml b/charts/clickhouse/templates/service-account.yaml new file mode 100644 index 000000000..649086dac --- /dev/null +++ b/charts/clickhouse/templates/service-account.yaml @@ -0,0 +1,19 @@ +{{- /* +Copyright VMware, Inc. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if .Values.serviceAccount.create }} +apiVersion: v1 +kind: ServiceAccount +metadata: + name: {{ include "clickhouse.serviceAccountName" . }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/component: clickhouse + {{- if or .Values.serviceAccount.annotations .Values.commonAnnotations }} + {{- $annotations := include "common.tplvalues.merge" ( dict "values" ( list .Values.serviceAccount.annotations .Values.commonAnnotations ) "context" . ) }} + annotations: {{- include "common.tplvalues.render" ( dict "value" $annotations "context" $) | nindent 4 }} + {{- end }} +automountServiceAccountToken: {{ .Values.serviceAccount.automountServiceAccountToken }} +{{- end }} diff --git a/charts/clickhouse/templates/service-external-access.yaml b/charts/clickhouse/templates/service-external-access.yaml new file mode 100644 index 000000000..f50baa214 --- /dev/null +++ b/charts/clickhouse/templates/service-external-access.yaml @@ -0,0 +1,155 @@ +{{- /* +Copyright VMware, Inc. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if $.Values.externalAccess.enabled }} +{{- $shards := $.Values.shards | int }} +{{- $replicas := $.Values.replicaCount | int }} +{{- $totalNodes := mul $shards $replicas }} +{{- range $shard, $e := until $shards }} +{{- range $i, $_e := until $replicas }} +{{- $loadBalancerAnnotationPosOffset := mul $shard $replicas }} +{{- $loadBalancerAnnotationPosition := add $loadBalancerAnnotationPosOffset $i }} +{{- $targetPod := printf "%s-shard%d-%d" (include "common.names.fullname" $) $shard $i }} +apiVersion: v1 +kind: Service +metadata: + name: {{ printf "%s-external" $targetPod | trunc 63 | trimSuffix "-" }} + namespace: {{ $.Release.Namespace | quote }} + {{- $labels := include "common.tplvalues.merge" ( dict "values" ( list $.Values.externalAccess.service.labels $.Values.commonLabels ) "context" $ ) }} + labels: {{- include "common.labels.standard" ( dict "customLabels" $labels "context" $ ) | nindent 4 }} + app.kubernetes.io/component: clickhouse + pod: {{ $targetPod }} + {{- if or $.Values.externalAccess.service.annotations $.Values.commonAnnotations $.Values.externalAccess.service.loadBalancerAnnotations }} + annotations: + {{- if and (not (empty $.Values.externalAccess.service.loadBalancerAnnotations)) (eq (len $.Values.externalAccess.service.loadBalancerAnnotations) $totalNodes) }} + {{ include "common.tplvalues.render" ( dict "value" (index $.Values.externalAccess.service.loadBalancerAnnotations $loadBalancerAnnotationPosition) "context" $) | nindent 4 }} + {{- end }} + {{- if $.Values.externalAccess.service.annotations }} + {{- include "common.tplvalues.render" ( dict "value" $.Values.externalAccess.service.annotations "context" $) | nindent 4 }} + {{- end }} + {{- if $.Values.commonAnnotations }} + {{- include "common.tplvalues.render" ( dict "value" $.Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} + {{- end }} +spec: + type: {{ $.Values.externalAccess.service.type }} + {{- if eq $.Values.externalAccess.service.type "LoadBalancer" }} + {{- if and (not (empty $.Values.externalAccess.service.loadBalancerIPs)) (eq (len $.Values.externalAccess.service.loadBalancerIPs) $totalNodes) }} + loadBalancerIP: {{ index $.Values.externalAccess.service.loadBalancerIPs $i }} + {{- end }} + {{- if $.Values.externalAccess.service.loadBalancerSourceRanges }} + loadBalancerSourceRanges: {{- toYaml $.Values.externalAccess.service.loadBalancerSourceRanges | nindent 4 }} + {{- end }} + {{- end }} + ports: + - name: http + port: {{ $.Values.externalAccess.service.ports.http }} + targetPort: http + {{- if not (empty $.Values.externalAccess.service.nodePorts.http) }} + nodePort: {{ index $.Values.externalAccess.service.nodePorts.http $i }} + {{- else }} + nodePort: null + {{- end }} + {{- if $.Values.tls.enabled }} + - name: https + port: {{ $.Values.externalAccess.service.ports.https }} + targetPort: https + {{- if not (empty $.Values.externalAccess.service.nodePorts.https) }} + nodePort: {{ index $.Values.externalAccess.service.nodePorts.https $i }} + {{- else }} + nodePort: null + {{- end }} + {{- end }} + {{- if $.Values.metrics.enabled }} + - name: http-metrics + port: {{ $.Values.externalAccess.service.ports.metrics }} + targetPort: http-metrics + {{- if not (empty $.Values.externalAccess.service.nodePorts.metrics) }} + nodePort: {{ index $.Values.externalAccess.service.nodePorts.metrics $i }} + {{- else }} + nodePort: null + {{- end }} + {{- end }} + - name: tcp + port: {{ $.Values.externalAccess.service.ports.tcp }} + targetPort: tcp + {{- if not (empty $.Values.externalAccess.service.nodePorts.tcp) }} + nodePort: {{ index $.Values.externalAccess.service.nodePorts.tcp $i }} + {{- else }} + nodePort: null + {{- end }} + {{- if $.Values.tls.enabled }} + - name: tcp-secure + port: {{ $.Values.externalAccess.service.ports.tcpSecure }} + targetPort: tcp-secure + {{- if not (empty $.Values.externalAccess.service.nodePorts.tcpSecure) }} + nodePort: {{ index $.Values.externalAccess.service.nodePorts.tcpSecure $i }} + {{- else }} + nodePort: null + {{- end }} + {{- end }} + {{- if $.Values.keeper.enabled }} + - name: tcp-keeper + port: {{ $.Values.externalAccess.service.ports.keeper }} + targetPort: tcp-keeper + {{- if not (empty $.Values.externalAccess.service.nodePorts.keeper) }} + nodePort: {{ index $.Values.externalAccess.service.nodePorts.keeper $i }} + {{- else }} + nodePort: null + {{- end }} + - name: tcp-keeperinter + port: {{ $.Values.externalAccess.service.ports.keeperInter }} + targetPort: tcp-keeperinter + {{- if not (empty $.Values.externalAccess.service.nodePorts.keeperInter) }} + nodePort: {{ index $.Values.externalAccess.service.nodePorts.keeperInter $i }} + {{- else }} + nodePort: null + {{- end }} + {{- if $.Values.tls.enabled }} + - name: tcp-keepertls + port: {{ $.Values.externalAccess.service.ports.keeperSecure }} + targetPort: tcp-keepertls + {{- if not (empty $.Values.externalAccess.service.nodePorts.keeperSecure) }} + nodePort: {{ index $.Values.externalAccess.service.nodePorts.keeperSecure $i }} + {{- else }} + nodePort: null + {{- end }} + {{- end }} + {{- end }} + - name: tcp-mysql + port: {{ $.Values.externalAccess.service.ports.mysql }} + targetPort: tcp-mysql + {{- if not (empty $.Values.externalAccess.service.nodePorts.mysql) }} + nodePort: {{ index $.Values.externalAccess.service.nodePorts.mysql $i }} + {{- else }} + nodePort: null + {{- end }} + - name: tcp-postgresql + port: {{ $.Values.externalAccess.service.ports.postgresql }} + targetPort: tcp-postgresql + {{- if not (empty $.Values.externalAccess.service.nodePorts.postgresql) }} + nodePort: {{ index $.Values.externalAccess.service.nodePorts.postgresql $i }} + {{- else }} + nodePort: null + {{- end }} + - name: tcp-intersrv + port: {{ $.Values.externalAccess.service.ports.interserver }} + targetPort: tcp-intersrv + {{- if not (empty $.Values.externalAccess.service.nodePorts.interserver) }} + nodePort: {{ index $.Values.externalAccess.service.nodePorts.interserver $i }} + {{- else }} + nodePort: null + {{- end }} + {{- if $.Values.externalAccess.service.extraPorts }} + {{- include "common.tplvalues.render" (dict "value" $.Values.externalAccess.service.extraPorts "context" $) | nindent 4 }} + {{- end }} + {{- $podLabels := include "common.tplvalues.merge" ( dict "values" ( list $.Values.podLabels $.Values.commonLabels ) "context" $ ) }} + selector: {{- include "common.labels.matchLabels" ( dict "customLabels" $podLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/component: clickhouse + statefulset.kubernetes.io/pod-name: {{ $targetPod }} +--- +{{- end }} +{{- end }} +{{- end }} diff --git a/charts/clickhouse/templates/service-headless.yaml b/charts/clickhouse/templates/service-headless.yaml new file mode 100644 index 000000000..f989841bd --- /dev/null +++ b/charts/clickhouse/templates/service-headless.yaml @@ -0,0 +1,69 @@ +{{- /* +Copyright VMware, Inc. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +apiVersion: v1 +kind: Service +metadata: + name: {{ include "clickhouse.headlessServiceName" . }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/component: clickhouse + {{- if or .Values.service.headless.annotations .Values.commonAnnotations }} + {{- $annotations := include "common.tplvalues.merge" ( dict "values" ( list .Values.service.headless.annotations .Values.commonAnnotations ) "context" . ) }} + annotations: {{- include "common.tplvalues.render" ( dict "value" $annotations "context" $) | nindent 4 }} + {{- end }} +spec: + type: ClusterIP + clusterIP: None + publishNotReadyAddresses: true + ports: + - name: http + targetPort: http + port: {{ .Values.service.ports.http }} + protocol: TCP + - name: tcp + targetPort: tcp + port: {{ .Values.service.ports.tcp }} + protocol: TCP + {{- if .Values.tls.enabled }} + - name: tcp-secure + targetPort: tcp-secure + port: {{ .Values.service.ports.tcpSecure }} + protocol: TCP + {{- end }} + {{- if .Values.keeper.enabled }} + - name: tcp-keeper + targetPort: tcp-keeper + port: {{ .Values.service.ports.keeper }} + protocol: TCP + - name: tcp-keeperinter + targetPort: tcp-keeperinter + port: {{ .Values.service.ports.keeperInter }} + protocol: TCP + {{- if .Values.tls.enabled }} + - name: tcp-keepertls + targetPort: tcp-keepertls + port: {{ .Values.service.ports.keeperSecure }} + protocol: TCP + {{- end }} + {{- end }} + - name: tcp-mysql + targetPort: tcp-mysql + port: {{ .Values.service.ports.mysql }} + protocol: TCP + - name: tcp-postgresql + targetPort: tcp-postgresql + port: {{ .Values.service.ports.postgresql }} + protocol: TCP + - name: http-intersrv + targetPort: http-intersrv + port: {{ .Values.service.ports.interserver }} + protocol: TCP + {{- if .Values.service.extraPorts }} + {{- include "common.tplvalues.render" (dict "value" .Values.service.extraPorts "context" $) | nindent 4 }} + {{- end }} + {{- $podLabels := include "common.tplvalues.merge" ( dict "values" ( list .Values.podLabels .Values.commonLabels ) "context" . ) }} + selector: {{- include "common.labels.matchLabels" ( dict "customLabels" $podLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/component: clickhouse diff --git a/charts/clickhouse/templates/service.yaml b/charts/clickhouse/templates/service.yaml new file mode 100644 index 000000000..f54e2268a --- /dev/null +++ b/charts/clickhouse/templates/service.yaml @@ -0,0 +1,152 @@ +{{- /* +Copyright VMware, Inc. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +apiVersion: v1 +kind: Service +metadata: + name: {{ template "common.names.fullname" . }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/component: clickhouse + {{- if or .Values.service.annotations .Values.commonAnnotations }} + {{- $annotations := include "common.tplvalues.merge" ( dict "values" ( list .Values.service.annotations .Values.commonAnnotations ) "context" . ) }} + annotations: {{- include "common.tplvalues.render" ( dict "value" $annotations "context" $) | nindent 4 }} + {{- end }} +spec: + type: {{ .Values.service.type }} + {{- if and .Values.service.clusterIP (eq .Values.service.type "ClusterIP") }} + clusterIP: {{ .Values.service.clusterIP }} + {{- end }} + {{- if .Values.service.sessionAffinity }} + sessionAffinity: {{ .Values.service.sessionAffinity }} + {{- end }} + {{- if .Values.service.sessionAffinityConfig }} + sessionAffinityConfig: {{- include "common.tplvalues.render" (dict "value" .Values.service.sessionAffinityConfig "context" $) | nindent 4 }} + {{- end }} + {{- if or (eq .Values.service.type "LoadBalancer") (eq .Values.service.type "NodePort") }} + externalTrafficPolicy: {{ .Values.service.externalTrafficPolicy | quote }} + {{- end }} + {{- if and (eq .Values.service.type "LoadBalancer") (not (empty .Values.service.loadBalancerSourceRanges)) }} + loadBalancerSourceRanges: {{- toYaml .Values.service.loadBalancerSourceRanges | nindent 4 }} + {{- end }} + {{- if and (eq .Values.service.type "LoadBalancer") (not (empty .Values.service.loadBalancerIP)) }} + loadBalancerIP: {{ .Values.service.loadBalancerIP }} + {{- end }} + ports: + - name: http + targetPort: http + port: {{ .Values.service.ports.http }} + protocol: TCP + {{- if and (or (eq .Values.service.type "NodePort") (eq .Values.service.type "LoadBalancer")) (not (empty .Values.service.nodePorts.http)) }} + nodePort: {{ .Values.service.nodePorts.http }} + {{- else if eq .Values.service.type "ClusterIP" }} + nodePort: null + {{- end }} + {{- if .Values.tls.enabled }} + - name: https + targetPort: https + port: {{ .Values.service.ports.https }} + protocol: TCP + {{- if and (or (eq .Values.service.type "NodePort") (eq .Values.service.type "LoadBalancer")) (not (empty .Values.service.nodePorts.https)) }} + nodePort: {{ .Values.service.nodePorts.https }} + {{- else if eq .Values.service.type "ClusterIP" }} + nodePort: null + {{- end }} + {{- end }} + - name: tcp + targetPort: tcp + port: {{ .Values.service.ports.tcp }} + protocol: TCP + {{- if and (or (eq .Values.service.type "NodePort") (eq .Values.service.type "LoadBalancer")) (not (empty .Values.service.nodePorts.tcp)) }} + nodePort: {{ .Values.service.nodePorts.tcp }} + {{- else if eq .Values.service.type "ClusterIP" }} + nodePort: null + {{- end }} + {{- if .Values.tls.enabled }} + - name: tcp-secure + targetPort: tcp-secure + port: {{ .Values.service.ports.tcpSecure }} + protocol: TCP + {{- if and (or (eq .Values.service.type "NodePort") (eq .Values.service.type "LoadBalancer")) (not (empty .Values.service.nodePorts.tcpSecure)) }} + nodePort: {{ .Values.service.nodePorts.tcpSecure }} + {{- else if eq .Values.service.type "ClusterIP" }} + nodePort: null + {{- end }} + {{- end }} + {{- if .Values.keeper.enabled }} + - name: tcp-keeper + targetPort: tcp-keeper + port: {{ .Values.service.ports.keeper }} + protocol: TCP + {{- if and (or (eq .Values.service.type "NodePort") (eq .Values.service.type "LoadBalancer")) (not (empty .Values.service.nodePorts.tcp)) }} + nodePort: {{ .Values.service.nodePorts.keeper }} + {{- else if eq .Values.service.type "ClusterIP" }} + nodePort: null + {{- end }} + - name: tcp-keeperinter + targetPort: tcp-keeperinter + port: {{ .Values.service.ports.keeperInter }} + protocol: TCP + {{- if and (or (eq .Values.service.type "NodePort") (eq .Values.service.type "LoadBalancer")) (not (empty .Values.service.nodePorts.tcp)) }} + nodePort: {{ .Values.service.nodePorts.keeperInter }} + {{- else if eq .Values.service.type "ClusterIP" }} + nodePort: null + {{- end }} + {{- if .Values.tls.enabled }} + - name: tcp-keepertls + targetPort: tcp-keepertls + port: {{ .Values.service.ports.keeperSecure }} + protocol: TCP + {{- if and (or (eq .Values.service.type "NodePort") (eq .Values.service.type "LoadBalancer")) (not (empty .Values.service.nodePorts.tcpSecure)) }} + nodePort: {{ .Values.service.nodePorts.keeperSecure }} + {{- else if eq .Values.service.type "ClusterIP" }} + nodePort: null + {{- end }} + {{- end }} + {{- end }} + - name: tcp-mysql + targetPort: tcp-mysql + port: {{ .Values.service.ports.mysql }} + protocol: TCP + {{- if and (or (eq .Values.service.type "NodePort") (eq .Values.service.type "LoadBalancer")) (not (empty .Values.service.nodePorts.mysql)) }} + nodePort: {{ .Values.service.nodePorts.mysql }} + {{- else if eq .Values.service.type "ClusterIP" }} + nodePort: null + {{- end }} + - name: tcp-postgresql + targetPort: tcp-postgresql + port: {{ .Values.service.ports.postgresql }} + protocol: TCP + {{- if and (or (eq .Values.service.type "NodePort") (eq .Values.service.type "LoadBalancer")) (not (empty .Values.service.nodePorts.postgresql)) }} + nodePort: {{ .Values.service.nodePorts.postgresql }} + {{- else if eq .Values.service.type "ClusterIP" }} + nodePort: null + {{- end }} + - name: http-intersrv + targetPort: http-intersrv + port: {{ .Values.service.ports.interserver }} + protocol: TCP + {{- if and (or (eq .Values.service.type "NodePort") (eq .Values.service.type "LoadBalancer")) (not (empty .Values.service.nodePorts.interserver)) }} + nodePort: {{ .Values.service.nodePorts.interserver }} + {{- else if eq .Values.service.type "ClusterIP" }} + nodePort: null + {{- end }} + {{- if .Values.metrics.enabled }} + - name: http-metrics + targetPort: http-metrics + port: {{ .Values.service.ports.metrics }} + protocol: TCP + {{- if and (or (eq .Values.service.type "NodePort") (eq .Values.service.type "LoadBalancer")) (not (empty .Values.service.nodePorts.metrics)) }} + nodePort: {{ .Values.service.nodePorts.metrics }} + {{- else if eq .Values.service.type "ClusterIP" }} + nodePort: null + {{- end }} + {{- end }} + {{- if .Values.service.extraPorts }} + {{- include "common.tplvalues.render" (dict "value" .Values.service.extraPorts "context" $) | nindent 4 }} + {{- end }} + {{- $podLabels := include "common.tplvalues.merge" ( dict "values" ( list .Values.podLabels .Values.commonLabels ) "context" . ) }} + selector: {{- include "common.labels.matchLabels" ( dict "customLabels" $podLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/component: clickhouse diff --git a/charts/clickhouse/templates/servicemonitor.yaml b/charts/clickhouse/templates/servicemonitor.yaml new file mode 100644 index 000000000..2148b375d --- /dev/null +++ b/charts/clickhouse/templates/servicemonitor.yaml @@ -0,0 +1,47 @@ +{{- /* +Copyright VMware, Inc. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if and .Values.metrics.enabled .Values.metrics.serviceMonitor.enabled }} +apiVersion: monitoring.coreos.com/v1 +kind: ServiceMonitor +metadata: + name: {{ include "common.names.fullname" . }} + namespace: {{ default (include "common.names.namespace" .) .Values.metrics.serviceMonitor.namespace | quote }} + {{- $labels := include "common.tplvalues.merge" ( dict "values" ( list .Values.metrics.serviceMonitor.labels .Values.commonLabels ) "context" . ) }} + labels: {{- include "common.labels.standard" ( dict "customLabels" $labels "context" $ ) | nindent 4 }} + app.kubernetes.io/component: clickhouse + {{- if or .Values.metrics.serviceMonitor.annotations .Values.commonAnnotations }} + {{- $annotations := include "common.tplvalues.merge" ( dict "values" ( list .Values.metrics.serviceMonitor.annotations .Values.commonAnnotations ) "context" . ) }} + annotations: {{- include "common.tplvalues.render" ( dict "value" $annotations "context" $) | nindent 4 }} + {{- end }} +spec: + jobLabel: {{ .Values.metrics.serviceMonitor.jobLabel | quote }} + selector: + matchLabels: {{- include "common.labels.matchLabels" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 6 }} + {{- if .Values.metrics.serviceMonitor.selector }} + {{- include "common.tplvalues.render" (dict "value" .Values.metrics.serviceMonitor.selector "context" $) | nindent 6 }} + {{- end }} + endpoints: + - port: http-metrics + path: "/metrics" + {{- if .Values.metrics.serviceMonitor.interval }} + interval: {{ .Values.metrics.serviceMonitor.interval }} + {{- end }} + {{- if .Values.metrics.serviceMonitor.scrapeTimeout }} + scrapeTimeout: {{ .Values.metrics.serviceMonitor.scrapeTimeout }} + {{- end }} + {{- if .Values.metrics.serviceMonitor.honorLabels }} + honorLabels: {{ .Values.metrics.serviceMonitor.honorLabels }} + {{- end }} + {{- if .Values.metrics.serviceMonitor.metricRelabelings }} + metricRelabelings: {{- include "common.tplvalues.render" ( dict "value" .Values.metrics.serviceMonitor.metricRelabelings "context" $) | nindent 8 }} + {{- end }} + {{- if .Values.metrics.serviceMonitor.relabelings }} + relabelings: {{- include "common.tplvalues.render" ( dict "value" .Values.metrics.serviceMonitor.relabelings "context" $) | nindent 8 }} + {{- end }} + namespaceSelector: + matchNames: + - {{ include "common.names.namespace" . | quote }} +{{- end }} diff --git a/charts/clickhouse/templates/start-scripts-secret.yaml b/charts/clickhouse/templates/start-scripts-secret.yaml new file mode 100644 index 000000000..c579f2e46 --- /dev/null +++ b/charts/clickhouse/templates/start-scripts-secret.yaml @@ -0,0 +1,19 @@ +{{- /* +Copyright VMware, Inc. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if and .Values.startdbScripts (not .Values.startdbScriptsSecret) }} +apiVersion: v1 +kind: Secret +metadata: + name: {{ printf "%s-start-scripts" (include "common.names.fullname" .) }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/component: clickhouse + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +stringData: +{{- include "common.tplvalues.render" (dict "value" .Values.startdbScripts "context" .) | nindent 2 }} +{{- end }} diff --git a/charts/clickhouse/templates/statefulset.yaml b/charts/clickhouse/templates/statefulset.yaml new file mode 100644 index 000000000..9357d4287 --- /dev/null +++ b/charts/clickhouse/templates/statefulset.yaml @@ -0,0 +1,462 @@ +{{- /* +Copyright VMware, Inc. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- $shards := .Values.shards | int }} +{{- range $i, $e := until $shards }} +apiVersion: {{ include "common.capabilities.statefulset.apiVersion" $ }} +kind: StatefulSet +metadata: + name: {{ printf "%s-shard%d" (include "common.names.fullname" $ ) $i }} + namespace: {{ include "common.names.namespace" $ | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" $.Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/component: clickhouse + {{- if $.Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" $.Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +spec: + replicas: {{ $.Values.replicaCount }} + podManagementPolicy: {{ $.Values.podManagementPolicy | quote }} + {{- $podLabels := include "common.tplvalues.merge" ( dict "values" ( list $.Values.podLabels $.Values.commonLabels ) "context" $ ) }} + selector: + matchLabels: {{- include "common.labels.matchLabels" ( dict "customLabels" $podLabels "context" $ ) | nindent 6 }} + app.kubernetes.io/component: clickhouse + serviceName: {{ printf "%s-headless" (include "common.names.fullname" $) }} + {{- if $.Values.updateStrategy }} + updateStrategy: {{- toYaml $.Values.updateStrategy | nindent 4 }} + {{- end }} + template: + metadata: + annotations: + checksum/config: {{ include (print $.Template.BasePath "/configmap.yaml") $ | sha256sum }} + checksum/config-extra: {{ include (print $.Template.BasePath "/configmap-extra.yaml") $ | sha256sum }} + checksum/config-users-extra: {{ include (print $.Template.BasePath "/configmap-users-extra.yaml") $ | sha256sum }} + {{- if $.Values.podAnnotations }} + {{- include "common.tplvalues.render" (dict "value" $.Values.podAnnotations "context" $) | nindent 8 }} + {{- end }} + {{- if and $.Values.metrics.enabled $.Values.metrics.podAnnotations }} + {{- include "common.tplvalues.render" (dict "value" $.Values.metrics.podAnnotations "context" $) | nindent 8 }} + {{- end }} + labels: {{- include "common.labels.standard" ( dict "customLabels" $podLabels "context" $ ) | nindent 8 }} + app.kubernetes.io/component: clickhouse + shard: {{ $i | quote }} + spec: + serviceAccountName: {{ template "clickhouse.serviceAccountName" $ }} + {{- include "clickhouse.imagePullSecrets" $ | nindent 6 }} + automountServiceAccountToken: {{ $.Values.automountServiceAccountToken }} + {{- if $.Values.hostAliases }} + hostAliases: {{- include "common.tplvalues.render" (dict "value" $.Values.hostAliases "context" $) | nindent 8 }} + {{- end }} + {{- if $.Values.affinity }} + affinity: {{- include "common.tplvalues.render" ( dict "value" $.Values.affinity "context" $) | nindent 8 }} + {{- else }} + affinity: + podAffinity: {{- include "common.affinities.pods" (dict "type" $.Values.podAffinityPreset "component" "clickhouse" "customLabels" $podLabels "context" $) | nindent 10 }} + podAntiAffinity: {{- include "common.affinities.pods" (dict "type" $.Values.podAntiAffinityPreset "component" "clickhouse" "customLabels" $podLabels "extraPodAffinityTerms" (ternary (list (dict "extraMatchLabels" (dict "shard" $i) "topologyKey" "topology.kubernetes.io/zone")) (list) $.Values.distributeReplicasByZone) "context" $) | nindent 10 }} + nodeAffinity: {{- include "common.affinities.nodes" (dict "type" $.Values.nodeAffinityPreset.type "key" $.Values.nodeAffinityPreset.key "values" $.Values.nodeAffinityPreset.values) | nindent 10 }} + {{- end }} + {{- if $.Values.nodeSelector }} + nodeSelector: {{- include "common.tplvalues.render" ( dict "value" $.Values.nodeSelector "context" $) | nindent 8 }} + {{- end }} + {{- if $.Values.tolerations }} + tolerations: {{- include "common.tplvalues.render" (dict "value" $.Values.tolerations "context" $) | nindent 8 }} + {{- end }} + {{- if $.Values.priorityClassName }} + priorityClassName: {{ $.Values.priorityClassName | quote }} + {{- end }} + {{- if $.Values.schedulerName }} + schedulerName: {{ $.Values.schedulerName | quote }} + {{- end }} + {{- if $.Values.topologySpreadConstraints }} + topologySpreadConstraints: {{- include "common.tplvalues.render" (dict "value" $.Values.topologySpreadConstraints "context" $) | nindent 8 }} + {{- end }} + {{- if $.Values.podSecurityContext.enabled }} + securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" $.Values.podSecurityContext "context" $) | nindent 8 }} + {{- end }} + {{- if $.Values.terminationGracePeriodSeconds }} + terminationGracePeriodSeconds: {{ $.Values.terminationGracePeriodSeconds }} + {{- end }} + initContainers: + {{- if and $.Values.tls.enabled (not $.Values.volumePermissions.enabled) }} + - name: copy-certs + image: {{ include "clickhouse.volumePermissions.image" $ }} + imagePullPolicy: {{ $.Values.volumePermissions.image.pullPolicy | quote }} + {{- if $.Values.resources }} + resources: {{- toYaml $.Values.resources | nindent 12 }} + {{- else if ne $.Values.resourcesPreset "none" }} + resources: {{- include "common.resources.preset" (dict "type" $.Values.resourcesPreset) | nindent 12 }} + {{- end }} + {{- if $.Values.containerSecurityContext.enabled }} + # We don't require a privileged container in this case + securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" $.Values.containerSecurityContext "context" $) | nindent 12 }} + {{- end }} + command: + - /bin/sh + - -ec + - | + cp -L /tmp/certs/* /opt/bitnami/clickhouse/certs/ + chmod 600 {{ include "clickhouse.tlsCertKey" $ }} + volumeMounts: + - name: raw-certificates + mountPath: /tmp/certs + - name: clickhouse-certificates + mountPath: /opt/bitnami/clickhouse/certs + - name: empty-dir + mountPath: /tmp + subPath: tmp-dir + {{- else if and $.Values.volumePermissions.enabled $.Values.persistence.enabled }} + - name: volume-permissions + image: {{ include "clickhouse.volumePermissions.image" $ }} + imagePullPolicy: {{ $.Values.volumePermissions.image.pullPolicy | quote }} + command: + - /bin/sh + - -ec + - | + mkdir -p /bitnami/clickhouse/data + chmod 700 /bitnami/clickhouse/data + {{- if $.Values.keeper.enabled }} + mkdir -p /bitnami/clickhouse/keeper + chmod 700 /bitnami/clickhouse/keeper + {{- end }} + chown {{ $.Values.containerSecurityContext.runAsUser }}:{{ $.Values.podSecurityContext.fsGroup }} /bitnami/clickhouse + find /bitnami/clickhouse -mindepth 1 -maxdepth 1 -not -name ".snapshot" -not -name "lost+found" | \ + xargs -r chown -R {{ $.Values.containerSecurityContext.runAsUser }}:{{ $.Values.podSecurityContext.fsGroup }} + {{- if $.Values.tls.enabled }} + cp /tmp/certs/* /opt/bitnami/clickhouse/certs/ + {{- if eq ( toString ( $.Values.volumePermissions.containerSecurityContext.runAsUser )) "auto" }} + chown -R `id -u`:`id -G | cut -d " " -f2` /opt/bitnami/clickhouse/certs/ + {{- else }} + chown -R {{ $.Values.containerSecurityContext.runAsUser }}:{{ $.Values.podSecurityContext.fsGroup }} /opt/bitnami/clickhouse/certs/ + {{- end }} + chmod 600 {{ include "clickhouse.tlsCertKey" $ }} + {{- end }} + securityContext: {{- include "common.tplvalues.render" (dict "value" $.Values.volumePermissions.containerSecurityContext "context" $) | nindent 12 }} + {{- if $.Values.volumePermissions.resources }} + resources: {{- toYaml $.Values.volumePermissions.resources | nindent 12 }} + {{- else if ne $.Values.volumePermissions.resourcesPreset "none" }} + resources: {{- include "common.resources.preset" (dict "type" $.Values.volumePermissions.resourcesPreset) | nindent 12 }} + {{- end }} + volumeMounts: + - name: data + mountPath: /bitnami/clickhouse + - name: empty-dir + mountPath: /tmp + subPath: tmp-dir + {{- if $.Values.tls.enabled }} + - name: raw-certificates + mountPath: /tmp/certs + - name: clickhouse-certificates + mountPath: /opt/bitnami/clickhouse/certs + {{- end }} + {{- end }} + {{- if $.Values.initContainers }} + {{- include "common.tplvalues.render" (dict "value" $.Values.initContainers "context" $) | nindent 8 }} + {{- end }} + containers: + - name: clickhouse + image: {{ template "clickhouse.image" $ }} + imagePullPolicy: {{ $.Values.image.pullPolicy }} + {{- if $.Values.containerSecurityContext.enabled }} + securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" $.Values.containerSecurityContext "context" $) | nindent 12 }} + {{- end }} + {{- if $.Values.diagnosticMode.enabled }} + command: {{- include "common.tplvalues.render" (dict "value" $.Values.diagnosticMode.command "context" $) | nindent 12 }} + {{- else if $.Values.command }} + command: {{- include "common.tplvalues.render" (dict "value" $.Values.command "context" $) | nindent 12 }} + {{- end }} + {{- if $.Values.diagnosticMode.enabled }} + args: {{- include "common.tplvalues.render" (dict "value" $.Values.diagnosticMode.args "context" $) | nindent 12 }} + {{- else if $.Values.args }} + args: {{- include "common.tplvalues.render" (dict "value" $.Values.args "context" $) | nindent 12 }} + {{- end }} + env: + - name: BITNAMI_DEBUG + value: {{ ternary "true" "false" (or $.Values.image.debug $.Values.diagnosticMode.enabled) | quote }} + - name: CLICKHOUSE_HTTP_PORT + value: {{ $.Values.containerPorts.http | quote }} + - name: CLICKHOUSE_TCP_PORT + value: {{ $.Values.containerPorts.tcp | quote }} + - name: CLICKHOUSE_MYSQL_PORT + value: {{ $.Values.containerPorts.mysql | quote }} + - name: CLICKHOUSE_POSTGRESQL_PORT + value: {{ $.Values.containerPorts.postgresql | quote }} + - name: CLICKHOUSE_INTERSERVER_HTTP_PORT + value: {{ $.Values.containerPorts.interserver | quote }} + {{- if $.Values.tls.enabled }} + - name: CLICKHOUSE_TCP_SECURE_PORT + value: {{ $.Values.containerPorts.tcpSecure | quote }} + - name: CLICKHOUSE_HTTPS_PORT + value: {{ $.Values.containerPorts.https | quote }} + {{- end }} + {{- if $.Values.keeper.enabled }} + - name: CLICKHOUSE_KEEPER_PORT + value: {{ $.Values.containerPorts.keeper | quote }} + - name: CLICKHOUSE_KEEPER_INTER_PORT + value: {{ $.Values.containerPorts.keeperInter | quote }} + {{- if $.Values.tls.enabled }} + - name: CLICKHOUSE_KEEPER_SECURE_PORT + value: {{ $.Values.containerPorts.keeperSecure | quote }} + {{- end }} + {{- end }} + {{- if $.Values.metrics.enabled }} + - name: CLICKHOUSE_METRICS_PORT + value: {{ $.Values.containerPorts.metrics | quote }} + {{- end }} + - name: CLICKHOUSE_ADMIN_USER + value: {{ $.Values.auth.username | quote }} + - name: CLICKHOUSE_SHARD_ID + value: {{ printf "shard%d" $i | quote }} + - name: CLICKHOUSE_REPLICA_ID + valueFrom: + fieldRef: + fieldPath: metadata.name + - name: CLICKHOUSE_ADMIN_PASSWORD + valueFrom: + secretKeyRef: + name: {{ include "clickhouse.secretName" $ }} + key: {{ include "clickhouse.secretKey" $ }} + {{- if $.Values.tls.enabled }} + - name: CLICKHOUSE_TLS_CERT_FILE + value: {{ include "clickhouse.tlsCert" $ | quote}} + - name: CLICKHOUSE_TLS_KEY_FILE + value: {{ include "clickhouse.tlsCertKey" $ | quote }} + - name: CLICKHOUSE_TLS_CA_FILE + value: {{ include "clickhouse.tlsCACert" $ | quote }} + {{- end }} + {{- if $.Values.extraEnvVars }} + {{- include "common.tplvalues.render" (dict "value" $.Values.extraEnvVars "context" $) | nindent 12 }} + {{- end }} + {{- if $.Values.keeper.enabled }} + {{- $replicas := $.Values.replicaCount | int }} + {{- range $j, $r := until $replicas }} + - name: {{ printf "KEEPER_NODE_%d" $j }} + value: {{ printf "%s-shard%d-%d.%s.%s.svc.%s" (include "common.names.fullname" $ ) $i $j (include "clickhouse.headlessServiceName" $) (include "common.names.namespace" $) $.Values.clusterDomain }} + {{- end }} + {{- else if $.Values.zookeeper.enabled }} + {{- $replicas := $.Values.zookeeper.replicaCount | int }} + {{- range $j, $r := until $replicas }} + - name: {{ printf "KEEPER_NODE_%d" $j }} + value: {{ printf "%s-%d.%s.%s.svc.%s" (include "clickhouse.zookeeper.fullname" $ ) $j (include "clickhouse.zookeeper.headlessServiceName" $) (include "common.names.namespace" $) $.Values.clusterDomain }} + {{- end }} + {{- end }} + envFrom: + {{- if $.Values.extraEnvVarsCM }} + - configMapRef: + name: {{ include "common.tplvalues.render" (dict "value" $.Values.extraEnvVarsCM "context" $) }} + {{- end }} + {{- if $.Values.extraEnvVarsSecret }} + - secretRef: + name: {{ include "common.tplvalues.render" (dict "value" $.Values.extraEnvVarsSecret "context" $) }} + {{- end }} + {{- if $.Values.resources }} + resources: {{- toYaml $.Values.resources | nindent 12 }} + {{- else if ne $.Values.resourcesPreset "none" }} + resources: {{- include "common.resources.preset" (dict "type" $.Values.resourcesPreset) | nindent 12 }} + {{- end }} + ports: + - name: http + containerPort: {{ $.Values.containerPorts.http }} + - name: tcp + containerPort: {{ $.Values.containerPorts.tcp }} + {{- if $.Values.tls.enabled }} + - name: https + containerPort: {{ $.Values.containerPorts.https }} + - name: tcp-secure + containerPort: {{ $.Values.containerPorts.tcpSecure }} + {{- end }} + {{- if $.Values.keeper.enabled }} + - name: tcp-keeper + containerPort: {{ $.Values.containerPorts.keeper }} + - name: tcp-keeperinter + containerPort: {{ $.Values.containerPorts.keeperInter }} + {{- if $.Values.tls.enabled }} + - name: tcp-keepertls + containerPort: {{ $.Values.containerPorts.keeperSecure }} + {{- end }} + {{- end }} + - name: tcp-postgresql + containerPort: {{ $.Values.containerPorts.postgresql }} + - name: tcp-mysql + containerPort: {{ $.Values.containerPorts.mysql }} + - name: http-intersrv + containerPort: {{ $.Values.containerPorts.interserver }} + {{- if $.Values.metrics.enabled }} + - name: http-metrics + containerPort: {{ $.Values.containerPorts.metrics }} + {{- end }} + {{- if not $.Values.diagnosticMode.enabled }} + {{- if $.Values.customLivenessProbe }} + livenessProbe: {{- include "common.tplvalues.render" (dict "value" $.Values.customLivenessProbe "context" $) | nindent 12 }} + {{- else if $.Values.livenessProbe.enabled }} + livenessProbe: {{- include "common.tplvalues.render" (dict "value" (omit $.Values.livenessProbe "enabled") "context" $) | nindent 12 }} + httpGet: + path: /ping + port: http + {{- end }} + {{- if $.Values.customReadinessProbe }} + readinessProbe: {{- include "common.tplvalues.render" (dict "value" $.Values.customReadinessProbe "context" $) | nindent 12 }} + {{- else if $.Values.readinessProbe.enabled }} + readinessProbe: {{- include "common.tplvalues.render" (dict "value" (omit $.Values.readinessProbe "enabled") "context" $) | nindent 12 }} + httpGet: + path: /ping + port: http + {{- end }} + {{- if $.Values.customStartupProbe }} + startupProbe: {{- include "common.tplvalues.render" (dict "value" $.Values.customStartupProbe "context" $) | nindent 12 }} + {{- else if $.Values.startupProbe.enabled }} + startupProbe: {{- include "common.tplvalues.render" (dict "value" (omit $.Values.startupProbe "enabled") "context" $) | nindent 12 }} + httpGet: + path: /ping + port: http + {{- end }} + {{- end }} + {{- if $.Values.lifecycleHooks }} + lifecycle: {{- include "common.tplvalues.render" (dict "value" $.Values.lifecycleHooks "context" $) | nindent 12 }} + {{- end }} + volumeMounts: + - name: empty-dir + mountPath: /opt/bitnami/clickhouse/etc + subPath: app-conf-dir + - name: empty-dir + mountPath: /opt/bitnami/clickhouse/logs + subPath: app-logs-dir + - name: empty-dir + mountPath: /opt/bitnami/clickhouse/tmp + subPath: app-tmp-dir + - name: empty-dir + mountPath: /tmp + subPath: tmp-dir + - name: scripts + mountPath: /scripts/setup.sh + subPath: setup.sh + - name: data + mountPath: /bitnami/clickhouse + - name: config + mountPath: /bitnami/clickhouse/etc/conf.d/default + {{- if or $.Values.extraOverridesConfigmap $.Values.extraOverrides }} + - name: extra-config + mountPath: /bitnami/clickhouse/etc/conf.d/extra-configmap + {{- end }} + {{- if or $.Values.usersExtraOverridesConfigmap $.Values.usersExtraOverrides }} + - name: users-extra-config + mountPath: /bitnami/clickhouse/etc/users.d/users-extra-configmap + {{- end }} + {{- if $.Values.extraOverridesSecret }} + - name: extra-secret + mountPath: /bitnami/clickhouse/etc/conf.d/extra-secret + {{- end }} + {{- if $.Values.usersExtraOverridesSecret }} + - name: users-extra-secret + mountPath: /bitnami/clickhouse/etc/users.d/users-extra-secret + {{- end }} + {{- if $.Values.tls.enabled }} + - name: clickhouse-certificates + mountPath: /bitnami/clickhouse/certs + {{- end }} + {{- if or $.Values.initdbScriptsSecret $.Values.initdbScripts }} + - name: custom-init-scripts + mountPath: /docker-entrypoint-initdb.d + {{- end }} + {{- if or $.Values.startdbScriptsSecret $.Values.startdbScripts }} + - name: custom-start-scripts + mountPath: /docker-entrypoint-startdb.d + {{- end }} + {{- if $.Values.extraVolumeMounts }} + {{- include "common.tplvalues.render" (dict "value" $.Values.extraVolumeMounts "context" $) | nindent 12 }} + {{- end }} + {{- if $.Values.sidecars }} + {{- include "common.tplvalues.render" ( dict "value" $.Values.sidecars "context" $) | nindent 8 }} + {{- end }} + volumes: + - name: scripts + configMap: + name: {{ printf "%s-scripts" (include "common.names.fullname" $) }} + defaultMode: 0755 + - name: empty-dir + emptyDir: {} + - name: config + configMap: + name: {{ template "clickhouse.configmapName" $ }} + {{- if or $.Values.initdbScriptsSecret $.Values.initdbScripts }} + - name: custom-init-scripts + secret: + secretName: {{ include "clickhouse.initdbScriptsSecret" $ }} + {{- end }} + {{- if or $.Values.startdbScriptsSecret $.Values.startdbScripts }} + - name: custom-start-scripts + secret: + secretName: {{ include "clickhouse.startdbScriptsSecret" $ }} + {{- end }} + {{- if or $.Values.extraOverridesConfigmap $.Values.extraOverrides }} + - name: extra-config + configMap: + name: {{ template "clickhouse.extraConfigmapName" $ }} + {{- end }} + {{- if or $.Values.usersExtraOverridesConfigmap $.Values.usersExtraOverrides }} + - name: users-extra-config + configMap: + name: {{ template "clickhouse.usersExtraConfigmapName" $ }} + {{- end }} + {{- if $.Values.extraOverridesSecret }} + - name: extra-secret + secret: + secretName: {{ $.Values.extraOverridesSecret }} + {{- end }} + {{- if $.Values.usersExtraOverridesSecret }} + - name: users-extra-secret + secret: + secretName: {{ $.Values.usersExtraOverridesSecret }} + {{- end }} + {{- if not $.Values.persistence.enabled }} + - name: data + emptyDir: {} + {{- else if $.Values.persistence.existingClaim }} + - name: data + persistentVolumeClaim: + claimName: {{ tpl $.Values.persistence.existingClaim $ }} + {{- end }} + {{- if $.Values.tls.enabled }} + - name: raw-certificates + secret: + secretName: {{ include "clickhouse.tlsSecretName" $ }} + - name: clickhouse-certificates + emptyDir: {} + {{- end }} + {{- if $.Values.extraVolumes }} + {{- include "common.tplvalues.render" (dict "value" $.Values.extraVolumes "context" $) | nindent 8 }} + {{- end }} + {{- if or $.Values.extraVolumeClaimTemplates (and $.Values.persistence.enabled (not $.Values.persistence.existingClaim)) }} + volumeClaimTemplates: + {{- if and $.Values.persistence.enabled (not $.Values.persistence.existingClaim) }} + - metadata: + name: data + {{- if or $.Values.persistence.annotations $.Values.commonAnnotations }} + {{- $claimAnnotations := include "common.tplvalues.merge" ( dict "values" ( list $.Values.persistence.annotations $.Values.commonLabels ) "context" $ ) }} + annotations: {{- include "common.tplvalues.render" ( dict "value" $claimAnnotations "context" $ ) | nindent 10 }} + {{- end }} + {{- $claimLabels := include "common.tplvalues.merge" ( dict "values" ( list $.Values.persistence.labels $.Values.commonLabels ) "context" $ ) }} + labels: {{- include "common.labels.matchLabels" ( dict "customLabels" $claimLabels "context" $ ) | nindent 10 }} + app.kubernetes.io/component: clickhouse + spec: + accessModes: + {{- range $.Values.persistence.accessModes }} + - {{ . | quote }} + {{- end }} + resources: + requests: + storage: {{ $.Values.persistence.size | quote }} + {{- if $.Values.persistence.selector }} + selector: {{- include "common.tplvalues.render" (dict "value" $.Values.persistence.selector "context" $) | nindent 10 }} + {{- end }} + {{- if $.Values.persistence.dataSource }} + dataSource: {{- include "common.tplvalues.render" (dict "value" $.Values.persistence.dataSource "context" $) | nindent 10 }} + {{- end }} + {{- include "common.storage.class" (dict "persistence" $.Values.persistence "global" $.Values.global) | nindent 8 }} + {{- end }} + {{- if $.Values.extraVolumeClaimTemplates }} + {{- include "common.tplvalues.render" ( dict "value" $.Values.extraVolumeClaimTemplates "context" $) | nindent 4 }} + {{- end }} + {{- end }} +--- +{{- end }} diff --git a/charts/clickhouse/templates/tls-secret.yaml b/charts/clickhouse/templates/tls-secret.yaml new file mode 100644 index 000000000..04b188e14 --- /dev/null +++ b/charts/clickhouse/templates/tls-secret.yaml @@ -0,0 +1,29 @@ +{{- /* +Copyright VMware, Inc. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if (include "clickhouse.createTlsSecret" . ) }} +{{- $secretName := printf "%s-crt" (include "common.names.fullname" .) }} +{{- $ca := genCA "clickhouse-ca" 365 }} +{{- $fullname := include "common.names.fullname" . }} +{{- $releaseNamespace := .Release.Namespace }} +{{- $clusterDomain := .Values.clusterDomain }} +{{- $primaryHeadlessServiceName := printf "%s-headless" (include "common.names.fullname" .)}} +{{- $altNames := list (printf "*.%s.%s.svc.%s" $fullname $releaseNamespace $clusterDomain) (printf "%s.%s.svc.%s" $fullname $releaseNamespace $clusterDomain) (printf "*.%s.%s.svc.%s" $primaryHeadlessServiceName $releaseNamespace $clusterDomain) (printf "%s.%s.svc.%s" $primaryHeadlessServiceName $releaseNamespace $clusterDomain) $fullname }} +{{- $cert := genSignedCert $fullname nil $altNames 365 $ca }} +apiVersion: v1 +kind: Secret +metadata: + name: {{ $secretName }} + namespace: {{ .Release.Namespace | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +type: kubernetes.io/tls +data: + tls.crt: {{ include "common.secrets.lookup" (dict "secret" $secretName "key" "tls.crt" "defaultValue" $cert.Cert "context" $) }} + tls.key: {{ include "common.secrets.lookup" (dict "secret" $secretName "key" "tls.key" "defaultValue" $cert.Key "context" $) }} + ca.crt: {{ include "common.secrets.lookup" (dict "secret" $secretName "key" "ca.crt" "defaultValue" $ca.Cert "context" $) }} +{{- end }} diff --git a/charts/clickhouse/values.yaml b/charts/clickhouse/values.yaml new file mode 100644 index 000000000..8d7de64fe --- /dev/null +++ b/charts/clickhouse/values.yaml @@ -0,0 +1,1200 @@ +# Copyright VMware, Inc. +# SPDX-License-Identifier: APACHE-2.0 + +## @section Global parameters +## Global Docker image parameters +## Please, note that this will override the image parameters, including dependencies, configured to use the global value +## Current available global Docker image parameters: imageRegistry, imagePullSecrets and storageClass +## + +## @param global.imageRegistry Global Docker image registry +## @param global.imagePullSecrets Global Docker registry secret names as an array +## @param global.storageClass Global StorageClass for Persistent Volume(s) +## +global: + imageRegistry: "" + ## E.g. + ## imagePullSecrets: + ## - myRegistryKeySecretName + ## + imagePullSecrets: [] + storageClass: "" + ## Compatibility adaptations for Kubernetes platforms + ## + compatibility: + ## Compatibility adaptations for Openshift + ## + openshift: + ## @param global.compatibility.openshift.adaptSecurityContext Adapt the securityContext sections of the deployment to make them compatible with Openshift restricted-v2 SCC: remove runAsUser, runAsGroup and fsGroup and let the platform use their allowed default IDs. Possible values: auto (apply if the detected running cluster is Openshift), force (perform the adaptation always), disabled (do not perform adaptation) + ## + adaptSecurityContext: disabled +## @section Common parameters +## + +## @param kubeVersion Override Kubernetes version +## +kubeVersion: "" +## @param nameOverride String to partially override common.names.name +## +nameOverride: "" +## @param fullnameOverride String to fully override common.names.fullname +## +fullnameOverride: "" +## @param namespaceOverride String to fully override common.names.namespace +## +namespaceOverride: "" +## @param commonLabels Labels to add to all deployed objects +## +commonLabels: {} +## @param commonAnnotations Annotations to add to all deployed objects +## +commonAnnotations: {} +## @param clusterDomain Kubernetes cluster domain name +## +clusterDomain: cluster.local +## @param extraDeploy Array of extra objects to deploy with the release +## +extraDeploy: [] +## Enable diagnostic mode in the deployment +## +diagnosticMode: + ## @param diagnosticMode.enabled Enable diagnostic mode (all probes will be disabled and the command will be overridden) + ## + enabled: false + ## @param diagnosticMode.command Command to override all containers in the deployment + ## + command: + - sleep + ## @param diagnosticMode.args Args to override all containers in the deployment + ## + args: + - infinity +## @section ClickHouse Parameters +## + +## Bitnami ClickHouse image +## ref: https://hub.docker.com/r/bitnami/clickhouse/tags/ +## @param image.registry [default: REGISTRY_NAME] ClickHouse image registry +## @param image.repository [default: REPOSITORY_NAME/clickhouse] ClickHouse image repository +## @skip image.tag ClickHouse image tag (immutable tags are recommended) +## @param image.digest ClickHouse image digest in the way sha256:aa.... Please note this parameter, if set, will override the tag +## @param image.pullPolicy ClickHouse image pull policy +## @param image.pullSecrets ClickHouse image pull secrets +## @param image.debug Enable ClickHouse image debug mode +## +image: + registry: docker.io + repository: bitnami/clickhouse + tag: 24.2.2-debian-12-r0 + digest: "" + ## Specify a imagePullPolicy + ## Defaults to 'Always' if image tag is 'latest', else set to 'IfNotPresent' + ## ref: http://kubernetes.io/docs/concepts/containers/images/#pre-pulled-images + ## + pullPolicy: IfNotPresent + ## Optionally specify an array of imagePullSecrets. + ## Secrets must be manually created in the namespace. + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/ + ## e.g: + ## pullSecrets: + ## - myRegistryKeySecretName + ## + pullSecrets: [] + ## Enable debug mode + ## + debug: false +## @param shards Number of ClickHouse shards to deploy +## +shards: 2 +## @param replicaCount Number of ClickHouse replicas per shard to deploy +## if keeper enable, same as keeper count, keeper cluster by shards. +## +replicaCount: 3 +## @param distributeReplicasByZone Schedules replicas of the same shard to different availability zones +## +distributeReplicasByZone: false +## @param containerPorts.http ClickHouse HTTP container port +## @param containerPorts.https ClickHouse HTTPS container port +## @param containerPorts.tcp ClickHouse TCP container port +## @param containerPorts.tcpSecure ClickHouse TCP (secure) container port +## @param containerPorts.keeper ClickHouse keeper TCP container port +## @param containerPorts.keeperSecure ClickHouse keeper TCP (secure) container port +## @param containerPorts.keeperInter ClickHouse keeper interserver TCP container port +## @param containerPorts.mysql ClickHouse MySQL container port +## @param containerPorts.postgresql ClickHouse PostgreSQL container port +## @param containerPorts.interserver ClickHouse Interserver container port +## @param containerPorts.metrics ClickHouse metrics container port +## +containerPorts: + http: 8123 + https: 8443 + tcp: 9000 + tcpSecure: 9440 + keeper: 2181 + keeperSecure: 3181 + keeperInter: 9444 + mysql: 9004 + postgresql: 9005 + interserver: 9009 + metrics: 8001 +## Configure extra options for ClickHouse containers' liveness and readiness probes +## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-probes/#configure-probes +## @param livenessProbe.enabled Enable livenessProbe on ClickHouse containers +## @param livenessProbe.initialDelaySeconds Initial delay seconds for livenessProbe +## @param livenessProbe.periodSeconds Period seconds for livenessProbe +## @param livenessProbe.timeoutSeconds Timeout seconds for livenessProbe +## @param livenessProbe.failureThreshold Failure threshold for livenessProbe +## @param livenessProbe.successThreshold Success threshold for livenessProbe +## +livenessProbe: + enabled: true + failureThreshold: 3 + initialDelaySeconds: 10 + periodSeconds: 10 + successThreshold: 1 + timeoutSeconds: 1 +## @param readinessProbe.enabled Enable readinessProbe on ClickHouse containers +## @param readinessProbe.initialDelaySeconds Initial delay seconds for readinessProbe +## @param readinessProbe.periodSeconds Period seconds for readinessProbe +## @param readinessProbe.timeoutSeconds Timeout seconds for readinessProbe +## @param readinessProbe.failureThreshold Failure threshold for readinessProbe +## @param readinessProbe.successThreshold Success threshold for readinessProbe +## +readinessProbe: + enabled: true + failureThreshold: 3 + initialDelaySeconds: 10 + periodSeconds: 10 + successThreshold: 1 + timeoutSeconds: 1 +## @param startupProbe.enabled Enable startupProbe on ClickHouse containers +## @param startupProbe.initialDelaySeconds Initial delay seconds for startupProbe +## @param startupProbe.periodSeconds Period seconds for startupProbe +## @param startupProbe.timeoutSeconds Timeout seconds for startupProbe +## @param startupProbe.failureThreshold Failure threshold for startupProbe +## @param startupProbe.successThreshold Success threshold for startupProbe +## +startupProbe: + enabled: false + failureThreshold: 3 + initialDelaySeconds: 10 + periodSeconds: 10 + successThreshold: 1 + timeoutSeconds: 1 +## @param customLivenessProbe Custom livenessProbe that overrides the default one +## +customLivenessProbe: {} +## @param customReadinessProbe Custom readinessProbe that overrides the default one +## +customReadinessProbe: {} +## @param customStartupProbe Custom startupProbe that overrides the default one +## +customStartupProbe: {} +## ClickHouse resource requests and limits +## ref: http://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ +## @param resourcesPreset Set container resources according to one common preset (allowed values: none, nano, small, medium, large, xlarge, 2xlarge). This is ignored if resources is set (resources is recommended for production). +## More information: https://github.com/bitnami/charts/blob/main/bitnami/common/templates/_resources.tpl#L15 +## +resourcesPreset: "none" +## @param resources Set container requests and limits for different resources like CPU or memory (essential for production workloads) +## Example: +## resources: +## requests: +## cpu: 2 +## memory: 512Mi +## limits: +## cpu: 3 +## memory: 1024Mi +## +resources: {} +## Configure Pods Security Context +## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/#set-the-security-context-for-a-pod +## @param podSecurityContext.enabled Enabled ClickHouse pods' Security Context +## @param podSecurityContext.fsGroupChangePolicy Set filesystem group change policy +## @param podSecurityContext.sysctls Set kernel settings using the sysctl interface +## @param podSecurityContext.supplementalGroups Set filesystem extra groups +## @param podSecurityContext.fsGroup Set ClickHouse pod's Security Context fsGroup +## If you are using Kubernetes 1.18, the following code needs to be commented out. +## +podSecurityContext: + enabled: true + fsGroupChangePolicy: Always + sysctls: [] + supplementalGroups: [] + fsGroup: 1001 +## Configure Container Security Context +## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/#set-the-security-context-for-a-container +## @param containerSecurityContext.enabled Enable containers' Security Context +## @param containerSecurityContext.seLinuxOptions [object,nullable] Set SELinux options in container +## @param containerSecurityContext.runAsUser Set containers' Security Context runAsUser +## @param containerSecurityContext.runAsGroup Set containers' Security Context runAsGroup +## @param containerSecurityContext.runAsNonRoot Set containers' Security Context runAsNonRoot +## @param containerSecurityContext.readOnlyRootFilesystem Set read only root file system pod's +## @param containerSecurityContext.privileged Set contraller container's Security Context privileged +## @param containerSecurityContext.allowPrivilegeEscalation Set contraller container's Security Context allowPrivilegeEscalation +## @param containerSecurityContext.capabilities.drop List of capabilities to be droppedn +## @param containerSecurityContext.seccompProfile.type Set container's Security Context seccomp profile +## +containerSecurityContext: + enabled: true + seLinuxOptions: null + runAsUser: 1001 + runAsGroup: 0 + runAsNonRoot: true + privileged: false + allowPrivilegeEscalation: false + readOnlyRootFilesystem: false + capabilities: + drop: ["ALL"] + seccompProfile: + type: "RuntimeDefault" +## Authentication +## @param auth.username ClickHouse Admin username +## @param auth.password ClickHouse Admin password +## @param auth.existingSecret Name of a secret containing the Admin password +## @param auth.existingSecretKey Name of the key inside the existing secret +## +auth: + username: default + password: "" + existingSecret: "" + existingSecretKey: "" +## @param logLevel Logging level +## +logLevel: information +## @section ClickHouse keeper configuration parameters +## @param keeper.enabled Deploy ClickHouse keeper. Support is experimental. +## +keeper: + enabled: false +## @param defaultConfigurationOverrides [string] Default configuration overrides (evaluated as a template) +## +defaultConfigurationOverrides: | + + + + + + {{ include "common.names.fullname" . }} + + + + {{ .Values.logLevel }} + + {{- if or (ne (int .Values.shards) 1) (ne (int .Values.replicaCount) 1)}} + + + + {{- $shards := $.Values.shards | int }} + {{- range $shard, $e := until $shards }} + + {{- $replicas := $.Values.replicaCount | int }} + {{- range $i, $_e := until $replicas }} + + {{ printf "%s-shard%d-%d.%s.%s.svc.%s" (include "common.names.fullname" $ ) $shard $i (include "clickhouse.headlessServiceName" $) (include "common.names.namespace" $) $.Values.clusterDomain }} + {{ $.Values.service.ports.tcp }} + + + + {{- end }} + + {{- end }} + + + {{- end }} + {{- if .Values.keeper.enabled }} + + + {{/*ClickHouse keeper configuration using the helm chart */}} + {{ $.Values.containerPorts.keeper }} + {{- if .Values.tls.enabled }} + {{ $.Values.containerPorts.keeperSecure }} + {{- end }} + + /bitnami/clickhouse/keeper/coordination/log + /bitnami/clickhouse/keeper/coordination/snapshots + + + 10000 + 30000 + trace + + + + {{- $nodes := .Values.replicaCount | int }} + {{- range $node, $e := until $nodes }} + + {{ $node | int }} + + {{ $.Values.service.ports.keeperInter }} + + {{- end }} + + + {{- end }} + {{- if or .Values.keeper.enabled .Values.zookeeper.enabled .Values.externalZookeeper.servers }} + + + {{- if or .Values.keeper.enabled }} + {{- $nodes := .Values.replicaCount | int }} + {{- range $node, $e := until $nodes }} + + + {{ $.Values.service.ports.keeper }} + + {{- end }} + {{- else if .Values.zookeeper.enabled }} + {{/* Zookeeper configuration using the helm chart */}} + {{- $nodes := .Values.zookeeper.replicaCount | int }} + {{- range $node, $e := until $nodes }} + + + {{ $.Values.zookeeper.service.ports.client }} + + {{- end }} + {{- else if .Values.externalZookeeper.servers }} + {{/* Zookeeper configuration using an external instance */}} + {{- range $node :=.Values.externalZookeeper.servers }} + + {{ $node }} + {{ $.Values.externalZookeeper.port }} + + {{- end }} + {{- end }} + + {{- end }} + {{- if .Values.tls.enabled }} + + + + + + {{- $certFileName := default "tls.crt" .Values.tls.certFilename }} + {{- $keyFileName := default "tls.key" .Values.tls.certKeyFilename }} + /bitnami/clickhouse/certs/{{$certFileName}} + /bitnami/clickhouse/certs/{{$keyFileName}} + none + true + sslv2,sslv3 + true + {{- if or .Values.tls.autoGenerated .Values.tls.certCAFilename }} + {{- $caFileName := default "ca.crt" .Values.tls.certCAFilename }} + /bitnami/clickhouse/certs/{{$caFileName}} + {{- else }} + true + {{- end }} + + + true + true + sslv2,sslv3 + true + none + + AcceptCertificateHandler + + + + {{- end }} + {{- if .Values.metrics.enabled }} + + + /metrics + + true + true + true + + {{- end }} + +## @param existingOverridesConfigmap The name of an existing ConfigMap with your custom configuration for ClickHouse +## +existingOverridesConfigmap: "" +## @param extraOverrides Extra configuration overrides (evaluated as a template) apart from the default +## +extraOverrides: "" +## @param extraOverridesConfigmap The name of an existing ConfigMap with extra configuration for ClickHouse +## +extraOverridesConfigmap: "" +## @param extraOverridesSecret The name of an existing ConfigMap with your custom configuration for ClickHouse +## +extraOverridesSecret: "" +## @param usersExtraOverrides Users extra configuration overrides (evaluated as a template) apart from the default +## +usersExtraOverrides: "" +## @param usersExtraOverridesConfigmap The name of an existing ConfigMap with users extra configuration for ClickHouse +## +usersExtraOverridesConfigmap: "" +## @param usersExtraOverridesSecret The name of an existing ConfigMap with your custom users configuration for ClickHouse +## +usersExtraOverridesSecret: "" +## @param initdbScripts Dictionary of initdb scripts +## Specify dictionary of scripts to be run at first boot +## Example: +## initdbScripts: +## my_init_script.sh: | +## #!/bin/bash +## echo "Do something." +## +initdbScripts: {} +## @param initdbScriptsSecret ConfigMap with the initdb scripts (Note: Overrides `initdbScripts`) +## +initdbScriptsSecret: "" +## @param startdbScripts Dictionary of startdb scripts +## Specify dictionary of scripts to be run on every start +## Example: +## startdbScripts: +## my_start_script.sh: | +## #!/bin/bash +## echo "Do something." +## +startdbScripts: {} +## @param startdbScriptsSecret ConfigMap with the startdb scripts (Note: Overrides `startdbScripts`) +## +startdbScriptsSecret: "" +## @param command Override default container command (useful when using custom images) +## +command: + - /scripts/setup.sh +## @param args Override default container args (useful when using custom images) +## +args: [] +## @param automountServiceAccountToken Mount Service Account token in pod +## +automountServiceAccountToken: false +## @param hostAliases ClickHouse pods host aliases +## https://kubernetes.io/docs/concepts/services-networking/add-entries-to-pod-etc-hosts-with-host-aliases/ +## +hostAliases: [] +## @param podLabels Extra labels for ClickHouse pods +## ref: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/ +## +podLabels: {} +## @param podAnnotations Annotations for ClickHouse pods +## ref: https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations/ +## +podAnnotations: {} +## @param podAffinityPreset Pod affinity preset. Ignored if `affinity` is set. Allowed values: `soft` or `hard` +## ref: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#inter-pod-affinity-and-anti-affinity +## +podAffinityPreset: "" +## @param podAntiAffinityPreset Pod anti-affinity preset. Ignored if `affinity` is set. Allowed values: `soft` or `hard` +## ref: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#inter-pod-affinity-and-anti-affinity +## +podAntiAffinityPreset: soft +## Node affinity preset +## ref: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#node-affinity +## +nodeAffinityPreset: + ## @param nodeAffinityPreset.type Node affinity preset type. Ignored if `affinity` is set. Allowed values: `soft` or `hard` + ## + type: "" + ## @param nodeAffinityPreset.key Node label key to match. Ignored if `affinity` is set + ## + key: "" + ## @param nodeAffinityPreset.values Node label values to match. Ignored if `affinity` is set + ## E.g. + ## values: + ## - e2e-az1 + ## - e2e-az2 + ## + values: [] +## @param affinity Affinity for ClickHouse pods assignment +## ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity +## NOTE: `podAffinityPreset`, `podAntiAffinityPreset`, and `nodeAffinityPreset` will be ignored when it's set +## +affinity: {} +## @param nodeSelector Node labels for ClickHouse pods assignment +## ref: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/ +## +nodeSelector: {} +## @param tolerations Tolerations for ClickHouse pods assignment +## ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/ +## +tolerations: [] +## @param updateStrategy.type ClickHouse statefulset strategy type +## ref: https://kubernetes.io/docs/concepts/workloads/controllers/statefulset/#update-strategies +## +updateStrategy: + ## StrategyType + ## Can be set to RollingUpdate or OnDelete + ## + type: RollingUpdate +## @param podManagementPolicy Statefulset Pod management policy, it needs to be Parallel to be able to complete the cluster join +## Ref: https://kubernetes.io/docs/concepts/workloads/controllers/statefulset/#pod-management-policies +## +podManagementPolicy: Parallel +## @param priorityClassName ClickHouse pods' priorityClassName +## +priorityClassName: "" +## @param topologySpreadConstraints Topology Spread Constraints for pod assignment spread across your cluster among failure-domains. Evaluated as a template +## Ref: https://kubernetes.io/docs/concepts/workloads/pods/pod-topology-spread-constraints/#spread-constraints-for-pods +## +topologySpreadConstraints: [] +## @param schedulerName Name of the k8s scheduler (other than default) for ClickHouse pods +## ref: https://kubernetes.io/docs/tasks/administer-cluster/configure-multiple-schedulers/ +## +schedulerName: "" +## @param terminationGracePeriodSeconds Seconds Redmine pod needs to terminate gracefully +## ref: https://kubernetes.io/docs/concepts/workloads/pods/pod/#termination-of-pods +## +terminationGracePeriodSeconds: "" +## @param lifecycleHooks for the ClickHouse container(s) to automate configuration before or after startup +## +lifecycleHooks: {} +## @param extraEnvVars Array with extra environment variables to add to ClickHouse nodes +## e.g: +## extraEnvVars: +## - name: FOO +## value: "bar" +## +extraEnvVars: [] +## @param extraEnvVarsCM Name of existing ConfigMap containing extra env vars for ClickHouse nodes +## +extraEnvVarsCM: "" +## @param extraEnvVarsSecret Name of existing Secret containing extra env vars for ClickHouse nodes +## +extraEnvVarsSecret: "" +## @param extraVolumes Optionally specify extra list of additional volumes for the ClickHouse pod(s) +## +extraVolumes: [] +## @param extraVolumeMounts Optionally specify extra list of additional volumeMounts for the ClickHouse container(s) +## +extraVolumeMounts: [] +## @param extraVolumeClaimTemplates Optionally specify extra list of additional volumeClaimTemplates for the ClickHouse container(s) +## +extraVolumeClaimTemplates: [] +## @param sidecars Add additional sidecar containers to the ClickHouse pod(s) +## e.g: +## sidecars: +## - name: your-image-name +## image: your-image +## imagePullPolicy: Always +## ports: +## - name: portname +## containerPort: 1234 +## +sidecars: [] +## @param initContainers Add additional init containers to the ClickHouse pod(s) +## ref: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/ +## e.g: +## initContainers: +## - name: your-image-name +## image: your-image +## imagePullPolicy: Always +## command: ['sh', '-c', 'echo "hello world"'] +## +initContainers: [] +## TLS configuration +## +tls: + ## @param tls.enabled Enable TLS traffic support + ## + enabled: false + ## @param tls.autoGenerated Generate automatically self-signed TLS certificates + ## + autoGenerated: false + ## @param tls.certificatesSecret Name of an existing secret that contains the certificates + ## + certificatesSecret: "" + ## @param tls.certFilename Certificate filename + ## + certFilename: "" + ## @param tls.certKeyFilename Certificate key filename + ## + certKeyFilename: "" + ## @param tls.certCAFilename CA Certificate filename + ## If provided, PostgreSQL will authenticate TLS/SSL clients by requesting them a certificate + ## ref: https://www.postgresql.org/docs/9.6/auth-methods.html + ## + certCAFilename: "" +## @section Traffic Exposure Parameters +## + +## ClickHouse service parameters +## +service: + ## @param service.type ClickHouse service type + ## + type: ClusterIP + ## @param service.ports.http ClickHouse service HTTP port + ## @param service.ports.https ClickHouse service HTTPS port + ## @param service.ports.tcp ClickHouse service TCP port + ## @param service.ports.tcpSecure ClickHouse service TCP (secure) port + ## @param service.ports.keeper ClickHouse keeper TCP container port + ## @param service.ports.keeperSecure ClickHouse keeper TCP (secure) container port + ## @param service.ports.keeperInter ClickHouse keeper interserver TCP container port + ## @param service.ports.mysql ClickHouse service MySQL port + ## @param service.ports.postgresql ClickHouse service PostgreSQL port + ## @param service.ports.interserver ClickHouse service Interserver port + ## @param service.ports.metrics ClickHouse service metrics port + ## + ports: + http: 8123 + https: 443 + tcp: 9000 + tcpSecure: 9440 + keeper: 2181 + keeperSecure: 3181 + keeperInter: 9444 + mysql: 9004 + postgresql: 9005 + interserver: 9009 + metrics: 8001 + ## Node ports to expose + ## @param service.nodePorts.http Node port for HTTP + ## @param service.nodePorts.https Node port for HTTPS + ## @param service.nodePorts.tcp Node port for TCP + ## @param service.nodePorts.tcpSecure Node port for TCP (with TLS) + ## @param service.nodePorts.keeper ClickHouse keeper TCP container port + ## @param service.nodePorts.keeperSecure ClickHouse keeper TCP (secure) container port + ## @param service.nodePorts.keeperInter ClickHouse keeper interserver TCP container port + ## @param service.nodePorts.mysql Node port for MySQL + ## @param service.nodePorts.postgresql Node port for PostgreSQL + ## @param service.nodePorts.interserver Node port for Interserver + ## @param service.nodePorts.metrics Node port for metrics + ## NOTE: choose port between <30000-32767> + ## + nodePorts: + http: "" + https: "" + tcp: "" + tcpSecure: "" + keeper: "" + keeperSecure: "" + keeperInter: "" + mysql: "" + postgresql: "" + interserver: "" + metrics: "" + ## @param service.clusterIP ClickHouse service Cluster IP + ## e.g.: + ## clusterIP: None + ## + clusterIP: "" + ## @param service.loadBalancerIP ClickHouse service Load Balancer IP + ## ref: https://kubernetes.io/docs/concepts/services-networking/service/#type-loadbalancer + ## + loadBalancerIP: "" + ## @param service.loadBalancerSourceRanges ClickHouse service Load Balancer sources + ## ref: https://kubernetes.io/docs/tasks/access-application-cluster/configure-cloud-provider-firewall/#restrict-access-for-loadbalancer-service + ## e.g: + ## loadBalancerSourceRanges: + ## - 10.10.10.0/24 + ## + loadBalancerSourceRanges: [] + ## @param service.externalTrafficPolicy ClickHouse service external traffic policy + ## ref http://kubernetes.io/docs/tasks/access-application-cluster/create-external-load-balancer/#preserving-the-client-source-ip + ## + externalTrafficPolicy: Cluster + ## @param service.annotations Additional custom annotations for ClickHouse service + ## + annotations: {} + ## @param service.extraPorts Extra ports to expose in ClickHouse service (normally used with the `sidecars` value) + ## + extraPorts: [] + ## @param service.sessionAffinity Control where client requests go, to the same pod or round-robin + ## Values: ClientIP or None + ## ref: https://kubernetes.io/docs/concepts/services-networking/service/ + ## + sessionAffinity: None + ## @param service.sessionAffinityConfig Additional settings for the sessionAffinity + ## sessionAffinityConfig: + ## clientIP: + ## timeoutSeconds: 300 + ## + sessionAffinityConfig: {} + ## Headless service properties + ## + headless: + ## @param service.headless.annotations Annotations for the headless service. + ## + annotations: {} +## External Access to ClickHouse configuration +## +externalAccess: + ## @param externalAccess.enabled Enable Kubernetes external cluster access to ClickHouse + ## + enabled: false + ## Parameters to configure K8s service(s) used to externally access ClickHouse + ## Note: A new service per will be created + ## + service: + ## @param externalAccess.service.type Kubernetes Service type for external access. It can be NodePort, LoadBalancer or ClusterIP + ## + type: LoadBalancer + ## @param externalAccess.service.ports.http ClickHouse service HTTP port + ## @param externalAccess.service.ports.https ClickHouse service HTTPS port + ## @param externalAccess.service.ports.tcp ClickHouse service TCP port + ## @param externalAccess.service.ports.tcpSecure ClickHouse service TCP (secure) port + ## @param externalAccess.service.ports.keeper ClickHouse keeper TCP container port + ## @param externalAccess.service.ports.keeperSecure ClickHouse keeper TCP (secure) container port + ## @param externalAccess.service.ports.keeperInter ClickHouse keeper interserver TCP container port + ## @param externalAccess.service.ports.mysql ClickHouse service MySQL port + ## @param externalAccess.service.ports.postgresql ClickHouse service PostgreSQL port + ## @param externalAccess.service.ports.interserver ClickHouse service Interserver port + ## @param externalAccess.service.ports.metrics ClickHouse service metrics port + ## + ports: + http: 80 + https: 443 + tcp: 9000 + tcpSecure: 9440 + keeper: 2181 + keeperSecure: 3181 + keeperInter: 9444 + mysql: 9004 + postgresql: 9005 + interserver: 9009 + metrics: 8001 + ## @param externalAccess.service.loadBalancerIPs Array of load balancer IPs for each ClickHouse . Length must be the same as replicaCount + ## e.g: + ## loadBalancerIPs: + ## - X.X.X.X + ## - Y.Y.Y.Y + ## + loadBalancerIPs: [] + ## @param externalAccess.service.loadBalancerAnnotations Array of load balancer annotations for each ClickHouse . Length must be the same as shards multiplied by replicaCount + ## e.g: + ## loadBalancerAnnotations: + ## - external-dns.alpha.kubernetes.io/hostname: 1.external.example.com. + ## - external-dns.alpha.kubernetes.io/hostname: 2.external.example.com. + ## + loadBalancerAnnotations: [] + ## @param externalAccess.service.loadBalancerSourceRanges Address(es) that are allowed when service is LoadBalancer + ## ref: https://kubernetes.io/docs/tasks/access-application-cluster/configure-cloud-provider-firewall/#restrict-access-for-loadbalancer-service + ## e.g: + ## loadBalancerSourceRanges: + ## - 10.10.10.0/24 + ## + loadBalancerSourceRanges: [] + ## @param externalAccess.service.nodePorts.http Node port for HTTP + ## @param externalAccess.service.nodePorts.https Node port for HTTPS + ## @param externalAccess.service.nodePorts.tcp Node port for TCP + ## @param externalAccess.service.nodePorts.tcpSecure Node port for TCP (with TLS) + ## @param externalAccess.service.nodePorts.keeper ClickHouse keeper TCP container port + ## @param externalAccess.service.nodePorts.keeperSecure ClickHouse keeper TCP container port (with TLS) + ## @param externalAccess.service.nodePorts.keeperInter ClickHouse keeper interserver TCP container port + ## @param externalAccess.service.nodePorts.mysql Node port for MySQL + ## @param externalAccess.service.nodePorts.postgresql Node port for PostgreSQL + ## @param externalAccess.service.nodePorts.interserver Node port for Interserver + ## @param externalAccess.service.nodePorts.metrics Node port for metrics + ## NOTE: choose port between <30000-32767> + ## e.g: + ## nodePorts: + ## tls: + ## - 30001 + ## - 30002 + ## + nodePorts: + http: [] + https: [] + tcp: [] + tcpSecure: [] + keeper: [] + keeperSecure: [] + keeperInter: [] + mysql: [] + postgresql: [] + interserver: [] + metrics: [] + ## @param externalAccess.service.labels Service labels for external access + ## + labels: {} + ## @param externalAccess.service.annotations Service annotations for external access + ## + annotations: {} + ## @param externalAccess.service.extraPorts Extra ports to expose in the ClickHouse external service + ## + extraPorts: [] +## ClickHouse ingress parameters +## ref: http://kubernetes.io/docs/concepts/services-networking/ingress/ +## +ingress: + ## @param ingress.enabled Enable ingress record generation for ClickHouse + ## + enabled: false + ## @param ingress.pathType Ingress path type + ## + pathType: ImplementationSpecific + ## @param ingress.apiVersion Force Ingress API version (automatically detected if not set) + ## + apiVersion: "" + ## @param ingress.hostname Default host for the ingress record + ## + hostname: clickhouse.local + ## @param ingress.ingressClassName IngressClass that will be be used to implement the Ingress (Kubernetes 1.18+) + ## This is supported in Kubernetes 1.18+ and required if you have more than one IngressClass marked as the default for your cluster . + ## ref: https://kubernetes.io/blog/2020/04/02/improvements-to-the-ingress-api-in-kubernetes-1.18/ + ## + ingressClassName: "" + ## @param ingress.path Default path for the ingress record + ## NOTE: You may need to set this to '/*' in order to use this with ALB ingress controllers + ## + path: / + ## @param ingress.annotations Additional annotations for the Ingress resource. To enable certificate autogeneration, place here your cert-manager annotations. + ## Use this parameter to set the required annotations for cert-manager, see + ## ref: https://cert-manager.io/docs/usage/ingress/#supported-annotations + ## e.g: + ## annotations: + ## kubernetes.io/ingress.class: nginx + ## cert-manager.io/cluster-issuer: cluster-issuer-name + ## + annotations: {} + ## @param ingress.tls Enable TLS configuration for the host defined at `ingress.hostname` parameter + ## TLS certificates will be retrieved from a TLS secret with name: `{{- printf "%s-tls" .Values.ingress.hostname }}` + ## You can: + ## - Use the `ingress.secrets` parameter to create this TLS secret + ## - Rely on cert-manager to create it by setting the corresponding annotations + ## - Rely on Helm to create self-signed certificates by setting `ingress.selfSigned=true` + ## + tls: false + ## @param ingress.selfSigned Create a TLS secret for this ingress record using self-signed certificates generated by Helm + ## + selfSigned: false + ## @param ingress.extraHosts An array with additional hostname(s) to be covered with the ingress record + ## e.g: + ## extraHosts: + ## - name: clickhouse.local + ## path: / + ## + extraHosts: [] + ## @param ingress.extraPaths An array with additional arbitrary paths that may need to be added to the ingress under the main host + ## e.g: + ## extraPaths: + ## - path: /* + ## backend: + ## serviceName: ssl-redirect + ## servicePort: use-annotation + ## + extraPaths: [] + ## @param ingress.extraTls TLS configuration for additional hostname(s) to be covered with this ingress record + ## ref: https://kubernetes.io/docs/concepts/services-networking/ingress/#tls + ## e.g: + ## extraTls: + ## - hosts: + ## - clickhouse.local + ## secretName: clickhouse.local-tls + ## + extraTls: [] + ## @param ingress.secrets Custom TLS certificates as secrets + ## NOTE: 'key' and 'certificate' are expected in PEM format + ## NOTE: 'name' should line up with a 'secretName' set further up + ## If it is not set and you're using cert-manager, this is unneeded, as it will create a secret for you with valid certificates + ## If it is not set and you're NOT using cert-manager either, self-signed certificates will be created valid for 365 days + ## It is also possible to create and manage the certificates outside of this helm chart + ## Please see README.md for more information + ## e.g: + ## secrets: + ## - name: clickhouse.local-tls + ## key: |- + ## -----BEGIN RSA PRIVATE KEY----- + ## ... + ## -----END RSA PRIVATE KEY----- + ## certificate: |- + ## -----BEGIN CERTIFICATE----- + ## ... + ## -----END CERTIFICATE----- + ## + secrets: [] + ## @param ingress.extraRules Additional rules to be covered with this ingress record + ## ref: https://kubernetes.io/docs/concepts/services-networking/ingress/#ingress-rules + ## e.g: + ## extraRules: + ## - host: example.local + ## http: + ## path: / + ## backend: + ## service: + ## name: example-svc + ## port: + ## name: http + ## + extraRules: [] +## @section Persistence Parameters +## + +## Enable persistence using Persistent Volume Claims +## ref: https://kubernetes.io/docs/concepts/storage/persistent-volumes/ +## +persistence: + ## @param persistence.enabled Enable persistence using Persistent Volume Claims + ## + enabled: true + ## @param persistence.existingClaim Name of an existing PVC to use + ## + existingClaim: "" + ## @param persistence.storageClass Storage class of backing PVC + ## If defined, storageClassName: + ## If set to "-", storageClassName: "", which disables dynamic provisioning + ## If undefined (the default) or set to null, no storageClassName spec is + ## set, choosing the default provisioner. (gp2 on AWS, standard on + ## GKE, AWS & OpenStack) + ## + storageClass: "" + ## @param persistence.labels Persistent Volume Claim labels + ## + labels: {} + ## @param persistence.annotations Persistent Volume Claim annotations + ## + annotations: {} + ## @param persistence.accessModes Persistent Volume Access Modes + ## + accessModes: + - ReadWriteOnce + ## @param persistence.size Size of data volume + ## + size: 8Gi + ## @param persistence.selector Selector to match an existing Persistent Volume for ClickHouse data PVC + ## If set, the PVC can't have a PV dynamically provisioned for it + ## E.g. + ## selector: + ## matchLabels: + ## app: my-app + ## + selector: {} + ## @param persistence.dataSource Custom PVC data source + ## + dataSource: {} +## @section Init Container Parameters +## + +## 'volumePermissions' init container parameters +## Changes the owner and group of the persistent volume mount point to runAsUser:fsGroup values +## based on the *podSecurityContext/*containerSecurityContext parameters +## +volumePermissions: + ## @param volumePermissions.enabled Enable init container that changes the owner/group of the PV mount point to `runAsUser:fsGroup` + ## + enabled: false + ## OS Shell + Utility image + ## ref: https://hub.docker.com/r/bitnami/os-shell/tags/ + ## @param volumePermissions.image.registry [default: REGISTRY_NAME] OS Shell + Utility image registry + ## @param volumePermissions.image.repository [default: REPOSITORY_NAME/os-shell] OS Shell + Utility image repository + ## @skip volumePermissions.image.tag OS Shell + Utility image tag (immutable tags are recommended) + ## @param volumePermissions.image.pullPolicy OS Shell + Utility image pull policy + ## @param volumePermissions.image.pullSecrets OS Shell + Utility image pull secrets + ## + image: + registry: docker.io + repository: bitnami/os-shell + tag: 12-debian-12-r16 + pullPolicy: IfNotPresent + ## Optionally specify an array of imagePullSecrets. + ## Secrets must be manually created in the namespace. + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/ + ## e.g: + ## pullSecrets: + ## - myRegistryKeySecretName + ## + pullSecrets: [] + ## Init container's resource requests and limits + ## ref: http://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ + ## @param volumePermissions.resourcesPreset Set container resources according to one common preset (allowed values: none, nano, small, medium, large, xlarge, 2xlarge). This is ignored if volumePermissions.resources is set (volumePermissions.resources is recommended for production). + ## More information: https://github.com/bitnami/charts/blob/main/bitnami/common/templates/_resources.tpl#L15 + ## + resourcesPreset: "none" + ## @param volumePermissions.resources Set container requests and limits for different resources like CPU or memory (essential for production workloads) + ## Example: + ## resources: + ## requests: + ## cpu: 2 + ## memory: 512Mi + ## limits: + ## cpu: 3 + ## memory: 1024Mi + ## + resources: {} + ## Init container Container Security Context + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/#set-the-security-context-for-a-container + ## @param volumePermissions.containerSecurityContext.seLinuxOptions [object,nullable] Set SELinux options in container + ## @param volumePermissions.containerSecurityContext.runAsUser Set init container's Security Context runAsUser + ## NOTE: when runAsUser is set to special value "auto", init container will try to chown the + ## data folder to auto-determined user&group, using commands: `id -u`:`id -G | cut -d" " -f2` + ## "auto" is especially useful for OpenShift which has scc with dynamic user ids (and 0 is not allowed) + ## + containerSecurityContext: + seLinuxOptions: null + runAsUser: 0 +## @section Other Parameters +## + +## ServiceAccount configuration +## +serviceAccount: + ## @param serviceAccount.create Specifies whether a ServiceAccount should be created + ## + create: true + ## @param serviceAccount.name The name of the ServiceAccount to use. + ## If not set and create is true, a name is generated using the common.names.fullname template + ## + name: "" + ## @param serviceAccount.annotations Additional Service Account annotations (evaluated as a template) + ## + annotations: {} + ## @param serviceAccount.automountServiceAccountToken Automount service account token for the server service account + ## + automountServiceAccountToken: false +## Prometheus metrics +## +metrics: + ## @param metrics.enabled Enable the export of Prometheus metrics + ## + enabled: false + ## @param metrics.podAnnotations [object] Annotations for metrics scraping + ## + podAnnotations: + prometheus.io/scrape: "true" + prometheus.io/port: "{{ .Values.containerPorts.metrics }}" + ## Prometheus Operator ServiceMonitor configuration + ## + serviceMonitor: + ## @param metrics.serviceMonitor.enabled if `true`, creates a Prometheus Operator ServiceMonitor (also requires `metrics.enabled` to be `true`) + ## + enabled: false + ## @param metrics.serviceMonitor.namespace Namespace in which Prometheus is running + ## + namespace: "" + ## @param metrics.serviceMonitor.annotations Additional custom annotations for the ServiceMonitor + ## + annotations: {} + ## @param metrics.serviceMonitor.labels Extra labels for the ServiceMonitor + ## + labels: {} + ## @param metrics.serviceMonitor.jobLabel The name of the label on the target service to use as the job name in Prometheus + ## + jobLabel: "" + ## @param metrics.serviceMonitor.honorLabels honorLabels chooses the metric's labels on collisions with target labels + ## + honorLabels: false + ## @param metrics.serviceMonitor.interval Interval at which metrics should be scraped. + ## ref: https://github.com/coreos/prometheus-operator/blob/master/Documentation/api.md#endpoint + ## e.g: + ## interval: 10s + ## + interval: "" + ## @param metrics.serviceMonitor.scrapeTimeout Timeout after which the scrape is ended + ## ref: https://github.com/coreos/prometheus-operator/blob/master/Documentation/api.md#endpoint + ## e.g: + ## scrapeTimeout: 10s + ## + scrapeTimeout: "" + ## @param metrics.serviceMonitor.metricRelabelings Specify additional relabeling of metrics + ## + metricRelabelings: [] + ## @param metrics.serviceMonitor.relabelings Specify general relabeling + ## + relabelings: [] + ## @param metrics.serviceMonitor.selector Prometheus instance selector labels + ## ref: https://github.com/bitnami/charts/tree/main/bitnami/prometheus-operator#prometheus-configuration + ## selector: + ## prometheus: my-prometheus + ## + selector: {} + ## Prometheus Operator PrometheusRule configuration + ## + prometheusRule: + ## @param metrics.prometheusRule.enabled Create a PrometheusRule for Prometheus Operator + ## + enabled: false + ## @param metrics.prometheusRule.namespace Namespace for the PrometheusRule Resource (defaults to the Release Namespace) + ## + namespace: "" + ## @param metrics.prometheusRule.additionalLabels Additional labels that can be used so PrometheusRule will be discovered by Prometheus + ## + additionalLabels: {} + ## @param metrics.prometheusRule.rules PrometheusRule definitions + ## - alert: ClickhouseServerRestart + ## annotations: + ## message: Clickhouse-server started recently + ## expr: ClickHouseAsyncMetrics_Uptime > 1 < 180 + ## for: 5m + ## labels: + ## severity: warning + rules: [] +## @section External Zookeeper paramaters +## +externalZookeeper: + ## @param externalZookeeper.servers List of external zookeeper servers to use + ## @param externalZookeeper.port Port of the Zookeeper servers + ## + servers: [] + port: 2888 +## @section Zookeeper subchart parameters +## +## @param zookeeper.enabled Deploy Zookeeper subchart +## @param zookeeper.replicaCount Number of Zookeeper instances +## @param zookeeper.service.ports.client Zookeeper client port +## +zookeeper: + enabled: true + ## Override zookeeper default image as 3.9 is not supported https://github.com/ClickHouse/ClickHouse/issues/53749 + ## ref: https://github.com/bitnami/containers/tree/main/bitnami/zookeeper + ## @param zookeeper.image.registry [default: REGISTRY_NAME] Zookeeper image registry + ## @param zookeeper.image.repository [default: REPOSITORY_NAME/zookeeper] Zookeeper image repository + ## @skip zookeeper.image.tag Zookeeper image tag (immutable tags are recommended) + ## @param zookeeper.image.pullPolicy Zookeeper image pull policy + image: + registry: docker.io + repository: bitnami/zookeeper + tag: 3.8.4-debian-12-r0 + pullPolicy: IfNotPresent + replicaCount: 3 + service: + ports: + client: 2181 +## @section Network Policies +## Ref: https://kubernetes.io/docs/concepts/services-networking/network-policies/ +## +networkPolicy: + ## @param networkPolicy.enabled Specifies whether a NetworkPolicy should be created + ## + enabled: true + ## @param networkPolicy.allowExternal Don't require client label for connections + ## The Policy model to apply. When set to false, only pods with the correct + ## client label will have network access to the ports Clickhouse is listening + ## on. When true, Clickhouse will accept connections from any source + ## (with the correct destination port). + ## + allowExternal: true + ## @param networkPolicy.allowExternalEgress Allow the pod to access any range of port and all destinations. + ## + allowExternalEgress: true + ## @param networkPolicy.extraIngress [array] Add extra ingress rules to the NetworkPolice + ## e.g: + ## extraIngress: + ## - ports: + ## - port: 1234 + ## from: + ## - podSelector: + ## - matchLabels: + ## - role: frontend + ## - podSelector: + ## - matchExpressions: + ## - key: role + ## operator: In + ## values: + ## - frontend + extraIngress: [] + ## @param networkPolicy.extraEgress [array] Add extra ingress rules to the NetworkPolicy + ## e.g: + ## extraEgress: + ## - ports: + ## - port: 1234 + ## to: + ## - podSelector: + ## - matchLabels: + ## - role: frontend + ## - podSelector: + ## - matchExpressions: + ## - key: role + ## operator: In + ## values: + ## - frontend + ## + extraEgress: [] + ## @param networkPolicy.ingressNSMatchLabels [object] Labels to match to allow traffic from other namespaces + ## @param networkPolicy.ingressNSPodMatchLabels [object] Pod labels to match to allow traffic from other namespaces + ## + ingressNSMatchLabels: {} + ingressNSPodMatchLabels: {} diff --git a/charts/contract-watcher/Chart.lock b/charts/contract-watcher/Chart.lock deleted file mode 100644 index 0b1128288..000000000 --- a/charts/contract-watcher/Chart.lock +++ /dev/null @@ -1,6 +0,0 @@ -dependencies: -- name: common - repository: file://../common - version: 1.0.0 -digest: sha256:c68e472825af446bb3561dc92bb4659f388e197d7742c12a3e4f93a81506ac41 -generated: "2022-10-06T14:15:09.018486+03:00" diff --git a/charts/contract-watcher/Chart.yaml b/charts/contract-watcher/Chart.yaml deleted file mode 100644 index cb1faab9d..000000000 --- a/charts/contract-watcher/Chart.yaml +++ /dev/null @@ -1,29 +0,0 @@ -apiVersion: v2 -name: contract-watcher -description: A Helm chart for Contracts monitring - -# A chart can be either an 'application' or a 'library' chart. -# -# Application charts are a collection of templates that can be packaged into versioned archives -# to be deployed. -# -# Library charts provide useful utilities or functions for the chart developer. They're included as -# a dependency of application charts to inject those utilities and functions into the rendering -# pipeline. Library charts do not define any templates and therefore cannot be deployed. -type: application - -# This is the chart version. This version number should be incremented each time you make changes -# to the chart and its templates, including the app version. -# Versions are expected to follow Semantic Versioning (https://semver.org/) -version: 1.0.0 - -# This is the version number of the application being deployed. This version number should be -# incremented each time you make changes to the application. Versions are not expected to -# follow Semantic Versioning. They should reflect the version the application is using. -# It is recommended to use it with quotes. -appVersion: "v0.0.2" - -dependencies: - - name: common - version: 1.x.x - repository: "file://../common" diff --git a/charts/contract-watcher/templates/deployment.yaml b/charts/contract-watcher/templates/deployment.yaml deleted file mode 100644 index 57488b87e..000000000 --- a/charts/contract-watcher/templates/deployment.yaml +++ /dev/null @@ -1,60 +0,0 @@ -apiVersion: apps/v1 -kind: Deployment -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -spec: - {{- if not .Values.autoscaling.enabled }} - replicas: {{ .Values.replicaCount }} - {{- end }} - selector: - matchLabels: - {{- include "common.labels.matchLabels" . | nindent 6 }} - template: - metadata: - {{- with .Values.podAnnotations }} - annotations: - {{- toYaml . | nindent 8 }} - {{- end }} - labels: - {{- include "common.labels.matchLabels" . | nindent 8 }} - spec: - {{- with .Values.imagePullSecrets }} - imagePullSecrets: - {{- toYaml . | nindent 8 }} - {{- end }} - serviceAccountName: {{ include "contract-watcher.serviceAccountName" . }} - 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 }} - env: - - name: WS_URL - value: {{ .Values.wsUrl | quote }} - - name: TELEGRAM_API_TOKEN - value: {{ .Values.telegramApiToken | quote }} - - name: TELEGRAM_RECEIVERS - value: {{ .Values.telegramReceivers | quote }} - - name: DISCORD_WEBHOOK_ID - value: {{ .Values.discordWebhookId | quote }} - - name: DISCORD_WEBHOOK_TOKEN - value: {{ .Values.discordWebhookToken | quote }} - 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 }} diff --git a/charts/contract-watcher/templates/hpa.yaml b/charts/contract-watcher/templates/hpa.yaml deleted file mode 100644 index 1f3aa4a38..000000000 --- a/charts/contract-watcher/templates/hpa.yaml +++ /dev/null @@ -1,28 +0,0 @@ -{{- if .Values.autoscaling.enabled }} -apiVersion: autoscaling/v2beta1 -kind: HorizontalPodAutoscaler -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -spec: - scaleTargetRef: - apiVersion: apps/v1 - kind: Deployment - name: {{ include "common.names.fullname" . }} - minReplicas: {{ .Values.autoscaling.minReplicas }} - maxReplicas: {{ .Values.autoscaling.maxReplicas }} - metrics: - {{- if .Values.autoscaling.targetCPUUtilizationPercentage }} - - type: Resource - resource: - name: cpu - targetAverageUtilization: {{ .Values.autoscaling.targetCPUUtilizationPercentage }} - {{- end }} - {{- if .Values.autoscaling.targetMemoryUtilizationPercentage }} - - type: Resource - resource: - name: memory - targetAverageUtilization: {{ .Values.autoscaling.targetMemoryUtilizationPercentage }} - {{- end }} -{{- end }} diff --git a/charts/contract-watcher/values.yaml b/charts/contract-watcher/values.yaml deleted file mode 100644 index 44c1ce78e..000000000 --- a/charts/contract-watcher/values.yaml +++ /dev/null @@ -1,67 +0,0 @@ -# Default values for contract-watcher. -# This is a YAML-formatted file. -# Declare variables to be passed into your templates. - -global: - serviceAccount: - # Specifies whether a service account should be created - create: true - -replicaCount: 1 - -image: - repository: europe-west4-docker.pkg.dev/stakewiselabs/private/contract-watcher - pullPolicy: IfNotPresent - # Overrides the image tag whose default is the chart appVersion. - tag: "v0.0.2" - -imagePullSecrets: [] -nameOverride: "" -fullnameOverride: "" - -wsUrl: "" -telegramApiToken: "" -telegramReceivers: "" -discordWebhookId: "" -discordWebhookToken: "" - -serviceAccount: - # Annotations to add to the service account - annotations: {} - # The name of the service account to use. - # If not set and create is true, a name is generated using the fullname template - name: "" - -podAnnotations: {} - -podSecurityContext: {} - # fsGroup: 2000 - -securityContext: {} - # capabilities: - # drop: - # - ALL - # readOnlyRootFilesystem: true - # runAsNonRoot: true - # runAsUser: 1000 - -resources: - limits: - cpu: 100m - memory: 128Mi - requests: - cpu: 100m - memory: 128Mi - -autoscaling: - enabled: false - minReplicas: 1 - maxReplicas: 100 - targetCPUUtilizationPercentage: 80 - # targetMemoryUtilizationPercentage: 80 - -nodeSelector: {} - -tolerations: [] - -affinity: {} diff --git a/charts/contract-watcher/.helmignore b/charts/dirk/.helmignore similarity index 100% rename from charts/contract-watcher/.helmignore rename to charts/dirk/.helmignore diff --git a/charts/besu/Chart.lock b/charts/dirk/Chart.lock similarity index 76% rename from charts/besu/Chart.lock rename to charts/dirk/Chart.lock index 841897137..bf2e36019 100644 --- a/charts/besu/Chart.lock +++ b/charts/dirk/Chart.lock @@ -3,4 +3,4 @@ dependencies: repository: file://../common version: 1.0.0 digest: sha256:07cebde439abe4ba19bb28e844b7419dab83c7f613886416aaf3ec08e8059144 -generated: "2022-03-07T13:51:53.662835433+03:00" +generated: "2022-05-02T13:36:12.005448244+03:00" diff --git a/charts/dirk/Chart.yaml b/charts/dirk/Chart.yaml new file mode 100644 index 000000000..27af54f87 --- /dev/null +++ b/charts/dirk/Chart.yaml @@ -0,0 +1,21 @@ +apiVersion: v2 +name: dirk +description: A Helm chart for installing and configuring large scale ETH staking infrastructure on top of the Kubernetes +type: application +version: 1.1.0 +appVersion: "v22.10.0" + +keywords: + - ethereum + - blockchain + - lighthouse + - prysm + - teku + - stakewise + +home: https://stakewise.io/ + +dependencies: +- name: common + repository: file://../common + version: 1.0.0 diff --git a/charts/dirk/scripts/generate_cert.sh b/charts/dirk/scripts/generate_cert.sh new file mode 100644 index 000000000..c2f103bd0 --- /dev/null +++ b/charts/dirk/scripts/generate_cert.sh @@ -0,0 +1,46 @@ +#!/bin/bash +set -euo pipefail +IFS=$'\n\t' + +set -x + + +generate_certs() { +LOCATION=$1 +CA_CERT_NAME=$2 +CERT_NAME=$3 + +mkdir -p "${LOCATION}" +pushd "${LOCATION}" + +if [ ! -f "${CA_CERT_NAME}.key" ] +then + echo "Generating authority key" + openssl genrsa -des3 -out "${CA_CERT_NAME}_pass.key" 4096 + openssl rsa -in "${CA_CERT_NAME}_pass.key" -out "${CA_CERT_NAME}.key" +fi + +if [ ! -f "${CA_CERT_NAME}.crt" ] +then + echo "Generating authority crt" + openssl req -x509 -new -nodes -key "${CA_CERT_NAME}.key" -sha256 -days 1825 -out "${CA_CERT_NAME}.crt" +fi + +cat >"${CERT_NAME}.ext" < cutoff_timestamp )); then + echo "Wait time completed. Should exit." + rm ${CHECK_FILE} + exit 1 + else + echo "Wait for ${remaining_seconds} seconds to exit" + fi + +fi \ No newline at end of file diff --git a/charts/dirk/templates/_helpers.tpl b/charts/dirk/templates/_helpers.tpl new file mode 100644 index 000000000..7c09d6afc --- /dev/null +++ b/charts/dirk/templates/_helpers.tpl @@ -0,0 +1,62 @@ +{{/* +Expand the name of the chart. +*/}} +{{- define "dirk.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 "dirk.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 "dirk.chart" -}} +{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }} +{{- end }} + +{{/* +Common labels +*/}} +{{- define "dirk.labels" -}} +helm.sh/chart: {{ include "dirk.chart" . }} +{{ include "dirk.selectorLabels" . }} +{{- if .Chart.AppVersion }} +app.kubernetes.io/version: {{ .Chart.AppVersion | quote }} +{{- end }} +app.kubernetes.io/managed-by: {{ .Release.Service }} +{{- end }} + +{{/* +Selector labels +*/}} +{{- define "dirk.selectorLabels" -}} +app.kubernetes.io/name: {{ include "dirk.name" . }} +app.kubernetes.io/instance: {{ .Release.Name }} +{{- end }} + +{{/* +Create the name of the service account to use +*/}} +{{- define "dirk.serviceAccountName" -}} +{{- if .Values.serviceAccount.create }} +{{- default (include "dirk.fullname" .) .Values.serviceAccount.name }} +{{- else }} +{{- default "default" .Values.serviceAccount.name }} +{{- end }} +{{- end }} diff --git a/charts/dirk/templates/configmap.yaml b/charts/dirk/templates/configmap.yaml new file mode 100644 index 000000000..32463a033 --- /dev/null +++ b/charts/dirk/templates/configmap.yaml @@ -0,0 +1,64 @@ +--- +apiVersion: v1 +kind: ConfigMap +metadata: + name: {{ include "common.names.fullname" . }}-env + labels: + {{- include "common.labels.standard" . | nindent 4 }} +data: + PEERS: 1:{{ include "dirk.fullname" . }}-0.{{ include "dirk.fullname" . }}:{{ .Values.service.httpPort }},2:{{ include "dirk.fullname" . }}-1.{{ include "dirk.fullname" . }}:{{ .Values.service.httpPort }},3:{{ include "dirk.fullname" . }}-2.{{ include "dirk.fullname" . }}:{{ .Values.service.httpPort }} +--- +apiVersion: v1 +kind: ConfigMap +metadata: + name: {{ include "common.names.fullname" . }} + labels: + {{- include "common.labels.standard" . | nindent 4 }} +data: + dirk.yaml.tml: | + log-level: {{ .Values.dirk.loglevel }} + server: + id: $INDEX + name: $HOSTNAME.{{ include "dirk.fullname" . }} + listen-address: 0.0.0.0:{{ .Values.service.httpPort }} + rules: + # admin-ips is a list of IP addresses from which requests for voluntary exists will be accepted. + admin-ips: {{ .Values.dirk.server.rules.adminIPs }} + certificates: + ca-cert: file:///data/dirk/certs/ca.crt + server-cert: file:///data/dirk/certs/$HOSTNAME.{{ include "dirk.fullname" . }}.crt + server-key: file:///data/dirk/certs/$HOSTNAME.{{ include "dirk.fullname" . }}.key + storage-path: /data/dirk/storage + stores: + - name: Local + type: filesystem + location: /data/dirk/wallets + peers: + 1: {{ include "dirk.fullname" . }}-0.{{ include "dirk.fullname" . }}:{{ .Values.service.httpPort }} + 2: {{ include "dirk.fullname" . }}-1.{{ include "dirk.fullname" . }}:{{ .Values.service.httpPort }} + 3: {{ include "dirk.fullname" . }}-2.{{ include "dirk.fullname" . }}:{{ .Values.service.httpPort }} + permissions: + {{ .Values.dirk.clientName }}: + Validators: All + metrics: + listen-address: 0.0.0.0:{{ .Values.metricsPort }} + {{- if .Values.dirk.tracing }} + tracing: + {{- toYaml .Values.dirk.tracing | nindent 6 }} + {{- end }} + +--- +apiVersion: v1 +kind: ConfigMap +metadata: + name: {{ include "common.names.fullname" . }}-scripts + labels: + {{- include "common.labels.standard" . | nindent 4 }} +data: +{{ $root := . }} +{{- range $path, $_ := .Files.Glob "scripts/**.sh" }} +{{- with $root }} + {{ $path | replace "scripts/" ""}}: |- +{{ .Files.Get $path | indent 4 }} +{{- end }} +{{- end }} \ No newline at end of file diff --git a/charts/dirk/templates/external-secret.yaml b/charts/dirk/templates/external-secret.yaml new file mode 100644 index 000000000..dd121a061 --- /dev/null +++ b/charts/dirk/templates/external-secret.yaml @@ -0,0 +1,19 @@ +{{- if .Values.externalSecrets.enabled }} +apiVersion: external-secrets.io/v1beta1 +kind: ExternalSecret +metadata: + name: eso-{{ include "common.names.fullname" . }} + labels: + {{- include "common.labels.standard" . | nindent 4 }} +spec: + refreshInterval: 10m + secretStoreRef: + name: {{ .Values.externalSecrets.secretStoreRef.name }} + kind: {{ .Values.externalSecrets.secretStoreRef.kind }} + target: + name: eso-{{ include "common.names.fullname" . }} + creationPolicy: Owner + dataFrom: + - extract: + key: {{ .Values.externalSecrets.dataFrom.key }} +{{- end }} diff --git a/charts/dirk/templates/service.yaml b/charts/dirk/templates/service.yaml new file mode 100644 index 000000000..c618784f6 --- /dev/null +++ b/charts/dirk/templates/service.yaml @@ -0,0 +1,23 @@ +--- +apiVersion: v1 +kind: Service +metadata: + name: {{ include "dirk.fullname" . }} + labels: + {{- include "dirk.labels" . | nindent 4 }} + annotations: + prometheus.io/probe: "true" +spec: + type: {{ .Values.service.type }} + clusterIP: None + ports: + - port: {{ .Values.service.httpPort }} + targetPort: http + protocol: TCP + name: http + - port: {{ .Values.metricsPort }} + targetPort: metrics + protocol: TCP + name: metrics + selector: + {{- include "dirk.selectorLabels" . | nindent 4 }} \ No newline at end of file diff --git a/charts/erigon/templates/serviceaccount.yaml b/charts/dirk/templates/serviceaccount.yaml similarity index 100% rename from charts/erigon/templates/serviceaccount.yaml rename to charts/dirk/templates/serviceaccount.yaml diff --git a/charts/backend/templates/admin-servicemonitor.yaml b/charts/dirk/templates/servicemonitor.yaml similarity index 95% rename from charts/backend/templates/admin-servicemonitor.yaml rename to charts/dirk/templates/servicemonitor.yaml index 1117154bf..bd99c3387 100644 --- a/charts/backend/templates/admin-servicemonitor.yaml +++ b/charts/dirk/templates/servicemonitor.yaml @@ -15,8 +15,8 @@ metadata: {{- end }} spec: endpoints: - - port: http - path: /service/prometheus + - port: metrics + path: /metrics {{- if .Values.serviceMonitor.interval }} interval: {{ .Values.serviceMonitor.interval }} {{- end }} @@ -38,5 +38,4 @@ spec: selector: matchLabels: {{- include "common.labels.matchLabels" . | nindent 6 }} - component: "admin" {{- end }} \ No newline at end of file diff --git a/charts/dirk/templates/statefulset.yaml b/charts/dirk/templates/statefulset.yaml new file mode 100644 index 000000000..d9e8f12a7 --- /dev/null +++ b/charts/dirk/templates/statefulset.yaml @@ -0,0 +1,202 @@ +--- +apiVersion: {{ include "common.capabilities.statefulset.apiVersion" . }} +kind: StatefulSet +metadata: + name: {{ include "common.names.fullname" . }} + labels: + {{- include "common.labels.standard" . | nindent 4 }} +spec: + replicas: {{ .Values.replicaCount }} + selector: + matchLabels: + {{- include "common.labels.matchLabels" . | nindent 6 }} + serviceName: {{ include "common.names.fullname" . }} + template: + metadata: + {{- with .Values.podAnnotations }} + annotations: + {{- toYaml . | nindent 8 }} + {{- end }} + labels: + {{- include "common.labels.matchLabels" . | nindent 8 }} + spec: + {{- with .Values.nodeSelector }} + nodeSelector: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with .Values.affinity }} + affinity: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with .Values.tolerations }} + tolerations: + {{- toYaml . | nindent 8 }} + {{- end }} + topologySpreadConstraints: + - maxSkew: 1 + topologyKey: topology.kubernetes.io/zone + whenUnsatisfiable: DoNotSchedule + labelSelector: + matchLabels: + {{- include "common.labels.matchLabels" . | nindent 14 }} + {{- with .Values.imagePullSecrets }} + imagePullSecrets: + {{- toYaml . | nindent 8 }} + {{- end }} + serviceAccountName: {{ include "dirk.serviceAccountName" . }} + securityContext: + {{- toYaml .Values.global.podSecurityContext | nindent 8 }} + initContainers: + - name: init + image: "{{ .Values.initImage.repository }}:{{ .Values.initImage.tag }}" + imagePullPolicy: {{ .Values.initImage.pullPolicy }} + securityContext: + {{- toYaml .Values.global.securityContext | nindent 12 }} + command: + - bash + - -xc + - > + rm -f /data/dirk/dirty; + mkdir -p /data/dirk/certs; + export INDEX=$((${HOSTNAME##*-}+1)); + echo "$INDEX" > /data/dirk/index; + envsubst < /config/dirk.yaml.tml > /data/dirk/dirk.yaml; + printenv CA_CRT | base64 -d > /data/dirk/certs/ca.crt; + printenv CA_KEY | base64 -d > /data/dirk/certs/ca.key; + bash /scripts/generate_cert.sh /data/dirk/certs/ ca ${HOSTNAME}.{{ include "dirk.fullname" . }}; + chown -R {{ .Values.global.podSecurityContext.runAsUser }}:{{ .Values.global.podSecurityContext.fsGroup }} /data/dirk; + envFrom: + - secretRef: + name: eso-{{ include "common.names.fullname" . }} + volumeMounts: + - name: data + mountPath: /data + - name: config + mountPath: /config + - name: scripts + mountPath: /scripts + - name: fetch-keys + image: "{{ .Values.cliImage.repository }}:{{ .Values.cliImage.tag }}" + imagePullPolicy: {{ .Values.cliImage.pullPolicy }} + securityContext: + {{- toYaml .Values.global.securityContext | nindent 12 }} + envFrom: + - secretRef: + name: eso-{{ include "common.names.fullname" . }} + - configMapRef: + name: {{ include "common.names.fullname" . }}-env + args: + - "sync-dirk-keys" + - "--db-url-env" + - "ESO_DB_KEYSTORE_URL" + - "--wallet-dir" + - "/data/dirk" + - "--decryption-key-env" + - "ESO_DECRYPTION_KEY" + {{- range .Values.dirk.fetchKeysExtraFlags }} + - {{ . | quote }} + {{- end }} + volumeMounts: + - name: data + mountPath: /data + containers: + - name: dirk + image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}" + imagePullPolicy: {{ .Values.image.pullPolicy }} + securityContext: + {{- toYaml .Values.global.securityContext | nindent 12 }} + envFrom: + - secretRef: + name: eso-{{ include "common.names.fullname" . }} + args: [ "--base-dir", "/data/dirk" ] + ports: + - name: http + containerPort: {{ .Values.service.httpPort }} + protocol: TCP + - name: metrics + containerPort: {{ .Values.metricsPort }} + protocol: TCP + {{- with .Values.resources }} + resources: + {{ toYaml . | nindent 12 }} + {{- end }} + {{- if .Values.livenessProbe }} + {{- with .Values.livenessProbe }} + livenessProbe: + {{- toYaml . | nindent 12 }} + {{- end }} + {{- if .Values.readinessProbe.enabled }} + readinessProbe: + initialDelaySeconds: {{ .Values.readinessProbe.initialDelaySeconds }} + timeoutSeconds: {{ .Values.readinessProbe.timeoutSeconds }} + periodSeconds: {{ .Values.readinessProbe.periodSeconds }} + failureThreshold: {{ .Values.readinessProbe.failureThreshold }} + successThreshold: {{ .Values.readinessProbe.successThreshold }} + httpGet: + path: {{ .Values.readinessProbe.httpGet.path }} + port: {{ .Values.readinessProbe.httpGet.port }} + scheme: {{ .Values.readinessProbe.httpGet.scheme }} + {{- end }} + {{- end }} + volumeMounts: + - name: data + mountPath: /data + - name: config + mountPath: /config + - name: scripts + mountPath: /scripts + - name: fetch-keys-syncer + image: "{{ .Values.cliImage.repository }}:{{ .Values.cliImage.tag }}" + imagePullPolicy: {{ .Values.cliImage.pullPolicy }} + securityContext: + {{- toYaml .Values.global.securityContext | nindent 12 }} + envFrom: + - secretRef: + name: eso-{{ include "common.names.fullname" . }} + - configMapRef: + name: {{ include "common.names.fullname" . }}-env +# command: [ "/bin/bash", "-c", "--" ] +# args: [ "while true; do sleep 30; done;" ] + args: + - "sync-dirk-keys" + - "--db-url-env" + - "ESO_DB_KEYSTORE_URL" + - "--wallet-dir" + - "/data/dirk" + - "--decryption-key-env" + - "ESO_DECRYPTION_KEY" + - "--refresh-frequency" + - "1800" + {{- range .Values.dirk.fetchKeysExtraFlags }} + - {{ . | quote }} + {{- end }} + volumeMounts: + - name: data + mountPath: /data + - name: config + mountPath: /config + - name: scripts + mountPath: /scripts + volumes: + - name: config + configMap: + name: {{ include "common.names.fullname" . }} + - name: scripts + configMap: + name: {{ include "common.names.fullname" . }}-scripts + minReadySeconds: {{ .Values.minReadySeconds }} + volumeClaimTemplates: + - metadata: + name: data + labels: + {{- include "common.labels.statefulset" . | nindent 10 }} + {{- with .Values.persistence.annotations }} + annotations: + {{ toYaml . | nindent 10 | trim }} + {{- end }} + spec: + accessModes: {{ .Values.persistence.accessModes }} + storageClassName: {{ .Values.persistence.storageClassName }} + resources: + requests: + storage: {{ .Values.persistence.size | quote }} diff --git a/charts/dirk/values.yaml b/charts/dirk/values.yaml new file mode 100644 index 000000000..35a781801 --- /dev/null +++ b/charts/dirk/values.yaml @@ -0,0 +1,189 @@ +# Default values for dirk. +# This is a YAML-formatted file. +# Declare variables to be passed into your templates. + +global: + serviceAccount: + create: true + ## Pod Security Context + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/ + ## + podSecurityContext: + runAsNonRoot: true + runAsUser: 10000 + fsGroup: 10000 + + securityContext: + readOnlyRootFilesystem: true + runAsNonRoot: true + runAsUser: 10000 + capabilities: + drop: + - ALL + +replicaCount: 3 + +image: + repository: attestant/dirk + pullPolicy: IfNotPresent + # Overrides the image tag whose default is the chart appVersion. + tag: "1.2.0" + +## Init image is used to chown data volume, etc. +## +initImage: + repository: bash + tag: "5.2" + pullPolicy: IfNotPresent + +## CLI image is used to fetch private keys. +## +cliImage: + repository: nethermindeth/keystores-cli + tag: "v1.0.0" + pullPolicy: IfNotPresent + +externalSecrets: + enabled: false + secretStoreRef: + name: secretStoreRef + kind: SecretStore + dataFrom: + key: dirk + +dirk: + server: + rules: + adminIPs: [127.0.0.1] + loglevel: Debug + clientName: client1 + tracing: + + fetchKeysExtraFlags: [] + +imagePullSecrets: [] + +## Provide a name in place of operator for `app:` labels +## +nameOverride: "" + +## Provide a name to substitute for the full names of resources +## +fullnameOverride: "" + +## Sets logging verbosity. +## Log levels are OFF, FATAL, WARN, INFO, DEBUG, TRACE, ALL. +loggingLevel: "INFO" + +## Port on which dirk HTTP listens. +## +httpPort: 8881 + +## The port (TCP) on which Prometheus accesses metrics +## +metricsPort: 9000 + +readinessProbe: + enabled: true + initialDelaySeconds: 10 + timeoutSeconds: 3 + periodSeconds: 1 + failureThreshold: 3 + successThreshold: 3 + httpGet: + path: /metrics + port: metrics + scheme: HTTP + +minReadySeconds: 10 + +persistence: + storageClassName: "" + accessModes: + - ReadWriteOnce + size: 1Gi + annotations: {} + +livenessProbe: + exec: + command: + - /bin/bash + - /scripts/liveness_probe.sh + periodSeconds: 90 + failureThreshold: 1 + + +## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ +## +serviceAccount: + # Annotations to add to the service account + annotations: {} + # The name of the service account to use. + # If not set and create is true, a name is generated using the fullname template + name: "" + +podAnnotations: {} + +service: + type: ClusterIP + httpPort: 8881 + +## Configure resource requests and limits. +## ref: http://kubernetes.io/docs/user-guide/compute-resources/ +## +resources: {} + # We usually recommend not to specify default resources and to leave this as a conscious + # choice for the user. This also increases chances charts run on environments with little + # resources, such as Minikube. If you do want to specify resources, uncomment the following + # lines, adjust them as necessary, and remove the curly braces after 'resources:'. + # limits: + # cpu: 100m + # memory: 128Mi + # requests: + # cpu: 100m + # memory: 128Mi + +## Node labels for pod assignment +## ref: https://kubernetes.io/docs/user-guide/node-selection/ +## +nodeSelector: {} + +## Tolerations for pod assignment +## ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/ +## +tolerations: {} + +## Affinity for pod assignment +## ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity +## +affinity: {} + +## Prometheus Service Monitor +## ref: https://github.com/coreos/prometheus-operator +## https://github.com/coreos/prometheus-operator/blob/master/Documentation/api.md#endpoint +## +serviceMonitor: + ## @param metrics.serviceMonitor.enabled Create ServiceMonitor resource(s) for scraping metrics using PrometheusOperator + ## + enabled: false + ## @param metrics.serviceMonitor.namespace The namespace in which the ServiceMonitor will be created + ## + namespace: "" + ## @param metrics.serviceMonitor.interval The interval at which metrics should be scraped + ## + interval: 30s + ## @param metrics.serviceMonitor.scrapeTimeout The timeout after which the scrape is ended + ## + scrapeTimeout: "" + ## @param metrics.serviceMonitor.relabellings Metrics RelabelConfigs to apply to samples before scraping. + ## + relabellings: [] + ## @param metrics.serviceMonitor.metricRelabelings Metrics RelabelConfigs to apply to samples before ingestion. + ## + metricRelabelings: [] + ## @param metrics.serviceMonitor.honorLabels Specify honorLabels parameter to add the scrape endpoint + ## + honorLabels: false + ## @param metrics.serviceMonitor.additionalLabels Additional labels that can be used so ServiceMonitor resource(s) can be discovered by Prometheus + ## + additionalLabels: {} diff --git a/charts/erigon/Chart.lock b/charts/erigon/Chart.lock deleted file mode 100644 index 9adc32cd2..000000000 --- a/charts/erigon/Chart.lock +++ /dev/null @@ -1,6 +0,0 @@ -dependencies: -- name: common - repository: file://../common - version: 1.0.0 -digest: sha256:c68e472825af446bb3561dc92bb4659f388e197d7742c12a3e4f93a81506ac41 -generated: "2022-03-07T10:31:15.694009208+03:00" diff --git a/charts/erigon/Chart.yaml b/charts/erigon/Chart.yaml deleted file mode 100644 index baa91d204..000000000 --- a/charts/erigon/Chart.yaml +++ /dev/null @@ -1,38 +0,0 @@ -apiVersion: v2 -name: erigon -description: Ethereum implementation on the efficiency frontier -icon: https://raw.githubusercontent.com/ethereum/ethereum-org/master/public/images/logos/ETHEREUM-ICON_Black.png - -# A chart can be either an 'application' or a 'library' chart. -# -# Application charts are a collection of templates that can be packaged into versioned archives -# to be deployed. -# -# Library charts provide useful utilities or functions for the chart developer. They're included as -# a dependency of application charts to inject those utilities and functions into the rendering -# pipeline. Library charts do not define any templates and therefore cannot be deployed. -type: application - -keywords: - - ethereum - - blockchain - - erigon - - p2p -sources: - - https://github.com/ledgerwatch/erigon - -# This is the chart version. This version number should be incremented each time you make changes -# to the chart and its templates, including the app version. -# Versions are expected to follow Semantic Versioning (https://semver.org/) -version: 2.3.1 - -# This is the version number of the application being deployed. This version number should be -# incremented each time you make changes to the application. Versions are not expected to -# follow Semantic Versioning. They should reflect the version the application is using. -# It is recommended to use it with quotes. -appVersion: "v2.28.1" - -dependencies: - - name: common - version: 1.x.x - repository: "file://../common" diff --git a/charts/erigon/templates/_helpers.yaml b/charts/erigon/templates/_helpers.yaml deleted file mode 100644 index 518206168..000000000 --- a/charts/erigon/templates/_helpers.yaml +++ /dev/null @@ -1,3 +0,0 @@ -{{- define "erigon.p2pPort" -}} -{{- printf "30303" -}} -{{- end -}} diff --git a/charts/erigon/templates/clusterrole.yaml b/charts/erigon/templates/clusterrole.yaml deleted file mode 100644 index 6d7136bd1..000000000 --- a/charts/erigon/templates/clusterrole.yaml +++ /dev/null @@ -1,10 +0,0 @@ -{{- if or .Values.global.rbac.create .Values.rbac.create }} -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: {{ include "common.names.clusterRoleName" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -rules: -{{- toYaml .Values.rbac.clusterRules | nindent 0 }} -{{- end }} diff --git a/charts/erigon/templates/clusterrolebinding.yaml b/charts/erigon/templates/clusterrolebinding.yaml deleted file mode 100644 index 87d636dac..000000000 --- a/charts/erigon/templates/clusterrolebinding.yaml +++ /dev/null @@ -1,16 +0,0 @@ -{{- if or .Values.global.rbac.create .Values.rbac.create }} -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: {{ include "common.names.clusterRoleName" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: {{ include "common.names.clusterRoleName" . }} -subjects: - - kind: ServiceAccount - name: {{ include "common.names.serviceAccountName" . }} - namespace: {{ .Release.Namespace }} -{{- end }} diff --git a/charts/erigon/templates/prometheusrules.yaml b/charts/erigon/templates/prometheusrules.yaml deleted file mode 100644 index 53fb4c53c..000000000 --- a/charts/erigon/templates/prometheusrules.yaml +++ /dev/null @@ -1,35 +0,0 @@ -{{- if and (or .Values.global.metrics.enabled .Values.metrics.enabled) - (or .Values.global.metrics.prometheusRule.enabled .Values.metrics.prometheusRule.enabled) }} -apiVersion: monitoring.coreos.com/v1 -kind: PrometheusRule -metadata: - name: {{ include "common.names.fullname" . }} - {{- if .Values.metrics.prometheusRule.namespace }} - namespace: {{ .Values.metrics.prometheusRule.namespace }} - {{- else }} - namespace: {{ .Release.Namespace | quote }} - {{- end }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.metrics.prometheusRule.additionalLabels }} - {{- toYaml .Values.metrics.prometheusRule.additionalLabels | nindent 4 }} - {{- end }} -spec: - groups: - {{- with .Values.metrics.prometheusRule.rules }} - - name: {{ include "common.names.fullname" $ }} - rules: {{- tpl (toYaml .) $ | nindent 8 }} - {{- end }} - {{- if .Values.metrics.prometheusRule.default }} - - name: {{ include "common.names.fullname" $ }}-default - rules: - - alert: ErigonNodeDown - expr: up{job=" {{ include "common.names.fullname" . }}"} == 0 - for: 5m - labels: - severity: critical - annotations: - summary: Erigon Node {{ printf "{{ $labels.instance }}" }} down - description: Erigon Node {{ printf "{{ $labels.instance }}" }} is down - {{- end }} -{{- end }} \ No newline at end of file diff --git a/charts/erigon/templates/role.yaml b/charts/erigon/templates/role.yaml deleted file mode 100644 index dfbc0fe48..000000000 --- a/charts/erigon/templates/role.yaml +++ /dev/null @@ -1,10 +0,0 @@ -{{- if or .Values.global.rbac.create .Values.rbac.create -}} -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -rules: -{{- toYaml .Values.rbac.rules | nindent 0 }} -{{- end }} diff --git a/charts/erigon/templates/rolebinding.yaml b/charts/erigon/templates/rolebinding.yaml deleted file mode 100644 index 1fdb617ba..000000000 --- a/charts/erigon/templates/rolebinding.yaml +++ /dev/null @@ -1,15 +0,0 @@ -{{- if or .Values.global.rbac.create .Values.rbac.create }} -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: {{ include "common.names.serviceAccountName" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: {{ include "common.names.serviceAccountName" . }} -subjects: - - kind: ServiceAccount - name: {{ include "common.names.serviceAccountName" . }} -{{- end }} diff --git a/charts/erigon/templates/secret.yaml b/charts/erigon/templates/secret.yaml deleted file mode 100644 index 2981fe224..000000000 --- a/charts/erigon/templates/secret.yaml +++ /dev/null @@ -1,11 +0,0 @@ -{{- if .Values.global.JWTSecret }} -apiVersion: v1 -kind: Secret -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -type: Opaque -data: - jwtsecret: {{ .Values.global.JWTSecret | b64enc | quote }} -{{- end }} diff --git a/charts/erigon/templates/service-p2p.yaml b/charts/erigon/templates/service-p2p.yaml deleted file mode 100644 index 8bbe8e834..000000000 --- a/charts/erigon/templates/service-p2p.yaml +++ /dev/null @@ -1,42 +0,0 @@ -{{- if .Values.p2pNodePort.enabled -}} -{{- range $i, $e := until (int .Values.global.replicaCount) }} -{{- $port := add $.Values.p2pNodePort.startAt $i -}} -{{- if hasKey $.Values.p2pNodePort.replicaToNodePort ($i | toString) -}} - {{ $port = index $.Values.p2pNodePort.replicaToNodePort ($i | toString) }} -{{- end }} - ---- -apiVersion: v1 -kind: Service -metadata: - name: {{ include "common.names.fullname" $ }}-{{ $i }} - labels: - {{- include "common.labels.standard" $ | nindent 4 }} - pod: "{{ include "common.names.fullname" $ }}-{{ $i }}" - type: p2p - {{- with $.Values.p2pNodePort.annotations }} - annotations: - {{- toYaml . | nindent 4 }} - {{- end }} -spec: - type: {{ $.Values.p2pNodePort.type }} - externalTrafficPolicy: Local - ports: - - name: p2p-tcp - port: {{ include "erigon.p2pPort" $ }} - protocol: TCP - targetPort: p2p-tcp - nodePort: {{ $port }} - {{- if eq $.Values.p2pNodePort.type "NodePort" }} - - name: p2p-udp - port: {{ include "erigon.p2pPort" $ }} - protocol: UDP - targetPort: p2p-udp - nodePort: {{ $port }} - {{- end }} - selector: - {{- include "common.labels.matchLabels" $ | nindent 4 }} - statefulset.kubernetes.io/pod-name: "{{ include "common.names.fullname" $ }}-{{ $i }}" - -{{- end }} -{{- end }} diff --git a/charts/erigon/templates/service.yaml b/charts/erigon/templates/service.yaml deleted file mode 100644 index 92d274b18..000000000 --- a/charts/erigon/templates/service.yaml +++ /dev/null @@ -1,45 +0,0 @@ -{{- if .Values.http.enabled }} ---- -apiVersion: v1 -kind: Service -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -spec: -{{- if .Values.svcHeadless }} - clusterIP: None -{{- end }} -{{- if .Values.sessionAffinity.enabled }} - sessionAffinity: ClientIP - sessionAffinityConfig: - clientIP: - timeoutSeconds: {{ .Values.sessionAffinity.timeoutSeconds }} -{{- end }} - type: "ClusterIP" - ports: - {{- if .Values.http.enabled }} - - port: {{ .Values.http.port }} - targetPort: http - protocol: TCP - name: http - {{- end }} - {{- if .Values.global.JWTSecret }} - - port: {{ .Values.authRpc.port }} - targetPort: authrpc - protocol: TCP - name: authrpc - {{- end }} - - port: {{ .Values.grpcPort }} - targetPort: grpc - protocol: TCP - name: grpc - {{- if .Values.global.metrics.enabled }} - - port: {{ .Values.metrics.port }} - targetPort: metrics - protocol: TCP - name: metrics - {{- end }} - selector: - {{- include "common.labels.matchLabels" . | nindent 4 }} -{{- end }} diff --git a/charts/erigon/templates/servicemonitor.yaml b/charts/erigon/templates/servicemonitor.yaml deleted file mode 100644 index 5a279940c..000000000 --- a/charts/erigon/templates/servicemonitor.yaml +++ /dev/null @@ -1,42 +0,0 @@ -{{- if and (or .Values.global.metrics.enabled .Values.metrics.enabled) - (or .Values.global.metrics.serviceMonitor.enabled .Values.metrics.serviceMonitor.enabled) }} -apiVersion: monitoring.coreos.com/v1 -kind: ServiceMonitor -metadata: - name: {{ template "common.names.fullname" . }} - {{- if .Values.metrics.serviceMonitor.namespace }} - namespace: {{ .Values.metrics.serviceMonitor.namespace }} - {{- else }} - namespace: {{ .Release.Namespace | quote }} - {{- end }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.metrics.serviceMonitor.additionalLabels }} - {{- toYaml .Values.metrics.serviceMonitor.additionalLabels | nindent 4 }} - {{- end }} -spec: - endpoints: - - port: metrics - path: /debug/metrics/prometheus - {{- if .Values.metrics.serviceMonitor.interval }} - interval: {{ .Values.metrics.serviceMonitor.interval }} - {{- end }} - {{- if .Values.metrics.serviceMonitor.scrapeTimeout }} - scrapeTimeout: {{ .Values.metrics.serviceMonitor.scrapeTimeout }} - {{- end }} - {{- if .Values.metrics.serviceMonitor.honorLabels }} - honorLabels: {{ .Values.metrics.serviceMonitor.honorLabels }} - {{- end }} - {{- if .Values.metrics.serviceMonitor.relabelings }} - relabelings: {{- toYaml .Values.metrics.serviceMonitor.relabelings | nindent 6 }} - {{- end }} - {{- if .Values.metrics.serviceMonitor.metricRelabelings }} - metricRelabelings: {{- toYaml .Values.metrics.serviceMonitor.metricRelabelings | nindent 6 }} - {{- end }} - namespaceSelector: - matchNames: - - {{ .Release.Namespace }} - selector: - matchLabels: - {{- include "common.labels.matchLabels" . | nindent 6 }} -{{- end }} diff --git a/charts/erigon/templates/statefulset.yaml b/charts/erigon/templates/statefulset.yaml deleted file mode 100644 index 15b987579..000000000 --- a/charts/erigon/templates/statefulset.yaml +++ /dev/null @@ -1,250 +0,0 @@ ---- -kind: StatefulSet -apiVersion: {{ include "common.capabilities.statefulset.apiVersion" . }} -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.statefulset" . | nindent 4 }} -spec: - replicas: {{ .Values.global.replicaCount }} - podManagementPolicy: "Parallel" - selector: - matchLabels: - {{- include "common.labels.matchLabels" . | nindent 6 }} - serviceName: {{ include "common.names.fullname" . }} - template: - metadata: - labels: - {{- include "common.labels.matchLabels" . | nindent 8 }} - spec: - {{- with (concat .Values.imagePullSecrets .Values.global.imagePullSecrets) }} - imagePullSecrets: - {{- toYaml . | nindent 8 }} - {{- end }} - {{- if .Values.terminationGracePeriodSeconds }} - terminationGracePeriodSeconds: {{ .Values.terminationGracePeriodSeconds }} - {{- end }} - securityContext: - {{- toYaml .Values.podSecurityContext | nindent 8 }} - priorityClassName: {{ .Values.priorityClassName | quote }} - serviceAccountName: {{ include "common.names.serviceAccountName" . }} - initContainers: - - name: init - image: "{{ .Values.initImage.repository }}:{{ .Values.initImage.tag }}" - imagePullPolicy: {{ .Values.initImage.pullPolicy }} - securityContext: - runAsNonRoot: false - runAsUser: 0 - env: - - name: POD_IP - valueFrom: - fieldRef: - fieldPath: status.podIP - - name: POD_NAME - valueFrom: - fieldRef: - fieldPath: metadata.name - - name: POD_NAMESPACE - valueFrom: - fieldRef: - fieldPath: metadata.namespace - - name: NODE_NAME - valueFrom: - fieldRef: - fieldPath: spec.nodeName - command: - - sh - - -c - - > - echo "Namespace: ${POD_NAMESPACE} Pod: ${POD_NAME}"; - {{- if .Values.p2pNodePort.enabled }} - {{- if eq .Values.p2pNodePort.type "LoadBalancer" }} - until [ -n "$(kubectl -n ${POD_NAMESPACE} get svc/${POD_NAME} -o jsonpath='{.status.loadBalancer.ingress[0].ip}')" ]; do echo "Waiting for load balancer gets an IP" && sleep 10; done; - export EXTERNAL_PORT=$(kubectl -n ${POD_NAMESPACE} get services -l "pod in (${POD_NAME}), type in (p2p)" -o jsonpath='{.items[0].spec.ports[0].nodePort}'); - export EXTERNAL_IP=$(kubectl -n ${POD_NAMESPACE} get svc/${POD_NAME} -o jsonpath='{.status.loadBalancer.ingress[0].ip}'); - {{- else }} - export EXTERNAL_PORT=$(kubectl get services -l "pod in (${POD_NAME}), type in (p2p)" -o jsonpath='{.items[0].spec.ports[0].nodePort}'); - export EXTERNAL_IP=$(kubectl get nodes "${NODE_NAME}" -o jsonpath='{.status.addresses[?(@.type=="ExternalIP")].address}'); - {{- end }} - echo "EXTERNAL_PORT=$EXTERNAL_PORT" > /env/init-nodeport; - echo "EXTERNAL_IP=$EXTERNAL_IP" >> /env/init-nodeport; - cat /env/init-nodeport; - {{- end }} - {{- if and .Values.persistence.enabled .Values.initChownData }} - mkdir -p /data && chown -R {{ .Values.securityContext.runAsUser }}:{{ .Values.securityContext.runAsUser }} /data; - {{- end }} - volumeMounts: - - name: env-nodeport - mountPath: /env - containers: - - name: {{ .Chart.Name }} - securityContext: - {{- toYaml .Values.securityContext | nindent 12 }} - image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}" - imagePullPolicy: {{ .Values.image.pullPolicy }} - command: - - sh - - -ac - - > - {{- if .Values.p2pNodePort.enabled }} - . /env/init-nodeport; - {{- end }} - exec erigon - --datadir=/data/erigon - --private.api.addr={{ .Values.privateApiAddr }} - --chain={{ .Values.global.network }} - {{- if .Values.p2pNodePort.enabled }} - --nat=extip:$EXTERNAL_IP - --port=$EXTERNAL_PORT - {{- else }} - --nat=extip:$(POD_IP) - --port={{ include "erigon.p2pPort" . }} - {{- end }} - {{- if .Values.terminalTotalDifficulty }} - --override.terminaltotaldifficulty={{ .Values.terminalTotalDifficulty }} - {{- end }} - --private.api.addr={{ .Values.privateApiAddr }} - {{- if .Values.http.enabled}} - --http.addr={{ .Values.http.addr }} - --http.vhosts={{ .Values.http.vhosts }} - --http.corsdomain={{ .Values.http.corsDomain }} - --http.api={{ .Values.http.api }} - --http.port={{ .Values.http.port }} - {{- end }} - {{- if .Values.global.JWTSecret }} - --authrpc.jwtsecret=/secret/jwtsecret - --authrpc.addr={{ .Values.authRpc.addr }} - --authrpc.port={{ .Values.authRpc.port }} - --authrpc.vhosts={{ .Values.authRpc.vhosts }} - {{- end }} - {{- range .Values.extraFlags }} - {{ . }} - {{- end }} - {{- if .Values.global.metrics.enabled }} - --metrics - --metrics.addr={{ .Values.metrics.addr }} - --metrics.port={{ .Values.metrics.port }} - {{- end }} - env: - - name: POD_IP - valueFrom: - fieldRef: - apiVersion: v1 - fieldPath: status.podIP - ports: - - name: grpc - protocol: TCP - containerPort: {{ .Values.grpcPort }} - {{- if .Values.http.enabled }} - - name: http - protocol: TCP - containerPort: {{ .Values.http.port }} - {{- end }} - {{- if .Values.global.JWTSecret }} - - name: authrpc - protocol: TCP - containerPort: {{ .Values.authRpc.port }} - {{- end }} - {{- if .Values.global.metrics.enabled }} - - name: metrics - protocol: TCP - containerPort: {{ .Values.metrics.port }} - {{- end }} - {{- if .Values.p2pNodePort.enabled }} - - name: p2p-tcp - containerPort: {{ include "erigon.p2pPort" . }} - protocol: TCP - - name: p2p-udp - containerPort: {{ include "erigon.p2pPort" . }} - protocol: UDP - {{- end }} - resources: - {{- toYaml .Values.resources | nindent 12 }} - volumeMounts: - - name: data - mountPath: /data - {{- if .Values.global.JWTSecret }} - - name: jwtsecret - mountPath: /secret - readOnly: true - {{- end }} - {{- if .Values.p2pNodePort.enabled }} - - name: env-nodeport - mountPath: /env - {{- end }} - - name: sidecar - image: "{{ .Values.sidecar.repository }}:{{ .Values.sidecar.tag }}" - imagePullPolicy: {{ .Values.sidecar.pullPolicy }} - env: - - name: SERVER_BINDADDR - value: "{{ .Values.sidecar.bindAddr }}:{{ .Values.sidecar.bindPort }}" - - name: CLIENT_PORT - value: {{ .Values.http.port | quote }} - ports: - - containerPort: {{ .Values.sidecar.bindPort }} - name: sidecar - protocol: TCP - {{- if or .Values.global.livenessProbe.enabled .Values.livenessProbe.enabled }} - livenessProbe: - initialDelaySeconds: {{ .Values.livenessProbe.initialDelaySeconds }} - timeoutSeconds: {{ .Values.livenessProbe.timeoutSeconds }} - periodSeconds: {{ .Values.livenessProbe.periodSeconds }} - failureThreshold: {{ .Values.livenessProbe.failureThreshold }} - successThreshold: {{ .Values.livenessProbe.successThreshold }} - httpGet: - path: {{ .Values.livenessProbe.httpGet.path }} - port: {{ .Values.livenessProbe.httpGet.port }} - scheme: {{ .Values.livenessProbe.httpGet.scheme }} - {{- end }} - {{- if or .Values.global.readinessProbe.enabled .Values.readinessProbe.enabled }} - readinessProbe: - initialDelaySeconds: {{ .Values.readinessProbe.initialDelaySeconds }} - timeoutSeconds: {{ .Values.readinessProbe.timeoutSeconds }} - periodSeconds: {{ .Values.readinessProbe.periodSeconds }} - failureThreshold: {{ .Values.readinessProbe.failureThreshold }} - successThreshold: {{ .Values.readinessProbe.successThreshold }} - httpGet: - path: {{ .Values.readinessProbe.httpGet.path }} - port: {{ .Values.readinessProbe.httpGet.port }} - scheme: {{ .Values.readinessProbe.httpGet.scheme }} - {{- end }} - {{- with .Values.nodeSelector }} - nodeSelector: - {{- toYaml . | nindent 8 }} - {{- end }} - {{- with .Values.affinity }} - affinity: - {{- toYaml . | nindent 8 }} - {{- end }} - {{- with .Values.tolerations }} - tolerations: - {{- toYaml . | nindent 8 }} - {{- end }} - volumes: - {{- if .Values.global.JWTSecret }} - - name: jwtsecret - secret: - secretName: {{ include "common.names.fullname" . }} - {{- end }} - - name: env-nodeport - emptyDir: {} -{{- if (not .Values.persistence.enabled) }} - - name: data - emptyDir: {} -{{- else }} - volumeClaimTemplates: - - metadata: - name: data - labels: - {{- include "common.labels.statefulset" . | nindent 10 }} - {{- with .Values.persistence.annotations }} - annotations: - {{ toYaml . | nindent 10 | trim }} - {{- end }} - spec: - accessModes: {{ .Values.persistence.accessModes }} - storageClassName: {{ .Values.persistence.storageClassName }} - resources: - requests: - storage: {{ .Values.persistence.size | quote }} -{{- end }} diff --git a/charts/erigon/templates/tests/test-connection.yaml b/charts/erigon/templates/tests/test-connection.yaml deleted file mode 100644 index 9ee66e95c..000000000 --- a/charts/erigon/templates/tests/test-connection.yaml +++ /dev/null @@ -1,15 +0,0 @@ -apiVersion: v1 -kind: Pod -metadata: - name: " {{ include "common.names.fullname" . }}-test-connection" - labels: - {{- include "common.labels.standard" . | nindent 4 }} - annotations: - "helm.sh/hook": test -spec: - containers: - - name: wget - image: busybox - command: ['wget'] - args: [' {{ include "common.names.fullname" . }}:{{ .Values.http.port }}'] - restartPolicy: Never diff --git a/charts/erigon/values.yaml b/charts/erigon/values.yaml deleted file mode 100644 index 70465fde9..000000000 --- a/charts/erigon/values.yaml +++ /dev/null @@ -1,381 +0,0 @@ -# Default values for erigon. -# This is a YAML-formatted file. -# Declare variables to be passed into your templates. - -global: - replicaCount: 1 - - ## Eth2 network ID - ## - network: mainnet - - ## JSON Web Token (JWT) authentication is used to secure the communication - ## between the beacon node and execution client. You can generate a JWT using - ## a command line tool, for example: - ## openssl rand -hex 32 > token.txt - ## - JWTSecret: "" - - ## Credentials to fetch images from private registry - ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/ - ## - imagePullSecrets: [] - - ## Service account - ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ - ## Additional settings could be made in non-global section. - ## - serviceAccount: - # Specifies whether a service account should be created - create: true - - ## RBAC configuration. - ## ref: https://kubernetes.io/docs/reference/access-authn-authz/rbac/ - ## Additional settings could be made in non-global section. - ## - rbac: - ## Specifies whether RBAC resources are to be created - ## - create: true - - ## Monitoring - ## Additional settings could be made in non-global section. - ## - metrics: - ## Whether to enable metrics collection or not - ## - enabled: true - - ## Prometheus Service Monitor - ## ref: https://github.com/coreos/prometheus-operator - ## https://github.com/coreos/prometheus-operator/blob/master/Documentation/api.md#endpoint - ## - serviceMonitor: - ## Create ServiceMonitor resource(s) for scraping metrics using PrometheusOperator - ## - enabled: false - - ## Custom PrometheusRule to be defined - ## ref: https://github.com/coreos/prometheus-operator#customresourcedefinitions - ## - prometheusRule: - ## Create a custom prometheusRule Resource for scraping metrics using PrometheusOperator - ## - enabled: false - - ## Configure liveness and readiness probes - ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/ - ## NB! readinessProbe and livenessProbe must be disabled before fully synced - ## Additional settings could be made in non-global section. - ## - livenessProbe: - enabled: true - - readinessProbe: - enabled: true - -## Init image is used to chown data volume, initialise genesis, etc. -## -initImage: - repository: "bitnami/kubectl" - tag: "1.24" - pullPolicy: IfNotPresent - -## Sidecar image is used to perform Liveness/Readiness probes. -## -sidecar: - repository: "europe-west4-docker.pkg.dev/stakewiselabs/public/ethnode-sidecar" - tag: "v1.0.5" - pullPolicy: IfNotPresent - bindAddr: "0.0.0.0" - bindPort: 3000 - -image: - repository: thorax/erigon - pullPolicy: IfNotPresent - # Overrides the image tag whose default is the chart appVersion. - tag: "v2.28.1" - -## Credentials to fetch images from private registry -## ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/ -## -imagePullSecrets: [] -nameOverride: "" -fullnameOverride: "" - -## Erigon configuration -## - -# private api network address, for example: 127.0.0.1:9090, -# empty string means not to start the listener. -# Do not expose to public network. -# Serves remote database interface (default: "127.0.0.1:9090") -privateApiAddr: "127.0.0.1:9090" - -# http rpc endpoint settings -http: - enabled: true - port: "8545" - # HTTP-RPC server listening interface - addr: "0.0.0.0" - # Comma separated list of virtual hostnames from which to accept requests (server enforced). - # Accepts '*' wildcard - vhosts: "*" - # Comma separated list of domains from which to accept cross origin requests (browser enforced) - corsDomain: "*" - # API's offered over the HTTP-RPC interface: eth,erigon,web3,net,debug,trace,txpool,db. - # Supported methods: https://github.com/ledgerwatch/erigon/tree/devel/cmd/rpcdaemon - api: "eth,erigon,web3,net,txpool,engine" - -# Manually specify TerminalTotalDifficulty, overriding the bundled setting -terminalTotalDifficulty: "" - -grpcPort: "9090" - -## AuthRPC configuration. -## -authRpc: - port: "8551" - vhosts: "*" - addr: "0.0.0.0" - -## Extra flags for mainnet network -## -extraFlags: - - "--prune.r.before=11184524" - - "--prune=htc" - -serviceAccount: - # Annotations to add to the service account - annotations: {} - # The name of the service account to use. - # If not set and create is true, a name is generated using the fullname template - name: "" - -## Additional labels for all resources -## -additionalLabels: - client-type: "execution" - -## Termination Grace Period -## ref: https://kubernetes.io/docs/tasks/run-application/force-delete-stateful-set-pod/#delete-pods -## -terminationGracePeriodSeconds: 300 - -podSecurityContext: - fsGroup: 1001 - runAsUser: 1001 - -securityContext: {} - # capabilities: - # drop: - # - ALL - # readOnlyRootFilesystem: true - # runAsNonRoot: true - # runAsUser: 1000 - -## RBAC configuration. -## ref: https://kubernetes.io/docs/reference/access-authn-authz/rbac/ -## -rbac: - # The name of the cluster role to use. - # If not set and create is true, a name is generated using the fullname template - name: "" - ## Required ClusterRole rules - ## - clusterRules: - ## Required to obtain the nodes external IP - ## - - apiGroups: [""] - resources: - - "nodes" - verbs: - - "get" - - "list" - - "watch" - ## Required Role rules - ## - rules: - ## Required to get information about the serices nodePort. - ## - - apiGroups: [""] - resources: - - "services" - verbs: - - "get" - - "list" - - "watch" - -## Defines whether the service must be headless -## -svcHeadless: true - -## Configure session affinity for validator clients to hit the same beacon node -## for the period specified in `timeoutSeconds` -## ref: https://kubernetes.io/docs/concepts/services-networking/service/#proxy-mode-userspace -## -sessionAffinity: - # Whether to enable session affinity or not - enabled: false - # The session duration in seconds - timeoutSeconds: 86400 - -## When p2pNodePort is enabled, your P2P port will be exposed via service type NodePort. -## This will generate a service for each replica, with a port binding via NodePort. -## This is useful if you want to expose and announce your node to the Internet. -## -p2pNodePort: - ## @param p2pNodePort.enabled Expose P2P port via NodePort - ## - enabled: false - ## @param p2pNodePort.annotations - ## - annotations: {} - ## @param p2pNodePort.type - ## Options: NodePort, LoadBalancer - type: NodePort - ## @param p2pNodePort.startAt The ports allocation will start from this value - ## - startAt: 31000 - ## @param p2pNodePort.replicaToNodePort Overwrite a port for specific replicas - ## @default -- See `values.yaml` for example - replicaToNodePort: {} - # "0": 32345 - # "3": 32348 - -resources: {} - # We usually recommend not to specify default resources and to leave this as a conscious - # choice for the user. This also increases chances charts run on environments with little - # resources, such as Minikube. If you do want to specify resources, uncomment the following - # lines, adjust them as necessary, and remove the curly braces after 'resources:'. - # limits: - # cpu: 100m - # memory: 128Mi - # requests: - # cpu: 100m - # memory: 128Mi - -## Configure liveness and readiness probes -## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/ -## NB! readinessProbe and livenessProbe must be disabled before fully synced -## -livenessProbe: - initialDelaySeconds: 900 - timeoutSeconds: 3 - periodSeconds: 30 - failureThreshold: 3 - successThreshold: 1 - httpGet: - path: /eth1/liveness - port: sidecar - scheme: HTTP - -readinessProbe: - initialDelaySeconds: 30 - timeoutSeconds: 3 - periodSeconds: 30 - failureThreshold: 30 - successThreshold: 1 - httpGet: - path: /eth1/readiness - port: sidecar - scheme: HTTP - -## Node labels for pod assignment -## ref: https://kubernetes.io/docs/user-guide/node-selection/ -## -nodeSelector: {} - -## Tolerations for pod assignment -## ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/ -## -tolerations: [] - -## Affinity for pod assignment -## ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity -## -## Example: -## affinity: -## podAntiAffinity: -## requiredDuringSchedulingIgnoredDuringExecution: -## - labelSelector: -## matchExpressions: -## - key: app.kubernetes.io/name -## operator: In -## values: -## - erigon -## topologyKey: kubernetes.io/hostname -## -affinity: {} - -## Used to assign priority to pods -## ref: https://kubernetes.io/docs/concepts/configuration/pod-priority-preemption/ -## -priorityClassName: "" - -## If false, data ownership will not be reset at startup -## This allows the geth node to be run with an arbitrary user -## -initChownData: true - -## Whether or not to allocate persistent volume disk for the data directory. -## In case of node failure, the node data directory will still persist. -## -persistence: - enabled: true - storageClassName: "" - accessModes: - - ReadWriteOnce - size: 1000Gi - annotations: {} - -## Monitoring -## -metrics: - # Enable stand-alone metrics HTTP server listening interface - addr: "0.0.0.0" - # Metrics HTTP server listening port - port: "6060" - - ## Prometheus Service Monitor - ## ref: https://github.com/coreos/prometheus-operator - ## https://github.com/coreos/prometheus-operator/blob/master/Documentation/api.md#endpoint - ## - serviceMonitor: - ## The namespace in which the ServiceMonitor will be created - ## - namespace: "" - ## The interval at which metrics should be scraped - ## - interval: 30s - ## The timeout after which the scrape is ended - ## - scrapeTimeout: "" - ## Metrics RelabelConfigs to apply to samples before scraping. - ## - relabellings: [] - ## Metrics RelabelConfigs to apply to samples before ingestion. - ## - metricRelabelings: [] - ## Specify honorLabels parameter to add the scrape endpoint - ## - honorLabels: false - ## Additional labels that can be used so ServiceMonitor resource(s) can be discovered by Prometheus - ## - additionalLabels: {} - ## Custom PrometheusRule to be defined - ## ref: https://github.com/coreos/prometheus-operator#customresourcedefinitions - ## - prometheusRule: - ## Create a default set of Alerts - ## - default: true - ## The namespace in which the prometheusRule will be created - ## - namespace: "" - ## Additional labels for the prometheusRule - ## - additionalLabels: {} - ## Custom Prometheus rules - ## - rules: [] diff --git a/charts/erigon/.helmignore b/charts/execution-beacon/.helmignore similarity index 100% rename from charts/erigon/.helmignore rename to charts/execution-beacon/.helmignore diff --git a/charts/validator-monitor/Chart.lock b/charts/execution-beacon/Chart.lock similarity index 77% rename from charts/validator-monitor/Chart.lock rename to charts/execution-beacon/Chart.lock index 53c2d8c05..cf81c09bd 100644 --- a/charts/validator-monitor/Chart.lock +++ b/charts/execution-beacon/Chart.lock @@ -3,4 +3,4 @@ dependencies: repository: file://../common version: 1.0.0 digest: sha256:07cebde439abe4ba19bb28e844b7419dab83c7f613886416aaf3ec08e8059144 -generated: "2022-07-01T13:50:38.331325+03:00" +generated: "2023-01-11T16:47:14.095745+02:00" diff --git a/charts/execution-beacon/Chart.yaml b/charts/execution-beacon/Chart.yaml new file mode 100644 index 000000000..08373cb6b --- /dev/null +++ b/charts/execution-beacon/Chart.yaml @@ -0,0 +1,19 @@ +apiVersion: v2 +name: execution-beacon +version: 1.0.0 +appVersion: 0.0.1 +kubeVersion: "^1.23.0-0" +description: Execution and Beacon +type: application +keywords: + - ethereum + - blockchain + - nethermind + - prysm + - p2p +home: https://www.ethereum.org/ + +dependencies: + - name: common + repository: file://../common + version: 1.0.0 diff --git a/charts/execution-beacon/templates/_helpers.yaml b/charts/execution-beacon/templates/_helpers.yaml new file mode 100644 index 000000000..e57c452df --- /dev/null +++ b/charts/execution-beacon/templates/_helpers.yaml @@ -0,0 +1,27 @@ +{{- define "execution.p2pPort" -}} +{{- printf "30303" -}} +{{- end -}} +{{- define "prysm.p2pPort" -}} +{{- printf "13000" -}} +{{- end -}} +{{- define "lighthouse.p2pPort" -}} +{{- printf "9000" -}} +{{- end -}} +{{- define "teku.p2pPort" -}} +{{- printf "9000" -}} +{{- end -}} +{{- define "nimbus.p2pPort" -}} +{{- printf "9000" -}} +{{- end -}} +{{- define "lodestar.p2pPort" -}} +{{- printf "9000" -}} +{{- end -}} + +{{- define "beacon.p2pPort" -}} +{{- $p2pPort := index (dict "lighthouse" (include "lighthouse.p2pPort" .) "teku" (include "teku.p2pPort" .) "prysm" (include "prysm.p2pPort" .) "nimbus" (include "nimbus.p2pPort" .) "lodestar" (include "lodestar.p2pPort" .)) .Values.beacon.client -}} +{{- if $p2pPort -}} +{{- $p2pPort -}} +{{- else -}} +{{- fail "Invalid beacon client specified" -}} +{{- end -}} +{{- end -}} \ No newline at end of file diff --git a/charts/besu/templates/clusterrole.yaml b/charts/execution-beacon/templates/clusterrole.yaml similarity index 100% rename from charts/besu/templates/clusterrole.yaml rename to charts/execution-beacon/templates/clusterrole.yaml diff --git a/charts/besu/templates/clusterrolebinding.yaml b/charts/execution-beacon/templates/clusterrolebinding.yaml similarity index 100% rename from charts/besu/templates/clusterrolebinding.yaml rename to charts/execution-beacon/templates/clusterrolebinding.yaml diff --git a/charts/execution-beacon/templates/configmap.yaml b/charts/execution-beacon/templates/configmap.yaml new file mode 100644 index 000000000..a58bd0b81 --- /dev/null +++ b/charts/execution-beacon/templates/configmap.yaml @@ -0,0 +1,39 @@ +--- +apiVersion: v1 +kind: ConfigMap +metadata: + name: {{ include "common.names.fullname" . }}-init + labels: + {{- include "common.labels.standard" . | nindent 4 }} +data: + init.sh: | + #!/bin/sh +{{- if or (and .Values.execution.persistence.enabled .Values.execution.initChownData) (and .Values.beacon.persistence.enabled .Values.beacon.initChownData) (.Values.sharedPersistence.enabled) }} + # mkdir -p /data && chown -R {{ .Values.global.podSecurityContext.runAsUser }}:{{ .Values.global.podSecurityContext.runAsUser }} /data; + mkdir -p /data/beacon && chown -R {{ .Values.global.podSecurityContext.runAsUser }}:{{ .Values.global.podSecurityContext.runAsUser }} /data/beacon; +{{- end }} + echo "Namespace: ${POD_NAMESPACE} Pod: ${POD_NAME}"; +{{- if .Values.global.p2pNodePort.enabled }} + {{- if eq .Values.global.p2pNodePort.type "LoadBalancer" }} + until [ -n "$(kubectl -n ${POD_NAMESPACE} get svc/${POD_NAME} -o jsonpath='{.status.loadBalancer.ingress[0].ip}')" ]; do echo "Waiting for load balancer to get an IP" && sleep 10; done; + export EXTERNAL_EXECUTION_PORT=$(kubectl -n ${POD_NAMESPACE} get services -l "client=execution,pod in (${POD_NAME}), type in (p2p)" -o jsonpath='{.items[0].spec.ports[0].nodePort}'); + export EXTERNAL_BEACON_PORT=$(kubectl -n ${POD_NAMESPACE} get services -l "client=beacon,pod in (${POD_NAME}), type in (p2p)" -o jsonpath='{.items[0].spec.ports[0].nodePort}'); + export EXTERNAL_IP=$(kubectl -n ${POD_NAMESPACE} get svc/${POD_NAME} -o jsonpath='{.status.loadBalancer.ingress[0].ip}'); + {{- else }} + export EXTERNAL_EXECUTION_PORT=$(kubectl get services -l "client=execution,pod in (${POD_NAME}), type in (p2p)" -o jsonpath='{.items[0].spec.ports[0].nodePort}'); + export EXTERNAL_BEACON_PORT=$(kubectl get services -l "client=beacon,pod in (${POD_NAME}), type in (p2p)" -o jsonpath='{.items[0].spec.ports[0].nodePort}'); + export EXTERNAL_IP=$(kubectl get nodes "${NODE_NAME}" -o jsonpath='{.status.addresses[?(@.type=="ExternalIP")].address}'); + {{- end }} + echo "EXTERNAL_EXECUTION_PORT=$EXTERNAL_EXECUTION_PORT" > /env/init-nodeport; + echo "EXTERNAL_BEACON_PORT=$EXTERNAL_BEACON_PORT" >> /env/init-nodeport; + echo "EXTERNAL_IP=$EXTERNAL_IP" >> /env/init-nodeport; + cat /env/init-nodeport; + {{- if eq .Values.beacon.client "prysm" }} + touch /data/beacon/config.yaml; + echo "p2p-host-ip: $EXTERNAL_IP" > /data/beacon/config.yaml; + echo "p2p-tcp-port: $EXTERNAL_BEACON_PORT" >> /data/beacon/config.yaml; + echo "p2p-udp-port: $EXTERNAL_BEACON_PORT" >> /data/beacon/config.yaml; + echo "Updated Prysm config.yaml file at /data/beacon/config.yaml"; + {{- end }} + if [ -f "/data/beacon/config.yaml" ]; then echo "Beacon client config:" && cat "/data/beacon/config.yaml"; fi; +{{- end }} \ No newline at end of file diff --git a/charts/execution-beacon/templates/prometheusrules.yaml b/charts/execution-beacon/templates/prometheusrules.yaml new file mode 100644 index 000000000..d9afee3ad --- /dev/null +++ b/charts/execution-beacon/templates/prometheusrules.yaml @@ -0,0 +1,175 @@ +{{- if and (or .Values.execution.metrics.enabled .Values.beacon.metrics.enabled) + (or .Values.execution.metrics.prometheusRule.enabled .Values.beacon.metrics.prometheusRule.enabled) }} +apiVersion: monitoring.coreos.com/v1 +kind: PrometheusRule +metadata: + name: {{ include "common.names.fullname" . }}-execution + {{- if .Values.global.metrics.prometheusRule.namespace }} + namespace: {{ .Values.global.metrics.prometheusRule.namespace }} + {{- else }} + namespace: {{ .Release.Namespace | quote }} + {{- end }} + labels: + {{- include "common.labels.standard" . | nindent 4 }} + {{- if .Values.global.metrics.prometheusRule.additionalLabels }} + {{- toYaml .Values.global.metrics.prometheusRule.additionalLabels | nindent 4 }} + {{- end }} +spec: + groups: + {{- with .Values.global.metrics.prometheusRule.rules }} + - name: {{ include "common.names.fullname" $ }} + rules: {{- tpl (toYaml .) $ | nindent 8 }} + {{- end }} + {{- if .Values.global.metrics.prometheusRule.default }} + {{- if eq .Values.execution.client "geth" }} + - name: {{ include "common.names.fullname" $ }}-default + rules: + - alert: GethNodeDown + expr: up{job="{{ include "common.names.fullname" . }}"} == 0 + for: 5m + labels: + severity: critical + annotations: + summary: Geth Node {{ printf "{{ $labels.instance }}" }} down + description: Geth Node {{ printf "{{ $labels.instance }}" }} is down + {{- else if eq .Values.execution.client "nethermind" }} + - name: {{ include "common.names.fullname" $ }}-default + rules: + - alert: NethermindNodeDown + expr: up{job="{{ include "common.names.fullname" . }}"} == 0 + for: 5m + labels: + severity: critical + annotations: + summary: Nethermind Node {{ printf "{{ $labels.instance }}" }} down + description: Nethermind Node {{ printf "{{ $labels.instance }}" }} is down + {{- end }} + {{- end }} +--- +apiVersion: monitoring.coreos.com/v1 +kind: PrometheusRule +metadata: + name: {{ include "common.names.fullname" . }}-beacon + {{- if .Values.global.metrics.prometheusRule.namespace }} + namespace: {{ .Values.global.metrics.prometheusRule.namespace }} + {{- else }} + namespace: {{ .Release.Namespace | quote }} + {{- end }} + labels: + {{- include "common.labels.standard" . | nindent 4 }} + {{- if .Values.global.metrics.prometheusRule.additionalLabels }} + {{- toYaml .Values.global.metrics.prometheusRule.additionalLabels | nindent 4 }} + {{- end }} +spec: + groups: + {{- with .Values.global.metrics.prometheusRule.rules }} + - name: {{ include "common.names.fullname" $ }} + rules: {{- tpl (toYaml .) $ | nindent 8 }} + {{- end }} + {{- if .Values.global.metrics.prometheusRule.default }} + {{- if eq .Values.beacon.client "lighthouse" }} + - name: {{ include "common.names.fullname" $ }}-default + rules: + - alert: LighthouseBeaconNodeDown + expr: up{job='{{ include "common.names.fullname" . }}'} == 0 + for: 1m + labels: + severity: critical + annotations: + summary: Lighthouse beacon node is down + description: Check {{ printf "{{ $labels.pod }}" }} beacon node in namespace {{ printf "{{ $labels.namespace }}" }} + - alert: LighthouseBeaconNodeIsNotConnectedToEth1Node + expr: sync_eth1_connected{job='{{ include "common.names.fullname" . }}'} == 0 + for: 1m + labels: + severity: critical + annotations: + summary: Lighthouse beacon node is not connected to eth1 node + description: Check {{ printf "{{ $labels.pod }}" }} beacon node in namespace {{ printf "{{ $labels.namespace }}" }} + - alert: LighthouseBeaconNodeIsOutOfSync + expr: sync_eth2_synced{job='{{ include "common.names.fullname" . }}'} == 0 + for: 3m + labels: + severity: critical + annotations: + summary: Lighthouse beacon node is out of sync + description: Check {{ printf "{{ $labels.pod }}" }} beacon node in namespace {{ printf "{{ $labels.namespace }}" }} + {{- else if eq .Values.beacon.client "prysm" }} + - name: {{ include "common.names.fullname" $ }}-default + rules: + - alert: PrysmBeaconNodeDown + expr: up{job='{{ include "common.names.fullname" . }}'} == 0 + for: 1m + labels: + severity: critical + annotations: + summary: Prysm beacon node is down + description: Check {{ printf "{{ $labels.pod }}" }} beacon node in namespace {{ printf "{{ $labels.namespace }}" }} + - alert: Prysm50SlotsBehind + expr: beacon_clock_time_slot{job='{{ include "common.names.fullname" . }}'}-beacon_head_slot{job='{{ include "common.names.fullname" . }}'} > 50 + for: 2m + labels: + severity: critical + annotations: + summary: Prysm beacon node is out of sync + description: Check {{ printf "{{ $labels.pod }}" }} beacon node in namespace {{ printf "{{ $labels.namespace }}" }} + - alert: PrysmParticipationRateLessThen66Percent + expr: beacon_prev_epoch_target_gwei{job='{{ include "common.names.fullname" . }}'}/beacon_prev_epoch_active_gwei{job='{{ include "common.names.fullname" . }}'}*100 < 66 + for: 5m + labels: + severity: critical + annotations: + summary: Prysm beacon node participation rate less then 66% + description: Check {{ printf "{{ $labels.pod }}" }} beacon node in namespace {{ printf "{{ $labels.namespace }}" }} + - alert: PrysmBeaconNodeRestarted + expr: (time()-process_start_time_seconds{job='{{ include "common.names.fullname" . }}'})/3600 < 0.1 + for: 1m + labels: + severity: warning + annotations: + summary: Prysm beacon node was restarted + description: Check {{ printf "{{ $labels.pod }}" }} beacon node in namespace {{ printf "{{ $labels.namespace }}" }} + {{- else if eq .Values.beacon.client "teku" }} + - name: {{ include "common.names.fullname" $ }}-default + rules: + - alert: TekuBeaconNodeDown + expr: up{job='{{ include "common.names.fullname" . }}'} == 0 + for: 1m + labels: + severity: critical + annotations: + summary: Teku beacon node is down + description: Check {{ printf "{{ $labels.pod }}" }} beacon node in namespace {{ printf "{{ $labels.namespace }}" }} + - alert: Teku50SlotsBehind + expr: beacon_slot{job='{{ include "common.names.fullname" . }}'}-beacon_head_slot{job='{{ include "common.names.fullname" . }}'} > 50 + for: 2m + labels: + severity: critical + annotations: + summary: Teku beacon node is out of sync + description: Check {{ printf "{{ $labels.pod }}" }} beacon node in namespace {{ printf "{{ $labels.namespace }}" }} + {{- else if eq .Values.beacon.client "nimbus" }} + - name: {{ include "common.names.fullname" $ }}-default + rules: + - alert: NimbusBeaconNodeDown + expr: up{job='{{ include "common.names.fullname" . }}'} == 0 + for: 1m + labels: + severity: critical + annotations: + summary: Nimbus beacon node is down + description: Check {{ printf "{{ $labels.pod }}" }} beacon node in namespace {{ printf "{{ $labels.namespace }}" }} + {{- else if eq .Values.beacon.client "lodestar" }} + - name: {{ include "common.names.fullname" $ }}-default + rules: + - alert: LodestarBeaconNodeDown + expr: up{job='{{ include "common.names.fullname" . }}'} == 0 + for: 1m + labels: + severity: critical + annotations: + summary: Lodestar beacon node is down + description: Check {{ printf "{{ $labels.pod }}" }} beacon node in namespace {{ printf "{{ $labels.namespace }}" }} + {{- end }} + {{- end }} +{{- end }} \ No newline at end of file diff --git a/charts/besu/templates/role.yaml b/charts/execution-beacon/templates/role.yaml similarity index 100% rename from charts/besu/templates/role.yaml rename to charts/execution-beacon/templates/role.yaml diff --git a/charts/besu/templates/rolebinding.yaml b/charts/execution-beacon/templates/rolebinding.yaml similarity index 100% rename from charts/besu/templates/rolebinding.yaml rename to charts/execution-beacon/templates/rolebinding.yaml diff --git a/charts/execution-beacon/templates/secret.yaml b/charts/execution-beacon/templates/secret.yaml new file mode 100644 index 000000000..bd00d306b --- /dev/null +++ b/charts/execution-beacon/templates/secret.yaml @@ -0,0 +1,30 @@ +{{- if .Values.global.JWTSecret }} +apiVersion: v1 +kind: Secret +metadata: + name: {{ include "common.names.fullname" . }} + labels: + {{- include "common.labels.standard" . | nindent 4 }} +type: Opaque +data: + jwtsecret: {{ .Values.global.JWTSecret | b64enc | quote }} +{{- end }} +--- +{{- if .Values.global.externalSecrets.enabled }} +apiVersion: external-secrets.io/v1beta1 +kind: ExternalSecret +metadata: + name: eso-{{ include "common.names.fullname" . }} + labels: + {{- include "common.labels.standard" . | nindent 4 }} +spec: + refreshInterval: 10m + secretStoreRef: + name: {{ .Values.global.externalSecrets.secretStoreRef.name }} + kind: {{ .Values.global.externalSecrets.secretStoreRef.kind }} + target: + name: eso-{{ include "common.names.fullname" . }} + creationPolicy: Owner + data: + {{- .Values.global.externalSecrets.data | toYaml | trim | nindent 2 }} +{{- end }} \ No newline at end of file diff --git a/charts/execution-beacon/templates/service-p2p.yaml b/charts/execution-beacon/templates/service-p2p.yaml new file mode 100644 index 000000000..0e02f11c5 --- /dev/null +++ b/charts/execution-beacon/templates/service-p2p.yaml @@ -0,0 +1,79 @@ +{{- if .Values.global.p2pNodePort.enabled -}} +{{- range $i, $e := until (int .Values.global.replicaCount) }} +{{- $portExecution := add $.Values.global.p2pNodePort.startAtExecution $i -}} +{{- $portBeacon := add $.Values.global.p2pNodePort.startAtBeacon $i -}} +{{- if hasKey $.Values.global.p2pNodePort.replicaToNodePort ($i | toString) -}} + {{ $portExecution = index $.Values.global.p2pNodePort.replicaToNodePort ($i | toString) }} + {{ $portBeacon = index $.Values.global.p2pNodePort.replicaToNodePort ($i | toString) }} +{{- end }} + +--- +apiVersion: v1 +kind: Service +metadata: + name: {{ include "common.names.fullname" $ }}-execution-{{ $i }} + labels: + {{- include "common.labels.standard" $ | nindent 4 }} + pod: "{{ include "common.names.fullname" $ }}-{{ $i }}" + type: p2p + client: execution + {{- with $.Values.global.p2pNodePort.annotations }} + annotations: + {{- toYaml . | nindent 4 }} + {{- end }} +spec: + type: {{ $.Values.global.p2pNodePort.type }} + externalTrafficPolicy: Local + ports: + - name: p2p-tcp-exec + port: {{ include "execution.p2pPort" $ }} + protocol: TCP + targetPort: {{ $portExecution }} + nodePort: {{ $portExecution }} + {{- if eq $.Values.global.p2pNodePort.type "NodePort" }} + - name: p2p-udp-exec + port: {{ include "execution.p2pPort" $ }} + protocol: UDP + targetPort: {{ $portExecution }} + nodePort: {{ $portExecution }} + {{- end }} + selector: + {{- include "common.labels.matchLabels" $ | nindent 4 }} + statefulset.kubernetes.io/pod-name: "{{ include "common.names.fullname" $ }}-{{ $i }}" + +--- +apiVersion: v1 +kind: Service +metadata: + name: {{ include "common.names.fullname" $ }}-beacon-{{ $i }} + labels: + {{- include "common.labels.standard" $ | nindent 4 }} + pod: "{{ include "common.names.fullname" $ }}-{{ $i }}" + type: p2p + client: beacon + {{- with $.Values.global.p2pNodePort.annotations }} + annotations: + {{- toYaml . | nindent 4 }} + {{- end }} +spec: + type: {{ $.Values.global.p2pNodePort.type }} + externalTrafficPolicy: Local + ports: + - name: p2p-tcp-beacon + port: {{ include "beacon.p2pPort" $ }} + protocol: TCP + targetPort: {{ $portBeacon }} + nodePort: {{ $portBeacon }} + {{- if eq $.Values.global.p2pNodePort.type "NodePort" }} + - name: p2p-udp-beacon + port: {{ include "beacon.p2pPort" $ }} + protocol: UDP + targetPort: {{ $portBeacon }} + nodePort: {{ $portBeacon }} + {{- end }} + selector: + {{- include "common.labels.matchLabels" $ | nindent 4 }} + statefulset.kubernetes.io/pod-name: "{{ include "common.names.fullname" $ }}-{{ $i }}" + +{{- end }} +{{- end }} diff --git a/charts/execution-beacon/templates/service.yaml b/charts/execution-beacon/templates/service.yaml new file mode 100644 index 000000000..9a06281be --- /dev/null +++ b/charts/execution-beacon/templates/service.yaml @@ -0,0 +1,74 @@ +--- +apiVersion: v1 +kind: Service +metadata: + name: {{ include "common.names.fullname" . }} + labels: + {{- include "common.labels.standard" . | nindent 4 }} + pod: "{{ include "common.names.fullname" . }}" + type: api + execution: {{ .Values.execution.client }} + beacon: {{ .Values.beacon.client }} +{{- if and .Values.execution.metrics.enabled .Values.execution.metrics.svcAnnotations }} + annotations: + {{ toYaml .Values.execution.metrics.svcAnnotations | nindent 4 | trim }} +{{- else }} + annotations: + {{ toYaml .Values.beacon.metrics.svcAnnotations | nindent 4 | trim }} +{{- end }} +spec: +{{- if .Values.global.sessionAffinity.enabled }} + sessionAffinity: ClientIP + sessionAffinityConfig: + clientIP: + timeoutSeconds: {{ .Values.global.sessionAffinity.timeoutSeconds }} +{{- end }} + type: ClusterIP +{{- if .Values.global.service.svcHeadless }} + clusterIP: None +{{- end }} + ports: + {{- if .Values.execution.jsonrpc.enabled }} + - name: jsonrpc-exec + port: {{ .Values.execution.jsonrpc.http.port }} + targetPort: jsonrpc-exec + - port: {{ .Values.execution.jsonrpc.engine.port }} + targetPort: engine-exec + name: engine-exec + {{- end }} + {{- if eq .Values.execution.client "erigon" }} + - name: grpc-exec + protocol: TCP + port: {{ .Values.execution.jsonrpc.grpc.port }} + targetPort: grpc-exec + {{- end }} + {{- if .Values.execution.jsonrpc.websocket.enabled }} + - name: ws-exec + port: {{ .Values.execution.jsonrpc.websocket.port }} + targetPort: ws-exec + protocol: TCP + {{- end }} + {{- if .Values.execution.metrics.enabled }} + - name: metrics-exec + port: {{ .Values.execution.metrics.port }} + targetPort: metrics-exec + protocol: TCP + {{- end }} + {{- if and (eq .Values.beacon.client "prysm") .Values.beacon.grpc.enabled }} + - name: {{ .Values.beacon.grpc.portName }}-beacon + port: {{ .Values.beacon.grpc.port }} + targetPort: {{ .Values.beacon.grpc.portName }}-beacon + {{- end }} + {{- if .Values.beacon.restApi.enabled }} + - name: http-beacon + port: {{ index .Values.beacon.restApi.portMap .Values.beacon.client }} + targetPort: http-beacon + {{- end }} + {{- if and .Values.global.metrics.enabled .Values.beacon.metrics.enabled }} + - name: metrics-beacon + port: {{ .Values.beacon.metrics.port }} + targetPort: metrics-beacon + {{- end }} + selector: + {{- include "common.labels.matchLabels" . | nindent 4 }} + diff --git a/charts/contract-watcher/templates/serviceaccount.yaml b/charts/execution-beacon/templates/serviceaccount.yaml similarity index 85% rename from charts/contract-watcher/templates/serviceaccount.yaml rename to charts/execution-beacon/templates/serviceaccount.yaml index ad5aa4d50..749322716 100644 --- a/charts/contract-watcher/templates/serviceaccount.yaml +++ b/charts/execution-beacon/templates/serviceaccount.yaml @@ -1,4 +1,4 @@ -{{- if .Values.serviceAccount.create -}} +{{- if .Values.global.serviceAccount.create -}} apiVersion: v1 kind: ServiceAccount metadata: diff --git a/charts/execution-beacon/templates/servicemonitor.yaml b/charts/execution-beacon/templates/servicemonitor.yaml new file mode 100644 index 000000000..543c5d0bb --- /dev/null +++ b/charts/execution-beacon/templates/servicemonitor.yaml @@ -0,0 +1,86 @@ +{{- if and (or .Values.execution.metrics.enabled .Values.beacon.metrics.enabled) + (or .Values.execution.metrics.serviceMonitor.enabled .Values.beacon.metrics.serviceMonitor.enabled) }} +apiVersion: monitoring.coreos.com/v1 +kind: ServiceMonitor +metadata: + name: {{ template "common.names.fullname" . }}-execution + {{- if .Values.execution.metrics.serviceMonitor.namespace }} + namespace: {{ .Values.execution.metrics.serviceMonitor.namespace }} + {{- else }} + namespace: {{ .Release.Namespace | quote }} + {{- end }} + labels: + {{- include "common.labels.standard" . | nindent 4 }} + {{- if .Values.execution.metrics.serviceMonitor.additionalLabels }} + {{- toYaml .Values.execution.metrics.serviceMonitor.additionalLabels | nindent 4 }} + {{- end }} +spec: + endpoints: + - port: metrics-exec + {{- if eq .Values.execution.client "geth" }} + path: /debug/metrics/prometheus + {{- else }} + path: /metrics + {{- end }} + {{- if .Values.execution.metrics.serviceMonitor.interval }} + interval: {{ .Values.execution.metrics.serviceMonitor.interval }} + {{- end }} + {{- if .Values.execution.metrics.serviceMonitor.scrapeTimeout }} + scrapeTimeout: {{ .Values.execution.metrics.serviceMonitor.scrapeTimeout }} + {{- end }} + {{- if .Values.execution.metrics.serviceMonitor.honorLabels }} + honorLabels: {{ .Values.execution.metrics.serviceMonitor.honorLabels }} + {{- end }} + {{- if .Values.execution.metrics.serviceMonitor.relabelings }} + relabelings: {{- toYaml .Values.execution.metrics.serviceMonitor.relabelings | nindent 6 }} + {{- end }} + {{- if .Values.execution.metrics.serviceMonitor.metricRelabelings }} + metricRelabelings: {{- toYaml .Values.execution.metrics.serviceMonitor.metricRelabelings | nindent 6 }} + {{- end }} + namespaceSelector: + matchNames: + - {{ .Release.Namespace }} + selector: + matchLabels: + {{- include "common.labels.matchLabels" . | nindent 6 }} +--- +apiVersion: monitoring.coreos.com/v1 +kind: ServiceMonitor +metadata: + name: {{ template "common.names.fullname" . }}-beacon + {{- if .Values.beacon.metrics.serviceMonitor.namespace }} + namespace: {{ .Values.beacon.metrics.serviceMonitor.namespace }} + {{- else }} + namespace: {{ .Release.Namespace | quote }} + {{- end }} + labels: + {{- include "common.labels.standard" . | nindent 4 }} + {{- if .Values.beacon.metrics.serviceMonitor.additionalLabels }} + {{- toYaml .Values.beacon.metrics.serviceMonitor.additionalLabels | nindent 4 }} + {{- end }} +spec: + endpoints: + - port: metrics-beacon + path: /metrics + {{- if .Values.beacon.metrics.serviceMonitor.interval }} + interval: {{ .Values.beacon.metrics.serviceMonitor.interval }} + {{- end }} + {{- if .Values.beacon.metrics.serviceMonitor.scrapeTimeout }} + scrapeTimeout: {{ .Values.beacon.metrics.serviceMonitor.scrapeTimeout }} + {{- end }} + {{- if .Values.beacon.metrics.serviceMonitor.honorLabels }} + honorLabels: {{ .Values.beacon.metrics.serviceMonitor.honorLabels }} + {{- end }} + {{- if .Values.beacon.metrics.serviceMonitor.relabelings }} + relabelings: {{- toYaml .Values.beacon.metrics.serviceMonitor.relabelings | nindent 6 }} + {{- end }} + {{- if .Values.beacon.metrics.serviceMonitor.metricRelabelings }} + metricRelabelings: {{- toYaml .Values.beacon.metrics.serviceMonitor.metricRelabelings | nindent 6 }} + {{- end }} + namespaceSelector: + matchNames: + - {{ .Release.Namespace }} + selector: + matchLabels: + {{- include "common.labels.matchLabels" . | nindent 6 }} +{{- end }} diff --git a/charts/execution-beacon/templates/statefulset.yaml b/charts/execution-beacon/templates/statefulset.yaml new file mode 100644 index 000000000..0120ba882 --- /dev/null +++ b/charts/execution-beacon/templates/statefulset.yaml @@ -0,0 +1,816 @@ +--- +apiVersion: {{ include "common.capabilities.statefulset.apiVersion" . }} +kind: StatefulSet +metadata: + name: {{ include "common.names.fullname" . }} + labels: + {{- include "common.labels.statefulset" . | nindent 4 }} +spec: + replicas: {{ .Values.global.replicaCount }} + podManagementPolicy: "Parallel" + selector: + matchLabels: + {{- include "common.labels.matchLabels" . | nindent 6 }} + serviceName: {{ include "common.names.fullname" . }} + template: + metadata: + labels: + {{- include "common.labels.matchLabels" . | nindent 8 }} + execution: {{ .Values.execution.client }} + beacon: {{ .Values.beacon.client }} + annotations: + checksum/configmap: {{ include (print $.Template.BasePath "/configmap.yaml") . | sha256sum }} + spec: + {{- with (concat .Values.global.imagePullSecrets .Values.global.imagePullSecrets) }} + imagePullSecrets: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with .Values.global.affinity }} + affinity: + {{ toYaml . | nindent 8 | trim }} + {{- end }} + {{- with .Values.global.tolerations }} + tolerations: + {{ toYaml . | nindent 8 | trim }} + {{- end }} + {{- with .Values.global.nodeSelector }} + nodeSelector: + {{ toYaml . | nindent 8 | trim }} + {{- end }} + securityContext: + {{- toYaml .Values.global.podSecurityContext | nindent 8 }} + {{- if .Values.global.terminationGracePeriodSeconds }} + terminationGracePeriodSeconds: {{ .Values.global.terminationGracePeriodSeconds }} + {{- end }} + serviceAccountName: {{ include "common.names.fullname" . }} + priorityClassName: {{ .Values.global.priorityClassName | quote }} + initContainers: + {{/* Container used for initialising data directory and setting right values for ports and external_ip */}} + - name: init + image: "{{ .Values.global.initImage.repository }}:{{ .Values.global.initImage.tag }}" + imagePullPolicy: {{ .Values.global.initImage.pullPolicy }} + securityContext: + {{- toYaml .Values.global.securityContext | nindent 12 }} + env: + - name: POD_IP + valueFrom: + fieldRef: + fieldPath: status.podIP + - name: POD_NAME + valueFrom: + fieldRef: + fieldPath: metadata.name + - name: POD_NAMESPACE + valueFrom: + fieldRef: + fieldPath: metadata.namespace + - name: NODE_NAME + valueFrom: + fieldRef: + fieldPath: spec.nodeName + command: ['/bin/sh', '/scripts/init.sh'] + volumeMounts: + {{- if .Values.global.sharedPersistence.enabled }} + - name: data + mountPath: /data + {{- else }} + - name: data-execution + mountPath: /data/execution + - name: data-beacon + mountPath: /data/beacon + {{- end }} + - name: env-nodeport + mountPath: /env + - name: scripts-init + mountPath: /scripts + {{/* Container used for initialising nimbus checkpoint sync */}} + {{- if and (eq .Values.beacon.client "nimbus") .Values.beacon.checkPointSync.enabled }} + - name: init-nimbus + image: "{{ (pluck .Values.beacon.client .Values.global.image.beacon | first ).repository }}:{{ (pluck .Values.beacon.client .Values.global.image.beacon | first ).tag }}" + imagePullPolicy: {{ .Values.beacon.imagePullPolicy }} + securityContext: + {{- toYaml .Values.global.securityContext | nindent 12 }} + command: + - sh + - -ac + - > + exec /home/user/nimbus-eth2/build/nimbus_beacon_node + trustedNodeSync + --backfill=false + --network={{ .Values.global.network }} + --data-dir=/data/beacon + --trusted-node-url={{ .Values.beacon.checkPointSync.url }} + volumeMounts: + {{- if .Values.global.sharedPersistence.enabled }} + - name: data + mountPath: /data + {{- else }} + - name: data-beacon + mountPath: /data/beacon + {{- end }} + {{- end }} + containers: + {{/* Container used for Execution clients: Nethermind, Geth, Besu, Erigon */}} + - name: execution + image: "{{ (pluck .Values.execution.client .Values.global.image.execution | first ).repository }}:{{ (pluck .Values.execution.client .Values.global.image.execution | first ).tag }}" + imagePullPolicy: {{ .Values.global.image.imagePullPolicy }} + securityContext: + readOnlyRootFilesystem: false + runAsNonRoot: true + runAsUser: 10000 + capabilities: + drop: + - ALL + {{- if .Values.global.externalSecrets.enabled }} + envFrom: + - secretRef: + name: eso-{{ include "common.names.fullname" . }} + {{- end }} + command: + - sh + - -ac + - > + {{- if .Values.global.p2pNodePort.enabled }} + . /env/init-nodeport; + {{- end }} + {{- /* Configuration for Nethermind execution client */}} + {{- if eq .Values.execution.client "nethermind" }} + exec /nethermind/Nethermind.Runner + --config={{ .Values.global.network }} + --datadir=/data/execution + {{- if .Values.execution.jsonrpc.enabled }} + --JsonRpc.Enabled={{ .Values.execution.jsonrpc.enabled }} + --JsonRpc.EnabledModules={{ .Values.execution.jsonrpc.namespaces.nethermind | join "," }} + --JsonRpc.Host={{ .Values.execution.jsonrpc.host }} + --JsonRpc.Port={{ .Values.execution.jsonrpc.http.port }} + {{- if .Values.execution.healthchecks.enabled }} + --HealthChecks.Enabled={{ .Values.execution.healthchecks.enabled }} + --HealthChecks.Slug={{ .Values.execution.healthchecks.slug }} + --HealthChecks.PollingInterval={{ .Values.execution.healthchecks.pollingInterval }} + --HealthChecks.LowStorageSpaceShutdownThreshold={{ .Values.execution.healthchecks.lowStorageSpaceShutdownThreshold }} + --HealthChecks.LowStorageSpaceWarningThreshold={{ .Values.execution.healthchecks.lowStorageSpaceWarningThreshold }} + {{- if .Values.execution.jsonrpc.websocket.enabled }} + --JsonRpc.WebSocketsPort={{ .Values.execution.jsonrpc.websocket.port }} + {{- end }} + {{- end }} + {{- end }} + {{- if or .Values.global.JWTSecret .Values.global.externalSecrets.enabled }} + {{- if .Values.global.externalSecrets.enabled }} + --JsonRpc.JwtSecretFile=/external-secrets/JWT_SECRET + {{- else }} + --JsonRpc.JwtSecretFile=/secret/jwtsecret + {{- end }} + --JsonRpc.EnginePort={{ .Values.execution.jsonrpc.engine.port }} + --JsonRpc.EngineHost={{ .Values.execution.jsonrpc.host }} + --JsonRpc.EngineEnabledModules={{ .Values.execution.jsonrpc.namespaces.nethermind | join "," }} + {{- end }} + {{- if and .Values.global.metrics.enabled .Values.execution.metrics.enabled }} + --Metrics.Enabled={{ .Values.execution.metrics.enabled }} + --Metrics.ExposePort={{ .Values.execution.metrics.port }} + --Metrics.NodeName=$POD_NAME + {{- end }} + --Network.MaxActivePeers={{ .Values.execution.targetPeers }} + {{- if .Values.global.p2pNodePort.enabled }} + --Network.ExternalIp=$EXTERNAL_IP + --Network.P2PPort=$EXTERNAL_EXECUTION_PORT + --Network.DiscoveryPort=$EXTERNAL_EXECUTION_PORT + {{- else }} + --Network.ExternalIp=$POD_IP + --Network.P2PPort={{ include "execution.p2pPort" . }} + --Network.DiscoveryPort={{ include "execution.p2pPort" . }} + {{- end }} + {{- if .Values.execution.terminalTotalDifficulty }} + --Merge.TerminalTotalDifficulty={{ .Values.execution.terminalTotalDifficulty }} + {{- end }} + {{- /* Configuration for Geth execution client */}} + {{- else if eq .Values.execution.client "geth" }} + exec geth + --syncmode=snap + --datadir=/data/execution + --ipcdisable + --{{ .Values.global.network }} + {{- if or .Values.global.JWTSecret .Values.global.externalSecrets.enabled }} + --authrpc.jwtsecret=/external-secrets/JWT_SECRET + {{- else }} + --authrpc.jwtsecret=/secret/jwtsecret + {{- end }} + --authrpc.addr={{ .Values.execution.jsonrpc.host }} + --authrpc.port={{ .Values.execution.jsonrpc.engine.port }} + --authrpc.vhosts={{ .Values.execution.jsonrpc.engine.hostAllowList | join "," }} + {{- if .Values.execution.jsonrpc.enabled }} + --http + --http.addr={{ .Values.execution.jsonrpc.host }} + --http.port={{ .Values.execution.jsonrpc.http.port }} + --http.corsdomain={{ .Values.execution.jsonrpc.http.corsOrigins | join "," }} + --http.vhosts={{ .Values.execution.jsonrpc.http.hostAllowList | join "," }} + --http.api={{ .Values.execution.jsonrpc.namespaces.geth | join "," }} + {{- if .Values.execution.jsonrpc.websocket.enabled }} + --ws + --ws.addr={{ .Values.execution.jsonrpc.host }} + --ws.port={{ .Values.execution.jsonrpc.websocket.port }} + --ws.origins={{ .Values.execution.jsonrpc.websocket.origins }} + --ws.api={{ .Values.execution.jsonrpc.namespaces.geth | join "," }} + {{- end }} + {{- end }} + --maxpeers={{ .Values.execution.targetPeers }} + {{- if .Values.global.p2pNodePort.enabled }} + --nat=extip:$EXTERNAL_IP + --port=$EXTERNAL_EXECUTION_PORT + {{- else }} + --nat=extip:$POD_IP + --port={{ include "execution.p2pPort" . }} + {{- end }} + {{- if .Values.execution.terminalTotalDifficulty }} + --override.geth.terminaltotaldifficulty={{ .Values.execution.terminalTotalDifficulty }} + {{- end }} + {{- if and .Values.global.metrics.enabled .Values.execution.metrics.enabled }} + --metrics + --metrics.port={{ .Values.execution.metrics.port }} + --metrics.addr={{ .Values.execution.metrics.host }} + {{- end }} + {{- /* Configuration for Besu execution client */}} + {{- else if eq .Values.execution.client "besu" }} + exec /opt/besu/bin/besu + --network={{ .Values.global.network }} + --data-path=/data/execution + --sync-mode=X_SNAP + --p2p-enabled=true + {{- if or .Values.global.JWTSecret .Values.global.externalSecrets.enabled }} + --engine-jwt-secret=/external-secrets/JWT_SECRET + {{- else }} + --engine-jwt-secret=/secret/jwtsecret + {{- end }} + --engine-rpc-enabled=true + --engine-host-allowlist={{ .Values.execution.jsonrpc.engine.hostAllowList | join "," }} + --engine-rpc-port={{ .Values.execution.jsonrpc.engine.port | join "," }} + {{- if .Values.execution.jsonrpc.enabled }} + --rpc-http-enabled=true + --rpc-http-host={{ .Values.execution.jsonrpc.host }} + --rpc-http-port={{ .Values.execution.jsonrpc.http.port }} + --rpc-http-cors-origins={{ .Values.execution.jsonrpc.http.corsOrigins | join "," }} + --host-allowlist={{ .Values.execution.jsonrpc.http.hostAllowList | join "," }} + {{- end }} + {{- if and .Values.global.metrics.enabled .Values.execution.metrics.enabled }} + --metrics-enabled=true + --metrics.port={{ .Values.execution.metrics.port }} + --metrics.addr={{ .Values.execution.metrics.host }} + {{- end }} + {{- /* Configuration for Erigon execution client */}} + {{- else if eq .Values.execution.client "erigon" }} + exec erigon + --datadir=/data/execution + --private.api.addr={{ .Values.execution.privateApiAddr }} + --chain={{ .Values.global.network }} + {{- if .Values.global.p2pNodePort.enabled }} + --nat=extip:$EXTERNAL_IP + --port=$EXTERNAL_EXECUTION_PORT + {{- else }} + --nat=extip:$POD_IP + --port={{ include "execution.p2pPort" . }} + {{- end }} + {{- if .Values.execution.terminalTotalDifficulty }} + --override.terminaltotaldifficulty={{ .Values.execution.terminalTotalDifficulty }} + {{- end }} + {{- if or .Values.global.JWTSecret .Values.global.externalSecrets.enabled }} + --authrpc.jwtsecret=/external-secrets/JWT_SECRET + {{- else }} + --authrpc.jwtsecret=/secret/jwtsecret + {{- end }} + --authrpc.addr={{ .Values.execution.jsonrpc.host }} + --authrpc.port={{ .Values.execution.jsonrpc.engine.port }} + --authrpc.vhosts={{ .Values.execution.jsonrpc.engine.hostAllowList | join "," }} + {{- if .Values.execution.jsonrpc.enabled }} + --http + --http.addr={{ .Values.execution.jsonrpc.host }} + --http.port={{ .Values.execution.jsonrpc.http.port }} + --http.corsdomain={{ .Values.execution.jsonrpc.http.corsOrigins | join "," }} + --http.vhosts={{ .Values.execution.jsonrpc.http.hostAllowList | join "," }} + --http.api={{ .Values.execution.jsonrpc.namespaces.erigon | join "," }} + {{- if .Values.execution.jsonrpc.websocket.enabled }} + --ws + {{- end }} + {{- end }} + {{- range .Values.extraFlags }} + {{ . }} + {{- end }} + {{- if .Values.global.metrics.enabled }} + --metrics + --metrics.addr={{ .Values.execution.metrics.host }} + --metrics.port={{ .Values.execution.metrics.port }} + {{- end }} + {{- end }} + {{- range .Values.execution.extraFlags }} + {{ . }} + {{- end }} + env: + - name: POD_IP + valueFrom: + fieldRef: + fieldPath: status.podIP + - name: POD_NAME + valueFrom: + fieldRef: + fieldPath: metadata.name + {{- if .Values.execution.javaOpts.enabled }} + - name: BESU_OPTS + value: {{ .Values.execution.javaOpts.maxHeapSize }} + {{- end }} + {{- if .Values.global.externalSecrets.enabled }} + envFrom: + - secretRef: + name: eso-{{ include "common.names.fullname" . }} + {{- end }} + ports: + {{- if eq .Values.execution.client "erigon" }} + - name: grpc-exec + protocol: TCP + containerPort: {{ .Values.execution.jsonrpc.grpc.port }} + {{- end }} + {{- if .Values.execution.jsonrpc.enabled }} + - name: engine-exec + containerPort: {{ .Values.execution.jsonrpc.engine.port }} + - name: jsonrpc-exec + containerPort: {{ .Values.execution.jsonrpc.http.port }} + {{- if .Values.execution.jsonrpc.websocket.enabled }} + - name: ws-exec + containerPort: {{ .Values.execution.jsonrpc.websocket.port }} + {{- end }} + {{- end }} + {{- if and .Values.global.metrics.enabled .Values.execution.metrics.enabled }} + - name: metrics-exec + containerPort: {{ .Values.execution.metrics.port }} + {{- end }} + {{- if .Values.global.p2pNodePort.enabled }} + - name: p2p-tcp-exec + containerPort: {{ include "execution.p2pPort" . }} + protocol: TCP + - name: p2p-udp-exec + containerPort: {{ include "execution.p2pPort" . }} + protocol: UDP + {{- end }} + volumeMounts: + {{- if .Values.global.sharedPersistence.enabled }} + - name: data + mountPath: /data + {{- else }} + - name: data-execution + mountPath: /data/execution + {{- end }} + {{- if .Values.global.externalSecrets.enabled }} + - name: external-secrets + mountPath: /external-secrets + readOnly: true + {{- end }} + {{- if .Values.global.JWTSecret }} + - name: jwtsecret + mountPath: /secret + readOnly: true + {{- end }} + - name: env-nodeport + mountPath: /env + {{- with .Values.execution.resources }} + resources: + {{ toYaml . | nindent 12 | trim }} + {{- end }} + {{/* Container used for Beacon clients: Prysm, Teku, Lighthouse, Nimbus, Lodestar */}} + - name: beacon + image: "{{ (pluck .Values.beacon.client .Values.global.image.beacon | first ).repository }}:{{ (pluck .Values.beacon.client .Values.global.image.beacon | first ).tag }}" + imagePullPolicy: {{ .Values.global.image.imagePullPolicy }} + securityContext: + readOnlyRootFilesystem: false + runAsNonRoot: true + runAsUser: 10000 + capabilities: + drop: + - ALL + {{/* Configuration for Prysm beacon client */}} + {{- if eq .Values.beacon.client "prysm" }} + args: + - "--datadir=/data/beacon" + - "--execution-endpoint=http://localhost:{{ .Values.execution.jsonrpc.engine.port }}" + - "--{{ .Values.global.network }}" + {{- if .Values.beacon.grpc.enabled }} + - "--rpc-host={{ .Values.beacon.grpc.host }}" + - "--rpc-port={{ .Values.beacon.grpc.port }}" + {{- end }} + {{- if .Values.global.p2pNodePort.enabled }} + - "--config-file=/data/beacon/config.yaml" + {{- else }} + - "--p2p-host-ip=$(POD_IP)" + - "--p2p-tcp-port={{ include "beacon.p2pPort" . }}" + - "--p2p-udp-port={{ include "beacon.p2pPort" . }}" + {{- end }} + - "--p2p-max-peers={{ .Values.beacon.targetPeers }}" + - "--accept-terms-of-use" + {{- if .Values.global.externalSecrets.enabled }} + - "--jwt-secret=/external-secrets/JWT_SECRET" + {{- else }} + - "--jwt-secret=/secret/jwtsecret" + {{- end }} + {{- if .Values.beacon.builderEndpoint }} + - "--http-mev-relay={{ .Values.beacon.builderEndpoint }}" + {{- end }} + {{- if .Values.beacon.suggestedFeeRecipient }} + - "--suggested-fee-recipient={{ .Values.beacon.suggestedFeeRecipient }}" + {{- end }} + {{- if .Values.beacon.totalDifficultyOverride }} + - "--terminal-total-difficulty-override={{ .Values.beacon.totalDifficultyOverride }}" + {{- end }} + {{- if .Values.beacon.checkPointSync.enabled }} + - "--checkpoint-sync-url={{ .Values.beacon.checkPointSync.url }}" + - "--genesis-beacon-api-url={{ .Values.beacon.checkPointSync.url }}" + {{- end }} + {{- if and .Values.global.metrics.enabled .Values.beacon.metrics.enabled }} + - "--monitoring-port={{ .Values.beacon.metrics.port }}" + - "--monitoring-host={{ .Values.beacon.metrics.host }}" + {{- else }} + - "--disable-monitoring" + {{- end }} + {{- if .Values.beacon.restApi.enabled }} + - "--grpc-gateway-host={{ .Values.beacon.restApi.host }}" + - "--grpc-gateway-port={{ index .Values.beacon.restApi.portMap "prysm" }}" + {{- else }} + - "--disable-grpc-gateway" + {{- end }} + {{- range .Values.beacon.extraFlags }} + - {{ . | quote }} + {{- end }} + {{/* Configuration for Teku beacon client */}} + {{- else if eq .Values.beacon.client "teku" }} + command: + - sh + - -ac + - > + {{- if .Values.global.p2pNodePort.enabled }} + . /env/init-nodeport; + {{- end }} + exec /opt/teku/bin/teku + --network={{ .Values.global.network }} + --data-beacon-path=/data/beacon/teku + --data-path=/data/beacon + --ee-endpoint=http://localhost:{{ .Values.execution.jsonrpc.engine.port }} + {{- if .Values.global.externalSecrets.enabled }} + --ee-jwt-secret-file=/external-secrets/JWT_SECRET + {{- else }} + --ee-jwt-secret-file=/secret/jwtsecret + {{- end }} + {{- if .Values.beacon.builderEndpoint }} + --builder-endpoint={{ .Values.beacon.builderEndpoint }} + {{- end }} + {{- if .Values.beacon.suggestedFeeRecipient }} + --validators-proposer-default-fee-recipient={{ .Values.beacon.suggestedFeeRecipient }} + {{- end }} + {{- if .Values.beacon.checkPointSync.enabled }} + --initial-state={{ .Values.beacon.checkPointSync.url }}/eth/v2/debug/beacon/states/finalized + {{- end }} + {{- if .Values.beacon.restApi.enabled }} + --rest-api-enabled={{ .Values.beacon.restApi.enabled }} + --rest-api-host-allowlist={{ .Values.beacon.restApi.hostAllowList | join "," }} + --rest-api-interface={{ .Values.beacon.restApi.host }} + --rest-api-port={{ index .Values.beacon.restApi.portMap "teku" }} + --rest-api-cors-origins={{ .Values.beacon.restApi.corsOrigins | join "," }} + {{- end }} + --p2p-enabled=true + --p2p-peer-upper-bound={{ .Values.beacon.targetPeers }} + --p2p-peer-lower-bound={{ .Values.beacon.targetPeersMin }} + {{- if .Values.global.p2pNodePort.enabled }} + --p2p-advertised-port=$EXTERNAL_BEACON_PORT + --p2p-advertised-ip=$EXTERNAL_IP + --p2p-port=$EXTERNAL_BEACON_PORT + {{- else }} + --p2p-advertised-ip=$POD_IP + --p2p-advertised-port={{ include "beacon.p2pPort" . }} + --p2p-port={{ include "beacon.p2pPort" . }} + {{- end }} + {{- if and .Values.global.metrics.enabled .Values.beacon.metrics.enabled }} + --metrics-enabled={{ .Values.beacon.metrics.enabled }} + --metrics-categories={{ .Values.beacon.metrics.categories | join "," }} + --metrics-host-allowlist={{ .Values.beacon.metrics.hostAllowList | join "," }} + --metrics-interface={{ .Values.beacon.metrics.host }} + --metrics-port={{ .Values.beacon.metrics.port }} + {{- end }} + {{- range .Values.beacon.extraFlags }} + {{ . | quote }} + {{- end }} + {{/* Configuration for Lighthouse beacon client */}} + {{- else if eq .Values.beacon.client "lighthouse" }} + command: + - sh + - -ac + - > + {{- if .Values.global.p2pNodePort.enabled }} + . /env/init-nodeport; + {{- end }} + exec lighthouse + bn + --staking + {{- if .Values.beacon.proposerOnly }} + --proposer-only + {{- end }} + --datadir=/data/beacon + --network={{ .Values.global.network }} + --disable-upnp + --target-peers={{ .Values.beacon.targetPeers }} + {{- if .Values.beacon.restApi.enabled }} + --http + --http-port={{ index .Values.beacon.restApi.portMap "lighthouse" }} + --http-address={{ .Values.beacon.restApi.host }} + --http-allow-origin={{ .Values.beacon.restApi.corsOrigins | join "," }} + {{- end }} + {{- if .Values.beacon.checkPointSync.enabled }} + --checkpoint-sync-url={{ .Values.beacon.checkPointSync.url }} + {{- end }} + {{- if .Values.beacon.builderEndpoint }} + --builder={{ .Values.beacon.builderEndpoint }} + {{- end }} + {{- if .Values.beacon.suggestedFeeRecipient }} + --suggested-fee-recipient={{ .Values.beacon.suggestedFeeRecipient }} + {{- end }} + --execution-endpoint=http://localhost:{{ .Values.execution.jsonrpc.engine.port }} + {{- if .Values.global.externalSecrets.enabled }} + --execution-jwt=/external-secrets/JWT_SECRET + {{- else }} + --execution-jwt=/secret/jwtsecret + {{- end }} + {{- if .Values.global.p2pNodePort.enabled }} + --discovery-port=$EXTERNAL_BEACON_PORT + --port=$EXTERNAL_BEACON_PORT + {{- else }} + --discovery-port={{ include "beacon.p2pPort" . }} + --port={{ include "beacon.p2pPort" . }} + {{- end }} + {{- if and .Values.global.metrics.enabled .Values.beacon.metrics.enabled }} + --metrics + --metrics-port={{ .Values.beacon.metrics.port }} + --metrics-address={{ .Values.beacon.metrics.host }} + {{- end }} + {{- range .Values.beacon.extraFlags }} + {{ . }} + {{- end }} + {{/* Configuration for Nimbus beacon client */}} + {{- else if eq .Values.beacon.client "nimbus" }} + command: + - sh + - -ac + - > + {{- if .Values.global.p2pNodePort.enabled }} + . /env/init-nodeport; + {{- end }} + exec /home/user/nimbus-eth2/build/nimbus_beacon_node + --network={{ .Values.global.network }} + --data-dir=/data/beacon + {{- if .Values.global.externalSecrets.enabled }} + --jwt-secret=/external-secrets/JWT_SECRET + {{- else }} + --jwt-secret=/secret/jwtsecret + {{- end }} + --non-interactive + {{- if .Values.beacon.restApi.enabled }} + --rest=true + --rest-port={{ index .Values.beacon.restApi.portMap .Values.beacon.client }} + --rest-address={{ .Values.beacon.restApi.host }} + --rest-allow-origin=={{ .Values.beacon.restApi.hostAllowList | join "," }} + {{- end }} + {{- if .Values.beacon.builderEndpoint }} + --payload-builder=true + --payload-builder-url={{ .Values.beacon.builderEndpoint }} + {{- end }} + {{- if .Values.beacon.suggestedFeeRecipient }} + --suggested-fee-recipient={{ .Values.beacon.suggestedFeeRecipient }} + {{- end }} + --el=http://localhost:{{ .Values.execution.jsonrpc.engine.port }} + --max-peers={{ .Values.beacon.targetPeers }} + --enr-auto-update=true + {{- if .Values.global.p2pNodePort.enabled }} + --nat=extip:$EXTERNAL_IP + --tcp-port=$EXTERNAL_BEACON_PORT + --udp-port=$EXTERNAL_BEACON_PORT + {{- else }} + --tcp-port={{ include "beacon.p2pPort" . }} + --udp-port={{ include "beacon.p2pPort" . }} + {{- end }} + {{- if and .Values.global.metrics.enabled .Values.beacon.metrics.enabled }} + --metrics + --metrics-port={{ .Values.beacon.metrics.port }} + --metrics-address={{ .Values.beacon.metrics.host }} + {{- end }} + {{- range .Values.beacon.extraFlags }} + {{ . }} + {{- end }} + {{/* Configuration for Lodestar beacon client */}} + {{- else if eq .Values.beacon.client "lodestar" }} + command: + - sh + - -ac + - > + {{- if .Values.global.p2pNodePort.enabled }} + . /env/init-nodeport; + {{- end }} + exec node + --max-old-space-size=4096 + /usr/app/node_modules/.bin/lodestar + beacon + --network={{ .Values.global.network }} + --dataDir=/data/beacon + {{- if .Values.beacon.checkPointSync.enabled }} + --checkpointSyncUrl={{ .Values.beacon.checkPointSync.url }} + {{- end }} + {{- if .Values.beacon.builderEndpoint }} + --builder + --builder.urls={{ .Values.beacon.builderEndpoint }} + {{- end }} + {{- if .Values.beacon.suggestedFeeRecipient }} + --suggestedFeeRecipient={{ .Values.beacon.suggestedFeeRecipient }} + {{- end }} + {{- if .Values.global.externalSecrets.enabled }} + --jwt-secret=/external-secrets/JWT_SECRET + {{- else }} + --jwt-secret=/secret/jwtsecret + {{- end }} + {{- if .Values.beacon.restApi.enabled }} + --rest + --rest.port={{ index .Values.beacon.restApi.portMap .Values.beacon.client }} + --rest.address={{ .Values.beacon.restApi.host }} + --rest.cors={{ .Values.beacon.restApi.corsOrigins | join "," }} + {{- end }} + --execution.urls=http://127.0.0.1:{{ .Values.execution.jsonrpc.engine.port }} + --targetPeers={{ .Values.beacon.targetPeers }} + {{- if .Values.global.p2pNodePort.enabled }} + --nat + --enr.ip=$EXTERNAL_IP + --enr.tcp=$EXTERNAL_BEACON_PORT + --enr.udp=$EXTERNAL_BEACON_PORT + --port=$EXTERNAL_BEACON_PORT + {{- else }} + --port={{ include "beacon.p2pPort" . }} + {{- end }} + {{- if and .Values.global.metrics.enabled .Values.beacon.metrics.enabled }} + --metrics=true + --metrics.port={{ .Values.beacon.metrics.port }} + --metrics.address={{ .Values.beacon.metrics.host }} + {{- end }} + {{- range .Values.beacon.extraFlags }} + {{ . }} + {{- end }} + {{- end }} + env: + - name: POD_IP + valueFrom: + fieldRef: + fieldPath: status.podIP + {{- if and (eq .Values.beacon.client "teku") .Values.beacon.javaOpts.enabled }} + - name: JAVA_OPTS + value: {{ .Values.beacon.javaOpts.maxHeapSize }} + {{- end }} + ports: + {{- if and (eq .Values.beacon.client "prysm") .Values.beacon.grpc.enabled }} + - containerPort: {{ .Values.beacon.grpc.port }} + name: {{ .Values.beacon.grpc.portName }}-beacon + protocol: TCP + {{- end }} + {{- if .Values.global.p2pNodePort.enabled }} + - name: p2p-tcp-beacon + containerPort: {{ include "beacon.p2pPort" . }} + protocol: TCP + - name: p2p-udp-beacon + containerPort: {{ include "beacon.p2pPort" . }} + protocol: UDP + {{- end }} + {{- if .Values.beacon.restApi.enabled }} + - containerPort: {{ index .Values.beacon.restApi.portMap .Values.beacon.client }} + name: http-beacon + protocol: TCP + {{- end }} + {{- if and .Values.global.metrics.enabled .Values.beacon.metrics.enabled }} + - containerPort: {{ .Values.beacon.metrics.port }} + name: metrics-beacon + protocol: TCP + {{- end }} + volumeMounts: + {{- if .Values.global.sharedPersistence.enabled }} + - name: data + mountPath: /data + {{- else }} + - name: data-beacon + mountPath: /data/beacon + {{- end }} + {{- if .Values.global.externalSecrets.enabled }} + - name: external-secrets + mountPath: /external-secrets + readOnly: true + {{- end }} + {{- if .Values.global.JWTSecret }} + - name: jwtsecret + mountPath: /secret + readOnly: true + {{- end }} + - name: env-nodeport + mountPath: /env + {{- with .Values.beacon.resources }} + resources: + {{ toYaml . | nindent 12 | trim }} + {{- end }} + {{- if and .Values.global.ethsider.enabled .Values.beacon.restApi.enabled .Values.execution.jsonrpc.enabled }} + - name: ethsider + image: "{{ .Values.global.ethsider.repository }}:{{ .Values.global.ethsider.tag }}" + imagePullPolicy: {{ .Values.global.ethsider.pullPolicy }} + securityContext: + {{- toYaml .Values.global.securityContext | nindent 12 }} + env: + - name: EXECUTION_ENDPOINT + value: "http://localhost:{{ .Values.execution.jsonrpc.http.port }}" + - name: BEACON_ENDPOINT + value: "http://localhost:{{ index .Values.beacon.restApi.portMap .Values.beacon.client }}" + - name: BIND_ADDR + value: "{{ .Values.global.ethsider.bindAddr }}" + ports: + - containerPort: {{ .Values.global.ethsider.bindAddr }} + name: sidecar + protocol: TCP + {{- if .Values.global.ethsider.livenessProbe.enabled }} + livenessProbe: + initialDelaySeconds: {{ .Values.global.ethsider.livenessProbe.initialDelaySeconds }} + timeoutSeconds: {{ .Values.global.ethsider.livenessProbe.timeoutSeconds }} + periodSeconds: {{ .Values.global.ethsider.livenessProbe.periodSeconds }} + failureThreshold: {{ .Values.global.ethsider.livenessProbe.failureThreshold }} + successThreshold: {{ .Values.global.ethsider.livenessProbe.successThreshold }} + httpGet: + path: {{ .Values.global.ethsider.livenessProbe.httpGet.path }} + port: {{ .Values.global.ethsider.livenessProbe.httpGet.port }} + scheme: {{ .Values.global.ethsider.livenessProbe.httpGet.scheme }} + {{- end }} + {{- if .Values.global.ethsider.readinessProbe.enabled }} + readinessProbe: + initialDelaySeconds: {{ .Values.global.ethsider.readinessProbe.initialDelaySeconds }} + timeoutSeconds: {{ .Values.global.ethsider.readinessProbe.timeoutSeconds }} + periodSeconds: {{ .Values.global.ethsider.readinessProbe.periodSeconds }} + failureThreshold: {{ .Values.global.ethsider.readinessProbe.failureThreshold }} + successThreshold: {{ .Values.global.ethsider.readinessProbe.successThreshold }} + httpGet: + path: {{ .Values.global.ethsider.readinessProbe.httpGet.path }} + port: {{ .Values.global.ethsider.readinessProbe.httpGet.port }} + scheme: {{ .Values.global.ethsider.readinessProbe.httpGet.scheme }} + {{- end }} + {{- end }} + volumes: + - name: scripts-init + configMap: + name: {{ include "common.names.fullname" . }}-init + {{- if .Values.global.JWTSecret }} + - name: jwtsecret + secret: + secretName: {{ include "common.names.fullname" . }} + {{- end }} + {{- if .Values.global.externalSecrets.enabled }} + - name: external-secrets + secret: + secretName: eso-{{ include "common.names.fullname" . }} + {{- end }} + - name: env-nodeport + emptyDir: {} + volumeClaimTemplates: + {{- if .Values.global.sharedPersistence.enabled }} + - metadata: + name: data + labels: + {{- include "common.labels.statefulset" . | nindent 10 }} + {{- with .Values.global.sharedPersistence.annotations }} + annotations: + {{ toYaml . | nindent 10 | trim }} + {{- end }} + spec: + accessModes: {{ .Values.global.sharedPersistence.accessModes }} + storageClassName: {{ .Values.global.sharedPersistence.storageClassName }} + resources: + requests: + storage: {{ .Values.global.sharedPersistence.size | quote }} + {{- else }} + - metadata: + name: data-execution + labels: + {{- include "common.labels.statefulset" . | nindent 10 }} + {{- with .Values.execution.persistence.annotations }} + annotations: + {{ toYaml . | nindent 10 | trim }} + {{- end }} + spec: + accessModes: {{ .Values.execution.persistence.accessModes }} + storageClassName: {{ .Values.execution.persistence.storageClassName }} + resources: + requests: + storage: {{ .Values.execution.persistence.size | quote }} + - metadata: + name: data-beacon + labels: + {{- include "common.labels.statefulset" . | nindent 10 }} + {{- with .Values.beacon.persistence.annotations }} + annotations: + {{ toYaml . | nindent 10 | trim }} + {{- end }} + spec: + accessModes: {{ .Values.beacon.persistence.accessModes }} + storageClassName: {{ .Values.beacon.persistence.storageClassName }} + resources: + requests: + storage: {{ .Values.beacon.persistence.size | quote }} + {{- end }} diff --git a/charts/execution-beacon/templates/tests/test-connection-nethermind.yaml b/charts/execution-beacon/templates/tests/test-connection-nethermind.yaml new file mode 100644 index 000000000..e69de29bb diff --git a/charts/lighthouse/templates/tests/test-connection.yaml b/charts/execution-beacon/templates/tests/test-connection-prysm.yaml similarity index 81% rename from charts/lighthouse/templates/tests/test-connection.yaml rename to charts/execution-beacon/templates/tests/test-connection-prysm.yaml index 000bf9c13..f5374d447 100644 --- a/charts/lighthouse/templates/tests/test-connection.yaml +++ b/charts/execution-beacon/templates/tests/test-connection-prysm.yaml @@ -1,7 +1,8 @@ +{{- if eq .Values.beacon.client "prysm" }} apiVersion: v1 kind: Pod metadata: - name: "{{ include "common.names.fullname" . }}-test-connection" + name: "{{ include "common.names.fullname" . }}-test-connection-beacon" labels: {{- include "common.labels.standard" . | nindent 4 }} annotations: @@ -11,5 +12,6 @@ spec: - name: wget image: busybox command: ['wget'] - args: ['{{ include "common.names.fullname" . }}:{{ .Values.http.port }}'] + args: ['{{ include "common.names.fullname" . }}:{{ .Values.beacon.grpc.port }}'] restartPolicy: Never +{{- end }} diff --git a/charts/execution-beacon/templates/validate.yaml b/charts/execution-beacon/templates/validate.yaml new file mode 100644 index 000000000..f358d77f6 --- /dev/null +++ b/charts/execution-beacon/templates/validate.yaml @@ -0,0 +1,17 @@ +{{- $jwtSecret := .Values.global.JWTSecret }} +{{- $regex := "^[0-9a-f]{64}$" }} +{{- if and $jwtSecret (not (regexMatch $regex $jwtSecret)) }} +{{- fail "global.JWTSecret must be a 32-byte long hex string" }} +{{- end }} + +{{- $address := .Values.beacon.suggestedFeeRecipient }} +{{- $regex := "^0x[a-fA-F0-9]{40}$" }} +{{- if not $address }} +{{- fail "beacon.suggestedFeeRecipient is required" }} +{{- else if not (regexMatch $regex $address) }} +{{- fail "beacon.suggestedFeeRecipient must be a valid Ethereum address (0x string)" }} +{{- end }} + +# validate checkpoint +# validate builderEndpoint +# validate storagesize for mainnet \ No newline at end of file diff --git a/charts/execution-beacon/values.yaml b/charts/execution-beacon/values.yaml new file mode 100644 index 000000000..ea05ae7c2 --- /dev/null +++ b/charts/execution-beacon/values.yaml @@ -0,0 +1,561 @@ +# This is a YAML-formatted file. +# Declare variables to be passed into your templates. +global: + replicaCount: 1 + + ## Ethereum network + ## + network: mainnet + + image: + imagePullPolicy: IfNotPresent + execution: + nethermind: + repository: "nethermind/nethermind" + tag: "1.24.0" + geth: + repository: "ethereum/client-go" + tag: "v1.13.8" + bseu: + repository: "hyperledger/besu" + tag: "23.10.2" + erigon: + repository: "thorax/erigon" + tag: "v2.55.1" + beacon: + prysm: + repository: "gcr.io/prylabs-dev/prysm/beacon-chain" + tag: "v4.1.1" + teku: + repository: "consensys/teku" + tag: "23.12.1" + lighthouse: + repository: "sigp/lighthouse" + tag: "v4.5.0" + nimbus: + repository: "statusim/nimbus-eth2" + tag: "multiarch-v24.1.0" + lodestar: + repository: "chainsafe/lodestar" + tag: "v1.13.0" + + ## JSON Web Token (JWT) authentication is used to secure the communication + ## between the beacon node and execution client. You can generate a JWT using + ## a command line tool, for example: + ## openssl rand -hex 32 > token.txt + ## + JWTSecret: "" + + ## Credentials to fetch images from private registry + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/ + ## + imagePullSecrets: [] + # Node labels for pod assignment + ## ref: https://kubernetes.io/docs/user-guide/node-selection/ + ## + nodeSelector: {} + + ## Tolerations for pod assignment + ## ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/ + ## + tolerations: {} + + ## Affinity for pod assignment + ## ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity + ## + ## Example: + ## affinity: + ## podAntiAffinity: + ## requiredDuringSchedulingIgnoredDuringExecution: + ## - labelSelector: + ## matchExpressions: + ## - key: app.kubernetes.io/name + ## operator: In + ## values: + ## - prysm + ## topologyKey: kubernetes.io/hostname + ## + affinity: {} + + ## Used to assign priority to pods + ## ref: https://kubernetes.io/docs/concepts/configuration/pod-priority-preemption/ + ## + priorityClassName: "" + + ## Whether or not to allocate persistent volume disk for the data directory. + ## In case of node failure, the node data directory will still persist. + ## + sharedPersistence: + enabled: false + storageClassName: "" + accessModes: + - ReadWriteOnce + size: 300Gi + annotations: {} + + externalSecrets: + enabled: false + secretStoreRef: + name: secretStoreRef + kind: SecretStore + data: [] + + ethsider: + enabled: true + repository: "nethermindeth/ethsider" + tag: "v1.0.0" + pullPolicy: IfNotPresent + bindAddr: 3000 + ## Configure liveness and readiness probes + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/ + ## NB! readinessProbe and livenessProbe must be disabled before genesis + ## + livenessProbe: + enabled: false + initialDelaySeconds: 10 + timeoutSeconds: 3 + periodSeconds: 1 + failureThreshold: 3 + successThreshold: 3 + httpGet: + path: /liveness + port: sidecar + scheme: HTTP + + readinessProbe: + enabled: true + initialDelaySeconds: 10 + timeoutSeconds: 3 + periodSeconds: 1 + failureThreshold: 3 + successThreshold: 3 + httpGet: + path: /readiness + port: sidecar + scheme: HTTP + + service: + svcHeadless: true + + sessionAffinity: + # Whether to enable session affinity or not + enabled: false + # The session duration in seconds + timeoutSeconds: 86400 + + ## Service account + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ + ## + serviceAccount: + create: true + + ## RBAC configuration. + ## ref: https://kubernetes.io/docs/reference/access-authn-authz/rbac/ + ## + rbac: + create: true + + ## Termination Grace Period + ## ref: https://kubernetes.io/docs/tasks/run-application/force-delete-stateful-set-pod/#delete-pods + ## + terminationGracePeriodSeconds: 120 + + ## Init image is used to chown data volume, initialise genesis, etc. + ## + initImage: + repository: "bitnami/kubectl" + tag: "1.28" + pullPolicy: IfNotPresent + + ## Monitoring + ## + metrics: + enabled: true + annotations: {} + ## Prometheus Service Monitor + ## ref: https://github.com/coreos/prometheus-operator + ## https://github.com/coreos/prometheus-operator/blob/master/Documentation/api.md#endpoint + ## + serviceMonitor: + ## The namespace in which the ServiceMonitor will be created + ## + namespace: "" + ## The interval at which metrics should be scraped + ## + interval: 30s + ## The timeout after which the scrape is ended + ## + scrapeTimeout: "" + ## Metrics RelabelConfigs to apply to samples before scraping. + ## + relabellings: [] + ## Metrics RelabelConfigs to apply to samples before ingestion. + ## + metricRelabelings: [] + ## Specify honorLabels parameter to add the scrape endpoint + ## + honorLabels: false + ## Additional labels that can be used so ServiceMonitor resource(s) can be discovered by Prometheus + ## + additionalLabels: {} + ## Custom PrometheusRule to be defined + ## ref: https://github.com/coreos/prometheus-operator#customresourcedefinitions + ## + prometheusRule: + ## Create a default set of Alerts + ## + default: true + ## The namespace in which the prometheusRule will be created + ## + namespace: "" + ## Additional labels for the prometheusRule + ## + additionalLabels: {} + ## Custom Prometheus rules + ## + rules: [] + + ## When p2pNodePort is enabled, your P2P port will be exposed via service type NodePort. + ## This will generate a service for each replica, with a port binding via NodePort. + ## This is useful if you want to expose and announce your node to the Internet. + ## + p2pNodePort: + ## @param p2pNodePort.enabled Expose P2P port via NodePort + ## + enabled: false + ## @param p2pNodePort.annotations + ## + annotations: {} + ## @param p2pNodePort.type + ## Options: NodePort, LoadBalancer + type: NodePort + ## @param p2pNodePort.startAt The ports allocation will start from this value + ## + startAtExecution: 31100 + startAtBeacon: 31200 + ## @param p2pNodePort.replicaToNodePort Overwrite a port for specific replicas + ## @default -- See `values.yaml` for example + replicaToNodePort: {} + # "0": 32345 + # "3": 32348 + + ## Pod Security Context + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/ + ## + podSecurityContext: + runAsNonRoot: true + runAsUser: 10000 + fsGroup: 10000 + + securityContext: + readOnlyRootFilesystem: true + runAsNonRoot: true + runAsUser: 10000 + capabilities: + drop: + - ALL + +execution: + client: nethermind + + ## Whether or not to allocate persistent volume disk for the data directory. + ## In case of node failure, the node data directory will still persist. + ## + persistence: + enabled: true + storageClassName: "" + accessModes: + - ReadWriteOnce + size: 100Gi + annotations: {} + + ## If false, data ownership will not be reset at startup + ## This allows the execution node to be run with an arbitrary user + ## + initChownData: true + + # private api network address, for example: 127.0.0.1:9090, + # empty string means not to start the listener. + # Do not expose to public network. + # Serves remote database interface (default: "127.0.0.1:9090") + privateApiAddr: "127.0.0.1:9090" + + ## Monitoring + ## Additional settings could be made in non-global section. + ## + metrics: + ## Whether to enable metrics collection or not + ## + enabled: true + + port: 8008 + host: "0.0.0.0" + + ## Prometheus Service Monitor + ## ref: https://github.com/coreos/prometheus-operator + ## https://github.com/coreos/prometheus-operator/blob/master/Documentation/api.md#endpoint + ## + serviceMonitor: + ## Create ServiceMonitor resource(s) for scraping metrics using PrometheusOperator + ## + enabled: true + + ## Custom PrometheusRule to be defined + ## ref: https://github.com/coreos/prometheus-operator#customresourcedefinitions + ## + prometheusRule: + ## Create a custom prometheusRule Resource for scraping metrics using PrometheusOperator + ## + enabled: true + + ## -------------------------- Execution node specific settings ----------------------------------------- + # Manually specify TerminalTotalDifficulty, overriding the bundled setting + terminalTotalDifficulty: "" + + jsonrpc: + enabled: true + namespaces: + nethermind: + - Web3 + - Eth + - Net + - Subscribe + - Health + geth: + - web3 + - eth + - net + - engine + erigon: + - eth + - erigon + - web3 + - net + - engine + host: "0.0.0.0" + grpc: + port: 9090 + http: + port: 8545 + corsOrigins: + - "*" + hostAllowList: + - "*" + websocket: + enabled: true + port: 8546 + origins: "*" + engine: + port: 8551 + hostAllowList: + - "*" + corsOrigins: + - "*" + + ## Besu specific setting + javaOpts: + enabled: false + # This option is used to set java specific values for heap size and should be used if you experience out of memory errors. + # The Xmx option stands for the maximum memory allocation pool for a Java Virtual Machine ( JVM ). + # https://besu.hyperledger.org/en/stable/public-networks/how-to/configure-jvm/manage-memory/ + # Example for kubernetes resources at 8Gi memory: + # maxHeapSize: "-Xmx3g" + maxHeapSize: "" + + # Nethermind HealthChecks module + healthchecks: + enabled: true + slug: "/health" + pollingInterval: 5 + lowStorageSpaceShutdownThreshold: 0 + lowStorageSpaceWarningThreshold: 5 + + targetPeers: 50 + ## Extra flags to pass to the node + ## + extraFlags: [] + resources: {} + +beacon: + client: nimbus + + ## Whether or not to allocate persistent volume disk for the data directory. + ## In case of node failure, the node data directory will still persist. + ## + persistence: + enabled: true + storageClassName: "" + accessModes: + - ReadWriteOnce + size: 100Gi + annotations: {} + + ## If false, data ownership will not be reset at startup + ## This allows the beacon node to be run with an arbitrary user + ## + initChownData: true + + metrics: + ## Whether to enable metrics collection or not + ## + enabled: true + annotations: {} + + port: 9090 + host: "0.0.0.0" + + ## Monitoring + ## Teku Metric categories to enable + categories: + - JVM + - PROCESS + - BEACON + - DISCOVERY + - EVENTBUS + - EXECUTOR + - NETWORK + - STORAGE + - STORAGE_HOT_DB + - STORAGE_FINALIZED_DB + - REMOTE_VALIDATOR + - VALIDATOR + - VALIDATOR_PERFORMANCE + + # List of hostnames to allow, or * to allow any host + hostAllowList: + - "*" + ## Prometheus Service Monitor + ## ref: https://github.com/coreos/prometheus-operator + ## https://github.com/coreos/prometheus-operator/blob/master/Documentation/api.md#endpoint + ## + serviceMonitor: + ## Create ServiceMonitor resource(s) for scraping metrics using PrometheusOperator + ## + enabled: true + + ## Custom PrometheusRule to be defined + ## ref: https://github.com/coreos/prometheus-operator#customresourcedefinitions + ## + prometheusRule: + ## Create a custom prometheusRule Resource for scraping metrics using PrometheusOperator + ## + enabled: true + + ## To get Beacon node up and running in only a few minutes + ## from a recent finalized checkpoint state rather than syncing from genesis. + ## + checkPointSync: + enabled: true + url: "https://mainnet-checkpoint-sync.attestant.io" + trustedSourceUrl: "" + + ## Post bellatrix, this address will receive the transaction fees produced + ## by any blocks from this node. Default to junk whilst bellatrix is in development state. + ## Validator client can override this value through the preparebeaconproposer api. + ## + suggestedFeeRecipient: "" + + # Lighthouse specific setting + proposerOnly: false + + ## Teku specific setting + javaOpts: + enabled: true + # This option is used to set java specific values for heap size and should be used if you experience out of memory errors. + # The Xmx option stands for the maximum memory allocation pool for a Java Virtual Machine ( JVM ). + # https://besu.hyperledger.org/en/stable/public-networks/how-to/configure-jvm/manage-memory/ + # Example for kubernetes resources at 8Gi memory: + # maxHeapSize: "-Xmx3g" + maxHeapSize: "-Xmx3g" + + ## MEV Boost endpoint + ## + builderEndpoint: "" + + # Rest API Settings + restApi: + # Enables Beacon Rest API + enabled: true + host: "0.0.0.0" + # Comma-separated list of hostnames to allow, or * + # to allow any host + hostAllowList: + - "*" + corsOrigins: + - "*" + # Port number of Beacon Rest API + portMap: + teku: 5051 + prysm: 8080 + lighthouse: 5052 + nimbus: 5052 + lodestar: 9596 + + grpc: + enabled: true + host: "0.0.0.0" + port: 4000 + portName: "rpc" + + targetPeers: 50 + targetPeersMin: 40 + + ## Sets the total difficulty to manual overrides the default + ## TERMINAL_TOTAL_DIFFICULTY value. WARNING: This flag should be used only if you + ## have a clear understanding that community has decided to override the terminal difficulty. + ## Incorrect usage will result in your node experience consensus failure. + totalDifficultyOverride: "" + + ## Extra flags to pass to the node + ## + extraFlags: [] + resources: {} + +## Service account +## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ +## +serviceAccount: + # Annotations to add to the service account + annotations: {} + # The name of the service account to use. + # If not set and create is true, a name is generated using the fullname template + name: "" + +## Provide a name in place of geth for `app:` labels +## +nameOverride: "" + +## Provide a name to substitute for the full names of resources +## +fullnameOverride: "" +# RBAC configuration. +## ref: https://kubernetes.io/docs/reference/access-authn-authz/rbac/ +## +rbac: + # The name of the cluster role to use. + # If not set and create is true, a name is generated using the fullname template + name: "" + ## Required ClusterRole rules + ## + clusterRules: + ## Required to obtain the nodes external IP + ## + - apiGroups: [""] + resources: + - "nodes" + verbs: + - "get" + - "list" + - "watch" + ## Required Role rules + ## + rules: + ## Required to get information about the services nodePort. + ## + - apiGroups: [""] + resources: + - "services" + verbs: + - "get" + - "list" + - "watch" diff --git a/charts/geth/Chart.lock b/charts/geth/Chart.lock deleted file mode 100644 index 3d060a672..000000000 --- a/charts/geth/Chart.lock +++ /dev/null @@ -1,6 +0,0 @@ -dependencies: -- name: common - repository: file://../common - version: 1.0.0 -digest: sha256:c68e472825af446bb3561dc92bb4659f388e197d7742c12a3e4f93a81506ac41 -generated: "2022-03-07T12:06:40.772220951+03:00" diff --git a/charts/geth/Chart.yaml b/charts/geth/Chart.yaml deleted file mode 100644 index c2a52d79c..000000000 --- a/charts/geth/Chart.yaml +++ /dev/null @@ -1,24 +0,0 @@ -apiVersion: v2 -name: geth -version: 2.1.7 -kubeVersion: "^1.18.0-0" -description: Official Golang implementation of the Ethereum v1 protocol. -type: application -keywords: - - ethereum - - blockchain - - geth - - p2p -home: https://www.ethereum.org/ -sources: - - https://github.com/ethereum/go-ethereum/ -maintainers: - - name: Dmitri Tsumak - email: dmitri@stakewise.io -icon: https://raw.githubusercontent.com/ethereum/ethereum-org/master/public/images/logos/ETHEREUM-ICON_Black.png -appVersion: v1.10.25 - -dependencies: - - name: common - version: 1.x.x - repository: "file://../common" diff --git a/charts/geth/templates/_helpers.yaml b/charts/geth/templates/_helpers.yaml deleted file mode 100644 index eb6c1e29b..000000000 --- a/charts/geth/templates/_helpers.yaml +++ /dev/null @@ -1,3 +0,0 @@ -{{- define "geth.p2pPort" -}} -{{- printf "30303" -}} -{{- end -}} diff --git a/charts/geth/templates/clusterrole.yaml b/charts/geth/templates/clusterrole.yaml deleted file mode 100644 index 6d7136bd1..000000000 --- a/charts/geth/templates/clusterrole.yaml +++ /dev/null @@ -1,10 +0,0 @@ -{{- if or .Values.global.rbac.create .Values.rbac.create }} -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: {{ include "common.names.clusterRoleName" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -rules: -{{- toYaml .Values.rbac.clusterRules | nindent 0 }} -{{- end }} diff --git a/charts/geth/templates/clusterrolebinding.yaml b/charts/geth/templates/clusterrolebinding.yaml deleted file mode 100644 index 87d636dac..000000000 --- a/charts/geth/templates/clusterrolebinding.yaml +++ /dev/null @@ -1,16 +0,0 @@ -{{- if or .Values.global.rbac.create .Values.rbac.create }} -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: {{ include "common.names.clusterRoleName" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: {{ include "common.names.clusterRoleName" . }} -subjects: - - kind: ServiceAccount - name: {{ include "common.names.serviceAccountName" . }} - namespace: {{ .Release.Namespace }} -{{- end }} diff --git a/charts/geth/templates/pdb.yaml b/charts/geth/templates/pdb.yaml deleted file mode 100644 index 4ef63f0ff..000000000 --- a/charts/geth/templates/pdb.yaml +++ /dev/null @@ -1,18 +0,0 @@ -{{- if .Values.podDisruptionBudget.enabled }} -apiVersion: {{ include "common.capabilities.policy.apiVersion" . }} -kind: PodDisruptionBudget -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -spec: -{{- if .Values.podDisruptionBudget.minAvailable }} - minAvailable: {{ .Values.podDisruptionBudget.minAvailable }} -{{- end }} -{{- if .Values.podDisruptionBudget.maxUnavailable }} - maxUnavailable: {{ .Values.podDisruptionBudget.maxUnavailable }} -{{- end }} - selector: - matchLabels: - {{- include "common.labels.matchLabels" . | nindent 6 }} -{{- end }} diff --git a/charts/geth/templates/prometheusrules.yaml b/charts/geth/templates/prometheusrules.yaml deleted file mode 100644 index 6145908f8..000000000 --- a/charts/geth/templates/prometheusrules.yaml +++ /dev/null @@ -1,35 +0,0 @@ -{{- if and (or .Values.global.metrics.enabled .Values.metrics.enabled) - (or .Values.global.metrics.prometheusRule.enabled .Values.metrics.prometheusRule.enabled) }} -apiVersion: monitoring.coreos.com/v1 -kind: PrometheusRule -metadata: - name: {{ include "common.names.fullname" . }} - {{- if .Values.metrics.prometheusRule.namespace }} - namespace: {{ .Values.metrics.prometheusRule.namespace }} - {{- else }} - namespace: {{ .Release.Namespace | quote }} - {{- end }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.metrics.prometheusRule.additionalLabels }} - {{- toYaml .Values.metrics.prometheusRule.additionalLabels | nindent 4 }} - {{- end }} -spec: - groups: - {{- with .Values.metrics.prometheusRule.rules }} - - name: {{ include "common.names.fullname" $ }} - rules: {{- tpl (toYaml .) $ | nindent 8 }} - {{- end }} - {{- if .Values.metrics.prometheusRule.default }} - - name: {{ include "common.names.fullname" $ }}-default - rules: - - alert: GethNodeDown - expr: up{job="{{ include "common.names.fullname" . }}"} == 0 - for: 5m - labels: - severity: critical - annotations: - summary: Geth Node {{ printf "{{ $labels.instance }}" }} down - description: Geth Node {{ printf "{{ $labels.instance }}" }} is down - {{- end }} -{{- end }} \ No newline at end of file diff --git a/charts/geth/templates/role.yaml b/charts/geth/templates/role.yaml deleted file mode 100644 index dfbc0fe48..000000000 --- a/charts/geth/templates/role.yaml +++ /dev/null @@ -1,10 +0,0 @@ -{{- if or .Values.global.rbac.create .Values.rbac.create -}} -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -rules: -{{- toYaml .Values.rbac.rules | nindent 0 }} -{{- end }} diff --git a/charts/geth/templates/rolebinding.yaml b/charts/geth/templates/rolebinding.yaml deleted file mode 100644 index 1fdb617ba..000000000 --- a/charts/geth/templates/rolebinding.yaml +++ /dev/null @@ -1,15 +0,0 @@ -{{- if or .Values.global.rbac.create .Values.rbac.create }} -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: {{ include "common.names.serviceAccountName" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: {{ include "common.names.serviceAccountName" . }} -subjects: - - kind: ServiceAccount - name: {{ include "common.names.serviceAccountName" . }} -{{- end }} diff --git a/charts/geth/templates/secret.yaml b/charts/geth/templates/secret.yaml deleted file mode 100644 index 2981fe224..000000000 --- a/charts/geth/templates/secret.yaml +++ /dev/null @@ -1,11 +0,0 @@ -{{- if .Values.global.JWTSecret }} -apiVersion: v1 -kind: Secret -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -type: Opaque -data: - jwtsecret: {{ .Values.global.JWTSecret | b64enc | quote }} -{{- end }} diff --git a/charts/geth/templates/service-p2p.yaml b/charts/geth/templates/service-p2p.yaml deleted file mode 100644 index 4ee213b94..000000000 --- a/charts/geth/templates/service-p2p.yaml +++ /dev/null @@ -1,42 +0,0 @@ -{{- if .Values.p2pNodePort.enabled -}} -{{- range $i, $e := until (int .Values.global.replicaCount) }} -{{- $port := add $.Values.p2pNodePort.startAt $i -}} -{{- if hasKey $.Values.p2pNodePort.replicaToNodePort ($i | toString) -}} - {{ $port = index $.Values.p2pNodePort.replicaToNodePort ($i | toString) }} -{{- end }} - ---- -apiVersion: v1 -kind: Service -metadata: - name: {{ include "common.names.fullname" $ }}-{{ $i }} - labels: - {{- include "common.labels.standard" $ | nindent 4 }} - pod: "{{ include "common.names.fullname" $ }}-{{ $i }}" - type: p2p - {{- with $.Values.p2pNodePort.annotations }} - annotations: - {{- toYaml . | nindent 4 }} - {{- end }} -spec: - type: {{ $.Values.p2pNodePort.type }} - externalTrafficPolicy: Local - ports: - - name: p2p-tcp - port: {{ include "geth.p2pPort" $ }} - protocol: TCP - targetPort: p2p-tcp - nodePort: {{ $port }} - {{- if eq $.Values.p2pNodePort.type "NodePort" }} - - name: p2p-udp - port: {{ include "geth.p2pPort" $ }} - protocol: UDP - targetPort: p2p-udp - nodePort: {{ $port }} - {{- end }} - selector: - {{- include "common.labels.matchLabels" $ | nindent 4 }} - statefulset.kubernetes.io/pod-name: "{{ include "common.names.fullname" $ }}-{{ $i }}" - -{{- end }} -{{- end }} diff --git a/charts/geth/templates/service.yaml b/charts/geth/templates/service.yaml deleted file mode 100644 index 16eaff920..000000000 --- a/charts/geth/templates/service.yaml +++ /dev/null @@ -1,43 +0,0 @@ -{{- if or .Values.http.enabled .Values.ws.enabled }} ---- -apiVersion: v1 -kind: Service -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -spec: -{{- if .Values.svcHeadless }} - clusterIP: None -{{- end }} -{{- if .Values.sessionAffinity.enabled }} - sessionAffinity: ClientIP - sessionAffinityConfig: - clientIP: - timeoutSeconds: {{ .Values.sessionAffinity.timeoutSeconds }} -{{- end }} - type: ClusterIP - ports: - {{- if .Values.global.JWTSecret }} - - name: authrpc - port: {{ .Values.authRpc.port }} - targetPort: authrpc - {{- end }} - {{- if .Values.http.enabled }} - - name: http - port: {{ .Values.http.port }} - targetPort: http - {{- end }} - {{- if .Values.ws.enabled }} - - name: ws - port: {{ .Values.ws.port }} - targetPort: ws - {{- end }} - {{- if .Values.global.metrics.enabled }} - - name: metrics - port: {{ .Values.metrics.port }} - targetPort: metrics - {{- end }} - selector: - {{- include "common.labels.matchLabels" . | nindent 4 }} -{{- end }} diff --git a/charts/geth/templates/servicemonitor.yaml b/charts/geth/templates/servicemonitor.yaml deleted file mode 100644 index 5a279940c..000000000 --- a/charts/geth/templates/servicemonitor.yaml +++ /dev/null @@ -1,42 +0,0 @@ -{{- if and (or .Values.global.metrics.enabled .Values.metrics.enabled) - (or .Values.global.metrics.serviceMonitor.enabled .Values.metrics.serviceMonitor.enabled) }} -apiVersion: monitoring.coreos.com/v1 -kind: ServiceMonitor -metadata: - name: {{ template "common.names.fullname" . }} - {{- if .Values.metrics.serviceMonitor.namespace }} - namespace: {{ .Values.metrics.serviceMonitor.namespace }} - {{- else }} - namespace: {{ .Release.Namespace | quote }} - {{- end }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.metrics.serviceMonitor.additionalLabels }} - {{- toYaml .Values.metrics.serviceMonitor.additionalLabels | nindent 4 }} - {{- end }} -spec: - endpoints: - - port: metrics - path: /debug/metrics/prometheus - {{- if .Values.metrics.serviceMonitor.interval }} - interval: {{ .Values.metrics.serviceMonitor.interval }} - {{- end }} - {{- if .Values.metrics.serviceMonitor.scrapeTimeout }} - scrapeTimeout: {{ .Values.metrics.serviceMonitor.scrapeTimeout }} - {{- end }} - {{- if .Values.metrics.serviceMonitor.honorLabels }} - honorLabels: {{ .Values.metrics.serviceMonitor.honorLabels }} - {{- end }} - {{- if .Values.metrics.serviceMonitor.relabelings }} - relabelings: {{- toYaml .Values.metrics.serviceMonitor.relabelings | nindent 6 }} - {{- end }} - {{- if .Values.metrics.serviceMonitor.metricRelabelings }} - metricRelabelings: {{- toYaml .Values.metrics.serviceMonitor.metricRelabelings | nindent 6 }} - {{- end }} - namespaceSelector: - matchNames: - - {{ .Release.Namespace }} - selector: - matchLabels: - {{- include "common.labels.matchLabels" . | nindent 6 }} -{{- end }} diff --git a/charts/geth/templates/statefulset.yaml b/charts/geth/templates/statefulset.yaml deleted file mode 100644 index f40a7de33..000000000 --- a/charts/geth/templates/statefulset.yaml +++ /dev/null @@ -1,257 +0,0 @@ ---- -apiVersion: {{ include "common.capabilities.statefulset.apiVersion" . }} -kind: StatefulSet -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.statefulset" . | nindent 4 }} -spec: - replicas: {{ .Values.global.replicaCount }} - podManagementPolicy: "Parallel" - selector: - matchLabels: - {{- include "common.labels.matchLabels" . | nindent 6 }} - serviceName: {{ include "common.names.fullname" . }} - template: - metadata: - labels: - {{- include "common.labels.matchLabels" . | nindent 8 }} - spec: - {{- with (concat .Values.imagePullSecrets .Values.global.imagePullSecrets) }} - imagePullSecrets: - {{- toYaml . | nindent 8 }} - {{- end }} - {{- with .Values.affinity }} - affinity: - {{ toYaml . | nindent 8 | trim }} - {{- end }} - {{- with .Values.tolerations }} - tolerations: - {{ toYaml . | nindent 8 | trim }} - {{- end }} - {{- with .Values.nodeSelector }} - nodeSelector: - {{ toYaml . | nindent 8 | trim }} - {{- end }} - {{- with .Values.securityContext }} - securityContext: - {{ toYaml . | nindent 8 | trim }} - {{- end }} - {{- if .Values.terminationGracePeriodSeconds }} - terminationGracePeriodSeconds: {{ .Values.terminationGracePeriodSeconds }} - {{- end }} - serviceAccountName: {{ include "common.names.serviceAccountName" . }} - priorityClassName: {{ .Values.priorityClassName | quote }} - initContainers: - - name: init - image: "{{ .Values.initImage.repository }}:{{ .Values.initImage.tag }}" - imagePullPolicy: {{ .Values.initImage.pullPolicy }} - securityContext: - runAsNonRoot: false - runAsUser: 0 - env: - - name: POD_IP - valueFrom: - fieldRef: - fieldPath: status.podIP - - name: POD_NAME - valueFrom: - fieldRef: - fieldPath: metadata.name - - name: POD_NAMESPACE - valueFrom: - fieldRef: - fieldPath: metadata.namespace - - name: NODE_NAME - valueFrom: - fieldRef: - fieldPath: spec.nodeName - command: - - sh - - -c - - > - echo "Namespace: ${POD_NAMESPACE} Pod: ${POD_NAME}"; - {{- if .Values.p2pNodePort.enabled }} - {{- if eq .Values.p2pNodePort.type "LoadBalancer" }} - until [ -n "$(kubectl -n ${POD_NAMESPACE} get svc/${POD_NAME} -o jsonpath='{.status.loadBalancer.ingress[0].ip}')" ]; do echo "Waiting for load balancer gets an IP" && sleep 10; done; - export EXTERNAL_PORT=$(kubectl -n ${POD_NAMESPACE} get services -l "pod in (${POD_NAME}), type in (p2p)" -o jsonpath='{.items[0].spec.ports[0].nodePort}'); - export EXTERNAL_IP=$(kubectl -n ${POD_NAMESPACE} get svc/${POD_NAME} -o jsonpath='{.status.loadBalancer.ingress[0].ip}'); - {{- else }} - export EXTERNAL_PORT=$(kubectl get services -l "pod in (${POD_NAME}), type in (p2p)" -o jsonpath='{.items[0].spec.ports[0].nodePort}'); - export EXTERNAL_IP=$(kubectl get nodes "${NODE_NAME}" -o jsonpath='{.status.addresses[?(@.type=="ExternalIP")].address}'); - {{- end }} - echo "EXTERNAL_PORT=$EXTERNAL_PORT" > /env/init-nodeport; - echo "EXTERNAL_IP=$EXTERNAL_IP" >> /env/init-nodeport; - cat /env/init-nodeport; - {{- end }} - {{- if and .Values.persistence.enabled .Values.initChownData }} - mkdir -p /data && chown -R {{ .Values.securityContext.runAsUser }}:{{ .Values.securityContext.runAsUser }} /data; - {{- end }} - volumeMounts: - - name: env-nodeport - mountPath: /env - containers: - - name: {{ .Chart.Name }} - image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}" - imagePullPolicy: {{ .Values.image.pullPolicy }} - command: - - sh - - -ac - - > - {{- if .Values.p2pNodePort.enabled }} - . /env/init-nodeport; - {{- end }} - exec geth - {{- if .Values.global.JWTSecret }} - --authrpc.jwtsecret=/secret/jwtsecret - --authrpc.addr={{ .Values.authRpc.addr }} - --authrpc.port={{ .Values.authRpc.port }} - --authrpc.vhosts={{ .Values.authRpc.vhosts }} - {{- end }} - {{- if .Values.http.enabled }} - --http - --http.addr=0.0.0.0 - --http.port={{ .Values.http.port }} - --http.corsdomain={{ .Values.http.corsDomain }} - --http.vhosts={{ .Values.http.vhosts }} - --http.api={{ .Values.http.api }} - {{- end }} - {{- if .Values.p2pNodePort.enabled }} - --nat=extip:$EXTERNAL_IP - --port=$EXTERNAL_PORT - {{- else }} - --nat=extip:$(POD_IP) - --port={{ include "geth.p2pPort" . }} - {{- end }} - {{- if .Values.ws.enabled }} - --ws - --ws.addr=0.0.0.0 - --ws.port={{ .Values.ws.port }} - --ws.origins={{ .Values.ws.origins }} - --ws.api={{ .Values.ws.api }} - {{- end }} - {{- if .Values.terminalTotalDifficulty }} - --override.terminaltotaldifficulty={{ .Values.terminalTotalDifficulty }} - {{- end }} - --datadir=/data/ethereum - --ethash.dagdir=/data/ethereum/.ethash - --ipcdisable - --{{ .Values.global.network }} - {{- range .Values.extraFlags }} - {{ . | quote }} - {{- end }} - {{- if .Values.global.metrics.enabled }} - {{- range .Values.metrics.flags }} - {{ . | quote }} - {{- end }} - {{- end }} - env: - - name: POD_IP - valueFrom: - fieldRef: - fieldPath: status.podIP - ports: - {{- if .Values.global.JWTSecret }} - - name: authrpc - containerPort: {{ .Values.authRpc.port }} - {{- end }} - {{- if .Values.http.enabled }} - - name: http - containerPort: {{ .Values.http.port }} - {{- end }} - {{- if .Values.ws.enabled }} - - name: ws - containerPort: {{ .Values.ws.port }} - {{- end }} - {{- if .Values.global.metrics.enabled }} - - name: metrics - containerPort: {{ .Values.metrics.port }} - {{- end }} - {{- if .Values.p2pNodePort.enabled }} - - name: p2p-tcp - containerPort: {{ include "geth.p2pPort" . }} - protocol: TCP - - name: p2p-udp - containerPort: {{ include "geth.p2pPort" . }} - protocol: UDP - {{- end }} - volumeMounts: - - name: data - mountPath: /data/ethereum - {{- if .Values.global.JWTSecret }} - - name: jwtsecret - mountPath: /secret - readOnly: true - {{- end }} - - name: env-nodeport - mountPath: /env - {{- with .Values.resources }} - resources: - {{ toYaml . | nindent 12 | trim }} - {{- end }} - {{- if .Values.http.enabled }} - - name: sidecar - image: "{{ .Values.sidecar.repository }}:{{ .Values.sidecar.tag }}" - imagePullPolicy: {{ .Values.sidecar.pullPolicy }} - env: - - name: SERVER_BINDADDR - value: "{{ .Values.sidecar.bindAddr }}:{{ .Values.sidecar.bindPort }}" - - name: CLIENT_PORT - value: {{ .Values.http.port | quote }} - ports: - - containerPort: {{ .Values.sidecar.bindPort }} - name: sidecar - protocol: TCP - {{- if or .Values.global.livenessProbe.enabled .Values.livenessProbe.enabled }} - livenessProbe: - initialDelaySeconds: {{ .Values.livenessProbe.initialDelaySeconds }} - timeoutSeconds: {{ .Values.livenessProbe.timeoutSeconds }} - periodSeconds: {{ .Values.livenessProbe.periodSeconds }} - failureThreshold: {{ .Values.livenessProbe.failureThreshold }} - successThreshold: {{ .Values.livenessProbe.successThreshold }} - httpGet: - path: {{ .Values.livenessProbe.httpGet.path }} - port: {{ .Values.livenessProbe.httpGet.port }} - scheme: {{ .Values.livenessProbe.httpGet.scheme }} - {{- end }} - {{- if or .Values.global.readinessProbe.enabled .Values.readinessProbe.enabled }} - readinessProbe: - initialDelaySeconds: {{ .Values.readinessProbe.initialDelaySeconds }} - timeoutSeconds: {{ .Values.readinessProbe.timeoutSeconds }} - periodSeconds: {{ .Values.readinessProbe.periodSeconds }} - failureThreshold: {{ .Values.readinessProbe.failureThreshold }} - successThreshold: {{ .Values.readinessProbe.successThreshold }} - httpGet: - path: {{ .Values.readinessProbe.httpGet.path }} - port: {{ .Values.readinessProbe.httpGet.port }} - scheme: {{ .Values.readinessProbe.httpGet.scheme }} - {{- end }} - {{- end }} - volumes: - {{- if .Values.global.JWTSecret }} - - name: jwtsecret - secret: - secretName: {{ include "common.names.fullname" . }} - {{- end }} - - name: env-nodeport - emptyDir: {} -{{- if (not .Values.persistence.enabled) }} - - name: data - emptyDir: {} -{{- else }} - volumeClaimTemplates: - - metadata: - name: data - labels: - {{- include "common.labels.statefulset" . | nindent 10 }} - {{- with .Values.persistence.annotations }} - annotations: - {{ toYaml . | nindent 10 | trim }} - {{- end }} - spec: - accessModes: {{ .Values.persistence.accessModes }} - storageClassName: {{ .Values.persistence.storageClassName }} - resources: - requests: - storage: {{ .Values.persistence.size | quote }} -{{- end }} diff --git a/charts/geth/templates/tests/test-connection.yaml b/charts/geth/templates/tests/test-connection.yaml deleted file mode 100644 index 2e7e9fdbb..000000000 --- a/charts/geth/templates/tests/test-connection.yaml +++ /dev/null @@ -1,19 +0,0 @@ -{{- if .Values.http.enabled }} -apiVersion: v1 -kind: Pod -metadata: - name: "{{ include "common.names.fullname" . }}-test-connection" - labels: - {{- include "common.labels.standard" . | nindent 4 }} - annotations: - "helm.sh/hook": test -spec: - containers: - - name: wget - image: busybox - command: ['wget'] - {{- if .Values.http.enabled }} - args: ['{{ include "common.names.fullname" . }}:{{ .Values.http.port }}'] - {{- end }} - restartPolicy: Never -{{- end }} diff --git a/charts/geth/values.yaml b/charts/geth/values.yaml deleted file mode 100644 index 812166bfb..000000000 --- a/charts/geth/values.yaml +++ /dev/null @@ -1,386 +0,0 @@ -# Default values for geth. -# This is a YAML-formatted file. -# Declare variables to be passed into your templates. - -global: - replicaCount: 1 - - ## Eth2 network ID - ## - network: mainnet - - ## JSON Web Token (JWT) authentication is used to secure the communication - ## between the beacon node and execution client. You can generate a JWT using - ## a command line tool, for example: - ## openssl rand -hex 32 > token.txt - ## - JWTSecret: "" - - ## Credentials to fetch images from private registry - ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/ - ## - imagePullSecrets: [] - - ## Service account - ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ - ## Additional settings could be made in non-global section. - ## - serviceAccount: - # Specifies whether a service account should be created - create: true - - ## RBAC configuration. - ## ref: https://kubernetes.io/docs/reference/access-authn-authz/rbac/ - ## Additional settings could be made in non-global section. - ## - rbac: - ## Specifies whether RBAC resources are to be created - ## - create: true - - ## Monitoring - ## Additional settings could be made in non-global section. - ## - metrics: - ## Whether to enable metrics collection or not - ## - enabled: true - - ## Prometheus Service Monitor - ## ref: https://github.com/coreos/prometheus-operator - ## https://github.com/coreos/prometheus-operator/blob/master/Documentation/api.md#endpoint - ## - serviceMonitor: - ## Create ServiceMonitor resource(s) for scraping metrics using PrometheusOperator - ## - enabled: false - - ## Custom PrometheusRule to be defined - ## ref: https://github.com/coreos/prometheus-operator#customresourcedefinitions - ## - prometheusRule: - ## Create a custom prometheusRule Resource for scraping metrics using PrometheusOperator - ## - enabled: false - - ## Configure liveness and readiness probes - ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/ - ## NB! readinessProbe and livenessProbe must be disabled before fully synced - ## Additional settings could be made in non-global section. - ## - livenessProbe: - enabled: true - - readinessProbe: - enabled: true - -## Init image is used to chown data volume, initialise genesis, etc. -## -initImage: - repository: "bitnami/kubectl" - tag: "1.24" - pullPolicy: IfNotPresent - -## Sidecar image is used to perform Liveness/Readiness probes. -## -sidecar: - repository: "europe-west4-docker.pkg.dev/stakewiselabs/public/ethnode-sidecar" - tag: "v1.0.5" - pullPolicy: IfNotPresent - bindAddr: "0.0.0.0" - bindPort: 3000 - -## Geth image version -## ref: https://hub.docker.com/r/ethereum/client-go/tags/ -## -image: - repository: "ethereum/client-go" - tag: "v1.10.25" - pullPolicy: IfNotPresent - -## Credentials to fetch images from private registry -## ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/ -## -imagePullSecrets: [] - -## Provide a name in place of geth for `app:` labels -## -nameOverride: "" - -## Provide a name to substitute for the full names of resources -## -fullnameOverride: "" - -## Service account -## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ -## -serviceAccount: - # Annotations to add to the service account - annotations: {} - # The name of the service account to use. - # If not set and create is true, a name is generated using the fullname template - name: "" - -## Additional labels for all resources -## -additionalLabels: - client-type: "execution" - -## Termination Grace Period -## ref: https://kubernetes.io/docs/tasks/run-application/force-delete-stateful-set-pod/#delete-pods -## -terminationGracePeriodSeconds: 300 - -## Pod Security Context -## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/ -## -securityContext: - fsGroup: 1001 - runAsUser: 1001 - -## RBAC configuration. -## ref: https://kubernetes.io/docs/reference/access-authn-authz/rbac/ -## -rbac: - # The name of the cluster role to use. - # If not set and create is true, a name is generated using the fullname template - name: "" - ## Required ClusterRole rules - ## - clusterRules: - ## Required to obtain the nodes external IP - ## - - apiGroups: [""] - resources: - - "nodes" - verbs: - - "get" - - "list" - - "watch" - ## Required Role rules - ## - rules: - ## Required to get information about the serices nodePort. - ## - - apiGroups: [""] - resources: - - "services" - verbs: - - "get" - - "list" - - "watch" - -# Manually specify TerminalTotalDifficulty, overriding the bundled setting -terminalTotalDifficulty: "" - -## AuthRPC configuration. -## -authRpc: - port: "8551" - vhosts: "*" - addr: "0.0.0.0" - -## RPC configuration. -## -http: - enabled: true - port: "8545" - api: "web3,eth,net,engine" - corsDomain: "" - vhosts: "*" - -## WebSocket configuration. -## -ws: - enabled: true - port: "8546" - api: "web3,eth,net,engine" - origins: "*" - -## Extra flags to pass to the node -## -extraFlags: - - "--syncmode=snap" - -## Configure pod disruption budgets for Alertmanager -## ref: https://kubernetes.io/docs/tasks/run-application/configure-pdb/#specifying-a-poddisruptionbudget -## This configuration is immutable once created and will require the PDB to be deleted to be changed -## https://github.com/kubernetes/kubernetes/issues/45398 -## -podDisruptionBudget: - enabled: true - maxUnavailable: 1 - -## Defines whether the service must be headless -## -svcHeadless: true - -## Configure session affinity for validator clients to hit the same beacon node -## for the period specified in `timeoutSeconds` -## ref: https://kubernetes.io/docs/concepts/services-networking/service/#proxy-mode-userspace -## -sessionAffinity: - # Whether to enable session affinity or not - enabled: false - # The session duration in seconds - timeoutSeconds: 86400 - -## When p2pNodePort is enabled, your P2P port will be exposed via service type NodePort. -## This will generate a service for each replica, with a port binding via NodePort. -## This is useful if you want to expose and announce your node to the Internet. -## -p2pNodePort: - ## @param p2pNodePort.enabled Expose P2P port via NodePort - ## - enabled: false - ## @param p2pNodePort.annotations - ## - annotations: {} - ## @param p2pNodePort.type - ## Options: NodePort, LoadBalancer - type: NodePort - ## @param p2pNodePort.startAt The ports allocation will start from this value - ## - startAt: 31100 - ## @param p2pNodePort.replicaToNodePort Overwrite a port for specific replicas - ## @default -- See `values.yaml` for example - replicaToNodePort: {} - # "0": 32345 - # "3": 32348 - -## Monitoring -## -metrics: - ## Prometheus exporter port - ## - port: 6060 - - ## Extra flags to pass for collecting metrics - ## - flags: - - "--metrics" - - "--pprof" - - "--pprof.addr=0.0.0.0" - - "--pprof.port=6060" - - ## Prometheus Service Monitor - ## ref: https://github.com/coreos/prometheus-operator - ## https://github.com/coreos/prometheus-operator/blob/master/Documentation/api.md#endpoint - ## - serviceMonitor: - ## The namespace in which the ServiceMonitor will be created - ## - namespace: "" - ## The interval at which metrics should be scraped - ## - interval: 30s - ## The timeout after which the scrape is ended - ## - scrapeTimeout: "" - ## Metrics RelabelConfigs to apply to samples before scraping. - ## - relabellings: [] - ## Metrics RelabelConfigs to apply to samples before ingestion. - ## - metricRelabelings: [] - ## Specify honorLabels parameter to add the scrape endpoint - ## - honorLabels: false - ## Additional labels that can be used so ServiceMonitor resource(s) can be discovered by Prometheus - ## - additionalLabels: {} - ## Custom PrometheusRule to be defined - ## ref: https://github.com/coreos/prometheus-operator#customresourcedefinitions - ## - prometheusRule: - ## Create a default set of Alerts - ## - default: true - ## The namespace in which the prometheusRule will be created - ## - namespace: "" - ## Additional labels for the prometheusRule - ## - additionalLabels: {} - ## Custom Prometheus rules - ## - rules: [] - -## Configure resource requests and limits. -## http://kubernetes.io/docs/user-guide/compute-resources/ -## -resources: {} - -## If false, data ownership will not be reset at startup -## This allows the geth node to be run with an arbitrary user -## -initChownData: true - -## Whether or not to allocate persistent volume disk for the data directory. -## In case of node failure, the node data directory will still persist. -## -persistence: - enabled: true - storageClassName: "" - accessModes: - - ReadWriteOnce - size: 900Gi - annotations: {} - -## Node labels for pod assignment -## ref: https://kubernetes.io/docs/user-guide/node-selection/ -## -nodeSelector: {} - -## Tolerations for pod assignment -## ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/ -## -tolerations: {} - -## Affinity for pod assignment -## ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity -## -## Example: -## affinity: -## podAntiAffinity: -## requiredDuringSchedulingIgnoredDuringExecution: -## - labelSelector: -## matchExpressions: -## - key: app.kubernetes.io/name -## operator: In -## values: -## - geth -## topologyKey: kubernetes.io/hostname -## -affinity: {} - -## used to assign priority to pods -## ref: https://kubernetes.io/docs/concepts/configuration/pod-priority-preemption/ -## -priorityClassName: "" - -## Configure liveness and readiness probes -## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/ -## NB! readinessProbe and livenessProbe must be disabled before fully synced -## -livenessProbe: - initialDelaySeconds: 900 - timeoutSeconds: 3 - periodSeconds: 30 - failureThreshold: 3 - successThreshold: 1 - httpGet: - path: /eth1/liveness - port: sidecar - scheme: HTTP - -readinessProbe: - initialDelaySeconds: 30 - timeoutSeconds: 3 - periodSeconds: 30 - failureThreshold: 30 - successThreshold: 1 - httpGet: - path: /eth1/readiness - port: sidecar - scheme: HTTP diff --git a/charts/grafana-stakewise-dashboards/Chart.yaml b/charts/grafana-stakewise-dashboards/Chart.yaml deleted file mode 100644 index 63e70f79e..000000000 --- a/charts/grafana-stakewise-dashboards/Chart.yaml +++ /dev/null @@ -1,29 +0,0 @@ -apiVersion: v2 -name: grafana-stakewise-dashboards -description: A set of Grafana Dashboards for Staking Infrastructure - -# A chart can be either an 'application' or a 'library' chart. -# -# Application charts are a collection of templates that can be packaged into versioned archives -# to be deployed. -# -# Library charts provide useful utilities or functions for the chart developer. They're included as -# a dependency of application charts to inject those utilities and functions into the rendering -# pipeline. Library charts do not define any templates and therefore cannot be deployed. -type: application - -# This is the chart version. This version number should be incremented each time you make changes -# to the chart and its templates, including the app version. -# Versions are expected to follow Semantic Versioning (https://semver.org/) -version: 1.0.0 - -# This is the version number of the application being deployed. This version number should be -# incremented each time you make changes to the application. Versions are not expected to -# follow Semantic Versioning. They should reflect the version the application is using. -# It is recommended to use it with quotes. -appVersion: "1.0.0" - -dependencies: -- name: common - repository: file://../common - version: 1.0.0 diff --git a/charts/grafana-stakewise-dashboards/dashboards/erigon.json b/charts/grafana-stakewise-dashboards/dashboards/erigon.json deleted file mode 100644 index dba388746..000000000 --- a/charts/grafana-stakewise-dashboards/dashboards/erigon.json +++ /dev/null @@ -1,5151 +0,0 @@ -{ - "annotations": { - "list": [ - { - "builtIn": 1, - "datasource": "-- Grafana --", - "enable": true, - "hide": true, - "iconColor": "rgba(0, 211, 255, 1)", - "name": "Annotations & Alerts", - "target": { - "limit": 100, - "matchAny": false, - "tags": [], - "type": "dashboard" - }, - "type": "dashboard" - } - ] - }, - "description": "", - "editable": true, - "fiscalYearStartMonth": 0, - "graphTooltip": 0, - "id": 155, - "iteration": 1650531130174, - "links": [], - "liveNow": false, - "panels": [ - { - "collapsed": false, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 0 - }, - "id": 171, - "panels": [], - "title": "Blocks execution", - "type": "row" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 8, - "x": 0, - "y": 1 - }, - "id": 144, - "links": [], - "options": { - "legend": { - "calcs": [ - "last" - ], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.0.6", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "sync{namespace=\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{stage}}: {{pod}}", - "refId": "A" - } - ], - "title": "Sync Stages progress", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "ops" - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 8, - "x": 8, - "y": 1 - }, - "id": 158, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean" - ], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.0.6", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "rate(sync{namespace=\"$namespace\",pod=~\"$pod\"}[$rate_interval])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{stage}}: {{pod}}", - "refId": "A" - } - ], - "title": "Sync Stages progress rate", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "s" - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 8, - "x": 16, - "y": 1 - }, - "id": 112, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull" - ], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.0.6", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "chain_execution_seconds{quantile=\"$quantile\",namespace=\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "execution: {{pod}}", - "refId": "A" - } - ], - "title": "Block Execution speed ", - "type": "timeseries" - }, - { - "collapsed": false, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 6 - }, - "id": 17, - "panels": [], - "title": "Database", - "type": "row" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "ops" - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 8, - "x": 0, - "y": 7 - }, - "id": 141, - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.0.6", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "rate(db_commit_seconds_count{phase=\"total\",namespace=\"$namespace\",pod=~\"$pod\"}[$__rate_interval])", - "interval": "", - "legendFormat": "commit: {{pod}}", - "refId": "A" - } - ], - "title": "Commit", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "s" - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 8, - "x": 8, - "y": 7 - }, - "id": 166, - "options": { - "legend": { - "calcs": [ - "mean" - ], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.0.6", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "db_commit_seconds{phase=\"total\",quantile=\"$quantile\",namespace=\"$namespace\",pod=~\"$pod\"}", - "interval": "", - "legendFormat": "commit_total: {{pod}}", - "refId": "A" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "db_commit_seconds{phase=\"gc\",quantile=\"$quantile\",namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "commit_gc: {{pod}}", - "refId": "B" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "db_commit_seconds{phase=\"write\",quantile=\"$quantile\",namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "commit_write: {{pod}}", - "refId": "C" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "db_commit_seconds{phase=\"sync\",quantile=\"$quantile\",namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "commit_sync: {{pod}}", - "refId": "D" - } - ], - "title": "Commit speed", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "decbytes" - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 8, - "x": 16, - "y": 7 - }, - "id": 159, - "options": { - "legend": { - "calcs": [ - "lastNotNull" - ], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "single", - "sort": "none" - } - }, - "pluginVersion": "8.0.6", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "expr": "db_size{namespace=\"$namespace\",pod=~\"$pod\"}", - "interval": "", - "legendFormat": "size: {{pod}}", - "refId": "A" - } - ], - "title": "DB Size", - "type": "timeseries" - }, - { - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 8, - "x": 0, - "y": 12 - }, - "id": 169, - "options": { - "legend": { - "calcs": [ - "mean" - ], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.0.6", - "targets": [ - { - "exemplar": true, - "expr": "db_gc_leaf{namespace=\"$namespace\",pod=~\"$pod\"}", - "interval": "", - "legendFormat": "gc_leaf: {{pod}}", - "refId": "A" - }, - { - "exemplar": true, - "expr": "db_gc_overflow{namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "gc_overflow: {{pod}}", - "refId": "B" - }, - { - "exemplar": true, - "expr": "db_state_leaf{namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "state_leaf: {{pod}}", - "refId": "C" - }, - { - "exemplar": true, - "expr": "db_state_branch{namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "state_branch: {{pod}}", - "refId": "D" - } - ], - "title": "GC and State", - "type": "timeseries" - }, - { - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 8, - "x": 8, - "y": 12 - }, - "id": 168, - "options": { - "legend": { - "calcs": [ - "mean" - ], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.0.6", - "targets": [ - { - "exemplar": true, - "expr": "rate(db_pgops_newly{namespace=\"$namespace\",pod=~\"$pod\"}[$rate_interval])", - "hide": true, - "interval": "", - "legendFormat": "newly: {{pod}}", - "refId": "A" - }, - { - "exemplar": true, - "expr": "rate(db_pgops_cow{namespace=\"$namespace\",pod=~\"$pod\"}[$rate_interval])", - "hide": true, - "interval": "", - "legendFormat": "cow: {{pod}}", - "refId": "B" - }, - { - "exemplar": true, - "expr": "rate(db_pgops_clone{namespace=\"$namespace\",pod=~\"$pod\"}[$rate_interval])", - "hide": false, - "interval": "", - "legendFormat": "clone: {{pod}}", - "refId": "C" - }, - { - "exemplar": true, - "expr": "rate(db_pgops_split{namespace=\"$namespace\",pod=~\"$pod\"}[$rate_interval])", - "hide": false, - "interval": "", - "legendFormat": "split: {{pod}}", - "refId": "D" - }, - { - "exemplar": true, - "expr": "rate(db_pgops_merge{namespace=\"$namespace\",pod=~\"$pod\"}[$rate_interval])", - "hide": true, - "interval": "", - "legendFormat": "merge: {{pod}}", - "refId": "E" - }, - { - "exemplar": true, - "expr": "rate(db_pgops_spill{namespace=\"$namespace\",pod=~\"$pod\"}[$rate_interval])", - "hide": false, - "interval": "", - "legendFormat": "spill: {{pod}}", - "refId": "F" - }, - { - "exemplar": true, - "expr": "rate(db_pgops_wops{namespace=\"$namespace\",pod=~\"$pod\"}[$rate_interval])", - "hide": false, - "interval": "", - "legendFormat": "wops: {{pod}}", - "refId": "G" - }, - { - "exemplar": true, - "expr": "rate(db_pgops_unspill{namespace=\"$namespace\",pod=~\"$pod\"}[$rate_interval])", - "hide": false, - "interval": "", - "legendFormat": "unspill: {{pod}}", - "refId": "H" - } - ], - "title": "DB Pages Ops/sec", - "type": "timeseries" - }, - { - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "decbytes" - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 8, - "x": 16, - "y": 12 - }, - "id": 167, - "options": { - "legend": { - "calcs": [ - "mean" - ], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.0.6", - "targets": [ - { - "expr": "tx_limit{namespace=\"$namespace\",pod=~\"$pod\"}", - "interval": "", - "legendFormat": "limit: {{pod}}", - "refId": "A" - }, - { - "expr": "tx_dirty{namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "dirty: {{pod}}", - "refId": "B" - } - ], - "title": "Tx Size", - "type": "timeseries" - }, - { - "collapsed": false, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 18 - }, - "id": 134, - "panels": [], - "title": "Process", - "type": "row" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [] - }, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 18, - "w": 8, - "x": 0, - "y": 19 - }, - "id": 165, - "options": { - "colorMode": "value", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "range" - ], - "fields": "", - "values": false - }, - "text": { - "titleSize": 14, - "valueSize": 14 - }, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "expr": "ru_inblock{namespace=\"$namespace\",pod=~\"$pod\"}", - "interval": "", - "legendFormat": "inblock: {{pod}}", - "refId": "A" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "expr": "ru_outblock{namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "outblock: {{pod}}", - "refId": "B" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "expr": "ru_minflt{namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "minflt: {{pod}}", - "refId": "C" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "expr": "ru_majflt{namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "majflt: {{pod}}", - "refId": "D" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "expr": "system_disk_readbytes{namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "system_disk_readbytes: {{pod}}", - "refId": "E" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "expr": "system_disk_writebytes{namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "system_disk_writebytes: {{pod}}", - "refId": "F" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "expr": "db_pgops_newly{namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "pgops_newly: {{pod}}", - "refId": "H" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "expr": "db_pgops_cow{namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "pgops_cow: {{pod}}", - "refId": "I" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "expr": "db_pgops_clone{namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "pgops_clone: {{pod}}", - "refId": "J" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "expr": "db_pgops_split{namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "pgops_split: {{pod}}", - "refId": "K" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "expr": "db_pgops_merge{namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "pgops_merge: {{pod}}", - "refId": "L" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "expr": "db_pgops_spill{namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "pgops_spill: {{pod}}", - "refId": "G" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "expr": "db_pgops_unspill{namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "pgops_unspill: {{pod}}", - "refId": "M" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "expr": "db_pgops_wops{namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "pgops_wops: {{pod}}", - "refId": "N" - } - ], - "title": "Rusage Total (\"last value\" - \"first value\" on selected period)", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 8, - "x": 8, - "y": 19 - }, - "id": 155, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean" - ], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.0.6", - "targets": [ - { - "exemplar": true, - "expr": "rate(process_io_write_syscalls_total{namespace=\"$namespace\",pod=~\"$pod\"}[$rate_interval])", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "in: {{pod}}", - "refId": "C" - }, - { - "exemplar": true, - "expr": "rate(process_io_read_syscalls_total{namespace=\"$namespace\",pod=~\"$pod\"}[$rate_interval])", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "out: {{pod}}", - "refId": "D" - } - ], - "title": "Read/Write syscall/sec", - "type": "timeseries" - }, - { - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "ops" - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 8, - "x": 16, - "y": 19 - }, - "id": 150, - "options": { - "legend": { - "calcs": [ - "mean" - ], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.0.6", - "targets": [ - { - "exemplar": true, - "expr": "rate(process_minor_pagefaults_total{namespace=\"$namespace\",pod=~\"$pod\"}[$rate_interval])", - "interval": "", - "legendFormat": "soft: {{pod}}", - "refId": "A" - }, - { - "exemplar": true, - "expr": "rate(process_major_pagefaults_total{namespace=\"$namespace\",pod=~\"$pod\"}[$rate_interval])", - "hide": false, - "interval": "", - "legendFormat": "hard: {{pod}}", - "refId": "B" - } - ], - "title": "getrusage: minflt - soft page faults (reclaims), majflt - hard faults", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "Bps" - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 8, - "x": 8, - "y": 25 - }, - "id": 85, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean" - ], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.0.6", - "targets": [ - { - "exemplar": true, - "expr": "rate(process_io_storage_read_bytes_total{namespace=\"$namespace\",pod=~\"$pod\"}[$rate_interval])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "read: {{pod}}", - "refId": "A" - }, - { - "exemplar": true, - "expr": "rate(process_io_storage_written_bytes_total{namespace=\"$namespace\",pod=~\"$pod\"}[$rate_interval])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "write: {{pod}}", - "refId": "B" - } - ], - "title": "Disk bytes/sec", - "type": "timeseries" - }, - { - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "cps" - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 8, - "x": 16, - "y": 25 - }, - "id": 153, - "options": { - "legend": { - "calcs": [ - "mean" - ], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.0.6", - "targets": [ - { - "exemplar": true, - "expr": "rate(go_cgo_calls_count{namespace=\"$namespace\",pod=~\"$pod\"}[$rate_interval])", - "interval": "", - "legendFormat": "go_cgo_calls_count: {{pod}}", - "refId": "A" - } - ], - "title": "cgo calls", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "decbytes" - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 8, - "x": 8, - "y": 31 - }, - "id": 154, - "links": [], - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.0.6", - "targets": [ - { - "exemplar": true, - "expr": "go_memstats_stack_sys_bytes{namespace=\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "go_memstats_stack_sys_bytes", - "refId": "A" - }, - { - "exemplar": true, - "expr": "go_memstats_sys_bytes{namespace=\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "go_memstats_sys_bytes", - "refId": "B" - }, - { - "exemplar": true, - "expr": "go_memstats_stack_inuse_bytes{namespace=\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "go_memstats_stack_inuse_bytes", - "refId": "C" - }, - { - "exemplar": true, - "expr": "go_memstats_mspan_sys_bytes{namespace=\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "go_memstats_mspan_sys_bytes", - "refId": "D" - }, - { - "exemplar": true, - "expr": "go_memstats_mcache_sys_bytes{namespace=\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "go_memstats_mcache_sys_bytes", - "refId": "E" - }, - { - "exemplar": true, - "expr": "go_memstats_heap_alloc_bytes{namespace=\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "go_memstats_heap_alloc_bytes", - "refId": "F" - } - ], - "title": "go memstat", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 8, - "x": 16, - "y": 31 - }, - "id": 128, - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.0.6", - "targets": [ - { - "expr": "go_goroutines{namespace=\"$namespace\",pod=~\"$pod\"}", - "instant": false, - "interval": "", - "legendFormat": "go/goroutines: {{pod}}", - "refId": "A" - }, - { - "expr": "go_threads{namespace=\"$namespace\",pod=~\"$pod\"}", - "instant": false, - "interval": "", - "legendFormat": "go/threads: {{pod}}", - "refId": "B" - } - ], - "title": "GO Goroutines and Threads", - "type": "timeseries" - }, - { - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "decbytes" - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 8, - "x": 0, - "y": 37 - }, - "id": 148, - "options": { - "legend": { - "calcs": [ - "max" - ], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.0.6", - "targets": [ - { - "exemplar": true, - "expr": "process_virtual_memory_bytes{namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": true, - "interval": "", - "legendFormat": "resident virtual mem: {{pod}}", - "refId": "A" - }, - { - "exemplar": true, - "expr": "process_resident_memory_anon_bytes{namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": true, - "interval": "", - "legendFormat": "resident anon mem: {{pod}}", - "refId": "B" - }, - { - "exemplar": true, - "expr": "process_resident_memory_bytes{namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "resident mem: {{pod}}", - "refId": "C" - }, - { - "expr": "mem_data{namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "data: {{pod}}", - "refId": "D" - }, - { - "expr": "mem_stack{namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "stack: {{pod}}", - "refId": "E" - }, - { - "expr": "mem_locked{namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "locked: {{pod}}", - "refId": "F" - }, - { - "expr": "mem_swap{namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "swap: {{pod}}", - "refId": "G" - } - ], - "title": "mem: resident set size", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "decbytes" - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 8, - "x": 8, - "y": 37 - }, - "id": 157, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean" - ], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.0.6", - "targets": [ - { - "expr": "vmem_total{namespace=\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "total: {{pod}}", - "refId": "A" - }, - { - "expr": "vmem_available{namespace=\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "available: {{pod}}", - "refId": "B" - }, - { - "expr": "vmem_used{namespace=\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "used: {{pod}}", - "refId": "C" - }, - { - "expr": "vmem_buffers{namespace=\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "buffers: {{pod}}", - "refId": "D" - }, - { - "expr": "vmem_cached{namespace=\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "cached: {{pod}}", - "refId": "E" - }, - { - "expr": "vmem_writeback{namespace=\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "writeback: {{pod}}", - "refId": "F" - }, - { - "expr": "vmem_dirty{namespace=\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "dirty: {{pod}}", - "refId": "G" - }, - { - "expr": "vmem_shared{namespace=\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "shared: {{pod}}", - "refId": "H" - }, - { - "expr": "vmem_mapped{namespace=\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "mapped: {{pod}}", - "refId": "I" - } - ], - "title": "Host VMem", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "s" - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 8, - "x": 16, - "y": 37 - }, - "id": 124, - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.0.6", - "targets": [ - { - "exemplar": true, - "expr": "rate(go_gc_duration_seconds{quantile=\"0.75\",namespace=\"$namespace\",pod=~\"$pod\"}[$rate_interval])", - "instant": false, - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "GC Stop the World per sec", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 8, - "x": 0, - "y": 42 - }, - "id": 86, - "links": [], - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.0.6", - "targets": [ - { - "exemplar": true, - "expr": "rate(go_memstats_mallocs_total{namespace=\"$namespace\",pod=~\"$pod\"}[$rate_interval])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "go_memstats_mallocs_total", - "refId": "A" - }, - { - "exemplar": true, - "expr": "rate(go_memstats_frees_total{namespace=\"$namespace\",pod=~\"$pod\"}[$rate_interval])", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "go_memstats_frees_total", - "refId": "B" - } - ], - "title": "Process Mem: allocate objects/sec, free", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "percent" - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 8, - "x": 0, - "y": 47 - }, - "id": 106, - "links": [], - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.0.6", - "targets": [ - { - "exemplar": true, - "expr": "increase(process_cpu_seconds_system_total{namespace=\"$namespace\",pod=~\"$pod\"}[1m])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "system: {{pod}}", - "refId": "A" - }, - { - "exemplar": true, - "expr": "increase(process_cpu_seconds_user_total{namespace=\"$namespace\",pod=~\"$pod\"}[1m])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "iowait: {{pod}}", - "refId": "B" - } - ], - "title": "CPU", - "type": "timeseries" - }, - { - "collapsed": true, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 52 - }, - "id": 173, - "panels": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 0, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "auto", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green" - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "s" - }, - "overrides": [ - { - "__systemRef": "hideSeriesFrom", - "matcher": { - "id": "byNames", - "options": { - "mode": "exclude", - "names": [ - "pool_write_to_db: turbogeth16c.weblogix.it:6060" - ], - "prefix": "All except:", - "readOnly": true - } - }, - "properties": [ - { - "id": "custom.hideFrom", - "value": { - "legend": false, - "tooltip": false, - "viz": true - } - } - ] - } - ] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 53 - }, - "id": 175, - "options": { - "legend": { - "calcs": [ - "mean", - "last" - ], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "single", - "sort": "none" - } - }, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "pool_process_remote_txs{quantile=\"$quantile\",namespace=\"$namespace\",pod=~\"$pod\"}", - "interval": "", - "legendFormat": "process_remote_txs: {{pod}}", - "refId": "A" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "pool_add_remote_txs{quantile=\"$quantile\",namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "add_remote_txs: {{pod}}", - "refId": "B" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "pool_new_block{quantile=\"$quantile\",namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "new_block: {{pod}}", - "refId": "C" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "pool_write_to_db{quantile=\"$quantile\",namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "write_to_db: {{pod}}", - "refId": "D" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "pool_propagate_to_new_peer{quantile=\"$quantile\",namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "propagate_to_new_peer: {{pod}}", - "refId": "E" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "pool_propagate_new_txs{quantile=\"$quantile\",namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "propagate_new_txs: {{pod}}", - "refId": "F" - } - ], - "title": "Timings", - "transformations": [], - "type": "timeseries" - }, - { - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 0, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "auto", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green" - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "reqps" - }, - "overrides": [ - { - "__systemRef": "hideSeriesFrom", - "matcher": { - "id": "byNames", - "options": { - "mode": "exclude", - "names": [ - "pool_add_remote_txs_count: turbogeth16c.weblogix.it:6060" - ], - "prefix": "All except:", - "readOnly": true - } - }, - "properties": [ - { - "id": "custom.hideFrom", - "value": { - "legend": false, - "tooltip": false, - "viz": true - } - } - ] - } - ] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 53 - }, - "id": 177, - "options": { - "legend": { - "calcs": [ - "mean", - "last" - ], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "single", - "sort": "none" - } - }, - "targets": [ - { - "exemplar": true, - "expr": "rate(pool_process_remote_txs_count{namespace=\"$namespace\",pod=~\"$pod\"}[$rate_interval])", - "hide": false, - "interval": "", - "legendFormat": "pool_process_remote_txs_count: {{pod}}", - "refId": "A" - }, - { - "exemplar": true, - "expr": "rate(pool_add_remote_txs_count{namespace=\"$namespace\",pod=~\"$pod\"}[$rate_interval])", - "hide": false, - "interval": "", - "legendFormat": "pool_add_remote_txs_count: {{pod}}", - "refId": "B" - }, - { - "exemplar": true, - "expr": "rate(pool_new_block_count{namespace=\"$namespace\",pod=~\"$pod\"}[$rate_interval])", - "hide": false, - "interval": "", - "legendFormat": "pool_new_block_count: {{pod}}", - "refId": "C" - }, - { - "exemplar": true, - "expr": "rate(pool_write_to_db_count{namespace=\"$namespace\",pod=~\"$pod\"}[$rate_interval])", - "hide": false, - "interval": "", - "legendFormat": "pool_write_to_db_count: {{pod}}", - "refId": "D" - } - ], - "title": "RPS", - "transformations": [], - "type": "timeseries" - }, - { - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 0, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "auto", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green" - }, - { - "color": "red", - "value": 80 - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 8, - "x": 0, - "y": 61 - }, - "id": 176, - "options": { - "legend": { - "calcs": [ - "mean", - "last" - ], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "single", - "sort": "none" - } - }, - "targets": [ - { - "exemplar": true, - "expr": "sum(delta(cache_total{result=\"hit\",name=\"txpool\",namespace=\"$namespace\",pod=~\"$pod\"}[1m]))/sum(delta(cache_total{name=\"txpool\",namespace=\"$namespace\",pod=~\"$pod\"}[1m])) ", - "hide": false, - "interval": "", - "legendFormat": "hit rate: {{pod}} ", - "refId": "A" - } - ], - "title": "Cache hit-rate", - "type": "timeseries" - }, - { - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 0, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "auto", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green" - }, - { - "color": "red", - "value": 80 - } - ] - } - }, - "overrides": [ - { - "__systemRef": "hideSeriesFrom", - "matcher": { - "id": "byNames", - "options": { - "mode": "exclude", - "names": [ - "hit: turbogeth16c.weblogix.it:6060 " - ], - "prefix": "All except:", - "readOnly": true - } - }, - "properties": [ - { - "id": "custom.hideFrom", - "value": { - "legend": false, - "tooltip": false, - "viz": true - } - } - ] - } - ] - }, - "gridPos": { - "h": 6, - "w": 8, - "x": 8, - "y": 61 - }, - "id": 180, - "options": { - "legend": { - "calcs": [ - "mean", - "last" - ], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "single", - "sort": "none" - } - }, - "targets": [ - { - "exemplar": true, - "expr": "rate(cache_total{name=\"txpool\",namespace=\"$namespace\",pod=~\"$pod\"}[1m])", - "hide": false, - "interval": "", - "legendFormat": "{{result}}: {{pod}} ", - "refId": "A" - }, - { - "exemplar": true, - "expr": "rate(cache_timeout_total{name=\"txpool\",namespace=\"$namespace\",pod=~\"$pod\"}[1m])", - "hide": false, - "interval": "", - "legendFormat": "timeout: {{pod}} ", - "refId": "B" - } - ], - "title": "Cache rps", - "type": "timeseries" - }, - { - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 0, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "auto", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green" - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 8, - "x": 16, - "y": 61 - }, - "id": 181, - "options": { - "legend": { - "calcs": [ - "mean", - "last" - ], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "single", - "sort": "none" - } - }, - "targets": [ - { - "exemplar": true, - "expr": "cache_keys_total{name=\"txpool\",namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "keys: {{pod}} ", - "refId": "A" - }, - { - "exemplar": true, - "expr": "cache_list_total{name=\"txpool\",namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "list: {{pod}} ", - "refId": "B" - } - ], - "title": "Cache keys", - "type": "timeseries" - }, - { - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 0, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "auto", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green" - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "binBps" - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 8, - "x": 0, - "y": 67 - }, - "id": 178, - "options": { - "legend": { - "calcs": [ - "mean", - "last" - ], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "single", - "sort": "none" - } - }, - "targets": [ - { - "exemplar": true, - "expr": "rate(pool_write_to_db_bytes{namespace=\"$namespace\",pod=~\"$pod\"}[$rate_interval])", - "hide": false, - "interval": "", - "legendFormat": "pool_write_to_db_bytes: {{pod}}", - "refId": "A" - } - ], - "title": "DB", - "type": "timeseries" - } - ], - "title": "TxPool v2", - "type": "row" - }, - { - "collapsed": true, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 53 - }, - "id": 183, - "panels": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 0, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "auto", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "reqps" - }, - "overrides": [ - { - "__systemRef": "hideSeriesFrom", - "matcher": { - "id": "byNames", - "options": { - "mode": "exclude", - "names": [ - "success eth_call turbogeth16c.weblogix.it:6062 " - ], - "prefix": "All except:", - "readOnly": true - } - }, - "properties": [ - { - "id": "custom.hideFrom", - "value": { - "legend": false, - "tooltip": false, - "viz": true - } - } - ] - } - ] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 54 - }, - "id": 185, - "options": { - "legend": { - "calcs": [ - "mean", - "last" - ], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "single", - "sort": "none" - } - }, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "rate(rpc_duration_seconds_count{instance=~\"$instance\",success=\"success\"}[1m])", - "interval": "", - "legendFormat": "success {{method}} {{pod}} ", - "refId": "A" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "rate(rpc_duration_seconds_count{instance=~\"$instance\",success=\"failure\"}[1m])", - "hide": false, - "interval": "", - "legendFormat": "failure {{method}} {{pod}} ", - "refId": "B" - } - ], - "title": "RPS", - "transformations": [], - "type": "timeseries" - }, - { - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 0, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "auto", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "s" - }, - "overrides": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 54 - }, - "id": 186, - "options": { - "legend": { - "calcs": [ - "mean", - "last" - ], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "single", - "sort": "none" - } - }, - "targets": [ - { - "exemplar": true, - "expr": "db_begin_seconds{quantile=\"$quantile\",namespace=\"$namespace\",pod=~\"$pod\"}", - "interval": "", - "legendFormat": "db_begin_seconds: {{method}} {{pod}}", - "refId": "A" - } - ], - "title": "DB begin", - "transformations": [], - "type": "timeseries" - }, - { - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 0, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "auto", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "s" - }, - "overrides": [ - { - "__systemRef": "hideSeriesFrom", - "matcher": { - "id": "byNames", - "options": { - "mode": "exclude", - "names": [ - " eth_call turbogeth16c.weblogix.it:6062 success", - " eth_call turbogeth16c.weblogix.it:6062 failure" - ], - "prefix": "All except:", - "readOnly": true - } - }, - "properties": [ - { - "id": "custom.hideFrom", - "value": { - "legend": false, - "tooltip": false, - "viz": true - } - } - ] - } - ] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 62 - }, - "id": 187, - "options": { - "legend": { - "calcs": [ - "mean", - "last" - ], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "single", - "sort": "none" - } - }, - "targets": [ - { - "exemplar": true, - "expr": "rpc_duration_seconds{quantile=\"$quantile\",namespace=\"$namespace\",pod=~\"$pod\"}", - "interval": "", - "legendFormat": " {{method}} {{pod}} {{sucess}}", - "refId": "A" - } - ], - "title": "Timings", - "transformations": [], - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 62 - }, - "id": 188, - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.0.6", - "targets": [ - { - "expr": "go_goroutines{namespace=\"$namespace\",pod=~\"$pod\"}", - "instant": false, - "interval": "", - "legendFormat": "go/goroutines: {{pod}}", - "refId": "A" - }, - { - "expr": "go_threads{namespace=\"$namespace\",pod=~\"$pod\"}", - "instant": false, - "interval": "", - "legendFormat": "go/threads: {{pod}}", - "refId": "B" - } - ], - "title": "GO Goroutines and Threads", - "type": "timeseries" - }, - { - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 0, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "auto", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 12, - "x": 0, - "y": 70 - }, - "id": 189, - "options": { - "legend": { - "calcs": [ - "mean", - "last" - ], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "single", - "sort": "none" - } - }, - "targets": [ - { - "exemplar": true, - "expr": "cache_keys_total{name=\"rpc\",namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "keys: {{pod}} ", - "refId": "A" - }, - { - "exemplar": true, - "expr": "cache_list_total{name=\"rpc\",namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "list: {{pod}} ", - "refId": "B" - }, - { - "exemplar": true, - "expr": "cache_code_keys_total{name=\"rpc\",namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "code_keys: {{pod}} ", - "refId": "C" - }, - { - "exemplar": true, - "expr": "cache_code_list_total{name=\"rpc\",namespace=\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "code_list: {{pod}} ", - "refId": "D" - } - ], - "title": "Cache keys", - "type": "timeseries" - }, - { - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 0, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "auto", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 12, - "x": 12, - "y": 70 - }, - "id": 184, - "options": { - "legend": { - "calcs": [ - "mean", - "last" - ], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "single", - "sort": "none" - } - }, - "targets": [ - { - "exemplar": true, - "expr": "sum(delta(cache_total{result=\"hit\",name=\"rpc\",namespace=\"$namespace\",pod=~\"$pod\"}[1m]))/sum(delta(cache_total{name=\"rpc\",namespace=\"$namespace\",pod=~\"$pod\"}[1m])) ", - "hide": false, - "interval": "", - "legendFormat": "hit rate: {{pod}} ", - "refId": "A" - }, - { - "exemplar": true, - "expr": "sum(delta(cache_code_total{result=\"hit\",name=\"rpc\",namespace=\"$namespace\",pod=~\"$pod\"}[1m]))/sum(delta(cache_code_total{name=\"rpc\",namespace=\"$namespace\",pod=~\"$pod\"}[1m])) ", - "hide": false, - "interval": "", - "legendFormat": "code hit rate: {{pod}} ", - "refId": "B" - } - ], - "title": "Cache hit-rate", - "type": "timeseries" - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 24, - "x": 0, - "y": 76 - }, - "hiddenSeries": false, - "id": 136, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "sum by (grpc_service, grpc_method, instance) (rate(grpc_server_started_total{namespace=\"$namespace\",pod=~\"$pod\"}[1m]))", - "interval": "", - "legendFormat": "Calls: {{grpc_service}}.{{grpc_method}}, {{pod}}", - "refId": "A" - }, - { - "expr": "sum by (grpc_service, grpc_method, instance) (rate(grpc_server_handled_total{instance=~\"$instance\",grpc_code!=\"OK\"}[1m])) ", - "interval": "", - "legendFormat": "Errors: {{grpc_service}}.{{grpc_method}}, {{pod}}", - "refId": "B" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "gRPC call, error rates ", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - } - ], - "title": "RPC", - "type": "row" - }, - { - "collapsed": false, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 54 - }, - "id": 75, - "panels": [], - "title": "Network", - "type": "row" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "Bps" - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 12, - "x": 0, - "y": 55 - }, - "id": 96, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.0.6", - "targets": [ - { - "exemplar": true, - "expr": "rate(p2p_ingress{namespace=\"$namespace\",pod=~\"$pod\"}[$rate_interval])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "ingress: {{pod}}", - "refId": "B" - }, - { - "exemplar": true, - "expr": "rate(p2p_egress{namespace=\"$namespace\",pod=~\"$pod\"}[$rate_interval])", - "format": "time_series", - "hide": true, - "interval": "", - "intervalFactor": 1, - "legendFormat": "egress: {{pod}}", - "refId": "C" - } - ], - "title": "Traffic", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 12, - "x": 12, - "y": 55 - }, - "id": 77, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.0.6", - "targets": [ - { - "expr": "p2p_peers{namespace=\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "peers: {{pod}}", - "refId": "A" - }, - { - "expr": "rate(p2p_dials{namespace=\"$namespace\",pod=~\"$pod\"}[1m])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "dials: {{pod}}", - "refId": "B" - }, - { - "expr": "rate(p2p_serves{namespace=\"$namespace\",pod=~\"$pod\"}[1m])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "serves: {{pod}}", - "refId": "C" - } - ], - "title": "Peers", - "type": "timeseries" - }, - { - "collapsed": true, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 61 - }, - "id": 4, - "panels": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "mappings": [ - { - "options": { - "match": "null", - "result": { - "text": "N/A" - } - }, - "type": "special" - } - ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green" - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 4, - "x": 0, - "y": 62 - }, - "id": 108, - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "value", - "fieldOptions": { - "calcs": [ - "lastNotNull" - ] - }, - "graphMode": "none", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "stage_headers{namespace=\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "Header: {{pod}}", - "refId": "A" - } - ], - "title": "Latest header", - "type": "stat" - }, - { - "fieldConfig": { - "defaults": { - "mappings": [ - { - "options": { - "match": "null", - "result": { - "text": "N/A" - } - }, - "type": "special" - } - ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green" - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 4, - "x": 4, - "y": 62 - }, - "id": 111, - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "value", - "fieldOptions": { - "calcs": [ - "lastNotNull" - ] - }, - "graphMode": "none", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "exemplar": true, - "expr": "chain_head_receipt{namespace=\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{pod}}", - "refId": "A" - } - ], - "title": "Latest receipt", - "type": "stat" - }, - { - "fieldConfig": { - "defaults": { - "mappings": [ - { - "options": { - "match": "null", - "result": { - "text": "N/A" - } - }, - "type": "special" - } - ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green" - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 4, - "x": 8, - "y": 62 - }, - "id": 109, - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "value", - "fieldOptions": { - "calcs": [ - "lastNotNull" - ] - }, - "graphMode": "none", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "exemplar": true, - "expr": "stage_headers{namespace=\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "blocks:{{pod}}", - "refId": "A" - } - ], - "title": "Latest block", - "type": "stat" - }, - { - "fieldConfig": { - "defaults": { - "mappings": [ - { - "options": { - "match": "null", - "result": { - "text": "N/A" - } - }, - "type": "special" - } - ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green" - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 4, - "x": 12, - "y": 62 - }, - "id": 113, - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "value", - "fieldOptions": { - "calcs": [ - "lastNotNull" - ] - }, - "graphMode": "none", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "txpool_pending{namespace=\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{pod}}", - "refId": "A" - } - ], - "title": "Executable transactions", - "type": "stat" - }, - { - "fieldConfig": { - "defaults": { - "mappings": [ - { - "options": { - "match": "null", - "result": { - "text": "N/A" - } - }, - "type": "special" - } - ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green" - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 4, - "x": 16, - "y": 62 - }, - "id": 114, - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "value", - "fieldOptions": { - "calcs": [ - "lastNotNull" - ] - }, - "graphMode": "none", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "txpool_queued{namespace=\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{pod}}", - "refId": "A" - } - ], - "title": "Gapped transactions", - "type": "stat" - }, - { - "fieldConfig": { - "defaults": { - "mappings": [ - { - "options": { - "match": "null", - "result": { - "text": "N/A" - } - }, - "type": "special" - } - ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green" - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 4, - "x": 20, - "y": 62 - }, - "id": 115, - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "value", - "fieldOptions": { - "calcs": [ - "lastNotNull" - ] - }, - "graphMode": "none", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "txpool_local{namespace=\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{pod}}", - "refId": "A" - } - ], - "title": "Local transactions", - "type": "stat" - }, - { - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green" - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 12, - "x": 0, - "y": 65 - }, - "id": 110, - "links": [], - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "single", - "sort": "none" - } - }, - "pluginVersion": "8.0.6", - "targets": [ - { - "expr": "chain_head_header{namespace=\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "header: {{pod}}", - "refId": "A" - }, - { - "expr": "chain_head_receipt{namespace=\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "receipt: {{pod}}", - "refId": "B" - }, - { - "expr": "chain_head_block{namespace=\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "block: {{pod}}", - "refId": "C" - } - ], - "title": "Chain head", - "type": "timeseries" - }, - { - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green" - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 12, - "x": 12, - "y": 65 - }, - "id": 116, - "links": [], - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "single", - "sort": "none" - } - }, - "pluginVersion": "8.0.6", - "targets": [ - { - "expr": "txpool_pending{namespace=\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "executable: {{pod}}", - "refId": "A" - }, - { - "expr": "txpool_queued{namespace=\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "gapped: {{pod}}", - "refId": "B" - }, - { - "expr": "txpool_local{namespace=\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "local: {{pod}}", - "refId": "C" - } - ], - "title": "Transaction pool", - "type": "timeseries" - }, - { - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green" - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 7, - "w": 24, - "x": 0, - "y": 71 - }, - "id": 117, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "right" - }, - "tooltip": { - "mode": "single", - "sort": "none" - } - }, - "pluginVersion": "8.0.6", - "targets": [ - { - "expr": "rate(txpool_valid{namespace=\"$namespace\",pod=~\"$pod\"}[1m])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "valid: {{pod}}", - "refId": "K" - }, - { - "expr": "rate(txpool_invalid{namespace=\"$namespace\",pod=~\"$pod\"}[1m])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "invalid: {{pod}}", - "refId": "A" - }, - { - "expr": "rate(txpool_underpriced{instance=\"$instance\"}[1m])", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "underpriced", - "refId": "B" - }, - { - "expr": "rate(txpool_pending_discard{instance=\"$instance\"}[1m])", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "executable discard", - "refId": "C" - }, - { - "expr": "rate(txpool_pending_replace{instance=\"$instance\"}[1m])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "executable replace", - "refId": "D" - }, - { - "expr": "rate(txpool_pending_ratelimit{instance=\"$instance\"}[1m])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "executable ratelimit", - "refId": "E" - }, - { - "expr": "rate(txpool_pending_nofunds{instance=\"$instance\"}[1m])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "executable nofunds", - "refId": "F" - }, - { - "expr": "rate(txpool_queued_discard{instance=\"$instance\"}[1m])", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "gapped discard", - "refId": "G" - }, - { - "expr": "rate(txpool_queued_replace{instance=\"$instance\"}[1m])", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "gapped replace", - "refId": "H" - }, - { - "expr": "rate(txpool_queued_ratelimit{instance=\"$instance\"}[1m])", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "gapped ratelimit", - "refId": "I" - }, - { - "expr": "rate(txpool_queued_nofunds{instance=\"$instance\"}[1m])", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "gapped nofunds", - "refId": "J" - } - ], - "title": "Transaction propagation", - "type": "timeseries" - } - ], - "title": "Blockchain", - "type": "row" - } - ], - "refresh": "1m", - "schemaVersion": 35, - "style": "dark", - "tags": [ - "eth1.0", - "ethereum", - "erigon" - ], - "templating": { - "list": [ - { - "current": { - "selected": false, - "text": "default", - "value": "default" - }, - "hide": 0, - "includeAll": false, - "multi": false, - "name": "datasource", - "options": [], - "query": "prometheus", - "queryValue": "", - "refresh": 1, - "regex": "", - "skipUrlSync": false, - "type": "datasource" - }, - { - "current": { - "selected": false, - "text": "goerli", - "value": "goerli" - }, - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "definition": "label_values(sync{}, namespace)", - "hide": 0, - "includeAll": false, - "multi": false, - "name": "namespace", - "options": [], - "query": { - "query": "label_values(sync{}, namespace)", - "refId": "StandardVariableQuery" - }, - "refresh": 1, - "regex": "", - "skipUrlSync": false, - "sort": 0, - "type": "query" - }, - { - "current": { - "selected": false, - "text": "All", - "value": "$__all" - }, - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "definition": "label_values(sync{}, pod)", - "hide": 0, - "includeAll": true, - "label": "pod", - "multi": true, - "name": "pod", - "options": [], - "query": { - "query": "label_values(sync{}, pod)", - "refId": "StandardVariableQuery" - }, - "refresh": 1, - "regex": "", - "skipUrlSync": false, - "sort": 0, - "tagValuesQuery": "", - "tagsQuery": "", - "type": "query", - "useTags": false - }, - { - "current": { - "selected": true, - "text": "0.5", - "value": "0.5" - }, - "hide": 0, - "includeAll": false, - "multi": false, - "name": "quantile", - "options": [ - { - "selected": true, - "text": "0.5", - "value": "0.5" - }, - { - "selected": false, - "text": "0.9", - "value": "0.9" - }, - { - "selected": false, - "text": "0.97", - "value": "0.97" - }, - { - "selected": false, - "text": "0.99", - "value": "0.99" - }, - { - "selected": false, - "text": "1", - "value": "1" - } - ], - "query": "0.5, 0.9, 0.97, 0.99, 1", - "queryValue": "", - "skipUrlSync": false, - "type": "custom" - }, - { - "auto": false, - "auto_count": 30, - "auto_min": "10s", - "current": { - "selected": false, - "text": "1m", - "value": "1m" - }, - "hide": 0, - "label": "Rate Interval", - "name": "rate_interval", - "options": [ - { - "selected": true, - "text": "1m", - "value": "1m" - }, - { - "selected": false, - "text": "10m", - "value": "10m" - }, - { - "selected": false, - "text": "30m", - "value": "30m" - }, - { - "selected": false, - "text": "1h", - "value": "1h" - }, - { - "selected": false, - "text": "3h", - "value": "3h" - }, - { - "selected": false, - "text": "6h", - "value": "6h" - }, - { - "selected": false, - "text": "12h", - "value": "12h" - }, - { - "selected": false, - "text": "1d", - "value": "1d" - }, - { - "selected": false, - "text": "7d", - "value": "7d" - }, - { - "selected": false, - "text": "14d", - "value": "14d" - }, - { - "selected": false, - "text": "30d", - "value": "30d" - } - ], - "query": "1m,10m,30m,1h,3h,6h,12h,1d,7d,14d,30d", - "queryValue": "", - "refresh": 2, - "skipUrlSync": false, - "type": "interval" - } - ] - }, - "time": { - "from": "now-1h", - "to": "now" - }, - "timepicker": { - "refresh_intervals": [ - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ], - "time_options": [ - "5m", - "15m", - "1h", - "6h", - "12h", - "24h", - "2d", - "7d", - "30d" - ] - }, - "timezone": "", - "title": "Erigon", - "uid": "XV2Q27jXyTf4zaReHMeNky5", - "version": 3, - "weekStart": "" -} \ No newline at end of file diff --git a/charts/grafana-stakewise-dashboards/dashboards/geth.json b/charts/grafana-stakewise-dashboards/dashboards/geth.json deleted file mode 100644 index daa2dd179..000000000 --- a/charts/grafana-stakewise-dashboards/dashboards/geth.json +++ /dev/null @@ -1,1496 +0,0 @@ -{ - "annotations": { - "list": [ - { - "builtIn": 1, - "datasource": "-- Grafana --", - "enable": true, - "hide": true, - "iconColor": "rgba(0, 211, 255, 1)", - "name": "Annotations & Alerts", - "target": { - "limit": 100, - "matchAny": false, - "tags": [], - "type": "dashboard" - }, - "type": "dashboard" - } - ] - }, - "editable": true, - "fiscalYearStartMonth": 0, - "graphTooltip": 0, - "id": 157, - "iteration": 1650530164929, - "links": [], - "liveNow": false, - "panels": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [ - { - "options": { - "0": { - "color": "text", - "index": 0, - "text": "syncing" - } - }, - "type": "value" - } - ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "blue", - "value": null - } - ] - }, - "unit": "locale" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 4, - "x": 0, - "y": 0 - }, - "id": 4, - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "background", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": false, - "expr": "chain_head_block{namespace=\"$namespace\",pod=\"$pod\"}", - "format": "time_series", - "instant": true, - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{pod}}", - "refId": "A" - } - ], - "title": "Current Block", - "transparent": true, - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "bars", - "fillOpacity": 100, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 0, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "locale" - }, - "overrides": [ - { - "matcher": { - "id": "byName", - "options": "Transactions" - }, - "properties": [ - { - "id": "color", - "value": { - "fixedColor": "#e0752d", - "mode": "fixed" - } - } - ] - } - ] - }, - "gridPos": { - "h": 6, - "w": 7, - "x": 4, - "y": 0 - }, - "id": 8, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "max", - "min" - ], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "single", - "sort": "none" - } - }, - "pluginVersion": "8.3.6", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": false, - "expr": "rate(txpool_known{namespace=\"$namespace\",pod=\"$pod\"}[1m])", - "format": "time_series", - "instant": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{pod}}", - "refId": "A" - } - ], - "title": "Transaction Rate (tx/s)", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "bars", - "fillOpacity": 100, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "locale" - }, - "overrides": [ - { - "matcher": { - "id": "byName", - "options": "gwei" - }, - "properties": [ - { - "id": "color", - "value": { - "fixedColor": "#0a50a1", - "mode": "fixed" - } - } - ] - }, - { - "matcher": { - "id": "byName", - "options": "transactions" - }, - "properties": [ - { - "id": "color", - "value": { - "fixedColor": "#cca300", - "mode": "fixed" - } - } - ] - } - ] - }, - "gridPos": { - "h": 6, - "w": 7, - "x": 11, - "y": 0 - }, - "id": 10, - "links": [], - "options": { - "legend": { - "calcs": [ - "sum" - ], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "single", - "sort": "none" - } - }, - "pluginVersion": "8.3.6", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "txpool_pending{namespace=\"$namespace\",pod=\"$pod\"}", - "format": "time_series", - "instant": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{pod}}", - "refId": "A" - } - ], - "title": "Pending Transactions", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "super-light-yellow", - "value": null - } - ] - }, - "unit": "bytes" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 3, - "x": 18, - "y": 0 - }, - "id": 12, - "options": { - "colorMode": "none", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${DS_STAKEWISE-PROD-VALIDATORS}" - }, - "exemplar": true, - "expr": "system_memory_used", - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Geth Memory Usage", - "transparent": true, - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "super-light-yellow", - "value": null - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 3, - "x": 21, - "y": 0 - }, - "id": 22, - "options": { - "colorMode": "none", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${DS_STAKEWISE-PROD-VALIDATORS}" - }, - "exemplar": true, - "expr": "system_cpu_threads", - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Geth CPU Threads", - "transparent": true, - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "decimals": 2, - "mappings": [ - { - "options": { - "match": "null", - "result": { - "text": "N/A" - } - }, - "type": "special" - } - ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "text", - "value": null - } - ] - }, - "unit": "locale" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 4, - "x": 0, - "y": 3 - }, - "id": 6, - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "value", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": false, - "expr": "chain_head_receipt{namespace=\"$namespace\",pod=\"$pod\"}", - "format": "time_series", - "instant": true, - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{pod}}", - "refId": "A" - } - ], - "title": "Last Received Block", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "super-light-yellow", - "value": null - } - ] - }, - "unit": "bytes" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 3, - "x": 18, - "y": 3 - }, - "id": 16, - "options": { - "colorMode": "none", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": false, - "expr": "node_memory_MemTotal_bytes", - "instant": true, - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Total System Memory", - "transparent": true, - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 0, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "auto", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "super-light-yellow", - "value": null - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 3, - "x": 21, - "y": 3 - }, - "id": 20, - "options": { - "legend": { - "calcs": [], - "displayMode": "hidden", - "placement": "bottom" - }, - "tooltip": { - "mode": "single", - "sort": "none" - } - }, - "pluginVersion": "8.3.6", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${DS_STAKEWISE-PROD-VALIDATORS}" - }, - "exemplar": true, - "expr": "system_cpu_procload", - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Geth Processor Loading", - "transparent": true, - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 4, - "x": 0, - "y": 6 - }, - "id": 24, - "options": { - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "showThresholdLabels": false, - "showThresholdMarkers": true - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "p2p_peers{namespace=\"$namespace\",pod=\"$pod\"}", - "instant": false, - "interval": "", - "legendFormat": "{{pod}}", - "refId": "A" - } - ], - "title": "Peer Count", - "type": "gauge" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "super-light-yellow", - "value": null - } - ] - }, - "unit": "bytes" - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 4, - "x": 4, - "y": 6 - }, - "id": 28, - "options": { - "colorMode": "background", - "graphMode": "none", - "justifyMode": "center", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "rate(p2p_egress{namespace=\"$namespace\",pod=\"$pod\"}[5m])", - "interval": "", - "legendFormat": "Out: {{pod}}", - "refId": "A" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "rate(p2p_ingress{namespace=\"$namespace\",pod=\"$pod\"}[5m])", - "hide": false, - "interval": "", - "legendFormat": "In: {{pod}}", - "refId": "B" - } - ], - "title": "Network Traffic (bytes/s)", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "super-light-purple", - "value": null - } - ] - }, - "unit": "bytes" - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 4, - "x": 8, - "y": 6 - }, - "id": 30, - "options": { - "colorMode": "background", - "graphMode": "none", - "justifyMode": "center", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "rate(system_disk_readbytes{namespace=\"$namespace\",pod=\"$pod\"}[5m])", - "interval": "", - "legendFormat": "Read: {{pod}}", - "refId": "A" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "rate(system_disk_writebytes{namespace=\"$namespace\",pod=\"$pod\"}[5m])", - "hide": false, - "interval": "", - "legendFormat": "Write: {{pod}}", - "refId": "B" - } - ], - "title": "Disk Activity (bytes/s)", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "fixedColor": "super-light-purple", - "mode": "fixed" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 100, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineStyle": { - "fill": "solid" - }, - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "bytes" - }, - "overrides": [ - { - "matcher": { - "id": "byName", - "options": "Difficulty" - }, - "properties": [ - { - "id": "color", - "value": { - "fixedColor": "rgb(199, 70, 70)", - "mode": "fixed" - } - } - ] - } - ] - }, - "gridPos": { - "h": 6, - "w": 6, - "x": 12, - "y": 6 - }, - "id": 42, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom" - }, - "tooltip": { - "mode": "single", - "sort": "none" - } - }, - "pluginVersion": "8.3.6", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": false, - "expr": "eth_db_chaindata_disk_size{namespace=\"$namespace\",pod=\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{pod}}", - "refId": "A" - } - ], - "title": "Chain Data Disk Size", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "fixedColor": "text", - "mode": "fixed" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 6, - "x": 18, - "y": 6 - }, - "id": 32, - "options": { - "colorMode": "value", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "rpc_requests{namespace=\"$namespace\",pod=\"$pod\"}", - "interval": "", - "legendFormat": "{{pod}}", - "refId": "A" - } - ], - "title": "RPC Requests", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "fixedColor": "light-purple", - "mode": "fixed" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 0, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineStyle": { - "fill": "solid" - }, - "lineWidth": 1, - "pointSize": 3, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "always", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "bytes" - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 8, - "x": 0, - "y": 12 - }, - "id": 40, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom" - }, - "tooltip": { - "mode": "single", - "sort": "none" - } - }, - "pluginVersion": "8.3.6", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "rate(system_disk_writebytes{namespace=\"$namespace\",pod=\"$pod\"}[1m])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{pod}}", - "refId": "A" - } - ], - "title": "Disk Write Activity (bytes/s)", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "fixedColor": "light-purple", - "mode": "fixed" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 0, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineStyle": { - "fill": "solid" - }, - "lineWidth": 1, - "pointSize": 3, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "always", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "bytes" - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 8, - "x": 8, - "y": 12 - }, - "id": 38, - "links": [], - "options": { - "legend": { - "calcs": [ - "mean", - "lastNotNull", - "max", - "min" - ], - "displayMode": "table", - "placement": "bottom" - }, - "tooltip": { - "mode": "single", - "sort": "none" - } - }, - "pluginVersion": "8.3.6", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "rate(system_disk_readbytes{namespace=\"$namespace\",pod=\"$pod\"}[1m])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{pod}}", - "refId": "A" - } - ], - "title": "Disk Read Activity (bytes/s)", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "fixedColor": "yellow", - "mode": "fixed" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 15, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "stepAfter", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "bytes" - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 8, - "x": 16, - "y": 12 - }, - "id": 36, - "links": [], - "options": { - "legend": { - "calcs": [ - "last", - "min", - "max" - ], - "displayMode": "table", - "placement": "bottom" - }, - "tooltip": { - "mode": "single", - "sort": "none" - } - }, - "pluginVersion": "8.3.6", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "rate(p2p_egress{namespace=\"$namespace\",pod=\"$pod\"}[5m])", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{pod}}", - "refId": "A" - } - ], - "title": "Outgoing Network (bytes/s)", - "type": "timeseries" - } - ], - "refresh": "1m", - "schemaVersion": 35, - "style": "dark", - "tags": [ - "eth1.0", - "ethereum", - "geth" - ], - "templating": { - "list": [ - { - "current": { - "selected": false, - "text": "default", - "value": "default" - }, - "hide": 0, - "includeAll": false, - "multi": false, - "name": "datasource", - "options": [], - "query": "prometheus", - "queryValue": "", - "refresh": 1, - "regex": "", - "skipUrlSync": false, - "type": "datasource" - }, - { - "current": { - "selected": false, - "text": "goerli", - "value": "goerli" - }, - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "definition": "label_values(vflux_server_active_count{}, namespace)", - "hide": 0, - "includeAll": false, - "multi": false, - "name": "namespace", - "options": [], - "query": { - "query": "label_values(vflux_server_active_count{}, namespace)", - "refId": "StandardVariableQuery" - }, - "refresh": 1, - "regex": "", - "skipUrlSync": false, - "sort": 0, - "type": "query" - }, - { - "current": { - "selected": true, - "text": "geth-0", - "value": "geth-0" - }, - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "definition": "label_values(vflux_server_active_count{}, pod)", - "hide": 0, - "includeAll": false, - "multi": false, - "name": "pod", - "options": [], - "query": { - "query": "label_values(vflux_server_active_count{}, pod)", - "refId": "StandardVariableQuery" - }, - "refresh": 1, - "regex": "", - "skipUrlSync": false, - "sort": 0, - "type": "query" - } - ] - }, - "time": { - "from": "now-1h", - "to": "now" - }, - "timepicker": {}, - "timezone": "", - "title": "Geth", - "uid": "C9EVmtFMb3pKJUqdasdvMwVDN", - "version": 2, - "weekStart": "" -} \ No newline at end of file diff --git a/charts/grafana-stakewise-dashboards/dashboards/lighthouse.json b/charts/grafana-stakewise-dashboards/dashboards/lighthouse.json deleted file mode 100644 index 433e1491d..000000000 --- a/charts/grafana-stakewise-dashboards/dashboards/lighthouse.json +++ /dev/null @@ -1,5612 +0,0 @@ -{ - "annotations": { - "list": [ - { - "builtIn": 1, - "datasource": { - "type": "datasource", - "uid": "grafana" - }, - "enable": true, - "hide": true, - "iconColor": "rgba(0, 211, 255, 1)", - "name": "Annotations & Alerts", - "target": { - "limit": 100, - "matchAny": false, - "tags": [], - "type": "dashboard" - }, - "type": "dashboard" - } - ] - }, - "editable": true, - "fiscalYearStartMonth": 0, - "graphTooltip": 0, - "id": 581, - "iteration": 1661180817974, - "links": [], - "liveNow": false, - "panels": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [ - { - "options": { - "match": "null", - "result": { - "text": "N/A" - } - }, - "type": "special" - } - ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 3, - "x": 0, - "y": 0 - }, - "id": 2, - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "none", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.0.1", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "avg(beacon_head_state_total_validators_total{namespace=~\"$namespace\",pod=~\"$pod\"})", - "format": "time_series", - "intervalFactor": 1, - "refId": "A" - } - ], - "title": "Avg. Validator Count", - "transparent": true, - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [ - { - "options": { - "match": "null", - "result": { - "text": "N/A" - } - }, - "type": "special" - } - ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 3, - "x": 3, - "y": 0 - }, - "id": 3, - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "none", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.0.1", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "avg(beacon_head_state_active_validators_total{namespace=~\"$namespace\",pod=~\"$pod\"})", - "format": "time_series", - "intervalFactor": 1, - "refId": "A" - } - ], - "title": "Avg. Active Validators", - "transparent": true, - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [ - { - "options": { - "match": "null", - "result": { - "text": "N/A" - } - }, - "type": "special" - } - ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 3, - "x": 6, - "y": 0 - }, - "id": 4, - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "none", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.0.1", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "avg(beacon_head_state_withdrawn_validators_total{namespace=~\"$namespace\",pod=~\"$pod\"})", - "format": "time_series", - "intervalFactor": 1, - "refId": "A" - } - ], - "title": "Avg. Withdrawable Validators", - "transparent": true, - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [ - { - "options": { - "match": "null", - "result": { - "text": "N/A" - } - }, - "type": "special" - } - ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 3, - "x": 9, - "y": 0 - }, - "id": 5, - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "none", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.0.1", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "avg(beacon_head_state_slashed_validators_total{namespace=~\"$namespace\",pod=~\"$pod\"})", - "format": "time_series", - "intervalFactor": 1, - "refId": "A" - } - ], - "title": "Avg. Slashed Validators", - "transparent": true, - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [ - { - "options": { - "match": "null", - "result": { - "text": "N/A" - } - }, - "type": "special" - } - ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "locale" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 3, - "x": 12, - "y": 0 - }, - "id": 6, - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "none", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.0.1", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "max(slotclock_present_slot{namespace=~\"$namespace\",pod=~\"$pod\"})", - "format": "time_series", - "intervalFactor": 1, - "refId": "A" - } - ], - "title": "Avg. Current Slot", - "transparent": true, - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [ - { - "options": { - "match": "null", - "result": { - "text": "N/A" - } - }, - "type": "special" - } - ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "locale" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 3, - "x": 15, - "y": 0 - }, - "id": 7, - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "none", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "9.0.1", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "max(slotclock_present_epoch{namespace=~\"$namespace\",pod=~\"$pod\"})", - "format": "time_series", - "intervalFactor": 1, - "refId": "A" - } - ], - "title": "Avg. Current Epoch", - "transparent": true, - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "rgb(199, 208, 217)", - "value": null - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 6, - "x": 18, - "y": 0 - }, - "id": 8, - "options": { - "colorMode": "value", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "name" - }, - "pluginVersion": "9.0.1", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "lighthouse_info{namespace=~\"$namespace\",pod=~\"$pod\"}", - "interval": "", - "legendFormat": "", - "queryType": "randomWalk", - "refId": "A" - } - ], - "title": "Build", - "transformations": [ - { - "id": "labelsToFields", - "options": { - "valueLabel": "version" - } - }, - { - "id": "merge", - "options": {} - } - ], - "transparent": true, - "type": "stat" - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 7, - "w": 8, - "x": 0, - "y": 3 - }, - "hiddenSeries": false, - "id": 9, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "system_loadavg_1{namespace=~\"$namespace\",pod=~\"$pod\"}", - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Average Load (loadavg 1m)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "percentunit", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 7, - "w": 8, - "x": 8, - "y": 3 - }, - "hiddenSeries": false, - "id": 10, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "system_virt_mem_free_bytes{namespace=~\"$namespace\",pod=~\"$pod\"}", - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Available Memory", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "decbytes", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 7, - "w": 8, - "x": 16, - "y": 3 - }, - "hiddenSeries": false, - "id": 11, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "process_resident_memory_bytes{namespace=~\"$namespace\",pod=~\"$pod\"}", - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Lighthouse Resident Memory Usage", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "decbytes", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "gridPos": { - "h": 2, - "w": 24, - "x": 0, - "y": 10 - }, - "id": 12, - "links": [], - "options": { - "content": "\n### Consensus\n\nOverview of consensus between nodes.\n\n\n", - "mode": "markdown" - }, - "pluginVersion": "9.0.1", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "refId": "A" - } - ], - "transparent": true, - "type": "text" - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 8, - "x": 0, - "y": 12 - }, - "hiddenSeries": false, - "id": 13, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "slotclock_present_slot{namespace=~\"$namespace\",pod=~\"$pod\"} - beacon_head_state_slot{namespace=~\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "intervalFactor": 1, - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Slots since Best Block", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "decimals": 0, - "format": "short", - "label": "Slots", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 8, - "x": 8, - "y": 12 - }, - "hiddenSeries": false, - "id": 14, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "slotclock_present_epoch{namespace=~\"$namespace\",pod=~\"$pod\"} - beacon_head_state_current_justified_epoch{namespace=~\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Epoch Boundaries since Justification (Min)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "decimals": 0, - "format": "short", - "label": "Epochs", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 8, - "x": 16, - "y": 12 - }, - "hiddenSeries": false, - "id": 15, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "slotclock_present_epoch{namespace=~\"$namespace\",pod=~\"$pod\"} - beacon_head_state_finalized_epoch{namespace=~\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "intervalFactor": 1, - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Epoch Boundaries since Finalization (Min)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "decimals": 0, - "format": "short", - "label": "Epochs", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 5, - "w": 13, - "x": 0, - "y": 18 - }, - "hiddenSeries": false, - "id": 16, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "beacon_participation_prev_epoch_attester{namespace=~\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Previous Epoch Attesting Balance", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "decimals": 0, - "format": "percentunit", - "label": "Percentage of Balance", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 5, - "w": 6, - "x": 13, - "y": 18 - }, - "hiddenSeries": false, - "id": 17, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "beacon_participation_prev_epoch_target_attester{namespace=~\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Previous Epoch Target Attesting Balance", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "decimals": 0, - "format": "percentunit", - "label": "Percentage of Balance", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 5, - "w": 5, - "x": 19, - "y": 18 - }, - "hiddenSeries": false, - "id": 18, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "beacon_participation_prev_epoch_head_attester{namespace=~\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Previous Epoch Head Attesting Balance", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "decimals": 0, - "format": "percentunit", - "label": "Percentage of Balance", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "The number of attesters for which we have seen an attestation. That attestation is not necessarily included in the chain.", - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 5, - "w": 12, - "x": 0, - "y": 23 - }, - "hiddenSeries": false, - "id": 19, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "beacon_attn_observation_epoch_attesters{namespace=~\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Previous Epoch Observed Attesters", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "decimals": 0, - "format": "none", - "label": "# of Validators", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "The number of aggregators for which we have seen an attestation. That attestation is not necessarily included in the chain.", - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 5, - "w": 12, - "x": 12, - "y": 23 - }, - "hiddenSeries": false, - "id": 20, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "beacon_attn_observation_epoch_aggregators{namespace=~\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Previous Epoch Observed Aggregators", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "decimals": 0, - "format": "none", - "label": "# of Validators", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 0, - "fillGradient": 0, - "gridPos": { - "h": 4, - "w": 4, - "x": 0, - "y": 28 - }, - "hiddenSeries": false, - "id": 21, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "beacon_head_state_validator_balances_total{namespace=~\"$namespace\",pod=~\"$pod\"} / 1000000000", - "format": "time_series", - "intervalFactor": 1, - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Validator Balances", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "none", - "label": "Total Validator ETH", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 0, - "fillGradient": 0, - "gridPos": { - "h": 4, - "w": 5, - "x": 4, - "y": 28 - }, - "hiddenSeries": false, - "id": 22, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "beacon_head_state_active_validators_total{namespace=~\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "intervalFactor": 1, - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Active Validators", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "none", - "label": "Total Validator ETH", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 0, - "fillGradient": 0, - "gridPos": { - "h": 4, - "w": 5, - "x": 9, - "y": 28 - }, - "hiddenSeries": false, - "id": 23, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "beacon_head_state_total_validators_total{namespace=~\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "intervalFactor": 1, - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Total Validators", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "none", - "label": "Total Validator ETH", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 0, - "fillGradient": 0, - "gridPos": { - "h": 4, - "w": 5, - "x": 14, - "y": 28 - }, - "hiddenSeries": false, - "id": 24, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": true, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "beacon_head_state_finalized_root{namespace=~\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "intervalFactor": 1, - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Finalized Root (hash shown as int)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "sci", - "label": "int(hash)", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 0, - "fillGradient": 0, - "gridPos": { - "h": 4, - "w": 5, - "x": 19, - "y": 28 - }, - "hiddenSeries": false, - "id": 25, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "beacon_fork_choice_reorg_total{namespace=~\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Total Fork Choice Re-Orgs", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "decimals": 0, - "format": "none", - "label": "Re-Orgs", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "gridPos": { - "h": 2, - "w": 24, - "x": 0, - "y": 32 - }, - "id": 26, - "links": [], - "options": { - "content": "\n### Networking\n\n\n\n", - "mode": "markdown" - }, - "pluginVersion": "9.0.1", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "refId": "A" - } - ], - "transparent": true, - "type": "text" - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 12, - "x": 0, - "y": 34 - }, - "hiddenSeries": false, - "id": 27, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "libp2p_peers{namespace=~\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "intervalFactor": 1, - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "libp2p Connected Peers", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "decimals": 0, - "format": "short", - "label": "Peers", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "Peers via client implementations", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "max": 100, - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 12, - "x": 12, - "y": 34 - }, - "id": 28, - "options": { - "displayMode": "gradient", - "minVizHeight": 10, - "minVizWidth": 0, - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "showUnfilled": true, - "text": {} - }, - "pluginVersion": "9.0.1", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "libp2p_peers_per_client{namespace=~\"$namespace\",pod=~\"$pod\"}", - "instant": true, - "interval": "", - "legendFormat": "{{Client}}", - "refId": "A" - } - ], - "title": "Connected Clients", - "type": "bargauge" - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "", - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 7, - "w": 10, - "x": 0, - "y": 40 - }, - "hiddenSeries": false, - "id": 29, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "discovery_requests{namespace=~\"$namespace\",pod=~\"$pod\"}", - "interval": "", - "legendFormat": "Discovery Requests Per Second", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Unsolicited Discovery Requests/s", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "", - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 7, - "w": 10, - "x": 10, - "y": 40 - }, - "hiddenSeries": false, - "id": 30, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "discovery_sessions{namespace=~\"$namespace\",pod=~\"$pod\"}", - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Active Discv5 Sessions", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "max": 100, - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 7, - "w": 4, - "x": 20, - "y": 40 - }, - "id": 31, - "options": { - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "showThresholdLabels": false, - "showThresholdMarkers": true, - "text": {} - }, - "pluginVersion": "9.0.1", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "discovery_queue_size{namespace=~\"$namespace\",pod=~\"$pod\"}", - "interval": "", - "legendFormat": "Queued Discoveries", - "refId": "A" - } - ], - "title": "Queued Discovery Queries", - "type": "gauge" - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 8, - "w": 8, - "x": 0, - "y": 47 - }, - "hiddenSeries": false, - "id": 32, - "interval": "", - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "rate(libp2p_total_bandwidth{namespace=~\"$namespace\",pod=~\"$pod\"}[1m])", - "legendFormat": "bytes/s", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Total Libp2p Bandwidth", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 8, - "w": 8, - "x": 8, - "y": 47 - }, - "hiddenSeries": false, - "id": 33, - "interval": "", - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "rate(libp2p_inbound_bytes{namespace=~\"$namespace\",pod=~\"$pod\"}[1m])", - "legendFormat": "bytes/s", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Libp2p Inbound Bandwidth", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 8, - "w": 8, - "x": 16, - "y": 47 - }, - "hiddenSeries": false, - "id": 34, - "interval": "", - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "rate(libp2p_outbound_bytes{namespace=~\"$namespace\",pod=~\"$pod\"}[1m])", - "legendFormat": "bytes/s", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Libp2p Outbound Bandwidth", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "gridPos": { - "h": 2, - "w": 24, - "x": 0, - "y": 55 - }, - "id": 35, - "options": { - "content": "### Gossipsub Metrics", - "mode": "markdown" - }, - "pluginVersion": "9.0.1", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "refId": "A" - } - ], - "transparent": true, - "type": "text" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "max": 100, - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 57 - }, - "id": 36, - "options": { - "displayMode": "gradient", - "minVizHeight": 10, - "minVizWidth": 0, - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "showUnfilled": true, - "text": {} - }, - "pluginVersion": "9.0.1", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "gossipsub_mesh_peers_per_main_topic{namespace=~\"$namespace\",pod=~\"$pod\"}", - "instant": true, - "interval": "", - "legendFormat": "{{topic_hash}}", - "refId": "A" - } - ], - "title": "Mesh peers per topic", - "type": "bargauge" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "max": 100, - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 57 - }, - "id": 37, - "options": { - "displayMode": "gradient", - "minVizHeight": 10, - "minVizWidth": 0, - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "showUnfilled": true, - "text": {} - }, - "pluginVersion": "9.0.1", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "gossipsub_avg_peer_score_per_topic{namespace=~\"$namespace\",pod=~\"$pod\"}", - "interval": "", - "legendFormat": "{{topic_hash}}", - "refId": "A" - } - ], - "title": "Average Peer Score per Topic", - "type": "bargauge" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "max": 100, - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 7, - "w": 24, - "x": 0, - "y": 65 - }, - "id": 38, - "options": { - "displayMode": "gradient", - "minVizHeight": 10, - "minVizWidth": 0, - "orientation": "vertical", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "showUnfilled": true, - "text": {} - }, - "pluginVersion": "9.0.1", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "gossipsub_mesh_peers_per_subnet_topic{namespace=~\"$namespace\",pod=~\"$pod\"}", - "instant": true, - "interval": "", - "legendFormat": "{{subnet}}", - "refId": "A" - } - ], - "title": "Mesh peers per subnet", - "type": "bargauge" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "gridPos": { - "h": 2, - "w": 24, - "x": 0, - "y": 72 - }, - "id": 39, - "links": [], - "options": { - "content": "\n### Logging\n\n\n\n", - "mode": "markdown" - }, - "pluginVersion": "9.0.1", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "refId": "A" - } - ], - "transparent": true, - "type": "text" - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "", - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 6, - "x": 0, - "y": 74 - }, - "hiddenSeries": false, - "id": 40, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "crit_total{namespace=~\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Crit Logs Total", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "none", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "", - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 6, - "x": 6, - "y": 74 - }, - "hiddenSeries": false, - "id": 41, - "legend": { - "alignAsTable": false, - "avg": false, - "current": false, - "max": false, - "min": false, - "rightSide": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "rate(error_total{namespace=~\"$namespace\",pod=~\"$pod\"}[1m])", - "format": "time_series", - "intervalFactor": 1, - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Error Logs per Minute", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "none", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "", - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 6, - "x": 12, - "y": 74 - }, - "hiddenSeries": false, - "id": 42, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "rate(warn_total{namespace=~\"$namespace\",pod=~\"$pod\"}[1m])", - "format": "time_series", - "intervalFactor": 1, - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Warn Logs per Minute", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "none", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "", - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 6, - "x": 18, - "y": 74 - }, - "hiddenSeries": false, - "id": 43, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "rate(info_total{namespace=~\"$namespace\",pod=~\"$pod\"}[1m])", - "format": "time_series", - "intervalFactor": 1, - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Info Logs per Minute", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "none", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "gridPos": { - "h": 2, - "w": 24, - "x": 0, - "y": 80 - }, - "id": 44, - "links": [], - "options": { - "content": "\n### Core BeaconChain Functions\n\nTiming of core `BeaconChain` functions and syncing.\n\n\n", - "mode": "markdown" - }, - "pluginVersion": "9.0.1", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "refId": "A" - } - ], - "transparent": true, - "type": "text" - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 5, - "w": 8, - "x": 0, - "y": 82 - }, - "hiddenSeries": false, - "id": 45, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "rate(beacon_block_processing_seconds_sum{namespace=~\"$namespace\",pod=~\"$pod\"}[30s])\n/\nrate(beacon_block_processing_seconds_count{namespace=~\"$namespace\",pod=~\"$pod\"}[30s])", - "format": "time_series", - "instant": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Block Processing Times (24s moving avg)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "s", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 5, - "w": 8, - "x": 8, - "y": 82 - }, - "hiddenSeries": false, - "id": 46, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "rate(beacon_fork_choice_seconds_sum{namespace=~\"$namespace\",pod=~\"$pod\"}[1m])\n/\nrate(beacon_fork_choice_seconds_count{namespace=~\"$namespace\",pod=~\"$pod\"}[1m])", - "format": "time_series", - "intervalFactor": 1, - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Find & Update Head Routine (1m avg)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "s", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 5, - "w": 8, - "x": 16, - "y": 82 - }, - "hiddenSeries": false, - "id": 47, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "sync_slots_per_second{namespace=~\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "intervalFactor": 1, - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Syncing Slots per Second", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "none", - "label": "Slots", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "Time taken to calculate the tree hash root of a BeaconState during block processing.", - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 5, - "w": 12, - "x": 0, - "y": 87 - }, - "hiddenSeries": false, - "id": 48, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "rate(beacon_block_processing_block_root_seconds_sum{namespace=~\"$namespace\",pod=~\"$pod\"}[5m])\n/\nrate(beacon_block_processing_block_root_seconds_count{namespace=~\"$namespace\",pod=~\"$pod\"}[5m])", - "format": "time_series", - "intervalFactor": 1, - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Block Tree Hash Times (5m avg)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "s", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "Time taken to calculate the tree hash root of a BeaconState during block processing.", - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 5, - "w": 12, - "x": 12, - "y": 87 - }, - "hiddenSeries": false, - "id": 49, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "rate(beacon_block_processing_state_root_seconds_sum{namespace=~\"$namespace\",pod=~\"$pod\"}[5m])\n/\nrate(beacon_block_processing_state_root_seconds_count{namespace=~\"$namespace\",pod=~\"$pod\"}[5m])", - "format": "time_series", - "intervalFactor": 1, - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "State Tree Hash Times (5m avg)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "s", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "gridPos": { - "h": 2, - "w": 24, - "x": 0, - "y": 92 - }, - "id": 50, - "links": [], - "options": { - "content": "\n### Database\n\nStats about the on-disk database (LevelDB)\n\n\n\n", - "mode": "markdown" - }, - "pluginVersion": "9.0.1", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "refId": "A" - } - ], - "transparent": true, - "type": "text" - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 5, - "w": 12, - "x": 0, - "y": 94 - }, - "hiddenSeries": false, - "id": 51, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "store_disk_db_size{namespace=~\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "intervalFactor": 1, - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "On-Disk Database Size (Hot DB Only)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "decbytes", - "label": "", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 5, - "w": 6, - "x": 12, - "y": 94 - }, - "hiddenSeries": false, - "id": 52, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "increase(store_disk_db_read_bytes_total{namespace=~\"$namespace\",pod=~\"$pod\"}[1m])", - "format": "time_series", - "intervalFactor": 1, - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "DB Throughput (Read) per Minute", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "decbytes", - "label": "Bytes per Minute", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 5, - "w": 6, - "x": 18, - "y": 94 - }, - "hiddenSeries": false, - "id": 53, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "increase(store_disk_db_write_bytes_total{namespace=~\"$namespace\",pod=~\"$pod\"}[1m])", - "format": "time_series", - "intervalFactor": 1, - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "DB Throughput (Write) (1m avg)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "decbytes", - "label": "Bytes per Minute", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "Time taken to calculate the tree hash root of a BeaconState during block processing.", - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 5, - "w": 6, - "x": 0, - "y": 99 - }, - "hiddenSeries": false, - "id": 54, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "expr": "rate(beacon_persist_chain_sum{namespace=~\"$namespace\",pod=~\"$pod\"}[1m])\n/\nrate(beacon_persist_chain_count{namespace=~\"$namespace\",pod=~\"$pod\"}[1m])", - "format": "time_series", - "intervalFactor": 1, - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Persist Beacon Chain Times (1m avg)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "s", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "gridPos": { - "h": 3, - "w": 24, - "x": 0, - "y": 104 - }, - "id": 55, - "links": [], - "options": { - "content": "# Lighthouse Validator Client\n\nMetrics collected from a Lighthouse Validator Node.\n\n\n\n", - "mode": "markdown" - }, - "pluginVersion": "9.0.1", - "transparent": true, - "type": "text" - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 12, - "x": 0, - "y": 107 - }, - "hiddenSeries": false, - "id": 56, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "vc_validators_total_count{namespace=~\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Total Validators", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "decimals": 0, - "format": "short", - "label": "Validators", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 12, - "x": 12, - "y": 107 - }, - "hiddenSeries": false, - "id": 57, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "vc_validators_enabled_count{namespace=~\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Enabled Validators", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "decimals": 0, - "format": "short", - "label": "Validators", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 5, - "w": 6, - "x": 0, - "y": 113 - }, - "hiddenSeries": false, - "id": 58, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "expr": "vc_signed_beacon_blocks_total{namespace=~\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Block Signing Events", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "decimals": 0, - "format": "none", - "label": "BeaconBlock", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 5, - "w": 6, - "x": 6, - "y": 113 - }, - "hiddenSeries": false, - "id": 59, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "expr": "vc_signed_attestations_total{namespace=~\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Attestation Signing Events", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "decimals": 0, - "format": "none", - "label": "Attestation", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 5, - "w": 6, - "x": 12, - "y": 113 - }, - "hiddenSeries": false, - "id": 60, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "expr": "vc_signed_aggregates_total{namespace=~\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Aggregate Signing Events", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "decimals": 0, - "format": "none", - "label": "SignedAggregateAndProof", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 5, - "w": 6, - "x": 18, - "y": 113 - }, - "hiddenSeries": false, - "id": 61, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "expr": "vc_signed_selection_proofs_total{namespace=~\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Selection Proof Signing Events", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "decimals": 0, - "format": "none", - "label": "SelectionProof", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "gridPos": { - "h": 3, - "w": 24, - "x": 0, - "y": 118 - }, - "id": 62, - "links": [], - "options": { - "content": "\n# Lighthouse Validator Monitor\n\nMetrics collected from a Lighthouse Beacon Node.\n\n\n\n", - "mode": "markdown" - }, - "pluginVersion": "9.0.1", - "transparent": true, - "type": "text" - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 7, - "w": 11, - "x": 0, - "y": 121 - }, - "hiddenSeries": false, - "id": 63, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "expr": "validator_monitor_validators_total{namespace=~\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Monitored Validators Total", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:140", - "decimals": 0, - "format": "none", - "label": "Validators", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:141", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 7, - "w": 13, - "x": 11, - "y": 121 - }, - "hiddenSeries": false, - "id": 64, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": false, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "expr": "validator_monitor_balance_gwei{namespace=~\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Validator Balance", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:351", - "decimals": 0, - "format": "none", - "label": "Gwei", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:352", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "links": [], - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 6, - "x": 0, - "y": 128 - }, - "id": 65, - "links": [], - "options": { - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "showThresholdLabels": false, - "showThresholdMarkers": true - }, - "pluginVersion": "9.0.1", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "expr": "sum(validator_monitor_active{namespace=~\"$namespace\",pod=~\"$pod\"})", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "", - "refId": "A" - } - ], - "title": "Active Validators", - "type": "gauge" - }, - { - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "links": [], - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 6, - "x": 6, - "y": 128 - }, - "id": 66, - "links": [], - "options": { - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "showThresholdLabels": false, - "showThresholdMarkers": true - }, - "pluginVersion": "9.0.1", - "targets": [ - { - "expr": "sum(validator_monitor_slashed)", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "", - "refId": "A" - } - ], - "title": "Slashed Validators", - "type": "gauge" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "links": [], - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 6, - "x": 12, - "y": 128 - }, - "id": 67, - "links": [], - "options": { - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "showThresholdLabels": false, - "showThresholdMarkers": true - }, - "pluginVersion": "9.0.1", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "expr": "sum(validator_monitor_exited{namespace=~\"$namespace\",pod=~\"$pod\"})", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "", - "refId": "A" - } - ], - "title": "Exited Validators", - "type": "gauge" - }, - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "fieldConfig": { - "defaults": { - "links": [], - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 6, - "x": 18, - "y": 128 - }, - "id": 68, - "links": [], - "options": { - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "showThresholdLabels": false, - "showThresholdMarkers": true - }, - "pluginVersion": "9.0.1", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "prometheus" - }, - "expr": "sum(validator_monitor_withdrawable{namespace=~\"$namespace\",pod=~\"$pod\"})", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "", - "refId": "A" - } - ], - "title": "Withdrawable Validators", - "type": "gauge" - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": "Prometheus", - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 10, - "w": 7, - "x": 0, - "y": 134 - }, - "hiddenSeries": false, - "id": 69, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "9.0.1", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "validator_monitor_attestation_in_block_delay_slots{namespace=~\"$namespace\",pod=~\"$pod\"}", - "format": "time_series", - "instant": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Attestation Inclusion Delay (Slots)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:622", - "format": "short", - "label": "Slots", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:623", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - } - ], - "refresh": "10s", - "schemaVersion": 36, - "style": "dark", - "tags": [], - "templating": { - "list": [ - { - "current": { - "selected": false, - "text": "default", - "value": "default" - }, - "hide": 0, - "includeAll": false, - "multi": false, - "name": "prometheus", - "options": [], - "query": "prometheus", - "queryValue": "", - "refresh": 1, - "regex": "", - "skipUrlSync": false, - "type": "datasource" - }, - { - "current": { - "selected": true, - "text": [ - "ethereum-consensus" - ], - "value": [ - "ethereum-consensus" - ] - }, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "definition": "label_values(lighthouse_info{}, namespace)", - "hide": 0, - "includeAll": false, - "multi": true, - "name": "namespace", - "options": [], - "query": { - "query": "label_values(lighthouse_info{}, namespace)", - "refId": "StandardVariableQuery" - }, - "refresh": 1, - "regex": "", - "skipUrlSync": false, - "sort": 0, - "type": "query" - }, - { - "current": { - "selected": true, - "text": [ - "consensus-lighthouse-1-0" - ], - "value": [ - "consensus-lighthouse-1-0" - ] - }, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "definition": "label_values(lighthouse_info{namespace=~\"$namespace\"}, pod)", - "hide": 0, - "includeAll": false, - "multi": true, - "name": "pod", - "options": [], - "query": { - "query": "label_values(lighthouse_info{namespace=~\"$namespace\"}, pod)", - "refId": "StandardVariableQuery" - }, - "refresh": 1, - "regex": "", - "skipUrlSync": false, - "sort": 0, - "type": "query" - } - ] - }, - "time": { - "from": "now-12h", - "to": "now" - }, - "timepicker": { - "refresh_intervals": [ - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ], - "time_options": [ - "5m", - "15m", - "1h", - "6h", - "12h", - "24h", - "2d", - "7d", - "30d" - ] - }, - "timezone": "", - "title": "Lighthouse-New", - "uid": "7J28K7dhJhAZwHNnU2uwNhi", - "version": 7, - "weekStart": "" -} diff --git a/charts/grafana-stakewise-dashboards/dashboards/nethermind.json b/charts/grafana-stakewise-dashboards/dashboards/nethermind.json deleted file mode 100644 index 3f9a6383b..000000000 --- a/charts/grafana-stakewise-dashboards/dashboards/nethermind.json +++ /dev/null @@ -1,5035 +0,0 @@ -{ - "annotations": { - "list": [ - { - "$$hashKey": "object:13", - "builtIn": 1, - "datasource": "-- Grafana --", - "enable": true, - "hide": true, - "iconColor": "rgba(0, 211, 255, 1)", - "name": "Annotations & Alerts", - "target": { - "limit": 100, - "matchAny": false, - "tags": [], - "type": "dashboard" - }, - "type": "dashboard" - } - ] - }, - "editable": true, - "fiscalYearStartMonth": 0, - "graphTooltip": 0, - "id": 160, - "iteration": 1650532858685, - "links": [], - "liveNow": false, - "panels": [ - { - "collapsed": false, - "datasource": { - "uid": "${prometheus}" - }, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 0 - }, - "id": 118, - "panels": [], - "title": "Basic Parameters", - "type": "row" - }, - { - "datasource": { - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "mappings": [ - { - "options": { - "match": "null", - "result": { - "text": "N/A" - } - }, - "type": "special" - } - ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-green", - "value": null - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 3, - "x": 0, - "y": 1 - }, - "id": 49, - "links": [], - "options": { - "colorMode": "value", - "fieldOptions": { - "calcs": [ - "lastNotNull" - ] - }, - "graphMode": "none", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "last" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "nethermind_sync_peers{namespace=\"$namespace\",pod=\"$pod\"}", - "format": "time_series", - "intervalFactor": 1, - "refId": "A" - } - ], - "title": "Sync Peers", - "type": "stat" - }, - { - "datasource": { - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "mappings": [ - { - "options": { - "match": "null", - "result": { - "text": "N/A" - } - }, - "type": "special" - } - ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 3, - "x": 3, - "y": 1 - }, - "id": 16, - "links": [], - "options": { - "colorMode": "value", - "fieldOptions": { - "calcs": [ - "lastNotNull" - ] - }, - "graphMode": "none", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "max" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "nethermind_blocks{namespace=\"$namespace\",pod=\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "", - "refId": "A" - }, - { - "refId": "B" - } - ], - "title": "Block Number", - "type": "stat" - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 4, - "w": 18, - "x": 6, - "y": 1 - }, - "hiddenSeries": false, - "id": 73, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "sDqP14tnk" - }, - "exemplar": true, - "expr": "nethermind_version{namespace=\"$namespace\",pod=\"$pod\"}", - "interval": "", - "legendFormat": "{{pod}}", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Version", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:79", - "decimals": 3, - "format": "short", - "label": "", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:80", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "datasource": { - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - } - }, - "links": [], - "mappings": [] - }, - "overrides": [] - }, - "gridPos": { - "h": 8, - "w": 6, - "x": 0, - "y": 5 - }, - "id": 47, - "links": [], - "options": { - "legend": { - "displayMode": "hidden", - "placement": "bottom" - }, - "pieType": "pie", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "rate(nethermind_incoming_connections{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "Incoming Connections", - "refId": "F" - }, - { - "expr": "rate(nethermind_outgoing_connections{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "Outgoing Connections", - "refId": "E" - }, - { - "expr": "rate(nethermind_handshakes{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "Handshakes", - "refId": "G" - }, - { - "expr": "rate(nethermind_hellos_sent{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "Hellos Sent", - "refId": "A" - }, - { - "expr": "rate(nethermind_hellos_received{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "Hellos Received", - "refId": "B" - }, - { - "expr": "rate(nethermind_statuses_sent{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "hide": false, - "intervalFactor": 1, - "legendFormat": "Statuses Sent", - "refId": "C" - }, - { - "expr": "rate(nethermind_statuses_received{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "Statuses Received", - "refId": "D" - } - ], - "title": "Connections (per minute)", - "type": "piechart" - }, - { - "datasource": { - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - } - }, - "links": [], - "mappings": [] - }, - "overrides": [] - }, - "gridPos": { - "h": 8, - "w": 6, - "x": 6, - "y": 5 - }, - "id": 27, - "links": [], - "options": { - "legend": { - "displayMode": "hidden", - "placement": "bottom" - }, - "pieType": "pie", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "exemplar": true, - "expr": "rate(nethermind_pending_transactions_received{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "instant": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "Received", - "refId": "C" - }, - { - "exemplar": true, - "expr": "rate(nethermind_pending_transactions_known{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "Already Known", - "refId": "F" - }, - { - "expr": "rate(nethermind_pending_transactions_discarded{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "instant": false, - "intervalFactor": 1, - "legendFormat": "Discarded", - "refId": "D" - }, - { - "exemplar": true, - "expr": "rate(nethermind_pending_transactions_too_far_in_future{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "hide": false, - "interval": "", - "legendFormat": "Too far in future", - "refId": "J" - }, - { - "exemplar": true, - "expr": "rate(nethermind_pending_transactions_too_low_fee{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "hide": false, - "interval": "", - "legendFormat": "Too low fee", - "refId": "K" - }, - { - "exemplar": true, - "expr": "rate(nethermind_pending_transactions_added{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "hide": false, - "interval": "", - "legendFormat": "Added (all)", - "refId": "G" - }, - { - "exemplar": true, - "expr": "rate(nethermind_pending1559transactions_added{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "hide": false, - "interval": "", - "legendFormat": "Added (1559)", - "refId": "B" - }, - { - "exemplar": true, - "expr": "rate(nethermind_pending_transactions_evicted{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "hide": false, - "interval": "", - "legendFormat": "Evicted", - "refId": "H" - }, - { - "exemplar": true, - "expr": "rate(nethermind_pending_transactions_sent{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "instant": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "Sent txs", - "refId": "E" - }, - { - "exemplar": true, - "expr": "rate(nethermind_pending_transactions_hashes_sent{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "hide": false, - "interval": "", - "legendFormat": "Sent hashes", - "refId": "A" - } - ], - "title": "Pending Txs (per minute)", - "type": "piechart" - }, - { - "datasource": { - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - } - }, - "links": [], - "mappings": [] - }, - "overrides": [] - }, - "gridPos": { - "h": 8, - "w": 6, - "x": 12, - "y": 5 - }, - "id": 51, - "links": [], - "options": { - "legend": { - "displayMode": "hidden", - "placement": "bottom" - }, - "pieType": "pie", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "rate(nethermind_too_many_peers_disconnects{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "Too Many Peers", - "refId": "D" - }, - { - "expr": "rate(nethermind_client_quitting_disconnects{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "Client Quitting", - "refId": "C" - }, - { - "expr": "rate(nethermind_receive_message_timeout_disconnects{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "Receive Timeouts", - "refId": "E" - }, - { - "expr": "rate(nethermind_already_connected_disconnects{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "Already Connected", - "refId": "G" - }, - { - "expr": "rate(nethermind_breach_of_protocol_disconnects{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "Breach of Protocol", - "refId": "F" - }, - { - "expr": "rate(nethermind_incompatible_p2pdisconnects{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "Incompatible P2P", - "refId": "B" - }, - { - "expr": "rate(nethermind_null_node_identity_disconnects{job=\"nethermind\",_instance=\"$enode\",nethermind_group=\"$group\"}[1m])*60", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "Null Identity", - "refId": "H" - }, - { - "expr": "rate(nethermind_unexpected_identity_disconnects{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "Unexpected Identity", - "refId": "I" - }, - { - "expr": "rate(nethermind_useless_peer_disconnects{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "Useless Peer", - "refId": "J" - }, - { - "expr": "rate(nethermind_diconnect_requested_disconnects{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "Requested", - "refId": "K" - }, - { - "expr": "rate(nethermind_tcp_subsystem_error_disconnects{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "TCP Error", - "refId": "L" - }, - { - "expr": "rate(nethermind_same_as_self_disconnects{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "Same as Self", - "refId": "M" - }, - { - "expr": "rate(nethermind_other_disconnects{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "Other", - "refId": "A" - } - ], - "title": "Disconnects (per minute)", - "type": "piechart" - }, - { - "datasource": { - "uid": "${prometheus}" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - } - }, - "links": [], - "mappings": [] - }, - "overrides": [] - }, - "gridPos": { - "h": 8, - "w": 6, - "x": 18, - "y": 5 - }, - "id": 63, - "links": [], - "options": { - "legend": { - "displayMode": "hidden", - "placement": "bottom" - }, - "pieType": "pie", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "exemplar": true, - "expr": "rate(nethermind_eth62get_block_headers_received{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "GetBlockHeaders eth62", - "refId": "A" - }, - { - "exemplar": true, - "expr": "rate(nethermind_eth62block_headers_received{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "BlockHeaders eth62", - "refId": "B" - }, - { - "exemplar": true, - "expr": "rate(nethermind_eth62get_block_bodies_received{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "GetBlockBodies eth62", - "refId": "C" - }, - { - "exemplar": true, - "expr": "rate(nethermind_eth62block_bodies_received{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "BlockBodies eth62", - "refId": "D" - }, - { - "exemplar": true, - "expr": "rate(nethermind_eth62transactions_received{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "Txs received eth62", - "refId": "E" - }, - { - "exemplar": true, - "expr": "rate(nethermind_eth65get_pooled_transactions_received{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "hide": false, - "interval": "", - "legendFormat": "Txs requests received eth65", - "refId": "U" - }, - { - "exemplar": true, - "expr": "rate(nethermind_eth65get_pooled_transactions_requested{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "hide": false, - "interval": "", - "legendFormat": "Txs requested eth65", - "refId": "L" - }, - { - "exemplar": true, - "expr": "rate(nethermind_eth65pooled_transactions_received{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "hide": false, - "interval": "", - "legendFormat": "Txs received eth65", - "refId": "K" - }, - { - "exemplar": true, - "expr": "rate(nethermind_eth62new_block_hashes_received{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "NewBlockHashes eth62", - "refId": "F" - }, - { - "exemplar": true, - "expr": "rate(nethermind_eth62new_block_received{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "NewBlock eth62", - "refId": "G" - }, - { - "exemplar": true, - "expr": "rate(nethermind_eth63get_node_data_received{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "instant": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "GetNodeData eth63", - "refId": "H" - }, - { - "exemplar": true, - "expr": "rate(nethermind_eth63node_data_received{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "interval": "", - "legendFormat": "NodeData eth63", - "refId": "J" - }, - { - "exemplar": true, - "expr": "rate(nethermind_eth63get_receipts_received{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "GetReceipts eth63", - "refId": "I" - }, - { - "exemplar": true, - "expr": "rate(nethermind_eth63receipts_received{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "hide": false, - "interval": "", - "legendFormat": "Receipts eth63", - "refId": "M" - }, - { - "exemplar": true, - "expr": "rate(nethermind_eth66get_block_headers_received{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "hide": false, - "interval": "", - "legendFormat": "GetBlockHeaders eth66", - "refId": "N" - }, - { - "exemplar": true, - "expr": "rate(nethermind_eth66block_headers_received{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "hide": false, - "interval": "", - "legendFormat": "BlockHeaders eth66", - "refId": "O" - }, - { - "exemplar": true, - "expr": "rate(nethermind_eth66get_block_bodies_received{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "hide": false, - "interval": "", - "legendFormat": "GetBlockBodies eth66", - "refId": "P" - }, - { - "exemplar": true, - "expr": "rate(nethermind_eth66block_bodies_received{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "hide": false, - "interval": "", - "legendFormat": "BlockBodies eth66", - "refId": "Q" - }, - { - "exemplar": true, - "expr": "rate(nethermind_eth66get_pooled_transactions_received{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "hide": false, - "interval": "", - "legendFormat": "Txs requests received eth66", - "refId": "V" - }, - { - "exemplar": true, - "expr": "rate(nethermind_eth66get_pooled_transactions_requested{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "hide": false, - "interval": "", - "legendFormat": "Txs requested eth66", - "refId": "R" - }, - { - "exemplar": true, - "expr": "rate(nethermind_eth66pooled_transactions_received{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "hide": false, - "interval": "", - "legendFormat": "Txs received eth66", - "refId": "S" - }, - { - "exemplar": true, - "expr": "rate(nethermind_eth66get_node_data_received{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "hide": false, - "interval": "", - "legendFormat": "GetNodeData eth66", - "refId": "T" - }, - { - "exemplar": true, - "expr": "rate(nethermind_eth66node_data_received{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "hide": false, - "interval": "", - "legendFormat": "NodeData eth66", - "refId": "W" - }, - { - "exemplar": true, - "expr": "rate(nethermind_eth66get_receipts_received{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "hide": false, - "interval": "", - "legendFormat": "GetReceipts eth66", - "refId": "X" - }, - { - "exemplar": true, - "expr": "rate(nethermind_eth66receipts_received{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "hide": false, - "interval": "", - "legendFormat": "Receipts eth66", - "refId": "Y" - } - ], - "title": "Eth62, Eth63, Eth65, Eth66 (per minute)", - "type": "piechart" - }, - { - "aliasColors": {}, - "bars": true, - "dashLength": 10, - "dashes": false, - "datasource": { - "uid": "${prometheus}" - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 13 - }, - "hiddenSeries": false, - "id": 136, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": false, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": false - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": true, - "steppedLine": false, - "targets": [ - { - "expr": "rate(nethermind_json_rpc_bytes_sent{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "interval": "", - "legendFormat": "RPC Sent", - "refId": "A" - }, - { - "expr": "rate(nethermind_json_rpc_bytes_received{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "hide": false, - "interval": "", - "legendFormat": "RPC Received", - "refId": "B" - }, - { - "expr": "rate(nethermind_discovery_bytes_received{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "hide": false, - "interval": "", - "legendFormat": "Dscv Sent", - "refId": "C" - }, - { - "expr": "rate(nethermind_discovery_bytes_sent{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "hide": false, - "interval": "", - "legendFormat": "Dscv Received", - "refId": "D" - }, - { - "expr": "rate(nethermind_p2pbytes_received{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "hide": false, - "interval": "", - "legendFormat": "P2P Received", - "refId": "E" - }, - { - "expr": "rate(nethermind_p2pbytes_sent{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "hide": false, - "interval": "", - "legendFormat": "P2P Sent", - "refId": "F" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Traffic", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:209", - "format": "short", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:210", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "datasource": { - "uid": "${prometheus}" - }, - "description": "Total number of sealed blocks", - "fieldConfig": { - "defaults": { - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-green", - "value": null - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 3, - "x": 12, - "y": 13 - }, - "id": 88, - "options": { - "colorMode": "value", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "last" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "nethermind_blocks_sealed{namespace=\"$namespace\",pod=\"$pod\"}", - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Blocks Sealed (total)", - "type": "stat" - }, - { - "datasource": { - "uid": "${prometheus}" - }, - "description": "Total number of failed block seals", - "fieldConfig": { - "defaults": { - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "semi-dark-red", - "value": 10000 - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 3, - "x": 15, - "y": 13 - }, - "id": 90, - "options": { - "colorMode": "value", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "last" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "nethermind_failed_block_seals{namespace=\"$namespace\",pod=\"$pod\"}", - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Failed Block Seals (total)", - "type": "stat" - }, - { - "datasource": { - "uid": "${prometheus}" - }, - "description": "Number of reported benign misbehaviour validators", - "fieldConfig": { - "defaults": { - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 3, - "x": 18, - "y": 13 - }, - "id": 94, - "maxDataPoints": 1, - "options": { - "colorMode": "value", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "last" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "nethermind_reported_benign_misbehaviour{namespace=\"$namespace\",pod=\"$pod\"}", - "instant": false, - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Reported Benign Misbehaviour", - "type": "stat" - }, - { - "datasource": { - "uid": "${prometheus}" - }, - "description": "Indicator if blocks can be produced", - "fieldConfig": { - "defaults": { - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 3, - "x": 21, - "y": 13 - }, - "id": 92, - "maxDataPoints": 1, - "options": { - "colorMode": "value", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "last" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "nethermind_can_produce_blocks{namespace=\"$namespace\",pod=\"$pod\"}", - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Blocks Production Indicator", - "type": "stat" - }, - { - "datasource": { - "uid": "${prometheus}" - }, - "description": "Number of reported malicious misbehaviour validators", - "fieldConfig": { - "defaults": { - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "semi-dark-red", - "value": null - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 3, - "x": 12, - "y": 17 - }, - "id": 95, - "maxDataPoints": 1, - "options": { - "colorMode": "value", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "last" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "nethermind_reported_malicious_misbehaviour{namespace=\"$namespace\",pod=\"$pod\"}", - "instant": false, - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Reported Malicious Misbehaviour", - "type": "stat" - }, - { - "datasource": { - "uid": "${prometheus}" - }, - "description": "Number of current AuRa validators", - "fieldConfig": { - "defaults": { - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 3, - "x": 15, - "y": 17 - }, - "id": 96, - "maxDataPoints": 1, - "options": { - "colorMode": "value", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "last" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "nethermind_validators_count{namespace=\"$namespace\",pod=\"$pod\"}", - "instant": false, - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Validators Count", - "type": "stat" - }, - { - "datasource": { - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "links": [], - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 6, - "x": 18, - "y": 17 - }, - "id": 45, - "links": [], - "options": { - "colorMode": "background", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "nethermind_sync_peers{namespace=\"$namespace\",pod=\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "Sync Peers", - "refId": "A" - } - ], - "title": "Sync Peers", - "transparent": true, - "type": "stat" - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 7, - "w": 8, - "x": 0, - "y": 21 - }, - "hiddenSeries": false, - "id": 102, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "sDqP14tnk" - }, - "exemplar": true, - "expr": "nethermind_last_block_processing_time_in_ms{namespace=\"$namespace\",pod=\"$pod\"}", - "interval": "", - "legendFormat": "{{pod}}", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Block processing time (ms)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:112", - "format": "short", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:113", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 3, - "gridPos": { - "h": 7, - "w": 8, - "x": 8, - "y": 21 - }, - "hiddenSeries": false, - "id": 39, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "rate(nethermind_blocks{namespace=\"$namespace\",pod=\"$pod\"}[1m])", - "format": "time_series", - "instant": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "Blocks", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Blocks (per second)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:247", - "format": "pps", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:248", - "format": "short", - "logBase": 1, - "show": false - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 7, - "w": 8, - "x": 16, - "y": 21 - }, - "hiddenSeries": false, - "id": 79, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "sDqP14tnk" - }, - "exemplar": true, - "expr": "nethermind_state_synced{namespace=\"$namespace\",pod=\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "State", - "refId": "A" - }, - { - "datasource": { - "type": "prometheus", - "uid": "sDqP14tnk" - }, - "expr": "rate(nethermind_state_synced{namespace=\"$namespace\",pod=\"$pod\"}[60m])*3600", - "interval": "", - "legendFormat": "", - "refId": "B" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "State Synced (in bytes)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:412", - "format": "decbytes", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:413", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 8, - "w": 8, - "x": 0, - "y": 28 - }, - "hiddenSeries": false, - "id": 75, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "nethermind_fast_headers{namespace=\"$namespace\",pod=\"$pod\"}", - "interval": "", - "legendFormat": "Headers", - "refId": "A" - }, - { - "expr": "nethermind_fast_bodies{namespace=\"$namespace\",pod=\"$pod\"}", - "interval": "", - "legendFormat": "Bodies", - "refId": "B" - }, - { - "expr": "nethermind_fast_receipts{namespace=\"$namespace\",pod=\"$pod\"}", - "interval": "", - "legendFormat": "Receipts", - "refId": "C" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Fast Blocks", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "transformations": [ - { - "id": "seriesToColumns", - "options": {} - } - ], - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:134", - "format": "short", - "logBase": 1, - "min": "0", - "show": true - }, - { - "$$hashKey": "object:135", - "format": "short", - "logBase": 1, - "min": "0", - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": true, - "dashLength": 10, - "dashes": false, - "datasource": { - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 8, - "w": 8, - "x": 8, - "y": 28 - }, - "hiddenSeries": false, - "id": 69, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": false, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "nethermind_blocks{namespace=\"$namespace\",pod=\"$pod\"}", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Blocks", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 8, - "w": 8, - "x": 16, - "y": 28 - }, - "hiddenSeries": false, - "id": 67, - "legend": { - "alignAsTable": false, - "avg": false, - "current": true, - "max": false, - "min": false, - "show": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "process_cpu_seconds_total{namespace=\"$namespace\",pod=\"$pod\"}", - "legendFormat": "Uptime", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "CPU time (tracks restarts)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "s", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": { - "Deserialization Failures": "purple", - "Invalid Requests": "purple", - "RPC Errors": "red", - "RPC Requests": "green", - "RPC Successes": "green" - }, - "bars": true, - "dashLength": 10, - "dashes": false, - "datasource": { - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 7, - "w": 12, - "x": 0, - "y": 36 - }, - "hiddenSeries": false, - "id": 61, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": false, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": true, - "steppedLine": false, - "targets": [ - { - "expr": "rate(nethermind_json_rpc_requests{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "hide": true, - "instant": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "RPC Requests", - "refId": "B" - }, - { - "expr": "rate(nethermind_json_rpc_successes{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "hide": false, - "intervalFactor": 1, - "legendFormat": "RPC Successes", - "refId": "C" - }, - { - "expr": "rate(nethermind_json_rpc_errors{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "hide": false, - "intervalFactor": 1, - "legendFormat": "RPC Errors", - "refId": "E" - }, - { - "expr": "rate(nethermind_json_rpc_request_deserialization_failures{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "Deserialization Failures", - "refId": "A" - }, - { - "expr": "rate(nethermind_json_rpc_invalid_requests{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "Invalid Requests", - "refId": "D" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "JSON RPC (per minute)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:374", - "format": "short", - "logBase": 1, - "min": "0", - "show": true - }, - { - "$$hashKey": "object:375", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "datasource": { - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [], - "mappings": [], - "thresholds": { - "mode": "percentage", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "semi-dark-orange", - "value": 95 - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 7, - "w": 12, - "x": 12, - "y": 36 - }, - "id": 126, - "links": [], - "options": { - "displayMode": "gradient", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "sum" - ], - "fields": "", - "values": false - }, - "showUnfilled": true, - "text": {} - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "nethermind_json_rpc_requests{namespace=\"$namespace\",pod=\"$pod\"}", - "format": "time_series", - "hide": false, - "instant": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "RPC Requests", - "refId": "B" - }, - { - "expr": "nethermind_json_rpc_successes{namespace=\"$namespace\",pod=\"$pod\"}", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "RPC Successes", - "refId": "C" - }, - { - "expr": "nethermind_json_rpc_errors{namespace=\"$namespace\",pod=\"$pod\"}", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "RPC Errors", - "refId": "E" - }, - { - "expr": "nethermind_json_rpc_request_deserialization_failures{namespace=\"$namespace\",pod=\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "Deserialization Failures", - "refId": "A" - }, - { - "expr": "nethermind_json_rpc_invalid_requests{namespace=\"$namespace\",pod=\"$pod\"}", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "Invalid Requests", - "refId": "D" - } - ], - "title": "JSON RPC (total)", - "transparent": true, - "type": "bargauge" - }, - { - "collapsed": true, - "datasource": { - "uid": "${prometheus}" - }, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 43 - }, - "id": 86, - "panels": [ - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "uid": "${prometheus}" - }, - "description": "POSDAO number of emit init change transactions", - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 44 - }, - "hiddenSeries": false, - "id": 100, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "maxDataPoints": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "nethermind_emit_initiate_change{namespace=\"$namespace\",pod=\"$pod\"}", - "instant": false, - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "POSDAO Emit Initiate Change", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:2069", - "format": "short", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:2070", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "uid": "${prometheus}" - }, - "description": "Current AuRa step", - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 44 - }, - "hiddenSeries": false, - "id": 93, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "maxDataPoints": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "nethermind_au_ra_step{namespace=\"$namespace\",pod=\"$pod\"}", - "instant": false, - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Aura Step", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:373", - "format": "short", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:374", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "uid": "${prometheus}" - }, - "description": "RANDAO number of reveal number transactions", - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 52 - }, - "hiddenSeries": false, - "id": 99, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "maxDataPoints": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "nethermind_reveal_number{namespace=\"$namespace\",pod=\"$pod\"}", - "instant": false, - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "RANDAO Reveal Number", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:1967", - "format": "short", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:1968", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "uid": "${prometheus}" - }, - "description": "Number of sealed transactions generated by engine", - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 8, - "w": 12, - "x": 12, - "y": 52 - }, - "hiddenSeries": false, - "id": 97, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "maxDataPoints": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "nethermind_sealed_transactions{namespace=\"$namespace\",pod=\"$pod\"}", - "hide": false, - "instant": false, - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Sealed Transactions", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:1610", - "format": "short", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:1611", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "uid": "${prometheus}" - }, - "description": "RANDAO number of commit hash transactions", - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 8, - "w": 12, - "x": 0, - "y": 60 - }, - "hiddenSeries": false, - "id": 98, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "maxDataPoints": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "nethermind_commit_hash_transaction{namespace=\"$namespace\",pod=\"$pod\"}", - "instant": false, - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "RANDAO Commit Hash Transaction", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:1661", - "format": "short", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:1662", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - } - ], - "title": "AuRa Specific", - "type": "row" - }, - { - "collapsed": false, - "datasource": { - "uid": "${prometheus}" - }, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 44 - }, - "id": 132, - "panels": [], - "title": "Memory", - "type": "row" - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 7, - "w": 24, - "x": 0, - "y": 45 - }, - "hiddenSeries": false, - "id": 65, - "legend": { - "avg": true, - "current": true, - "max": true, - "min": true, - "show": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": true, - "steppedLine": false, - "targets": [ - { - "exemplar": true, - "expr": "dotnet_total_memory_bytes{namespace=\"$namespace\",pod=\"$pod\"}", - "instant": false, - "interval": "", - "legendFormat": "Managed Memory", - "refId": "A" - }, - { - "expr": " process_working_set_bytes{namespace=\"$namespace\",pod=\"$pod\"} - dotnet_total_memory_bytes{namespace=\"$namespace\",pod=\"$pod\"}", - "legendFormat": "Unmanaged Memory", - "refId": "B" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Memory", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:450", - "format": "bytes", - "logBase": 1, - "min": "0", - "show": true - }, - { - "$$hashKey": "object:451", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": true, - "dashLength": 10, - "dashes": false, - "datasource": { - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 3, - "gridPos": { - "h": 7, - "w": 24, - "x": 0, - "y": 52 - }, - "hiddenSeries": false, - "id": 2, - "legend": { - "avg": true, - "current": true, - "max": true, - "min": true, - "show": true, - "total": true, - "values": true - }, - "lines": false, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 5, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "deriv(dotnet_total_memory_bytes{namespace=\"$namespace\",pod=\"$pod\"}[1m]) > 0", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "Managed Memory", - "refId": "A", - "target": "*.Nethermind_Runner.*.*.*.*.gauge.*.Process_Physical_Memory" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Memory Growth (per second)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:2264", - "format": "Bps", - "logBase": 1, - "max": "8000000", - "min": "0", - "show": true - }, - { - "$$hashKey": "object:2265", - "format": "bytes", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": true, - "dashLength": 10, - "dashes": false, - "datasource": { - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 24, - "x": 0, - "y": 59 - }, - "hiddenSeries": false, - "id": 12, - "legend": { - "alignAsTable": false, - "avg": false, - "current": false, - "max": false, - "min": false, - "rightSide": false, - "show": true, - "total": false, - "values": false - }, - "lines": false, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 5, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": true, - "steppedLine": false, - "targets": [ - { - "expr": "rate(dotnet_collection_count_total{generation=\"0\",namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "hide": false, - "instant": false, - "intervalFactor": 1, - "legendFormat": "Gen 0", - "refId": "A" - }, - { - "expr": "rate(dotnet_collection_count_total{generation=\"1\",namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "hide": false, - "intervalFactor": 1, - "legendFormat": "Gen 1", - "refId": "B" - }, - { - "expr": "rate(dotnet_collection_count_total{generation=\"2\",namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "hide": false, - "intervalFactor": 1, - "legendFormat": "Gen 2", - "refId": "C" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "GC (per minute)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "ops", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "collapsed": true, - "datasource": { - "uid": "${prometheus}" - }, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 65 - }, - "id": 105, - "panels": [ - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "uid": "${prometheus}" - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 8, - "w": 24, - "x": 0, - "y": 46 - }, - "hiddenSeries": false, - "id": 116, - "legend": { - "alignAsTable": false, - "avg": false, - "current": false, - "max": false, - "min": false, - "rightSide": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": true, - "pluginVersion": "8.4.2", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": true, - "steppedLine": false, - "targets": [ - { - "expr": "nethermind_loaded_from_db_nodes_count{namespace=\"$namespace\",pod=\"$pod\"}", - "interval": "", - "legendFormat": "DB", - "refId": "A" - }, - { - "expr": "nethermind_loaded_from_rlp_cache_nodes_count{namespace=\"$namespace\",pod=\"$pod\"}", - "interval": "", - "legendFormat": "RLP Cache", - "refId": "B" - }, - { - "expr": "nethermind_loaded_from_cache_nodes_count{namespace=\"$namespace\",pod=\"$pod\"}", - "interval": "", - "legendFormat": "Node Cache", - "refId": "C" - }, - { - "expr": "", - "interval": "", - "legendFormat": "", - "refId": "D" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Caching Efficiency", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:126", - "format": "short", - "logBase": 1, - "min": "0", - "show": true - }, - { - "$$hashKey": "object:127", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "uid": "${prometheus}" - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 7, - "w": 24, - "x": 0, - "y": 54 - }, - "hiddenSeries": false, - "id": 128, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "nethermind_memory_used_by_cache{namespace=\"$namespace\",pod=\"$pod\"}", - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Pruning Cache", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:64", - "format": "decbytes", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:65", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "uid": "${prometheus}" - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 7, - "w": 24, - "x": 0, - "y": 61 - }, - "hiddenSeries": false, - "id": 122, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": true, - "pluginVersion": "8.4.2", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": true, - "steppedLine": false, - "targets": [ - { - "expr": "nethermind_committed_nodes_count{namespace=\"$namespace\",pod=\"$pod\"}", - "interval": "", - "legendFormat": "Committed", - "refId": "G" - }, - { - "expr": "nethermind_persisted_node_count{namespace=\"$namespace\",pod=\"$pod\"}", - "instant": false, - "interval": "", - "legendFormat": "Persisted", - "refId": "A" - }, - { - "expr": "nethermind_pruned_nodes_count{namespace=\"$namespace\",pod=\"$pod\"}", - "hide": true, - "instant": false, - "interval": "", - "legendFormat": "Pruned", - "refId": "B" - }, - { - "expr": "nethermind_cached_nodes_count{namespace=\"$namespace\",pod=\"$pod\"}", - "interval": "", - "legendFormat": "Cached", - "refId": "C" - }, - { - "expr": "nethermind_replaced_nodes_count{namespace=\"$namespace\",pod=\"$pod\"}", - "instant": false, - "interval": "", - "legendFormat": "Replaced", - "refId": "D" - }, - { - "expr": "nethermind_pruned_persisted_nodes_count{namespace=\"$namespace\",pod=\"$pod\"}", - "instant": false, - "interval": "", - "legendFormat": "Pruned Persisted", - "refId": "E" - }, - { - "expr": "nethermind_pruned_transient_nodes_count{namespace=\"$namespace\",pod=\"$pod\"}", - "instant": false, - "interval": "", - "legendFormat": "Pruned Transient", - "refId": "F" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Pruning Levels", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:773", - "format": "short", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:774", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "uid": "${prometheus}" - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 24, - "x": 0, - "y": 68 - }, - "hiddenSeries": false, - "id": 120, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "nethermind_snapshot_persistence_time{namespace=\"$namespace\",pod=\"$pod\"}", - "interval": "", - "legendFormat": "Persistence", - "refId": "A" - }, - { - "expr": "nethermind_pruning_time{namespace=\"$namespace\",pod=\"$pod\"}", - "interval": "", - "legendFormat": "Pruning", - "refId": "B" - }, - { - "expr": "nethermind_deep_pruning_time{namespace=\"$namespace\",pod=\"$pod\"}", - "interval": "", - "legendFormat": "", - "refId": "C" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Times", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:545", - "format": "short", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:546", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - } - ], - "title": "Pruning", - "type": "row" - }, - { - "collapsed": true, - "datasource": { - "uid": "${prometheus}" - }, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 66 - }, - "id": 134, - "panels": [ - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 7, - "w": 12, - "x": 0, - "y": 47 - }, - "hiddenSeries": false, - "id": 80, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "nethermind_beamed_transactions{namespace=\"$namespace\",pod=\"$pod\"}", - "interval": "", - "legendFormat": "Transactions", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Beamed Transactions", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 7, - "w": 12, - "x": 12, - "y": 47 - }, - "hiddenSeries": false, - "id": 82, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "nethermind_beamed_blocks{namespace=\"$namespace\",pod=\"$pod\"}", - "interval": "", - "legendFormat": "Blocks", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Beamed Blocks", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 7, - "w": 12, - "x": 0, - "y": 54 - }, - "hiddenSeries": false, - "id": 83, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "nethermind_beamed_requests{namespace=\"$namespace\",pod=\"$pod\"}", - "interval": "", - "legendFormat": "Requests", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Beamed Requests", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 7, - "w": 12, - "x": 12, - "y": 54 - }, - "hiddenSeries": false, - "id": 84, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "nethermind_beamed_trie_nodes{namespace=\"$namespace\",pod=\"$pod\"}", - "interval": "", - "legendFormat": "Trie Nodes", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Beamed Trie Nodes", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - } - ], - "title": "Beam", - "type": "row" - }, - { - "collapsed": true, - "datasource": { - "uid": "${prometheus}" - }, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 67 - }, - "id": 53, - "panels": [ - { - "aliasColors": {}, - "bars": true, - "dashLength": 10, - "dashes": false, - "datasource": { - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 24, - "x": 0, - "y": 48 - }, - "hiddenSeries": false, - "id": 22, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": false, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 5, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": true, - "steppedLine": false, - "targets": [ - { - "expr": "rate(nethermind_receipts_db_reads{namespace=\"$namespace\",pod=\"$pod\"}[10s])", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "Reads", - "refId": "A" - }, - { - "expr": "rate(nethermind_receipts_db_writes{namespace=\"$namespace\",pod=\"$pod\"}[10s])", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "Writes", - "refId": "B" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Receipts DB", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": true, - "dashLength": 10, - "dashes": false, - "datasource": { - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 24, - "x": 0, - "y": 54 - }, - "hiddenSeries": false, - "id": 21, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": false, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 5, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": true, - "steppedLine": false, - "targets": [ - { - "expr": "rate(nethermind_code_db_reads{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "Reads", - "refId": "A" - }, - { - "expr": "rate(nethermind_code_db_writes{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "Writes", - "refId": "B" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Code DB", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": true, - "dashLength": 10, - "dashes": false, - "datasource": { - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 24, - "x": 0, - "y": 60 - }, - "hiddenSeries": false, - "id": 24, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": false, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 5, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": true, - "steppedLine": false, - "targets": [ - { - "expr": "rate(nethermind_state_tree_reads{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "Reads", - "refId": "A" - }, - { - "expr": "rate(nethermind_state_tree_writes{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "Writes", - "refId": "B" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "State Tree", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": true, - "dashLength": 10, - "dashes": false, - "datasource": { - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 6, - "w": 24, - "x": 0, - "y": 66 - }, - "hiddenSeries": false, - "id": 23, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": false, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 5, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": true, - "steppedLine": false, - "targets": [ - { - "expr": "rate(nethermind_block_infos_db_reads{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "Reads", - "refId": "A" - }, - { - "expr": "rate(nethermind_block_infos_db_writes{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "Writes", - "refId": "B" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Block Info DB", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "logBase": 1, - "show": true - }, - { - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": true, - "dashLength": 10, - "dashes": false, - "datasource": { - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 8, - "w": 24, - "x": 0, - "y": 72 - }, - "hiddenSeries": false, - "id": 25, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": false, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 5, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": true, - "steppedLine": false, - "targets": [ - { - "expr": "rate(nethermind_state_db_reads{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "Reads", - "refId": "A" - }, - { - "exemplar": true, - "expr": "rate(nethermind_state_db_writes{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "Writes", - "refId": "B" - }, - { - "exemplar": true, - "expr": "rate(nethermind_state_db_in_pruning_writes{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "hide": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "Pruning Writes", - "refId": "C" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "State DB", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:121", - "format": "short", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:122", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": true, - "dashLength": 10, - "dashes": false, - "datasource": { - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 7, - "w": 24, - "x": 0, - "y": 80 - }, - "hiddenSeries": false, - "id": 8, - "legend": { - "alignAsTable": false, - "avg": false, - "current": false, - "max": false, - "min": false, - "rightSide": false, - "show": true, - "total": false, - "values": false - }, - "lines": false, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 5, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": true, - "steppedLine": false, - "targets": [ - { - "expr": "rate(nethermind_storage_tree_reads{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "Reads", - "refId": "A" - }, - { - "expr": "rate(nethermind_storage_tree_writes{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "Writes", - "refId": "B" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Storage Tree", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": "", - "logBase": 1, - "show": true - }, - { - "format": "short", - "label": "", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": true, - "dashLength": 10, - "dashes": false, - "datasource": { - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 7, - "w": 24, - "x": 0, - "y": 87 - }, - "hiddenSeries": false, - "id": 29, - "legend": { - "alignAsTable": false, - "avg": false, - "current": false, - "max": false, - "min": false, - "rightSide": false, - "show": true, - "total": false, - "values": false - }, - "lines": false, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 5, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": true, - "steppedLine": false, - "targets": [ - { - "expr": "rate(nethermind_tree_node_rlp_decodings{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "RLP.Encode", - "refId": "A" - }, - { - "expr": "rate(nethermind_tree_node_rlp_encodings{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "RLP.Decode", - "refId": "B" - }, - { - "expr": "rate(nethermind_tree_node_hash_calculations{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "Keccak", - "refId": "C" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Trie Operations", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": "", - "logBase": 1, - "show": true - }, - { - "format": "short", - "label": "", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 7, - "w": 24, - "x": 0, - "y": 94 - }, - "hiddenSeries": false, - "id": 28, - "legend": { - "alignAsTable": false, - "avg": false, - "current": false, - "max": false, - "min": false, - "rightSide": false, - "show": true, - "total": false, - "values": false - }, - "lines": true, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 5, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": true, - "steppedLine": false, - "targets": [ - { - "expr": "rate(nethermind_other_db_reads{namespace=\"$namespace\",pod=\"$pod\"}[10s])", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "Reads", - "refId": "A" - }, - { - "expr": "rate(nethermind_other_db_writes{namespace=\"$namespace\",pod=\"$pod\"}[10s])", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "Writes", - "refId": "B" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Other DB", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "format": "short", - "label": "", - "logBase": 1, - "show": true - }, - { - "format": "short", - "label": "", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": true, - "dashLength": 10, - "dashes": false, - "datasource": { - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 7, - "w": 24, - "x": 0, - "y": 101 - }, - "hiddenSeries": false, - "id": 20, - "legend": { - "avg": false, - "current": false, - "max": false, - "min": false, - "show": true, - "total": false, - "values": false - }, - "lines": false, - "linewidth": 1, - "links": [], - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 5, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "rate(nethermind_blocks_db_reads{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "interval": "", - "intervalFactor": 1, - "legendFormat": "Reads", - "refId": "A" - }, - { - "expr": "rate(nethermind_blocks_db_writes{namespace=\"$namespace\",pod=\"$pod\"}[1m])*60", - "format": "time_series", - "intervalFactor": 1, - "legendFormat": "Writes", - "refId": "B" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Blocks DB (per minute)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:150", - "format": "short", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:151", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - } - ], - "title": "Data", - "type": "row" - }, - { - "collapsed": false, - "datasource": { - "uid": "${prometheus}" - }, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 68 - }, - "id": 138, - "panels": [], - "title": "TxPool", - "type": "row" - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "uid": "${prometheus}" - }, - "description": "Unknown transactions in blocks", - "fill": 1, - "fillGradient": 0, - "gridPos": { - "h": 7, - "w": 24, - "x": 0, - "y": 69 - }, - "hiddenSeries": false, - "id": 140, - "legend": { - "avg": true, - "current": true, - "max": false, - "min": false, - "show": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "exemplar": true, - "expr": "nethermind_dark_pool_ratio_level1{namespace=\"$namespace\",pod=\"$pod\"}", - "interval": "", - "legendFormat": "Level1 (not known)", - "refId": "A" - }, - { - "exemplar": true, - "expr": "nethermind_dark_pool_ratio_level2{namespace=\"$namespace\",pod=\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "level2 (not pending)", - "refId": "B" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "DarkPool", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:149", - "format": "percentunit", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:150", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "datasource": { - "uid": "${prometheus}" - }, - "description": "Ratio of 1559-type transactions in the block.", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "axisSoftMax": 1, - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 30, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "auto", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "percentunit" - }, - "overrides": [] - }, - "gridPos": { - "h": 8, - "w": 24, - "x": 0, - "y": 76 - }, - "id": 142, - "options": { - "legend": { - "calcs": [ - "mean" - ], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "single", - "sort": "none" - } - }, - "targets": [ - { - "exemplar": true, - "expr": "nethermind_eip1559transactions_ratio{namespace=\"$namespace\",pod=\"$pod\"}", - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "1559-type transactions ratio", - "type": "timeseries" - } - ], - "refresh": "1m", - "schemaVersion": 35, - "style": "dark", - "tags": [ - "eth1.0", - "ethereum", - "nethermind" - ], - "templating": { - "list": [ - { - "current": { - "selected": true, - "text": "default", - "value": "default" - }, - "hide": 0, - "includeAll": false, - "multi": false, - "name": "prometheus", - "options": [], - "query": "prometheus", - "queryValue": "", - "refresh": 1, - "regex": "", - "skipUrlSync": false, - "type": "datasource" - }, - { - "current": { - "selected": false, - "text": "goerli", - "value": "goerli" - }, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "definition": "label_values(nethermind_version{}, namespace)", - "hide": 0, - "includeAll": false, - "multi": false, - "name": "namespace", - "options": [], - "query": { - "query": "label_values(nethermind_version{}, namespace)", - "refId": "StandardVariableQuery" - }, - "refresh": 1, - "regex": "", - "skipUrlSync": false, - "sort": 0, - "type": "query" - }, - { - "current": { - "selected": false, - "text": "nethermind-0", - "value": "nethermind-0" - }, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "definition": "label_values(nethermind_version{}, pod)", - "hide": 0, - "includeAll": false, - "multi": false, - "name": "pod", - "options": [], - "query": { - "query": "label_values(nethermind_version{}, pod)", - "refId": "StandardVariableQuery" - }, - "refresh": 1, - "regex": "", - "skipUrlSync": false, - "sort": 0, - "type": "query" - } - ] - }, - "time": { - "from": "now-1h", - "to": "now" - }, - "timepicker": { - "refresh_intervals": [ - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ], - "time_options": [ - "5m", - "15m", - "1h", - "6h", - "12h", - "24h", - "2d", - "7d", - "30d" - ] - }, - "timezone": "", - "title": "Nethermind", - "uid": "nQaasd123fghRO6Yiz", - "version": 7, - "weekStart": "" -} \ No newline at end of file diff --git a/charts/grafana-stakewise-dashboards/dashboards/nimbus.json b/charts/grafana-stakewise-dashboards/dashboards/nimbus.json deleted file mode 100644 index 0723c9e14..000000000 --- a/charts/grafana-stakewise-dashboards/dashboards/nimbus.json +++ /dev/null @@ -1,3418 +0,0 @@ -{ - "annotations": { - "list": [ - { - "builtIn": 1, - "datasource": "-- Grafana --", - "enable": true, - "hide": true, - "iconColor": "rgba(0, 211, 255, 1)", - "name": "Annotations & Alerts", - "target": { - "limit": 100, - "matchAny": false, - "tags": [], - "type": "dashboard" - }, - "type": "dashboard" - } - ] - }, - "editable": true, - "fiscalYearStartMonth": 0, - "graphTooltip": 0, - "id": 148, - "iteration": 1650533519071, - "links": [], - "liveNow": false, - "panels": [ - { - "collapsed": false, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 0 - }, - "id": 68, - "panels": [], - "title": "Main", - "type": "row" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [ - { - "options": { - "match": "null", - "result": { - "text": "N/A" - } - }, - "type": "special" - } - ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 2, - "w": 3, - "x": 0, - "y": 1 - }, - "id": 28, - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "background", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "beacon_slot{namespace=\"$namespace\",pod=\"${pod}\"}", - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Current Slot", - "transparent": true, - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [ - { - "options": { - "match": "null", - "result": { - "text": "N/A" - } - }, - "type": "special" - } - ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 2, - "w": 3, - "x": 3, - "y": 1 - }, - "id": 32, - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "background", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "beacon_current_epoch{namespace=\"$namespace\",pod=\"${pod}\"}", - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Current Epoch", - "transparent": true, - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [ - { - "options": { - "match": "null", - "result": { - "text": "N/A" - } - }, - "type": "special" - } - ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 2, - "w": 4, - "x": 6, - "y": 1 - }, - "id": 34, - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "background", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "beacon_current_justified_epoch{namespace=\"$namespace\",pod=\"${pod}\"}", - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Current Justified Epoch", - "transparent": true, - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [ - { - "options": { - "match": "null", - "result": { - "text": "N/A" - } - }, - "type": "special" - } - ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 2, - "w": 4, - "x": 10, - "y": 1 - }, - "id": 36, - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "background", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "beacon_finalized_epoch{namespace=\"$namespace\",pod=\"${pod}\"}", - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Last Finalized Epoch", - "transparent": true, - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - } - }, - "links": [], - "mappings": [], - "min": 0, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 6, - "x": 14, - "y": 1 - }, - "id": 16, - "options": { - "displayLabels": [ - "value" - ], - "legend": { - "displayMode": "list", - "placement": "bottom" - }, - "pieType": "pie", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.1.6", - "targets": [ - { - "expr": "libp2p_open_streams{namespace=\"$namespace\",pod=\"${pod}\"}", - "interval": "", - "legendFormat": "{{type}} ({{dir}})", - "refId": "A" - } - ], - "title": "Open streams", - "type": "piechart" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - } - }, - "mappings": [] - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 4, - "x": 20, - "y": 1 - }, - "id": 57, - "options": { - "legend": { - "displayMode": "hidden", - "placement": "bottom" - }, - "pieType": "donut", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "version{namespace=\"$namespace\",pod=\"${pod}\"}", - "interval": "", - "legendFormat": "{{version}}", - "refId": "A" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "network_name{namespace=\"$namespace\",pod=\"${pod}\"}", - "hide": false, - "interval": "", - "legendFormat": "{{name}}", - "refId": "B" - } - ], - "title": "version/network", - "transparent": true, - "type": "piechart" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [ - { - "options": { - "match": "null", - "result": { - "text": "N/A" - } - }, - "type": "special" - } - ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "dthms" - }, - "overrides": [] - }, - "gridPos": { - "h": 2, - "w": 3, - "x": 0, - "y": 3 - }, - "id": 40, - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "background", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "time() - process_start_time_seconds{namespace=\"$namespace\",pod=\"${pod}\"}", - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Runtime", - "transparent": true, - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [ - { - "options": { - "match": "null", - "result": { - "text": "N/A" - } - }, - "type": "special" - } - ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 2, - "w": 3, - "x": 3, - "y": 3 - }, - "id": 13, - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "background", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "sum(beacon_attestations_sent_total)", - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Att'ns Sent #all", - "transparent": true, - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [ - { - "options": { - "match": "null", - "result": { - "text": "N/A" - } - }, - "type": "special" - } - ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 2, - "w": 3, - "x": 6, - "y": 3 - }, - "id": 14, - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "background", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "beacon_attestations_received_total{namespace=\"$namespace\",pod=\"${pod}\"}", - "refId": "A" - } - ], - "title": "Att'ns Recv'd", - "transparent": true, - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "links": [], - "mappings": [], - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 2, - "w": 5, - "x": 9, - "y": 3 - }, - "id": 71, - "options": { - "colorMode": "background", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "beacon_active_validators{namespace=\"$namespace\",pod=\"${pod}\"}", - "interval": "", - "legendFormat": "current validators", - "refId": "A" - } - ], - "title": "Validators", - "transparent": true, - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "links": [], - "mappings": [], - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "short" - }, - "overrides": [ - { - "matcher": { - "id": "byName", - "options": "RSS" - }, - "properties": [ - { - "id": "unit", - "value": "bytes" - } - ] - }, - { - "matcher": { - "id": "byName", - "options": "Nim GC mem total" - }, - "properties": [ - { - "id": "unit", - "value": "bytes" - } - ] - }, - { - "matcher": { - "id": "byName", - "options": "Nim GC mem used" - }, - "properties": [ - { - "id": "unit", - "value": "bytes" - } - ] - } - ] - }, - "gridPos": { - "h": 6, - "w": 14, - "x": 0, - "y": 5 - }, - "id": 2, - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.1.6", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "rate(process_cpu_seconds_total{namespace=\"$namespace\",pod=\"${pod}\"}[$__rate_interval]) * 100", - "interval": "", - "legendFormat": "CPU usage %", - "refId": "A" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "process_open_fds{namespace=\"$namespace\",pod=\"${pod}\"}", - "interval": "", - "legendFormat": "open file descriptors", - "refId": "C" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "process_resident_memory_bytes{namespace=\"$namespace\",pod=\"${pod}\"}", - "interval": "", - "legendFormat": "RSS", - "refId": "D" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "sum(nim_gc_mem_bytes{namespace=\"$namespace\",pod=\"${pod}\"})", - "interval": "", - "legendFormat": "Nim GC mem total", - "refId": "F" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "sum(nim_gc_mem_occupied_bytes{namespace=\"$namespace\",pod=\"${pod}\"})", - "interval": "", - "legendFormat": "Nim GC mem used", - "refId": "G" - } - ], - "title": "Resources", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - } - }, - "links": [], - "mappings": [], - "min": 0, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 7, - "w": 6, - "x": 14, - "y": 7 - }, - "id": 51, - "options": { - "displayLabels": [ - "name", - "value" - ], - "legend": { - "displayMode": "hidden", - "placement": "bottom" - }, - "pieType": "pie", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "tooltip": { - "mode": "single", - "sort": "none" - } - }, - "pluginVersion": "8.1.6", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "libp2p_peers{namespace=\"$namespace\",pod=\"${pod}\"}", - "interval": "", - "legendFormat": "peers", - "refId": "A" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "libp2p_pubsub_peers{namespace=\"$namespace\",pod=\"${pod}\"}", - "interval": "", - "legendFormat": "pubsub", - "refId": "C" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "nbc_peers{namespace=\"$namespace\",pod=\"${pod}\"}", - "interval": "", - "legendFormat": "beacon_node", - "refId": "B" - } - ], - "title": "Peers", - "type": "piechart" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - } - }, - "mappings": [] - }, - "overrides": [] - }, - "gridPos": { - "h": 7, - "w": 4, - "x": 20, - "y": 7 - }, - "id": 59, - "options": { - "legend": { - "displayMode": "hidden", - "placement": "bottom" - }, - "pieType": "pie", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "libp2p_peers_identity{namespace=\"$namespace\",pod=\"${pod}\"}", - "interval": "", - "legendFormat": "{{agent}}", - "refId": "A" - } - ], - "title": "Peer Type", - "transformations": [ - { - "disabled": true, - "id": "calculateField", - "options": {} - } - ], - "type": "piechart" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "hidden", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "links": [], - "mappings": [], - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "bytes" - }, - "overrides": [ - { - "matcher": { - "id": "byRegexp", - "options": "/.*/" - }, - "properties": [ - { - "id": "custom.axisPlacement", - "value": "auto" - } - ] - }, - { - "matcher": { - "id": "byType", - "options": "time" - }, - "properties": [ - { - "id": "custom.axisPlacement", - "value": "auto" - } - ] - } - ] - }, - "gridPos": { - "h": 6, - "w": 14, - "x": 0, - "y": 11 - }, - "id": 18, - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.1.6", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "nim_gc_heap_instance_occupied_bytes{namespace=\"$namespace\",pod=\"${pod}\"}", - "interval": "", - "legendFormat": "{{type_name}}", - "refId": "A" - } - ], - "title": "GC Heap Objects", - "transformations": [], - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "auto", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "normal" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "binBps" - }, - "overrides": [ - { - "matcher": { - "id": "byName", - "options": "Total" - }, - "properties": [ - { - "id": "custom.stacking", - "value": { - "group": "A", - "mode": "none" - } - }, - { - "id": "custom.fillOpacity", - "value": 0 - }, - { - "id": "custom.lineWidth", - "value": 0 - } - ] - } - ] - }, - "gridPos": { - "h": 6, - "w": 10, - "x": 14, - "y": 14 - }, - "id": 61, - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "rate(libp2p_peers_traffic_read_total{namespace=\"$namespace\",pod=\"${pod}\"}[$__rate_interval])", - "interval": "", - "legendFormat": "{{agent}}", - "refId": "A" - } - ], - "title": "Incoming Traffic By Peer Type", - "transformations": [ - { - "id": "calculateField", - "options": {} - } - ], - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "links": [], - "mappings": [], - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "short" - }, - "overrides": [ - { - "matcher": { - "id": "byName", - "options": "proposed" - }, - "properties": [ - { - "id": "color", - "value": { - "fixedColor": "dark-yellow", - "mode": "fixed" - } - } - ] - }, - { - "matcher": { - "id": "byName", - "options": "received" - }, - "properties": [ - { - "id": "color", - "value": { - "fixedColor": "light-green", - "mode": "fixed" - } - } - ] - } - ] - }, - "gridPos": { - "h": 6, - "w": 14, - "x": 0, - "y": 17 - }, - "id": 38, - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.1.6", - "targets": [ - { - "exemplar": true, - "expr": "rate(beacon_blocks_received_total{namespace=\"$namespace\",pod=\"${pod}\"}[$__rate_interval])", - "interval": "", - "legendFormat": "received", - "refId": "B" - }, - { - "exemplar": true, - "expr": "rate(beacon_blocks_proposed_total{namespace=\"$namespace\",pod=\"${pod}\"}[$__rate_interval])", - "interval": "", - "legendFormat": "proposed", - "refId": "A" - } - ], - "title": "Blocks / Slot", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "auto", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "normal" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "binBps" - }, - "overrides": [ - { - "matcher": { - "id": "byName", - "options": "Total" - }, - "properties": [ - { - "id": "custom.stacking", - "value": { - "group": "A", - "mode": "none" - } - }, - { - "id": "custom.fillOpacity", - "value": 0 - }, - { - "id": "custom.lineWidth", - "value": 0 - } - ] - } - ] - }, - "gridPos": { - "h": 6, - "w": 10, - "x": 14, - "y": 20 - }, - "id": 62, - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "rate(libp2p_peers_traffic_write_total{namespace=\"$namespace\",pod=\"${pod}\"}[$__rate_interval])", - "interval": "", - "legendFormat": "{{agent}}", - "refId": "A" - } - ], - "title": "Outgoing Traffic By Peer Type", - "transformations": [ - { - "id": "calculateField", - "options": {} - } - ], - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "links": [], - "mappings": [], - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 14, - "x": 0, - "y": 23 - }, - "id": 30, - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.1.6", - "targets": [ - { - "exemplar": true, - "expr": "rate(beacon_attestations_received_total{namespace=\"$namespace\",pod=\"${pod}\"}[$__rate_interval])", - "interval": "", - "legendFormat": "received", - "refId": "A" - }, - { - "exemplar": true, - "expr": "rate(beacon_attestations_sent_total{namespace=\"$namespace\",pod=\"${pod}\"}[$__rate_interval])", - "interval": "", - "legendFormat": "sent", - "refId": "B" - } - ], - "title": "Attestations / Slot", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "links": [], - "mappings": [], - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "short" - }, - "overrides": [ - { - "matcher": { - "id": "byName", - "options": "no peers" - }, - "properties": [ - { - "id": "color", - "value": { - "fixedColor": "red", - "mode": "fixed" - } - } - ] - }, - { - "matcher": { - "id": "byName", - "options": "healthy" - }, - "properties": [ - { - "id": "color", - "value": { - "fixedColor": "green", - "mode": "fixed" - } - } - ] - }, - { - "matcher": { - "id": "byName", - "options": "low" - }, - "properties": [ - { - "id": "color", - "value": { - "fixedColor": "yellow", - "mode": "fixed" - } - } - ] - } - ] - }, - "gridPos": { - "h": 5, - "w": 10, - "x": 14, - "y": 26 - }, - "id": 20, - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.1.6", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "libp2p_gossipsub_healthy_peers_topics{namespace=\"$namespace\",pod=\"${pod}\"}", - "interval": "", - "legendFormat": "healthy", - "refId": "A" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "libp2p_gossipsub_low_peers_topics{namespace=\"$namespace\",pod=\"${pod}\"}", - "hide": false, - "interval": "", - "legendFormat": "low", - "refId": "C" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "libp2p_gossipsub_no_peers_topics{namespace=\"$namespace\",pod=\"${pod}\"}", - "hide": false, - "interval": "", - "legendFormat": "no peers", - "refId": "B" - } - ], - "title": "Mesh Health", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "links": [], - "mappings": [], - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 14, - "x": 0, - "y": 28 - }, - "id": 55, - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.1.6", - "targets": [ - { - "exemplar": true, - "expr": "rate(beacon_aggregates_received_total{namespace=\"$namespace\",pod=\"${pod}\"}[$__rate_interval])", - "interval": "", - "legendFormat": "received", - "refId": "A" - } - ], - "title": "aggregates/slot", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "links": [], - "mappings": [], - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "short" - }, - "overrides": [ - { - "matcher": { - "id": "byName", - "options": "healthy" - }, - "properties": [ - { - "id": "color", - "value": { - "fixedColor": "green", - "mode": "fixed" - } - } - ] - }, - { - "matcher": { - "id": "byName", - "options": "low" - }, - "properties": [ - { - "id": "color", - "value": { - "fixedColor": "red", - "mode": "fixed" - } - } - ] - }, - { - "matcher": { - "id": "byName", - "options": "good" - }, - "properties": [ - { - "id": "color", - "value": { - "fixedColor": "yellow", - "mode": "fixed" - } - } - ] - } - ] - }, - "gridPos": { - "h": 5, - "w": 10, - "x": 14, - "y": 31 - }, - "id": 72, - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.1.6", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "nbc_gossipsub_healthy_fanout{namespace=\"$namespace\",pod=\"${pod}\"}", - "interval": "", - "legendFormat": "healthy", - "refId": "A" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "nbc_gossipsub_good_fanout{namespace=\"$namespace\",pod=\"${pod}\"}", - "hide": false, - "interval": "", - "legendFormat": "good", - "refId": "C" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "nbc_gossipsub_low_fanout{namespace=\"$namespace\",pod=\"${pod}\"}", - "hide": false, - "interval": "", - "legendFormat": "low", - "refId": "B" - } - ], - "title": "Fanout Health", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "links": [], - "mappings": [], - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 14, - "x": 0, - "y": 33 - }, - "id": 22, - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.1.6", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "rate(attached_validator_balance_total{namespace=\"$namespace\",pod=\"${pod}\"}[$__rate_interval]) * 384 / 1000000000", - "interval": "", - "legendFormat": "GWei", - "refId": "A" - } - ], - "title": "Validator rewards / Epoch", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "links": [], - "mappings": [], - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "short" - }, - "overrides": [ - { - "matcher": { - "id": "byName", - "options": "dial attempts" - }, - "properties": [ - { - "id": "custom.axisPlacement", - "value": "right" - } - ] - }, - { - "matcher": { - "id": "byName", - "options": "dial attempts" - }, - "properties": [ - { - "id": "color", - "value": { - "fixedColor": "#73BF69", - "mode": "fixed" - } - } - ] - }, - { - "matcher": { - "id": "byName", - "options": "dial success" - }, - "properties": [ - { - "id": "custom.axisPlacement", - "value": "right" - } - ] - }, - { - "matcher": { - "id": "byName", - "options": "kicked peers" - }, - "properties": [ - { - "id": "custom.axisPlacement", - "value": "right" - } - ] - } - ] - }, - "gridPos": { - "h": 5, - "w": 10, - "x": 14, - "y": 36 - }, - "id": 73, - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.1.6", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "rate(libp2p_total_dial_attempts_total{namespace=\"$namespace\",pod=\"${pod}\"}[$__rate_interval])", - "interval": "", - "legendFormat": "dial attempts", - "refId": "A" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "rate(discovery_message_requests_outgoing_total{instance=\"${instance}\",response!=\"no_response\"}[$__rate_interval])", - "hide": false, - "interval": "", - "legendFormat": "discovery messages", - "refId": "B" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "rate(libp2p_successful_dials_total{namespace=\"$namespace\",pod=\"${pod}\"}[$__rate_interval])", - "hide": false, - "interval": "", - "legendFormat": "dial success", - "refId": "C" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "rate(nbc_cycling_kicked_peers_total{namespace=\"$namespace\",pod=\"${pod}\"}[$__rate_interval])", - "hide": false, - "interval": "", - "legendFormat": "kicked peers", - "refId": "D" - } - ], - "title": "Discovery & Dialing", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "links": [], - "mappings": [], - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 14, - "x": 0, - "y": 39 - }, - "id": 76, - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.1.6", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "eth1_chain_len{namespace=\"$namespace\",pod=\"${pod}\"}", - "interval": "", - "legendFormat": "Eth1 chain len", - "refId": "A" - } - ], - "title": "ETH1 Chain Length", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "links": [], - "mappings": [], - "max": 100, - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "percent" - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 10, - "x": 14, - "y": 41 - }, - "id": 24, - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.1.6", - "targets": [ - { - "expr": "beacon_state_data_cache_hits_total{namespace=\"$namespace\",pod=\"${pod}\"} * 100 / (beacon_state_data_cache_hits_total{namespace=\"$namespace\",pod=\"${pod}\"} + beacon_state_data_cache_misses_total{namespace=\"$namespace\",pod=\"${pod}\"})", - "interval": "", - "legendFormat": "cache hit rate", - "refId": "A" - } - ], - "title": "Pool Cached States", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "hidden", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "links": [], - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "short" - }, - "overrides": [ - { - "matcher": { - "id": "byRegexp", - "options": "/.*/" - }, - "properties": [ - { - "id": "unit", - "value": "bytes" - }, - { - "id": "min", - "value": 0 - }, - { - "id": "custom.axisPlacement", - "value": "auto" - } - ] - }, - { - "matcher": { - "id": "byType", - "options": "time" - }, - "properties": [ - { - "id": "custom.axisPlacement", - "value": "auto" - } - ] - } - ] - }, - "gridPos": { - "h": 6, - "w": 14, - "x": 0, - "y": 45 - }, - "id": 54, - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.1.6", - "targets": [ - { - "expr": "sqlite3_memory_used_bytes{namespace=\"$namespace\",pod=\"${pod}\"}", - "interval": "", - "legendFormat": "Memory used", - "refId": "A" - } - ], - "title": "SQLite3", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": true, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "links": [], - "mappings": [], - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "short" - }, - "overrides": [ - { - "matcher": { - "id": "byName", - "options": "sigs/aggregate" - }, - "properties": [ - { - "id": "custom.axisPlacement", - "value": "right" - } - ] - }, - { - "matcher": { - "id": "byName", - "options": "sigs/batch" - }, - "properties": [ - { - "id": "custom.axisPlacement", - "value": "right" - } - ] - } - ] - }, - "gridPos": { - "h": 5, - "w": 10, - "x": 14, - "y": 46 - }, - "id": 74, - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.1.6", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "rate(batch_verification_batches_total{namespace=\"$namespace\",pod=\"${pod}\"}[$__rate_interval])", - "interval": "", - "legendFormat": "batches", - "refId": "A" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "rate(batch_verification_signatures_total{namespace=\"$namespace\",pod=\"${pod}\"}[$__rate_interval])", - "hide": false, - "interval": "", - "legendFormat": "signatures", - "refId": "B" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "rate(batch_verification_aggregates_total{namespace=\"$namespace\",pod=\"${pod}\"}[$__rate_interval])", - "hide": false, - "interval": "", - "legendFormat": "aggregates", - "refId": "C" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "rate(batch_verification_signatures_total{namespace=\"$namespace\",pod=\"${pod}\"}[$__rate_interval]) /\nrate(batch_verification_aggregates_total{namespace=\"$namespace\",pod=\"${pod}\"}[$__rate_interval])", - "hide": false, - "interval": "", - "legendFormat": "sigs/aggregate", - "refId": "D" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "exemplar": true, - "expr": "rate(batch_verification_signatures_total{namespace=\"$namespace\",pod=\"${pod}\"}[$__rate_interval]) /\nrate(batch_verification_batches_total{namespace=\"$namespace\",pod=\"${pod}\"}[$__rate_interval])", - "hide": false, - "interval": "", - "legendFormat": "sigs/batch", - "refId": "E" - } - ], - "title": "Batch Verifications/Slot", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "links": [], - "mappings": [], - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 12, - "x": 0, - "y": 51 - }, - "id": 65, - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.1.6", - "targets": [ - { - "exemplar": true, - "expr": "rate(beacon_sync_committee_messages_received_total{namespace=\"$namespace\",pod=\"${pod}\"}[$__rate_interval])", - "interval": "", - "legendFormat": "messages", - "refId": "A" - }, - { - "exemplar": true, - "expr": "rate(beacon_sync_committee_contributions_received_total{namespace=\"$namespace\",pod=\"${pod}\"}[$__rate_interval])", - "hide": false, - "interval": "", - "legendFormat": "contributions", - "refId": "B" - } - ], - "title": "Sync Committee msgs/slot", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 10, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "never", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "links": [], - "mappings": [], - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - }, - "unit": "short" - }, - "overrides": [] - }, - "gridPos": { - "h": 6, - "w": 12, - "x": 12, - "y": 51 - }, - "id": 66, - "options": { - "legend": { - "calcs": [], - "displayMode": "list", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.1.6", - "targets": [ - { - "exemplar": true, - "expr": "rate(beacon_blocks_dropped_total{instance=\"${instance}\",reason=\"Ignore\"}[$__rate_interval])", - "interval": "", - "legendFormat": "blocks (I)", - "refId": "A" - }, - { - "exemplar": true, - "expr": "rate(beacon_attestations_dropped_total{instance=\"${instance}\",reason=\"Ignore\"}[$__rate_interval])", - "hide": false, - "interval": "", - "legendFormat": "attestations (I)", - "refId": "B" - }, - { - "exemplar": true, - "expr": "rate(beacon_aggregates_dropped_total{instance=\"${instance}\",reason=\"Ignore\"}[$__rate_interval])", - "hide": false, - "interval": "", - "legendFormat": "aggregates (I)", - "refId": "C" - }, - { - "exemplar": true, - "expr": "rate(beacon_sync_committee_messages_dropped_total{instance=\"${instance}\",reason=\"Ignore\"}[$__rate_interval])", - "hide": false, - "interval": "", - "legendFormat": "sync_msgs (I)", - "refId": "D" - }, - { - "exemplar": true, - "expr": "rate(beacon_sync_committee_contributions_dropped_total{instance=\"${instance}\",reason=\"Ignore\"}[$__rate_interval])", - "hide": false, - "interval": "", - "legendFormat": "sync_contribs (I)", - "refId": "E" - }, - { - "exemplar": true, - "expr": "rate(beacon_blocks_dropped_total{instance=\"${instance}\",reason=\"Reject\"}[$__rate_interval])", - "hide": false, - "interval": "", - "legendFormat": "blocks (R)", - "refId": "F" - }, - { - "exemplar": true, - "expr": "rate(beacon_attestations_dropped_total{instance=\"${instance}\",reason=\"Reject\"}[$__rate_interval])", - "hide": false, - "interval": "", - "legendFormat": "attestations (R)", - "refId": "G" - }, - { - "exemplar": true, - "expr": "rate(beacon_aggregates_dropped_total{instance=\"${instance}\",reason=\"Reject\"}[$__rate_interval])", - "hide": false, - "interval": "", - "legendFormat": "aggregates (R)", - "refId": "H" - }, - { - "exemplar": true, - "expr": "rate(beacon_sync_committee_messages_dropped_total{instance=\"${instance}\",reason=\"Reject\"}[$__rate_interval])", - "hide": false, - "interval": "", - "legendFormat": "sync_msgs (R)", - "refId": "I" - }, - { - "exemplar": true, - "expr": "rate(beacon_sync_committee_contributions_dropped_total{instance=\"${instance}\",reason=\"Reject\"}[$__rate_interval])", - "hide": false, - "interval": "", - "legendFormat": "sync_contribs (R)", - "refId": "J" - } - ], - "title": "Dropped msgs/slot (ignored/rejected)", - "type": "timeseries" - }, - { - "cards": {}, - "color": { - "cardColor": "#b4ff00", - "colorScale": "sqrt", - "colorScheme": "interpolateSpectral", - "exponent": 0.5, - "min": 0, - "mode": "opacity" - }, - "dataFormat": "tsbuckets", - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "gridPos": { - "h": 6, - "w": 12, - "x": 0, - "y": 57 - }, - "heatmap": {}, - "hideZeroBuckets": false, - "highlightCards": true, - "id": 26, - "interval": "", - "legend": { - "show": false - }, - "reverseYBuckets": false, - "targets": [ - { - "expr": "rate(beacon_attestation_delay_bucket{namespace=\"$namespace\",pod=\"${pod}\"}[$__rate_interval])", - "format": "heatmap", - "instant": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{le}}", - "refId": "A" - } - ], - "title": "Received Attestation Delay (s)", - "tooltip": { - "show": true, - "showHistogram": false - }, - "type": "heatmap", - "xAxis": { - "show": true - }, - "yAxis": { - "format": "short", - "logBase": 1, - "show": true - }, - "yBucketBound": "auto" - }, - { - "cards": {}, - "color": { - "cardColor": "#b4ff00", - "colorScale": "sqrt", - "colorScheme": "interpolateSpectral", - "exponent": 0.5, - "min": 0, - "mode": "opacity" - }, - "dataFormat": "tsbuckets", - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "description": "", - "gridPos": { - "h": 6, - "w": 12, - "x": 12, - "y": 57 - }, - "heatmap": {}, - "hideZeroBuckets": false, - "highlightCards": true, - "id": 52, - "interval": "", - "legend": { - "show": false - }, - "reverseYBuckets": false, - "targets": [ - { - "expr": "rate(beacon_aggregate_delay_bucket{namespace=\"$namespace\",pod=\"${pod}\"}[$__rate_interval])", - "format": "heatmap", - "instant": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{le}}", - "refId": "A" - } - ], - "title": "Received Aggregate Delay (s)", - "tooltip": { - "show": true, - "showHistogram": false - }, - "type": "heatmap", - "xAxis": { - "show": true - }, - "yAxis": { - "format": "short", - "logBase": 1, - "show": true - }, - "yBucketBound": "auto" - }, - { - "cards": {}, - "color": { - "cardColor": "#b4ff00", - "colorScale": "sqrt", - "colorScheme": "interpolateSpectral", - "exponent": 0.5, - "min": 0, - "mode": "opacity" - }, - "dataFormat": "tsbuckets", - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "description": "", - "gridPos": { - "h": 6, - "w": 12, - "x": 0, - "y": 63 - }, - "heatmap": {}, - "hideZeroBuckets": false, - "highlightCards": true, - "id": 53, - "interval": "", - "legend": { - "show": false - }, - "reverseYBuckets": false, - "targets": [ - { - "expr": "rate(beacon_block_delay_bucket{namespace=\"$namespace\",pod=\"${pod}\"}[$__rate_interval])", - "format": "heatmap", - "instant": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{le}}", - "refId": "A" - } - ], - "title": "Received Beacon Block Delay (s)", - "tooltip": { - "show": true, - "showHistogram": false - }, - "type": "heatmap", - "xAxis": { - "show": true - }, - "yAxis": { - "format": "short", - "logBase": 1, - "show": true - }, - "yBucketBound": "auto" - }, - { - "cards": {}, - "color": { - "cardColor": "#b4ff00", - "colorScale": "sqrt", - "colorScheme": "interpolateSpectral", - "exponent": 0.1, - "min": 0, - "mode": "opacity" - }, - "dataFormat": "tsbuckets", - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "gridPos": { - "h": 6, - "w": 12, - "x": 12, - "y": 63 - }, - "heatmap": {}, - "hideZeroBuckets": false, - "highlightCards": true, - "id": 50, - "interval": "", - "legend": { - "show": false - }, - "reverseYBuckets": false, - "targets": [ - { - "expr": "rate(beacon_store_block_duration_seconds_bucket{namespace=\"$namespace\",pod=\"${pod}\"}[$__rate_interval])", - "format": "heatmap", - "instant": false, - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{le}}", - "refId": "A" - } - ], - "title": "storeBlock() Duration (s)", - "tooltip": { - "show": true, - "showHistogram": false - }, - "type": "heatmap", - "xAxis": { - "show": true - }, - "yAxis": { - "format": "short", - "logBase": 1, - "show": true - }, - "yBucketBound": "auto" - } - ], - "refresh": "1m", - "schemaVersion": 35, - "style": "dark", - "tags": [ - "eth2.0", - "ethereum", - "nimbus" - ], - "templating": { - "list": [ - { - "current": { - "selected": false, - "text": "default", - "value": "default" - }, - "hide": 0, - "includeAll": false, - "multi": false, - "name": "datasource", - "options": [], - "query": "prometheus", - "queryValue": "", - "refresh": 1, - "regex": "", - "skipUrlSync": false, - "type": "datasource" - }, - { - "current": { - "selected": false, - "text": "goerli", - "value": "goerli" - }, - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "definition": "label_values(nim_gc_mem_bytes,namespace)", - "hide": 0, - "includeAll": false, - "multi": false, - "name": "namespace", - "options": [], - "query": { - "query": "label_values(nim_gc_mem_bytes,namespace)", - "refId": "StandardVariableQuery" - }, - "refresh": 1, - "regex": "", - "skipUrlSync": false, - "sort": 0, - "type": "query" - }, - { - "current": { - "selected": false, - "text": "nimbus-0", - "value": "nimbus-0" - }, - "datasource": { - "type": "prometheus", - "uid": "${datasource}" - }, - "definition": "label_values(nim_gc_mem_bytes,pod)", - "hide": 0, - "includeAll": false, - "multi": false, - "name": "pod", - "options": [], - "query": { - "query": "label_values(nim_gc_mem_bytes,pod)", - "refId": "StandardVariableQuery" - }, - "refresh": 1, - "regex": "", - "skipUrlSync": false, - "sort": 0, - "tagValuesQuery": "", - "tagsQuery": "", - "type": "query", - "useTags": false - } - ] - }, - "time": { - "from": "now-1h", - "to": "now" - }, - "timepicker": { - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ] - }, - "timezone": "", - "title": "Nimbus", - "uid": "nb3xeZbnpfNkLtFw5Ukhv5YgDu", - "version": 1, - "weekStart": "" -} \ No newline at end of file diff --git a/charts/grafana-stakewise-dashboards/dashboards/prysm.json b/charts/grafana-stakewise-dashboards/dashboards/prysm.json deleted file mode 100644 index d9938bcb9..000000000 --- a/charts/grafana-stakewise-dashboards/dashboards/prysm.json +++ /dev/null @@ -1,1101 +0,0 @@ -{ - "annotations": { - "list": [ - { - "builtIn": 1, - "datasource": "-- Grafana --", - "enable": true, - "hide": true, - "iconColor": "rgba(0, 211, 255, 1)", - "name": "Annotations & Alerts", - "target": { - "limit": 100, - "matchAny": false, - "tags": [], - "type": "dashboard" - }, - "type": "dashboard" - } - ] - }, - "description": "", - "editable": true, - "fiscalYearStartMonth": 0, - "graphTooltip": 0, - "id": 150, - "iteration": 1650533619470, - "links": [], - "liveNow": false, - "panels": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 4, - "w": 24, - "x": 0, - "y": 0 - }, - "id": 8, - "options": { - "colorMode": "background", - "graphMode": "area", - "justifyMode": "center", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "exemplar": true, - "expr": "beacon_current_active_validators{namespace=\"$namespace\",pod=\"$pod\"}", - "format": "time_series", - "interval": "", - "legendFormat": "Active Validators", - "refId": "A" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "exemplar": true, - "expr": "beacon_current_justified_epoch{namespace=\"$namespace\",pod=\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "Current Justified Epoch", - "refId": "B" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "exemplar": true, - "expr": "beacon_finalized_epoch{namespace=\"$namespace\",pod=\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "Finalized Epoch", - "refId": "C" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "exemplar": true, - "expr": "beacon_previous_justified_epoch{namespace=\"$namespace\",pod=\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "Previous Justified Epoch", - "refId": "D" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "exemplar": true, - "expr": "beacon_processed_deposits_total{namespace=\"$namespace\",pod=\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "Processed Deposits", - "refId": "E" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "exemplar": true, - "expr": "beacondb_all_deposits{namespace=\"$namespace\",pod=\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "All Deposits", - "refId": "G" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "exemplar": true, - "expr": "beacondb_pending_deposits{namespace=\"$namespace\",pod=\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "Pending Deposits", - "refId": "H" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "exemplar": true, - "expr": "beacon_reorgs_total{namespace=\"$namespace\",pod=\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "Reorgs", - "refId": "F" - } - ], - "title": "Beacon Stats", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 8, - "w": 4, - "x": 0, - "y": 4 - }, - "id": 2, - "options": { - "colorMode": "background", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "exemplar": true, - "expr": "libp2p_peers{namespace=\"$namespace\",pod=\"$pod\"}", - "interval": "", - "legendFormat": "{{pod}}", - "refId": "A" - } - ], - "title": "Peers", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 0, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "auto", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 8, - "w": 10, - "x": 4, - "y": 4 - }, - "id": 4, - "options": { - "legend": { - "calcs": [ - "min", - "max", - "mean", - "last" - ], - "displayMode": "table", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "exemplar": true, - "expr": "p2p_peer_count{namespace=\"$namespace\",pod=\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "{{state}}", - "refId": "A" - } - ], - "title": "Peers State", - "type": "timeseries" - }, - { - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "axisLabel": "", - "axisPlacement": "auto", - "barAlignment": 0, - "drawStyle": "line", - "fillOpacity": 2, - "gradientMode": "none", - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - }, - "lineInterpolation": "linear", - "lineStyle": { - "fill": "solid" - }, - "lineWidth": 1, - "pointSize": 5, - "scaleDistribution": { - "type": "linear" - }, - "showPoints": "auto", - "spanNulls": false, - "stacking": { - "group": "A", - "mode": "none" - }, - "thresholdsStyle": { - "mode": "off" - } - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "red", - "value": 80 - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 8, - "w": 10, - "x": 14, - "y": 4 - }, - "id": 6, - "options": { - "legend": { - "calcs": [ - "last", - "min", - "max", - "mean" - ], - "displayMode": "table", - "placement": "bottom" - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "exemplar": true, - "expr": "p2p_subscribed_topic_peer_total{namespace=\"$namespace\",pod=\"$pod\"}", - "interval": "", - "legendFormat": "{{topic}}", - "refId": "A" - } - ], - "title": "Peer Subscribed Topics", - "type": "timeseries" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - } - }, - "mappings": [] - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 4, - "x": 0, - "y": 12 - }, - "id": 10, - "options": { - "legend": { - "displayMode": "hidden", - "placement": "bottom", - "values": [] - }, - "pieType": "pie", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "exemplar": true, - "expr": "grpc_server_handled_total{namespace=\"$namespace\",pod=\"$pod\"}", - "interval": "", - "legendFormat": "{{grpc_service}} - {{grpc_method}}", - "refId": "A" - } - ], - "title": "GRPC Handled Total", - "type": "piechart" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - } - }, - "mappings": [] - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 4, - "x": 4, - "y": 12 - }, - "id": 11, - "options": { - "legend": { - "displayMode": "hidden", - "placement": "bottom", - "values": [] - }, - "pieType": "pie", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "exemplar": true, - "expr": "grpc_server_msg_received_total{namespace=\"$namespace\",pod=\"$pod\"}", - "interval": "", - "legendFormat": "{{grpc_service}} - {{grpc_method}}", - "refId": "A" - } - ], - "title": "GRPC MSG Received", - "type": "piechart" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - } - }, - "mappings": [] - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 4, - "x": 8, - "y": 12 - }, - "id": 12, - "options": { - "legend": { - "displayMode": "hidden", - "placement": "bottom", - "values": [] - }, - "pieType": "pie", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "exemplar": true, - "expr": "grpc_server_msg_sent_total{namespace=\"$namespace\",pod=\"$pod\"}", - "interval": "", - "legendFormat": "{{grpc_service}} - {{grpc_method}}", - "refId": "A" - } - ], - "title": "GRPC MSG Sent", - "type": "piechart" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - } - }, - "mappings": [], - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 4, - "x": 12, - "y": 12 - }, - "id": 13, - "options": { - "legend": { - "displayMode": "hidden", - "placement": "bottom", - "values": [] - }, - "pieType": "pie", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "exemplar": true, - "expr": "log_entries_total{namespace=\"$namespace\",pod=\"$pod\"}", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{level}} - {{prefix}}", - "refId": "A" - } - ], - "title": "Log Entries", - "type": "piechart" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - } - }, - "mappings": [], - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 4, - "x": 16, - "y": 12 - }, - "id": 14, - "options": { - "legend": { - "displayMode": "hidden", - "placement": "bottom" - }, - "pieType": "pie", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "exemplar": true, - "expr": "p2p_message_failed_processing_total{namespace=\"$namespace\",pod=\"$pod\"}", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{topic}}", - "refId": "A" - } - ], - "title": "P2P MSG Failed Processing", - "type": "piechart" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - } - }, - "mappings": [], - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 4, - "x": 20, - "y": 12 - }, - "id": 15, - "options": { - "legend": { - "displayMode": "hidden", - "placement": "bottom" - }, - "pieType": "pie", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "exemplar": true, - "expr": "p2p_message_failed_validation_total{namespace=\"$namespace\",pod=\"$pod\"}", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{topic}}", - "refId": "A" - } - ], - "title": "P2P MSG Failed Validation", - "type": "piechart" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - } - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 16, - "x": 0, - "y": 17 - }, - "id": 18, - "options": { - "colorMode": "background", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "exemplar": true, - "expr": "validator_count{namespace=\"$namespace\",pod=\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "{{state}}", - "refId": "A" - } - ], - "title": "Validator Count", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - } - }, - "mappings": [], - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 4, - "x": 16, - "y": 17 - }, - "id": 17, - "options": { - "legend": { - "displayMode": "hidden", - "placement": "bottom" - }, - "pieType": "pie", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "exemplar": true, - "expr": "p2p_message_received_total{namespace=\"$namespace\",pod=\"$pod\"}", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{topic}}", - "refId": "A" - } - ], - "title": "P2P MSG Received", - "type": "piechart" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "palette-classic" - }, - "custom": { - "hideFrom": { - "legend": false, - "tooltip": false, - "viz": false - } - }, - "mappings": [], - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 5, - "w": 4, - "x": 20, - "y": 17 - }, - "id": 16, - "options": { - "legend": { - "displayMode": "hidden", - "placement": "bottom" - }, - "pieType": "pie", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "tooltip": { - "mode": "multi", - "sort": "none" - } - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "exemplar": true, - "expr": "p2p_message_ignored_validation_total{namespace=\"$namespace\",pod=\"$pod\"}", - "interval": "", - "intervalFactor": 1, - "legendFormat": "{{topic}}", - "refId": "A" - } - ], - "title": "P2P MSG Ignored Validation", - "type": "piechart" - } - ], - "refresh": "1m", - "schemaVersion": 35, - "style": "dark", - "tags": [ - "eth2.0", - "ethereum", - "prysm" - ], - "templating": { - "list": [ - { - "current": { - "selected": false, - "text": "default", - "value": "default" - }, - "hide": 0, - "includeAll": false, - "multi": false, - "name": "prometheus", - "options": [], - "query": "prometheus", - "queryValue": "", - "refresh": 1, - "regex": "", - "skipUrlSync": false, - "type": "datasource" - }, - { - "current": { - "selected": false, - "text": "goerli", - "value": "goerli" - }, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "definition": "label_values(prysm_version{container=\"prysm\"}, namespace)", - "hide": 0, - "includeAll": false, - "multi": false, - "name": "namespace", - "options": [], - "query": { - "query": "label_values(prysm_version{container=\"prysm\"}, namespace)", - "refId": "StandardVariableQuery" - }, - "refresh": 1, - "regex": "", - "skipUrlSync": false, - "sort": 0, - "type": "query" - }, - { - "current": { - "selected": false, - "text": "prysm-0", - "value": "prysm-0" - }, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "definition": "label_values(prysm_version{container=\"prysm\"}, pod)", - "hide": 0, - "includeAll": false, - "multi": false, - "name": "pod", - "options": [], - "query": { - "query": "label_values(prysm_version{container=\"prysm\"}, pod)", - "refId": "StandardVariableQuery" - }, - "refresh": 1, - "regex": "", - "skipUrlSync": false, - "sort": 0, - "type": "query" - } - ] - }, - "time": { - "from": "now-1h", - "to": "now" - }, - "timepicker": {}, - "timezone": "", - "title": "Prysm", - "uid": "_67CunQ7z", - "version": 1, - "weekStart": "" -} \ No newline at end of file diff --git a/charts/grafana-stakewise-dashboards/dashboards/teku.json b/charts/grafana-stakewise-dashboards/dashboards/teku.json deleted file mode 100644 index ea4b22f85..000000000 --- a/charts/grafana-stakewise-dashboards/dashboards/teku.json +++ /dev/null @@ -1,2320 +0,0 @@ -{ - "annotations": { - "list": [ - { - "$$hashKey": "object:56", - "builtIn": 1, - "datasource": "-- Grafana --", - "enable": true, - "hide": true, - "iconColor": "rgba(0, 211, 255, 1)", - "limit": 100, - "name": "Annotations & Alerts", - "showIn": 0, - "target": { - "limit": 100, - "matchAny": false, - "tags": [], - "type": "dashboard" - }, - "type": "dashboard" - } - ] - }, - "description": "Dashboard to monitor multiple Teku instances on the same beacon chain", - "editable": true, - "fiscalYearStartMonth": 0, - "gnetId": 13457, - "graphTooltip": 1, - "id": 166, - "iteration": 1650534184996, - "links": [], - "liveNow": false, - "panels": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [ - { - "options": { - "match": "null", - "result": { - "text": "N/A" - } - }, - "type": "special" - } - ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "#5794F2", - "value": null - }, - { - "color": "#5794F2", - "value": 0 - }, - { - "color": "#5794F2", - "value": 1 - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 0 - }, - "id": 57, - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "background", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "1", - "interval": "", - "legendFormat": "VALIDATOR", - "refId": "A" - } - ], - "title": "VALIDATOR", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "Number of local validators", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "yellow", - "value": null - }, - { - "color": "green", - "value": 1 - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 5, - "x": 0, - "y": 1 - }, - "id": 36, - "options": { - "colorMode": "background", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "value" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "exemplar": false, - "expr": "sum(validator_local_validator_count{namespace=~\"$namespace\",pod=~\"$pod\"})", - "instant": true, - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Local Validators", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "Number of blocks published", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "yellow", - "value": null - }, - { - "color": "green", - "value": 1 - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 5, - "x": 5, - "y": 1 - }, - "id": 37, - "options": { - "colorMode": "background", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "value" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "sum(validator_beacon_node_published_block_total{namespace=~\"$namespace\",pod=~\"$pod\"})", - "instant": true, - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Published Blocks", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "Number of attestations published", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "yellow", - "value": null - }, - { - "color": "green", - "value": 1 - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 5, - "x": 10, - "y": 1 - }, - "id": 38, - "options": { - "colorMode": "background", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "value" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "sum(validator_beacon_node_published_attestation_total{namespace=~\"$namespace\",pod=~\"$pod\"})", - "instant": true, - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Published Attestations", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "Number of aggregates published", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "yellow", - "value": null - }, - { - "color": "green", - "value": 1 - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 5, - "x": 15, - "y": 1 - }, - "id": 39, - "options": { - "colorMode": "background", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "value" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "sum(validator_beacon_node_published_aggregate_total{namespace=~\"$namespace\",pod=~\"$pod\"})", - "instant": true, - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Published Aggregates", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "Total number of active validators in the network.", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "decimals": 0, - "displayName": "", - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 4, - "x": 20, - "y": 1 - }, - "id": 44, - "options": { - "colorMode": "background", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "value" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "max(beacon_current_active_validators{namespace=~\"$namespace\",pod=~\"$pod\"})", - "instant": true, - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Total Validators", - "type": "stat" - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "Percentage of attestations in each epoch with the correct head root, correct target root and that were successfully included in blocks.", - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 0, - "fillGradient": 1, - "gridPos": { - "h": 10, - "w": 8, - "x": 0, - "y": 4 - }, - "hiddenSeries": false, - "id": 41, - "legend": { - "alignAsTable": true, - "avg": true, - "current": true, - "max": false, - "min": false, - "show": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "validator_performance_included_attestations{namespace=~\"$namespace\",pod=~\"$pod\"} / validator_performance_expected_attestations{namespace=~\"$namespace\",pod=~\"$pod\"}", - "interval": "", - "legendFormat": "{{instance}} Included", - "refId": "C" - }, - { - "expr": "validator_performance_correct_head_block_count{namespace=~\"$namespace\",pod=~\"$pod\"} / validator_performance_included_attestations{namespace=~\"$namespace\",pod=~\"$pod\"}", - "interval": "", - "legendFormat": "{{instance}} Correct Head", - "refId": "A" - }, - { - "expr": "validator_performance_correct_target_count{namespace=~\"$namespace\",pod=~\"$pod\"} / validator_performance_included_attestations{namespace=~\"$namespace\",pod=~\"$pod\"}", - "interval": "", - "legendFormat": "{{instance}} Correct Target", - "refId": "B" - }, - { - "exemplar": true, - "expr": "\n(\nvalidator_performance_correct_head_block_count{namespace=~\"$namespace\",pod=~\"$pod\"} - (validator_performance_expected_attestations{namespace=~\"$namespace\",pod=~\"$pod\"} - validator_performance_correct_head_block_count{namespace=~\"$namespace\",pod=~\"$pod\"}) +\nvalidator_performance_correct_target_count{namespace=~\"$namespace\",pod=~\"$pod\"} - (validator_performance_expected_attestations{namespace=~\"$namespace\",pod=~\"$pod\"} - validator_performance_correct_target_count{namespace=~\"$namespace\",pod=~\"$pod\"}) +\nvalidator_performance_included_attestations{namespace=~\"$namespace\",pod=~\"$pod\"} - (validator_performance_expected_attestations{namespace=~\"$namespace\",pod=~\"$pod\"} - validator_performance_included_attestations{namespace=~\"$namespace\",pod=~\"$pod\"}) +\n(0.875 * validator_performance_included_attestations{namespace=~\"$namespace\",pod=~\"$pod\"} / validator_performance_inclusion_distance_average{namespace=~\"$namespace\",pod=~\"$pod\"})\n) / validator_performance_expected_attestations{namespace=~\"$namespace\",pod=~\"$pod\"} / 3.875", - "interval": "", - "legendFormat": "{{instance}} Attestation Rewards Earned", - "refId": "D" - }, - { - "exemplar": true, - "expr": "validator_performance_included_sync_committee_messages{namespace=~\"$namespace\",pod=~\"$pod\"} / validator_performance_expected_sync_committee_messages{namespace=~\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "{{instance}} Included Signatures", - "refId": "E" - }, - { - "exemplar": true, - "expr": "validator_performance_produced_sync_committee_messages{namespace=~\"$namespace\",pod=~\"$pod\"} / validator_performance_expected_sync_committee_messages{namespace=~\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "{{instance}} Produced Signatures", - "refId": "F" - }, - { - "exemplar": true, - "expr": "validator_performance_correct_sync_committee_messages{namespace=~\"$namespace\",pod=~\"$pod\"} / validator_performance_produced_sync_committee_messages{namespace=~\"$namespace\",pod=~\"$pod\"}", - "hide": false, - "interval": "", - "legendFormat": "{{instance}} Correct Signatures", - "refId": "G" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Attestation Performance", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:149", - "format": "percentunit", - "logBase": 1, - "max": "1", - "min": "0", - "show": true - }, - { - "$$hashKey": "object:150", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "Number of slots between when an attestation is created to when it is included in a block. The minimum possible inclusion distance is 1.", - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 0, - "fillGradient": 1, - "gridPos": { - "h": 10, - "w": 8, - "x": 8, - "y": 4 - }, - "hiddenSeries": false, - "id": 43, - "legend": { - "alignAsTable": true, - "avg": true, - "current": true, - "max": false, - "min": false, - "rightSide": false, - "show": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "validator_performance_inclusion_distance_min{namespace=~\"$namespace\",pod=~\"$pod\"}", - "interval": "", - "legendFormat": "{{instance}} Minimum", - "refId": "A" - }, - { - "expr": "validator_performance_inclusion_distance_average{namespace=~\"$namespace\",pod=~\"$pod\"}", - "interval": "", - "legendFormat": "{{instance}} Average", - "refId": "B" - }, - { - "expr": "validator_performance_inclusion_distance_max{namespace=~\"$namespace\",pod=~\"$pod\"}", - "interval": "", - "legendFormat": "{{instance}} Maximum", - "refId": "C" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Attestation Inclusion Distance (slots)", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:149", - "format": "none", - "logBase": 1, - "min": "1", - "show": true - }, - { - "$$hashKey": "object:150", - "format": "short", - "logBase": 1, - "show": false - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "Percentage of blocks produced in each epoch that were successfully included in the canonical chain.", - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 0, - "fillGradient": 1, - "gridPos": { - "h": 10, - "w": 8, - "x": 16, - "y": 4 - }, - "hiddenSeries": false, - "id": 42, - "legend": { - "alignAsTable": true, - "avg": true, - "current": true, - "max": false, - "min": false, - "rightSide": false, - "show": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "validator_performance_included_blocks{namespace=~\"$namespace\",pod=~\"$pod\"} / validator_performance_expected_blocks{namespace=~\"$namespace\",pod=~\"$pod\"}", - "interval": "", - "legendFormat": "{{instance}} Included Blocks", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Included Blocks", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:149", - "format": "percentunit", - "logBase": 1, - "max": "1", - "min": "0", - "show": true - }, - { - "$$hashKey": "object:150", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [ - { - "options": { - "match": "null", - "result": { - "text": "N/A" - } - }, - "type": "special" - } - ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "#5794F2", - "value": null - }, - { - "color": "#5794F2", - "value": 0 - }, - { - "color": "#5794F2", - "value": 1 - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 14 - }, - "id": 58, - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "background", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "1", - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "BEACON CHAIN", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "Current slot according to system time", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 5, - "x": 0, - "y": 15 - }, - "id": 45, - "options": { - "colorMode": "background", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "value" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "exemplar": false, - "expr": "max(beacon_slot{namespace=~\"$namespace\",pod=~\"$pod\"})", - "instant": true, - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Current slot", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "Slot of the latest imported block", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 5, - "x": 5, - "y": 15 - }, - "id": 48, - "options": { - "colorMode": "background", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "value" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "max(beacon_head_slot{namespace=~\"$namespace\",pod=~\"$pod\"})", - "instant": true, - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Head slot", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "Current justified epoch", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 5, - "x": 10, - "y": 15 - }, - "id": 49, - "options": { - "colorMode": "background", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "value" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "max(beacon_current_justified_epoch{namespace=~\"$namespace\",pod=~\"$pod\"})", - "instant": true, - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Justified Epoch", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "Current finalized epoch", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 5, - "x": 15, - "y": 15 - }, - "id": 51, - "options": { - "colorMode": "background", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "value" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "max(beacon_finalized_epoch{namespace=~\"$namespace\",pod=~\"$pod\"})", - "instant": true, - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Finalized Epoch", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "Total number of peers connected to the selected nodes.", - "fieldConfig": { - "defaults": { - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "red", - "value": null - }, - { - "color": "#EAB839", - "value": 25 - }, - { - "color": "green", - "value": 60 - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 4, - "x": 20, - "y": 15 - }, - "id": 64, - "links": [], - "options": { - "colorMode": "background", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "sum(beacon_peer_count{namespace=~\"$namespace\",pod=~\"$pod\"})", - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Peer Count", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "The current epoch according to system time", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 5, - "x": 0, - "y": 18 - }, - "id": 46, - "options": { - "colorMode": "background", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "value" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "max(beacon_epoch{namespace=~\"$namespace\",pod=~\"$pod\"})", - "instant": true, - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Current Epoch", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "Number of slots the head block is behind.", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "yellow", - "value": 3 - }, - { - "color": "red", - "value": 5 - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 5, - "x": 5, - "y": 18 - }, - "id": 47, - "options": { - "colorMode": "background", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "value" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "min(beacon_slot{namespace=~\"$namespace\",pod=~\"$pod\"} - beacon_head_slot{namespace=~\"$namespace\",pod=~\"$pod\"})", - "instant": true, - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Slots Behind", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "Number of epochs that justification has been delayed.", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "yellow", - "value": 2 - }, - { - "color": "red", - "value": 5 - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 5, - "x": 10, - "y": 18 - }, - "id": 50, - "options": { - "colorMode": "background", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "value" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "clamp_min(min(beacon_epoch{namespace=~\"$namespace\",pod=~\"$pod\"} - beacon_current_justified_epoch{namespace=~\"$namespace\",pod=~\"$pod\"} - 1), 0)", - "instant": true, - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Justification Delay (epochs)", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "Number of epochs that finalisation has been delayed.", - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "green", - "value": null - }, - { - "color": "yellow", - "value": 2 - }, - { - "color": "red", - "value": 5 - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 5, - "x": 15, - "y": 18 - }, - "id": 52, - "options": { - "colorMode": "background", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "auto", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "value" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "clamp_min(min(beacon_epoch{namespace=~\"$namespace\",pod=~\"$pod\"} - beacon_finalized_epoch{namespace=~\"$namespace\",pod=~\"$pod\"} - 2), 0)", - "instant": true, - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Finalisation Delay (epochs)", - "type": "stat" - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "Percentage of validators which voted for the correct target in the previous epoch.", - "fieldConfig": { - "defaults": { - "decimals": 1, - "mappings": [ - { - "$$hashKey": "object:167", - "id": 0, - "op": "=", - "text": "N/A", - "type": 1, - "value": "null" - } - ], - "max": 1, - "min": 0, - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "red", - "value": null - }, - { - "color": "#EAB839", - "value": 0.67 - }, - { - "color": "green", - "value": 0.9 - } - ] - }, - "unit": "percentunit" - }, - "overrides": [] - }, - "gridPos": { - "h": 3, - "w": 4, - "x": 20, - "y": 18 - }, - "id": 55, - "links": [], - "options": { - "colorMode": "background", - "graphMode": "area", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "lastNotNull" - ], - "fields": "", - "values": false - }, - "text": {}, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "max(beacon_previous_correct_validators{namespace=~\"$namespace\",pod=~\"$pod\"} / beacon_previous_active_validators{namespace=~\"$namespace\",pod=~\"$pod\"})", - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "Correct Attestation Rate", - "type": "stat" - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "Number of slots the head block is behind the current slot. Empty slots may mean the head block trails by a few slots.", - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 0, - "fillGradient": 1, - "gridPos": { - "h": 10, - "w": 8, - "x": 0, - "y": 21 - }, - "hiddenSeries": false, - "id": 66, - "legend": { - "alignAsTable": true, - "avg": true, - "current": true, - "hideZero": false, - "max": false, - "min": false, - "rightSide": false, - "show": true, - "sort": "current", - "sortDesc": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [ - { - "$$hashKey": "object:87", - "alias": "/.* Blocks\\/second/", - "yaxis": 2 - } - ], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "beacon_slot{namespace=~\"$namespace\",pod=~\"$pod\"} - beacon_head_slot{namespace=~\"$namespace\",pod=~\"$pod\"}", - "interval": "", - "legendFormat": "{{instance}} Head Slot", - "refId": "A" - }, - { - "expr": "clamp_min(min(beacon_epoch{namespace=~\"$namespace\",pod=~\"$pod\"} - beacon_current_justified_epoch{namespace=~\"$namespace\",pod=~\"$pod\"} - 1) without (instance), 0)", - "interval": "", - "legendFormat": "Justification Delay", - "refId": "B" - }, - { - "expr": "clamp_min(min(beacon_epoch{namespace=~\"$namespace\",pod=~\"$pod\"} - beacon_finalized_epoch{namespace=~\"$namespace\",pod=~\"$pod\"} - 2) without (instance), 0)", - "interval": "", - "legendFormat": "Finalisation Delay", - "refId": "C" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Trailing Distance", - "tooltip": { - "shared": true, - "sort": 2, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:149", - "format": "none", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:150", - "decimals": 4, - "format": "ops", - "label": "blocks/second", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "Overall participation rate in the chain. The Correct Validators must be above 2/3rd for the chain to finalize.", - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 0, - "fillGradient": 1, - "gridPos": { - "h": 10, - "w": 8, - "x": 8, - "y": 21 - }, - "hiddenSeries": false, - "id": 63, - "legend": { - "alignAsTable": true, - "avg": true, - "current": true, - "max": false, - "min": false, - "rightSide": false, - "show": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "max(beacon_previous_live_validators{namespace=~\"$namespace\",pod=~\"$pod\"} / beacon_previous_active_validators{namespace=~\"$namespace\",pod=~\"$pod\"})", - "interval": "", - "legendFormat": "Live Validators", - "refId": "A" - }, - { - "exemplar": true, - "expr": "max(beacon_previous_correct_validators{namespace=~\"$namespace\",pod=~\"$pod\"} / beacon_previous_active_validators{namespace=~\"$namespace\",pod=~\"$pod\"})", - "interval": "", - "legendFormat": "Correct Validators", - "refId": "B" - }, - { - "exemplar": true, - "expr": "max(beacon_previous_live_sync_committee{namespace=~\"$namespace\",pod=~\"$pod\"} / (512 * 32))", - "hide": false, - "interval": "", - "legendFormat": "Sync Committee Participation", - "refId": "D" - } - ], - "thresholds": [ - { - "$$hashKey": "object:1511", - "colorMode": "critical", - "fill": true, - "line": true, - "op": "lt", - "value": 0.66666666667, - "yaxis": "left" - } - ], - "timeRegions": [], - "title": "Participation Rate", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:149", - "format": "percentunit", - "logBase": 1, - "max": "1", - "min": "0", - "show": true - }, - { - "$$hashKey": "object:150", - "format": "short", - "logBase": 1, - "show": false - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "Rate of gossip messages received per second.", - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 0, - "fillGradient": 1, - "gridPos": { - "h": 10, - "w": 8, - "x": 16, - "y": 21 - }, - "hiddenSeries": false, - "id": 65, - "legend": { - "alignAsTable": true, - "avg": true, - "current": true, - "max": false, - "min": false, - "rightSide": false, - "show": true, - "sort": "current", - "sortDesc": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "irate(libp2p_gossip_messages_total{namespace=~\"$namespace\",pod=~\"$pod\"}[1m])", - "interval": "", - "legendFormat": "{{instance}} {{topic}}", - "refId": "A" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Gossip Messages", - "tooltip": { - "shared": true, - "sort": 2, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:149", - "format": "ops", - "logBase": 1, - "show": true - }, - { - "$$hashKey": "object:150", - "format": "short", - "logBase": 1, - "show": false - } - ], - "yaxis": { - "align": false - } - }, - { - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "fieldConfig": { - "defaults": { - "color": { - "mode": "thresholds" - }, - "mappings": [ - { - "options": { - "match": "null", - "result": { - "text": "N/A" - } - }, - "type": "special" - } - ], - "thresholds": { - "mode": "absolute", - "steps": [ - { - "color": "#5794F2", - "value": null - }, - { - "color": "#5794F2", - "value": 0 - }, - { - "color": "#5794F2", - "value": 1 - } - ] - }, - "unit": "none" - }, - "overrides": [] - }, - "gridPos": { - "h": 1, - "w": 24, - "x": 0, - "y": 31 - }, - "id": 62, - "links": [], - "maxDataPoints": 100, - "options": { - "colorMode": "background", - "graphMode": "none", - "justifyMode": "auto", - "orientation": "horizontal", - "reduceOptions": { - "calcs": [ - "mean" - ], - "fields": "", - "values": false - }, - "textMode": "auto" - }, - "pluginVersion": "8.4.2", - "targets": [ - { - "expr": "1", - "interval": "", - "legendFormat": "", - "refId": "A" - } - ], - "title": "SYSTEM", - "type": "stat" - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "", - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 0, - "fillGradient": 1, - "gridPos": { - "h": 10, - "w": 8, - "x": 0, - "y": 32 - }, - "hiddenSeries": false, - "id": 59, - "legend": { - "alignAsTable": true, - "avg": true, - "current": true, - "max": false, - "min": false, - "show": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "exemplar": true, - "expr": "irate(process_cpu_seconds_total{namespace=~\"$namespace\",pod=~\"$pod\"}[1m])", - "interval": "", - "legendFormat": "{{instance}} {{job}}", - "refId": "C" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "CPU usage", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:149", - "format": "none", - "logBase": 1, - "min": "0", - "show": true - }, - { - "$$hashKey": "object:150", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "", - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 0, - "fillGradient": 1, - "gridPos": { - "h": 10, - "w": 8, - "x": 8, - "y": 32 - }, - "hiddenSeries": false, - "id": 60, - "legend": { - "alignAsTable": true, - "avg": true, - "current": true, - "hideEmpty": true, - "hideZero": true, - "max": true, - "min": false, - "show": true, - "sort": "current", - "sortDesc": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "jvm_memory_pool_bytes_used{namespace=~\"$namespace\",pod=~\"$pod\"}", - "interval": "", - "legendFormat": "{{instance}} {{job}} {{pool}} Used", - "refId": "C" - }, - { - "expr": "sum by (instance) (jvm_memory_pool_bytes_used{namespace=~\"$namespace\",pod=~\"$pod\"})", - "interval": "", - "legendFormat": "{{instance}} {{job}} {{pool}} Used Total", - "refId": "A" - }, - { - "expr": "process_resident_memory_bytes{namespace=~\"$namespace\",pod=~\"$pod\"}", - "interval": "", - "legendFormat": "{{instance}} {{job}} {{pool}} Process Total", - "refId": "B" - }, - { - "expr": " (jvm_memory_pool_bytes_max{namespace=~\"$namespace\",pod=~\"$pod\"})", - "interval": "", - "legendFormat": "{{instance}} {{job}} {{pool}} Max", - "refId": "D" - }, - { - "expr": "node_memory_MemTotal_bytes{namespace=~\"$namespace\",pod=~\"$pod\"}", - "interval": "", - "legendFormat": "{{instance}} System Memory", - "refId": "E" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "Memory Usage", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:149", - "format": "bytes", - "logBase": 1, - "min": "0", - "show": true - }, - { - "$$hashKey": "object:150", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - }, - { - "aliasColors": {}, - "bars": false, - "dashLength": 10, - "dashes": false, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "description": "", - "fieldConfig": { - "defaults": { - "links": [] - }, - "overrides": [] - }, - "fill": 0, - "fillGradient": 1, - "gridPos": { - "h": 10, - "w": 8, - "x": 16, - "y": 32 - }, - "hiddenSeries": false, - "id": 61, - "legend": { - "alignAsTable": true, - "avg": true, - "current": true, - "hideEmpty": true, - "hideZero": false, - "max": true, - "min": false, - "show": true, - "total": false, - "values": true - }, - "lines": true, - "linewidth": 1, - "nullPointMode": "null", - "options": { - "alertThreshold": true - }, - "percentage": false, - "pluginVersion": "8.4.2", - "pointradius": 2, - "points": false, - "renderer": "flot", - "seriesOverrides": [], - "spaceLength": 10, - "stack": false, - "steppedLine": false, - "targets": [ - { - "expr": "rate(jvm_gc_collection_seconds_sum{namespace=~\"$namespace\",pod=~\"$pod\"}[1m])", - "interval": "", - "legendFormat": "{{instance}} {{gc}}", - "refId": "C" - } - ], - "thresholds": [], - "timeRegions": [], - "title": "GC Time", - "tooltip": { - "shared": true, - "sort": 0, - "value_type": "individual" - }, - "type": "graph", - "xaxis": { - "mode": "time", - "show": true, - "values": [] - }, - "yaxes": [ - { - "$$hashKey": "object:149", - "format": "percentunit", - "logBase": 1, - "min": "0", - "show": true - }, - { - "$$hashKey": "object:150", - "format": "short", - "logBase": 1, - "show": true - } - ], - "yaxis": { - "align": false - } - } - ], - "refresh": "1m", - "schemaVersion": 35, - "style": "dark", - "tags": [ - "eth2.0", - "ethereum", - "teku" - ], - "templating": { - "list": [ - { - "current": { - "selected": true, - "text": "default", - "value": "default" - }, - "hide": 0, - "includeAll": false, - "multi": false, - "name": "prometheus", - "options": [], - "query": "prometheus", - "queryValue": "", - "refresh": 1, - "regex": "", - "skipUrlSync": false, - "type": "datasource" - }, - { - "current": { - "selected": false, - "text": "All", - "value": "$__all" - }, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "definition": "label_values(beacon_teku_version{}, namespace)", - "hide": 0, - "includeAll": true, - "label": "namespace", - "multi": true, - "name": "namespace", - "options": [], - "query": { - "query": "label_values(beacon_teku_version{}, namespace)", - "refId": "StandardVariableQuery" - }, - "refresh": 2, - "regex": "", - "skipUrlSync": false, - "sort": 1, - "tagValuesQuery": "", - "tagsQuery": "", - "type": "query", - "useTags": false - }, - { - "current": { - "selected": false, - "text": "teku-0", - "value": "teku-0" - }, - "datasource": { - "type": "prometheus", - "uid": "${prometheus}" - }, - "definition": "label_values(beacon_teku_version{}, pod)", - "hide": 0, - "includeAll": false, - "label": "pod", - "multi": false, - "name": "pod", - "options": [], - "query": { - "query": "label_values(beacon_teku_version{}, pod)", - "refId": "StandardVariableQuery" - }, - "refresh": 1, - "regex": "", - "skipUrlSync": false, - "sort": 0, - "type": "query" - } - ] - }, - "time": { - "from": "now-1h", - "to": "now" - }, - "timepicker": { - "refresh_intervals": [ - "5s", - "10s", - "30s", - "1m", - "5m", - "15m", - "30m", - "1h", - "2h", - "1d" - ] - }, - "timezone": "", - "title": "Teku", - "uid": "qV3V4xrQZ4NF5UBpqT27mYQYQQ", - "version": 4, - "weekStart": "" -} \ No newline at end of file diff --git a/charts/grafana-stakewise-dashboards/templates/NOTES.txt b/charts/grafana-stakewise-dashboards/templates/NOTES.txt deleted file mode 100644 index a7b55d6f7..000000000 --- a/charts/grafana-stakewise-dashboards/templates/NOTES.txt +++ /dev/null @@ -1,7 +0,0 @@ -The following dashboards will be imported into Grafana: - -{{- $root := . }} -{{ range $path, $bytes := .Files.Glob "dashboards/**.json" }} --> {{ $path | replace "dashboards/" ""}} -{{- end }} - diff --git a/charts/grafana-stakewise-dashboards/templates/configmap.yaml b/charts/grafana-stakewise-dashboards/templates/configmap.yaml deleted file mode 100644 index 4f27dd42c..000000000 --- a/charts/grafana-stakewise-dashboards/templates/configmap.yaml +++ /dev/null @@ -1,35 +0,0 @@ -{{ $root := . }} - -{{- range $path, $_ := .Files.Glob "dashboards/**.json" }} -{{- with $root }} ---- -apiVersion: v1 -kind: ConfigMap -metadata: - annotations: - grafana-dashboard-folder: /tmp/dashboards/{{ $root.Values.dashboardsFolder }} - name: {{ include "common.names.fullname" $root }}-{{ $path | replace "dashboards/" "" | replace ".json" "" }} - labels: - {{- include "common.labels.standard" $root | nindent 4 }} - grafana_dashboard: "1" -data: - {{ $path | replace "dashboards/" ""}}: |- -{{ .Files.Get $path | indent 4 }} -{{- end }} -{{- end }} - -{{- range $key, $value := .Values.importFromValue }} ---- -apiVersion: v1 -kind: ConfigMap -metadata: - annotations: - grafana-dashboard-folder: /tmp/dashboards/{{ $root.Values.dashboardsFolder }} - name: {{ include "common.names.fullname" $root }}-{{ $key }} - labels: - {{- include "common.labels.standard" $root | nindent 4 }} - grafana_dashboard: "1" -data: - {{ $key }}.json: |- - {{ $value }} -{{- end }} diff --git a/charts/grafana-stakewise-dashboards/values.yaml b/charts/grafana-stakewise-dashboards/values.yaml deleted file mode 100644 index 78afd4034..000000000 --- a/charts/grafana-stakewise-dashboards/values.yaml +++ /dev/null @@ -1,9 +0,0 @@ -## Grafana dashboards folder -## -dashboardsFolder: StakeWise - -importFromValue: - # dashboardName: |- - # { - # dashboard json - # } diff --git a/charts/graph-node/Chart.lock b/charts/graph-node/Chart.lock deleted file mode 100644 index d3d911c30..000000000 --- a/charts/graph-node/Chart.lock +++ /dev/null @@ -1,12 +0,0 @@ -dependencies: -- name: common - repository: file://../common - version: 1.0.0 -- name: postgresql - repository: https://charts.bitnami.com/bitnami/ - version: 11.6.0 -- name: ipfs - repository: file://../ipfs - version: 1.0.3 -digest: sha256:9187bc479f0310eb8cfff6176af93722ab6414d10805166ad8b8fc3595cfe4aa -generated: "2022-09-19T13:05:33.777427+03:00" diff --git a/charts/graph-node/Chart.yaml b/charts/graph-node/Chart.yaml deleted file mode 100644 index dc22e33a7..000000000 --- a/charts/graph-node/Chart.yaml +++ /dev/null @@ -1,45 +0,0 @@ -apiVersion: v2 -name: graph-node -description: Graph Node indexes data from blockchains such as Ethereum and serves it over GraphQL - -# A chart can be either an 'application' or a 'library' chart. -# -# Application charts are a collection of templates that can be packaged into versioned archives -# to be deployed. -# -# Library charts provide useful utilities or functions for the chart developer. They're included as -# a dependency of application charts to inject those utilities and functions into the rendering -# pipeline. Library charts do not define any templates and therefore cannot be deployed. -type: application - -# This is the chart version. This version number should be incremented each time you make changes -# to the chart and its templates, including the app version. -# Versions are expected to follow Semantic Versioning (https://semver.org/) -version: 1.1.1 - -# This is the version number of the application being deployed. This version number should be -# incremented each time you make changes to the application. Versions are not expected to -# follow Semantic Versioning. They should reflect the version the application is using. -# It is recommended to use it with quotes. -appVersion: "v0.27.0" - -keywords: - - graph-node - - GraphQL - - Ethereum -home: https://thegraph.com/ -sources: - - https://github.com/graphprotocol/graph-node - -dependencies: - - name: common - version: 1.x.x - repository: "file://../common" - - name: postgresql - version: 11.6.0 - repository: https://charts.bitnami.com/bitnami/ - condition: postgresql.enabled - - name: ipfs - version: 1.x.x - repository: "file://../ipfs" - condition: ipfs.enabled diff --git a/charts/graph-node/templates/configmap.yaml b/charts/graph-node/templates/configmap.yaml deleted file mode 100644 index f69f0797c..000000000 --- a/charts/graph-node/templates/configmap.yaml +++ /dev/null @@ -1,21 +0,0 @@ -apiVersion: v1 -kind: ConfigMap -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -data: - ETHEREUM_POLLING_INTERVAL: {{ .Values.graph.ethereumPollingInterval | quote }} - EXPERIMENTAL_SUBGRAPH_VERSION_SWITCHING_MODE: {{ .Values.graph.experimentalSubgraphVersionSwitchingMode | quote }} - ETHEREUM_BLOCK_BATCH_SIZE: {{ .Values.graph.ethereumBlockBatchSize | quote }} - GRAPH_ETHEREUM_MAX_BLOCK_RANGE_SIZE: {{ .Values.graph.graphEthereumMaxBlockRangeSize | quote }} - STORE_CONNECTION_POOL_SIZE: {{ .Values.graph.storeConnectionPoolSize | quote }} - GRAPH_LOG: {{ .Values.graph.graphLog | quote }} - ipfs: {{ .Values.graph.ipfsUrl | quote }} - ethereum: {{ .Values.graph.ethereumNode | quote }} - - {{- with .Values.postgresql }} - postgres_host: {{ .postgresqlHost | quote }} - postgres_user: {{ .postgresqlUsername | quote }} - postgres_db: {{ .postgresqlDatabase | quote }} - {{- end }} diff --git a/charts/graph-node/templates/hpa.yaml b/charts/graph-node/templates/hpa.yaml deleted file mode 100644 index 1f3aa4a38..000000000 --- a/charts/graph-node/templates/hpa.yaml +++ /dev/null @@ -1,28 +0,0 @@ -{{- if .Values.autoscaling.enabled }} -apiVersion: autoscaling/v2beta1 -kind: HorizontalPodAutoscaler -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -spec: - scaleTargetRef: - apiVersion: apps/v1 - kind: Deployment - name: {{ include "common.names.fullname" . }} - minReplicas: {{ .Values.autoscaling.minReplicas }} - maxReplicas: {{ .Values.autoscaling.maxReplicas }} - metrics: - {{- if .Values.autoscaling.targetCPUUtilizationPercentage }} - - type: Resource - resource: - name: cpu - targetAverageUtilization: {{ .Values.autoscaling.targetCPUUtilizationPercentage }} - {{- end }} - {{- if .Values.autoscaling.targetMemoryUtilizationPercentage }} - - type: Resource - resource: - name: memory - targetAverageUtilization: {{ .Values.autoscaling.targetMemoryUtilizationPercentage }} - {{- end }} -{{- end }} diff --git a/charts/graph-node/templates/ingress.yaml b/charts/graph-node/templates/ingress.yaml deleted file mode 100644 index e4fd02cde..000000000 --- a/charts/graph-node/templates/ingress.yaml +++ /dev/null @@ -1,55 +0,0 @@ -{{- if .Values.ingress.enabled -}} -{{- $fullName := include "common.names.fullname" . -}} -{{- $svcPort := .Values.service.ports.http -}} -{{- if and .Values.ingress.className (not (semverCompare ">=1.18-0" .Capabilities.KubeVersion.GitVersion)) }} - {{- if not (hasKey .Values.ingress.annotations "kubernetes.io/ingress.class") }} - {{- $_ := set .Values.ingress.annotations "kubernetes.io/ingress.class" .Values.ingress.className}} - {{- end }} -{{- end }} -apiVersion: {{ include "common.capabilities.ingress.apiVersion" . }} -kind: Ingress -metadata: - name: {{ $fullName }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} - {{- with .Values.ingress.annotations }} - annotations: - {{- toYaml . | nindent 4 }} - {{- end }} -spec: - {{- if and .Values.ingress.className (semverCompare ">=1.18-0" .Capabilities.KubeVersion.GitVersion) }} - ingressClassName: {{ .Values.ingress.className }} - {{- end }} - {{- if .Values.ingress.tls }} - tls: - {{- range .Values.ingress.tls }} - - hosts: - {{- range .hosts }} - - {{ . | quote }} - {{- end }} - secretName: {{ .secretName }} - {{- end }} - {{- end }} - rules: - {{- range .Values.ingress.hosts }} - - host: {{ .host | quote }} - http: - paths: - {{- range .paths }} - - path: {{ .path }} - {{- if and .pathType (semverCompare ">=1.18-0" $.Capabilities.KubeVersion.GitVersion) }} - pathType: {{ .pathType }} - {{- end }} - backend: - {{- if semverCompare ">=1.19-0" $.Capabilities.KubeVersion.GitVersion }} - service: - name: {{ $fullName }} - port: - number: {{ $svcPort }} - {{- else }} - serviceName: {{ $fullName }} - servicePort: {{ $svcPort }} - {{- end }} - {{- end }} - {{- end }} -{{- end }} diff --git a/charts/graph-node/templates/prometheusrules.yaml b/charts/graph-node/templates/prometheusrules.yaml deleted file mode 100644 index 4670e3e53..000000000 --- a/charts/graph-node/templates/prometheusrules.yaml +++ /dev/null @@ -1,34 +0,0 @@ -{{- if .Values.prometheusRule.enabled }} -apiVersion: monitoring.coreos.com/v1 -kind: PrometheusRule -metadata: - name: {{ include "common.names.fullname" . }} - {{- if .Values.prometheusRule.namespace }} - namespace: {{ .Values.prometheusRule.namespace }} - {{- else }} - namespace: {{ .Release.Namespace | quote }} - {{- end }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.prometheusRule.additionalLabels }} - {{- toYaml .Values.prometheusRule.additionalLabels | nindent 4 }} - {{- end }} -spec: - groups: - {{- with .Values.prometheusRule.rules }} - - name: {{ include "common.names.fullname" $ }} - rules: {{- tpl (toYaml .) $ | nindent 8 }} - {{- end }} - {{- if .Values.prometheusRule.default }} - - name: {{ include "common.names.fullname" $ }}-default - rules: - - alert: SubgraphIsOutOfSync - expr: deployment_head < on (job,namespace) group_left ethereum_chain_head_number-50 - for: 10m - labels: - severity: critical - annotations: - summary: Subgraph {{ printf "{{ $labels.deployment }}" }} is out of sync - description: Namespace - {{ printf "{{ $labels.namespace }}" }} network - {{ printf "{{ $labels.network }}" }} - {{- end }} -{{- end }} \ No newline at end of file diff --git a/charts/graph-node/templates/secret.yaml b/charts/graph-node/templates/secret.yaml deleted file mode 100644 index 8c94aee3b..000000000 --- a/charts/graph-node/templates/secret.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: v1 -kind: Secret -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -type: Opaque -data: - postgres_pass: {{ .Values.postgresql.postgresqlPassword | b64enc | quote }} \ No newline at end of file diff --git a/charts/graph-node/templates/service.yaml b/charts/graph-node/templates/service.yaml deleted file mode 100644 index c70865d55..000000000 --- a/charts/graph-node/templates/service.yaml +++ /dev/null @@ -1,31 +0,0 @@ -apiVersion: v1 -kind: Service -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -spec: - type: {{ .Values.service.type }} - ports: - - port: {{ .Values.service.ports.http }} - targetPort: http - protocol: TCP - name: http - - port: {{ .Values.service.ports.websocket }} - targetPort: websocket - protocol: TCP - name: websocket - - port: {{ .Values.service.ports.jsonrpc }} - targetPort: jsonrpc - protocol: TCP - name: jsonrpc - - port: {{ .Values.service.ports.indexStatus }} - targetPort: index-status - protocol: TCP - name: index-status - - port: {{ .Values.service.ports.metrics }} - targetPort: metrics - protocol: TCP - name: metrics - selector: - {{- include "common.labels.matchLabels" . | nindent 4 }} diff --git a/charts/graph-node/templates/statefulset.yaml b/charts/graph-node/templates/statefulset.yaml deleted file mode 100644 index 4a9343c02..000000000 --- a/charts/graph-node/templates/statefulset.yaml +++ /dev/null @@ -1,80 +0,0 @@ -apiVersion: {{ include "common.capabilities.statefulset.apiVersion" . }} -kind: StatefulSet -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -spec: - {{- if not .Values.autoscaling.enabled }} - replicas: {{ .Values.replicaCount }} - {{- end }} - selector: - matchLabels: - {{- include "common.labels.matchLabels" . | nindent 6 }} - serviceName: {{ include "common.names.fullname" . }} - template: - metadata: - annotations: - checksum/graph-configmap: {{ include (print $.Template.BasePath "/configmap.yaml") . | sha256sum }} - checksum/graph-secret: {{ include (print $.Template.BasePath "/secret.yaml") . | sha256sum }} - {{- with .Values.podAnnotations }} - {{- toYaml . | nindent 8 }} - {{- end }} - labels: - {{- include "common.labels.matchLabels" . | nindent 8 }} - spec: - {{- with .Values.image.pullSecrets }} - imagePullSecrets: - {{- toYaml . | nindent 8 }} - {{- end }} - serviceAccountName: {{ include "common.names.serviceAccountName" . }} - securityContext: - {{- toYaml .Values.SecurityContext | nindent 8 }} - {{- with .Values.nodeSelector }} - nodeSelector: - {{- toYaml . | nindent 8 }} - {{- end }} - {{- with .Values.affinity }} - affinity: - {{- toYaml . | nindent 8 }} - {{- end }} - {{- with .Values.tolerations }} - tolerations: - {{- toYaml . | nindent 8 }} - {{- end }} - priorityClassName: {{ .Values.priorityClassName | quote }} - containers: - - name: {{ .Chart.Name }} - securityContext: - {{- toYaml .Values.securityContext | nindent 12 }} - image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}" - imagePullPolicy: {{ .Values.image.pullPolicy }} - envFrom: - - configMapRef: - name: {{ template "common.names.fullname" . }} - - secretRef: - name: {{ template "common.names.fullname" . }} - ports: - - name: http - containerPort: {{ .Values.service.ports.http }} - protocol: TCP - - name: websocket - containerPort: {{ .Values.service.ports.websocket }} - protocol: TCP - - name: jsonrpc - containerPort: {{ .Values.service.ports.jsonrpc }} - protocol: TCP - - name: index-status - containerPort: {{ .Values.service.ports.indexStatus }} - protocol: TCP - - name: metrics - containerPort: {{ .Values.service.ports.metrics }} - protocol: TCP - livenessProbe: - tcpSocket: - port: {{ .Values.service.ports.http }} - readinessProbe: - tcpSocket: - port: {{ .Values.service.ports.http }} - resources: - {{- toYaml .Values.resources | nindent 12 }} diff --git a/charts/graph-node/values.yaml b/charts/graph-node/values.yaml deleted file mode 100644 index 7a92fb0a2..000000000 --- a/charts/graph-node/values.yaml +++ /dev/null @@ -1,215 +0,0 @@ -# Default values for graph-node. -# This is a YAML-formatted file. -# Declare variables to be passed into your templates. - -global: - serviceAccount: - create: true - -replicaCount: 1 - -image: - repository: graphprotocol/graph-node - pullPolicy: IfNotPresent - # Overrides the image tag whose default is the chart appVersion. - tag: "v0.27.0" - -imagePullSecrets: [] -nameOverride: "" -fullnameOverride: "" - -## Graph Node Configuration -## -graph: - # How often to poll Ethereum for new blocks (in ms) - ethereumPollingInterval: 500 - # Control log levels - # Options: debug, error, info, warn, or trace - graphLog: "info" - # IPFS URL - ipfsUrl: graph-node-ipfs:5001 - # Ethereum Node Address - ethereumNode: mainnet:http://erigon.chain:8545 - # "instant" or "synced". Synced will only switch a named subgraph to a new deployment once it has synced, - # making the new deployment the "Pending" version - experimentalSubgraphVersionSwitchingMode: "synced" - # Number of Ethereum blocks to request in parallel. - # Also limits other parallel requests such such as trace_filter - ethereumBlockBatchSize: 250 - # Maximum number of blocks to scan for triggers in each request - graphEthereumMaxBlockRangeSize: 2000 - # How many simultaneous connections to allow to the store. - # Due to implementation details, this value may not be strictly adhered to - storeConnectionPoolSize: 25 - - -serviceAccount: - # Specifies whether a service account should be created - create: true - # Annotations to add to the service account - annotations: {} - # The name of the service account to use. - # If not set and create is true, a name is generated using the fullname template - name: "" - -service: - type: ClusterIP - ports: - # Port for the GraphQL HTTP server - http: 8000 - # Port for the GraphQL WebSocket server - websocket: 8001 - # Port for the JSON-RPC admin server - jsonrpc: 8020 - # Port for index status - indexStatus: 8030 - # Port for Prometheus Exporter - metrics: 8040 - -ingress: - enabled: false - className: "" - annotations: {} - # kubernetes.io/ingress.class: nginx - # kubernetes.io/tls-acme: "true" - hosts: - - host: chart-example.local - paths: - - path: / - pathType: ImplementationSpecific - tls: [] - # - secretName: chart-example-tls - # hosts: - # - chart-example.local - -autoscaling: - enabled: false - minReplicas: 1 - maxReplicas: 100 - targetCPUUtilizationPercentage: 80 - -## Configure resource requests and limits. -## http://kubernetes.io/docs/user-guide/compute-resources/ -## -resources: {} - -## Node labels for pod assignment -## ref: https://kubernetes.io/docs/user-guide/node-selection/ -## -nodeSelector: {} - -## Tolerations for pod assignment -## ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/ -## -tolerations: [] - -## Affinity for pod assignment -## ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity -## -affinity: {} - -## used to assign priority to pods -## ref: https://kubernetes.io/docs/concepts/configuration/pod-priority-preemption/ -## -priorityClassName: "" - -## PostgreSQL Server -## ref: https://github.com/bitnami/charts/tree/master/bitnami/postgresql -## -postgresql: - enabled: true - volumePermissions: - enabled: true - image: - registry: docker.io - repository: bitnami/bitnami-shell - tag: 10-debian-10-r98 - pullPolicy: Always - securityContext: - runAsUser: 0 - securityContext: - enabled: true - fsGroup: 1001 - containerSecurityContext: - enabled: true - runAsUser: 1001 - rbac: - create: false - postgresqlHost: graph-node-postgresql - postgresqlPort: "5432" - postgresqlUsername: "postgres" - postgresqlPassword: "graph" - usePasswordFile: true - postgresqlDatabase: graph - postgresqlDataDir: /bitnami/postgresql/data - primaryAsStandBy: - enabled: false - postgresqlSharedPreloadLibraries: "pgaudit,pg_stat_statements" - shmVolume: - enabled: true - chmod: - enabled: true - persistence: - enabled: true - mountPath: /bitnami/postgresql - subPath: '' - accessModes: - - ReadWriteOnce - size: 20Gi - annotations: { } - selector: { } - readReplicas: - persistence: - enabled: true - resources: - requests: - memory: 384Mi - cpu: 250m - networkPolicy: - enabled: false - tls: - enabled: false - metrics: - enabled: true - -## IPFS Server -## -ipfs: - enabled: true - -## Prometheus Service Monitor -## ref: https://github.com/coreos/prometheus-operator -## https://github.com/coreos/prometheus-operator/blob/master/Documentation/api.md#endpoint -## -serviceMonitor: - # Create ServiceMonitor resource(s) for scraping metrics using PrometheusOperator - enabled: false - # The namespace in which the ServiceMonitor will be created - namespace: "" - # The interval at which metrics should be scraped - interval: 30s - # The timeout after which the scrape is ended - scrapeTimeout: "" - # Metrics RelabelConfigs to apply to samples before scraping. - relabellings: [] - # Metrics RelabelConfigs to apply to samples before ingestion. - metricRelabelings: [] - # Specify honorLabels parameter to add the scrape endpoint - honorLabels: false - # Additional labels that can be used so ServiceMonitor resource(s) can be discovered by Prometheus - additionalLabels: {} - -## Custom PrometheusRule to be defined -## ref: https://github.com/coreos/prometheus-operator#customresourcedefinitions -## -prometheusRule: - # Create a custom prometheusRule Resource for scraping metrics using PrometheusOperator - enabled: false - # Create a default set of Alerts - default: true - # The namespace in which the prometheusRule will be created - namespace: "" - # Additional labels for the prometheusRule - additionalLabels: {} - # Custom Prometheus rules - rules: [] diff --git a/charts/horcrux/Chart.yaml b/charts/horcrux/Chart.yaml deleted file mode 100644 index 22c9e9aee..000000000 --- a/charts/horcrux/Chart.yaml +++ /dev/null @@ -1,17 +0,0 @@ -apiVersion: v2 -name: horcrux -version: 1.0.0 -appVersion: v1.0.0 -kubeVersion: "^1.14.0-0" -description: The StakeWise BLS hocrux. -type: application -keywords: - - ethereum - - blockchain - - staking -home: https://stakewise.io/ -sources: - - https://github.com/stakewise/bls-horcrux/ -maintainers: - - name: Dmitri Tsumak - email: dmitri@stakewise.io diff --git a/charts/horcrux/README.md b/charts/horcrux/README.md deleted file mode 100644 index 263cc92f6..000000000 --- a/charts/horcrux/README.md +++ /dev/null @@ -1,58 +0,0 @@ -# Horcrux Helm Chart - -Kubernetes Helm chart for deploying StakeWise BLS Horcrux dispatcher. - -## TL;DR; - -```bash -$ helm repo add stakewise https://charts.stakewise.io -$ helm install my-release --set dispatcher.authenticationKey="abcd1234" stakewise/horcrux -``` - -## Introduction - -Can be used to deploy StakeWise BLS Horcrux dispatcher on a [Kubernetes](http://kubernetes.io) cluster using the [Helm](https://helm.sh) package manager. - -## Prerequisites - -- Kubernetes 1.14+ -- Helm 3 - -## Installing the Chart - -To install the chart with the release name `my-release`: - -```bash -$ helm repo add stakewise https://charts.stakewise.io -$ helm install my-release stakewise/horcrux -``` - -The command deploys Horcrux dispatcher on the Kubernetes cluster in the default configuration. The [configuration](#configuration) section lists various ways to override default configuration during deployment. - -> **Tip**: List all releases using `helm list` - -## Uninstalling the Chart - -To uninstall/delete the `my-release` deployment: - -```bash -$ helm delete my-release -``` - -## Configuration - -See `values.yaml` for configuration notes. Specify each parameter using the `--set key=value[,key=value]` argument to `helm install`. For example, - -```bash -$ helm install my-release ./horcrux --set dispatcher.authenticationKey="abcd1234" -``` - -The above command specifies the authentication key for the dispatcher. - -Alternatively, a YAML file that specifies the values for the parameters can be provided while installing the chart. For example, - -```bash -$ helm install my-release stakewise/horcrux -f values.yaml -``` - -> **Tip**: You can override the default [values.yaml](values.yaml) \ No newline at end of file diff --git a/charts/horcrux/templates/_helpers.tpl b/charts/horcrux/templates/_helpers.tpl deleted file mode 100644 index d49e7c161..000000000 --- a/charts/horcrux/templates/_helpers.tpl +++ /dev/null @@ -1,33 +0,0 @@ -{{/* vim: set filetype=mustache: */}} -{{/* -Expand the name of the chart. -*/}} -{{- define "horcrux.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 "horcrux.fullname" -}} -{{- if .Values.fullnameOverride -}} -{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" -}} -{{- else -}} -{{- $name := default .Chart.Name .Values.nameOverride -}} -{{- if contains $name .Release.Name -}} -{{- printf .Release.Name | trunc 63 | trimSuffix "-" -}} -{{- else -}} -{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}} -{{- end -}} -{{- end -}} -{{- end -}} - -{{- define "dispatcher.fullname" -}} -{{- printf "%s-%s" (include "horcrux.fullname" .) "dispatcher" | trunc 63 | trimSuffix "-" -}} -{{- end -}} - -{{- define "horcrux.chart" -}} -{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" -}} -{{- end -}} diff --git a/charts/horcrux/templates/dispatcher-deployment.yaml b/charts/horcrux/templates/dispatcher-deployment.yaml deleted file mode 100644 index b2cac702b..000000000 --- a/charts/horcrux/templates/dispatcher-deployment.yaml +++ /dev/null @@ -1,82 +0,0 @@ -{{- if .Values.dispatcher.enabled }} -kind: Deployment -apiVersion: apps/v1 -metadata: - name: {{ template "dispatcher.fullname" . }} - namespace: {{ .Release.Namespace }} - labels: - app: {{ template "horcrux.name" . }} - chart: {{ template "horcrux.chart" . }} - component: "dispatcher" - release: {{ .Release.Name | quote }} - heritage: {{ .Release.Service | quote }} -spec: - replicas: 1 - selector: - matchLabels: - app: {{ template "horcrux.name" . }} - release: {{ .Release.Name | quote }} - component: "dispatcher" - template: - metadata: - labels: - app: {{ template "horcrux.name" . }} - release: {{ .Release.Name | quote }} - component: "dispatcher" - annotations: - checksum/dispatcher-secret: {{ include (print $.Template.BasePath "/dispatcher-secret.yaml") . | sha256sum }} - spec: - {{- if .Values.dispatcher.tolerations }} - tolerations: - {{ tpl .Values.dispatcher.tolerations . | nindent 8 | trim }} - {{- end }} - {{- if .Values.dispatcher.affinity }} - affinity: - {{ tpl .Values.dispatcher.affinity . | nindent 8 | trim }} - {{- end }} - {{- with .Values.securityContext }} - securityContext: - {{ toYaml . | nindent 8 | trim }} - {{- end }} - serviceAccountName: {{ template "dispatcher.fullname" . }} - priorityClassName: {{ .Values.dispatcher.priorityClassName | quote }} - containers: - - name: {{ .Chart.Name }} - image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}" - imagePullPolicy: {{ .Values.image.pullPolicy }} - command: [ "uvicorn", "--host=0.0.0.0", "--port=8000", "dispatcher.main:app" ] - envFrom: - - secretRef: - name: {{ template "dispatcher.fullname" . }} - env: - - name: DATABASE_PATH - value: "sqlite:////data/dispatcher/dispatcher.db" - {{- with .Values.dispatcher.resources }} - resources: - {{ toYaml . | nindent 12 | trim }} - {{- end }} - ports: - - name: http - containerPort: 8000 - protocol: TCP - livenessProbe: - httpGet: - path: "/health/" - port: http - timeoutSeconds: 30 - failureThreshold: 5 - periodSeconds: 60 - readinessProbe: - httpGet: - path: "/health/" - port: http - timeoutSeconds: 30 - failureThreshold: 5 - periodSeconds: 60 - volumeMounts: - - name: data - mountPath: /data/dispatcher - volumes: - - name: data - emptyDir: {} -{{- end }} diff --git a/charts/horcrux/templates/dispatcher-ingress.yaml b/charts/horcrux/templates/dispatcher-ingress.yaml deleted file mode 100644 index 8c6b62aa8..000000000 --- a/charts/horcrux/templates/dispatcher-ingress.yaml +++ /dev/null @@ -1,37 +0,0 @@ -{{- if and .Values.dispatcher.enabled .Values.dispatcher.ingress.enabled }} -{{ $fullName := include "dispatcher.fullname" . }} -{{ $ingressPath := .Values.dispatcher.ingress.path }} -apiVersion: extensions/v1beta1 -kind: Ingress -metadata: - name: {{ template "dispatcher.fullname" . }} - namespace: {{ .Release.Namespace }} - labels: - app: {{ template "horcrux.name" . }} - chart: {{ template "horcrux.chart" . }} - component: "dispatcher" - release: {{ .Release.Name | quote }} - heritage: {{ .Release.Service | quote }} - {{- with .Values.dispatcher.ingress.labels }} - {{ toYaml . | nindent 4 | trim }} - {{- end }} -{{- with .Values.dispatcher.ingress.annotations }} - annotations: - {{ toYaml . | nindent 4 | trim }} -{{- end }} -spec: -{{- with .Values.dispatcher.ingress.tls }} - tls: - {{ toYaml . | nindent 4 | trim }} -{{- end }} - rules: - {{- range .Values.dispatcher.ingress.hosts }} - - host: {{ . }} - http: - paths: - - path: {{ $ingressPath }} - backend: - serviceName: {{ $fullName }} - servicePort: http - {{- end }} -{{- end }} diff --git a/charts/horcrux/templates/dispatcher-role.yaml b/charts/horcrux/templates/dispatcher-role.yaml deleted file mode 100644 index 41911b4c3..000000000 --- a/charts/horcrux/templates/dispatcher-role.yaml +++ /dev/null @@ -1,24 +0,0 @@ -{{- if .Values.dispatcher.enabled }} -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: {{ template "dispatcher.fullname" . }} - namespace: {{ .Release.Namespace }} - labels: - app: {{ template "horcrux.name" . }} - chart: {{ template "horcrux.chart" . }} - component: "dispatcher" - release: {{ .Release.Name | quote }} - heritage: {{ .Release.Service | quote }} -rules: - - apiGroups: ["extensions"] - resources: ["podsecuritypolicies"] - verbs: ["use"] - resourceNames: - - {{ template "horcrux.fullname" . }} - - apiGroups: [""] - resources: ["secrets"] - resourceNames: - - {{ template "dispatcher.fullname" . }} - verbs: ["get"] -{{- end }} diff --git a/charts/horcrux/templates/dispatcher-rolebinding.yaml b/charts/horcrux/templates/dispatcher-rolebinding.yaml deleted file mode 100644 index 0a2eb1ef0..000000000 --- a/charts/horcrux/templates/dispatcher-rolebinding.yaml +++ /dev/null @@ -1,21 +0,0 @@ -{{- if .Values.dispatcher.enabled }} -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: {{ template "dispatcher.fullname" . }} - namespace: {{ .Release.Namespace }} - labels: - app: {{ template "horcrux.name" . }} - chart: {{ template "horcrux.chart" . }} - component: "dispatcher" - release: {{ .Release.Name | quote }} - heritage: {{ .Release.Service | quote }} -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: {{ template "dispatcher.fullname" . }} -subjects: - - kind: ServiceAccount - name: {{ template "dispatcher.fullname" . }} - namespace: {{ .Release.Namespace }} -{{- end }} diff --git a/charts/horcrux/templates/dispatcher-secret.yaml b/charts/horcrux/templates/dispatcher-secret.yaml deleted file mode 100644 index 51a369411..000000000 --- a/charts/horcrux/templates/dispatcher-secret.yaml +++ /dev/null @@ -1,16 +0,0 @@ -{{- if .Values.dispatcher.enabled }} -apiVersion: v1 -kind: Secret -metadata: - name: {{ template "dispatcher.fullname" . }} - namespace: {{ .Release.Namespace }} - labels: - app: {{ template "horcrux.name" . }} - chart: {{ template "horcrux.chart" . }} - component: "dispatcher" - release: {{ .Release.Name | quote }} - heritage: {{ .Release.Service | quote }} -type: Opaque -data: - AUTHENTICATION_KEY: {{ .Values.dispatcher.authenticationKey | b64enc | quote }} -{{- end }} diff --git a/charts/horcrux/templates/dispatcher-service.yaml b/charts/horcrux/templates/dispatcher-service.yaml deleted file mode 100644 index 35fa77706..000000000 --- a/charts/horcrux/templates/dispatcher-service.yaml +++ /dev/null @@ -1,24 +0,0 @@ -{{- if .Values.dispatcher.enabled }} -apiVersion: v1 -kind: Service -metadata: - name: {{ template "dispatcher.fullname" . }} - namespace: {{ .Release.Namespace }} - labels: - app: {{ template "horcrux.name" . }} - chart: {{ template "horcrux.chart" . }} - component: "dispatcher" - release: {{ .Release.Name | quote }} - heritage: {{ .Release.Service | quote }} -spec: - type: {{ .Values.dispatcher.serviceType | default "ClusterIP" }} - ports: - - name: http - port: 80 - protocol: TCP - targetPort: http - selector: - app: {{ template "horcrux.name" . }} - component: "dispatcher" - release: {{ .Release.Name }} -{{- end }} diff --git a/charts/horcrux/templates/dispatcher-serviceaccount.yaml b/charts/horcrux/templates/dispatcher-serviceaccount.yaml deleted file mode 100644 index f68e0ee48..000000000 --- a/charts/horcrux/templates/dispatcher-serviceaccount.yaml +++ /dev/null @@ -1,16 +0,0 @@ -{{- if .Values.dispatcher.enabled }} -apiVersion: v1 -kind: ServiceAccount -{{- if .Values.image.pullSecrets }} -imagePullSecrets: {{ toYaml .Values.image.pullSecrets | nindent 2 }} -{{- end }} -metadata: - name: {{ template "dispatcher.fullname" . }} - namespace: {{ .Release.Namespace }} - labels: - app: {{ template "horcrux.name" . }} - chart: {{ template "horcrux.chart" . }} - component: "dispatcher" - release: {{ .Release.Name | quote }} - heritage: {{ .Release.Service | quote }} -{{- end }} diff --git a/charts/horcrux/templates/podsecuritypolicy.yaml b/charts/horcrux/templates/podsecuritypolicy.yaml deleted file mode 100644 index 2a0b57f8b..000000000 --- a/charts/horcrux/templates/podsecuritypolicy.yaml +++ /dev/null @@ -1,44 +0,0 @@ -{{- if .Values.dispatcher.enabled }} -apiVersion: policy/v1beta1 -kind: PodSecurityPolicy -metadata: - name: {{ template "horcrux.fullname" . }} - namespace: {{ .Release.Namespace }} - labels: - app: {{ template "horcrux.name" . }} - chart: {{ template "horcrux.chart" . }} - release: {{ .Release.Name | quote }} - heritage: {{ .Release.Service | quote }} -spec: - privileged: false - allowPrivilegeEscalation: false - requiredDropCapabilities: - - ALL - volumes: - - 'configMap' - - 'emptyDir' - - 'projected' - - 'secret' - - 'downwardAPI' - - 'persistentVolumeClaim' - hostNetwork: false - hostIPC: false - hostPID: false - runAsUser: - rule: 'MustRunAsNonRoot' - seLinux: - rule: 'RunAsAny' - supplementalGroups: - rule: 'MustRunAs' - ranges: - # Forbid adding the root group. - - min: 1 - max: 65535 - fsGroup: - rule: 'MustRunAs' - ranges: - # Forbid adding the root group. - - min: 1 - max: 65535 - readOnlyRootFilesystem: false -{{- end }} diff --git a/charts/horcrux/values.yaml b/charts/horcrux/values.yaml deleted file mode 100644 index 2e2052493..000000000 --- a/charts/horcrux/values.yaml +++ /dev/null @@ -1,47 +0,0 @@ -securityContext: - fsGroup: 1001 - runAsUser: 1001 - -image: - repository: "stakewiselabs/bls-horcrux" - tag: "v1.0.0" - pullPolicy: IfNotPresent - pullSecrets: [ ] - -dispatcher: - # Whether to deploy dispatcher or not. - enabled: true - - authenticationKey: "" - - # For GKE load balancer ingress to work, the service type must be NodePort - # https://cloud.google.com/kubernetes-engine/docs/concepts/ingress - serviceType: ClusterIP - - # Configure ingress - # https://kubernetes.io/docs/concepts/services-networking/ingress/ - ingress: - enabled: false - annotations: { } - tls: [ ] - path: "/*" - hosts: [ ] - - # Configure resource requests and limits. - # http://kubernetes.io/docs/user-guide/compute-resources/ - resources: - requests: - cpu: 10m - memory: 150Mi - - # Affinity Settings - # https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity - affinity: { } - - # Toleration Settings - # https://kubernetes.io/docs/concepts/scheduling-eviction/taint-and-toleration/ - tolerations: [ ] - - # used to assign priority to pods - # ref: https://kubernetes.io/docs/concepts/configuration/pod-priority-preemption/ - priorityClassName: "" diff --git a/charts/ipfs/Chart.yaml b/charts/ipfs/Chart.yaml deleted file mode 100644 index 910b4e9b7..000000000 --- a/charts/ipfs/Chart.yaml +++ /dev/null @@ -1,36 +0,0 @@ -apiVersion: v2 -name: ipfs -description: IPFS implementation in Go - -# A chart can be either an 'application' or a 'library' chart. -# -# Application charts are a collection of templates that can be packaged into versioned archives -# to be deployed. -# -# Library charts provide useful utilities or functions for the chart developer. They're included as -# a dependency of application charts to inject those utilities and functions into the rendering -# pipeline. Library charts do not define any templates and therefore cannot be deployed. -type: application - -# This is the chart version. This version number should be incremented each time you make changes -# to the chart and its templates, including the app version. -# Versions are expected to follow Semantic Versioning (https://semver.org/) -version: 1.0.3 - -# This is the version number of the application being deployed. This version number should be -# incremented each time you make changes to the application. Versions are not expected to -# follow Semantic Versioning. They should reflect the version the application is using. -# It is recommended to use it with quotes. -appVersion: "v0.15.0" - -keywords: - - ipfs - - p2p -home: https://ipfs.io -sources: - - https://github.com/ipfs/go-ipfs - -dependencies: -- name: common - repository: file://../common - version: 1.0.0 diff --git a/charts/ipfs/templates/configmap.yaml b/charts/ipfs/templates/configmap.yaml deleted file mode 100644 index 3a6ded9b0..000000000 --- a/charts/ipfs/templates/configmap.yaml +++ /dev/null @@ -1,15 +0,0 @@ -apiVersion: v1 -kind: ConfigMap -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -data: - IPFS_PATH: {{ .Values.ipfs.path | quote }} - IPFS_PROFILE: {{ .Values.ipfs.profile | quote }} - IPFS_FD_MAX: {{ .Values.ipfs.fdMax | quote }} - LIBP2P_TCP_REUSEPORT: {{ .Values.ipfs.tcpReusePort | quote }} - IPFS_LOGGING: {{ .Values.ipfs.logging | quote }} - IPFS_LOGGING_FMT: {{ .Values.ipfs.loggingFmt | quote }} - IPFS_FUSE_DEBUG: {{ .Values.ipfs.fuseDebug | quote }} - YAMUX_DEBUG: {{ .Values.ipfs.yamuxDebug | quote }} diff --git a/charts/ipfs/templates/entrypoint.yaml b/charts/ipfs/templates/entrypoint.yaml deleted file mode 100644 index b485e7e35..000000000 --- a/charts/ipfs/templates/entrypoint.yaml +++ /dev/null @@ -1,65 +0,0 @@ -apiVersion: v1 -kind: ConfigMap -metadata: - name: {{ include "common.names.fullname" . }}-entrypoint - labels: - {{- include "common.labels.standard" . | nindent 4 }} -data: - start_ipfs: | - #!/bin/sh - set -e - user=ipfs - repo="$IPFS_PATH" - - if [ `id -u` -eq 0 ]; then - echo "Changing user to $user" - # ensure folder is writable - su-exec "$user" test -w "$repo" || chown -R -- "$user" "$repo" - # restart script with new privileges - exec su-exec "$user" "$0" "$@" - fi - - # 2nd invocation with regular user - ipfs version - - if [ -e "$repo/config" ]; then - echo "Found IPFS fs-repo at $repo" - else - case "$IPFS_PROFILE" in - "") INIT_ARGS="" ;; - *) INIT_ARGS="--profile=$IPFS_PROFILE" ;; - esac - ipfs init $INIT_ARGS - ipfs config Addresses.API /ip4/0.0.0.0/tcp/5001 - ipfs config Addresses.Gateway /ip4/0.0.0.0/tcp/8080 - ipfs config --json Peering.Peers "[{\"Addrs\":[\"/ip6/2606:4700:60::6/tcp/4009\",\"/ip4/172.65.0.13/tcp/4009\"],\"ID\": \"QmcfgsJsMtx6qJb74akCw1M24X1zFwgGo11h1cuhwQjtJP\"},{\"Addrs\":[\"/dnsaddr/fra1-1.hostnodes.pinata.cloud\"],\"ID\": \"QmWaik1eJcGHq1ybTWe7sezRfqKNcDRNkeBaLnGwQJz1Cj\"},{\"Addrs\":[\"/dnsaddr/fra1-2.hostnodes.pinata.cloud\"],\"ID\": \"QmNfpLrQQZr5Ns9FAJKpyzgnDL2GgC6xBug1yUZozKFgu4\"},{\"Addrs\":[\"/dnsaddr/fra1-3.hostnodes.pinata.cloud\"],\"ID\": \"QmPo1ygpngghu5it8u4Mr3ym6SEU2Wp2wA66Z91Y1S1g29\"},{\"Addrs\":[\"/dnsaddr/nyc1-1.hostnodes.pinata.cloud\"],\"ID\": \"QmRjLSisUCHVpFa5ELVvX3qVPfdxajxWJEHs9kN3EcxAW6\"},{\"Addrs\":[\"/dnsaddr/nyc1-2.hostnodes.pinata.cloud\"],\"ID\": \"QmPySsdmbczdZYBpbi2oq2WMJ8ErbfxtkG8Mo192UHkfGP\"},{\"Addrs\":[\"/dnsaddr/nyc1-3.hostnodes.pinata.cloud\"],\"ID\": \"QmSarArpxemsPESa6FNkmuu9iSE1QWqPX2R3Aw6f5jq4D5\"},{\"Addrs\":[\"/dns/cluster0.fsn.dwebops.pub\"],\"ID\": \"QmUEMvxS2e7iDrereVYc5SWPauXPyNwxcy9BXZrC1QTcHE\"},{\"Addrs\":[\"/dns/cluster1.fsn.dwebops.pub\"],\"ID\": \"QmNSYxZAiJHeLdkBg38roksAR9So7Y5eojks1yjEcUtZ7i\"},{\"Addrs\":[\"/dns/cluster2.fsn.dwebops.pub\"],\"ID\": \"QmUd6zHcbkbcs7SMxwLs48qZVX3vpcM8errYS7xEczwRMA\"},{\"Addrs\":[\"/dns/cluster3.fsn.dwebops.pub\"],\"ID\": \"QmbVWZQhCGrS7DhgLqWbgvdmKN7JueKCREVanfnVpgyq8x\"},{\"Addrs\":[\"/dns/cluster4.fsn.dwebops.pub\"],\"ID\": \"QmdnXwLrC8p1ueiq2Qya8joNvk3TVVDAut7PrikmZwubtR\"},{\"Addrs\":[\"/dns4/nft-storage-am6.nft.dwebops.net/tcp/18402\"],\"ID\": \"12D3KooWCRscMgHgEo3ojm8ovzheydpvTEqsDtq7Vby38cMHrYjt\"},{\"Addrs\":[\"/dns4/nft-storage-dc13.nft.dwebops.net/tcp/18402\"],\"ID\": \"12D3KooWQtpvNvUYFzAo1cRYkydgk15JrMSHp6B6oujqgYSnvsVm\"},{\"Addrs\":[\"/dns4/nft-storage-sv15.nft.dwebops.net/tcp/18402\"],\"ID\": \"12D3KooWQcgCwNCTYkyLXXQSZuL5ry1TzpM8PRe9dKddfsk1BxXZ\"},{\"Addrs\":[\"/ip4/104.210.43.77\"],\"ID\": \"QmR69wtWUMm1TWnmuD4JqC1TWLZcc8iR2KrTenfZZbiztd\"}]" - - # Set up the swarm key, if provided - - SWARM_KEY_FILE="$repo/swarm.key" - SWARM_KEY_PERM=0400 - - # Create a swarm key from a given environment variable - if [ ! -z "$IPFS_SWARM_KEY" ] ; then - echo "Copying swarm key from variable..." - echo -e "$IPFS_SWARM_KEY" >"$SWARM_KEY_FILE" || exit 1 - chmod $SWARM_KEY_PERM "$SWARM_KEY_FILE" - fi - - # Unset the swarm key variable - unset IPFS_SWARM_KEY - - # Check during initialization if a swarm key was provided and - # copy it to the ipfs directory with the right permissions - # WARNING: This will replace the swarm key if it exists - if [ ! -z "$IPFS_SWARM_KEY_FILE" ] ; then - echo "Copying swarm key from file..." - install -m $SWARM_KEY_PERM "$IPFS_SWARM_KEY_FILE" "$SWARM_KEY_FILE" || exit 1 - fi - - # Unset the swarm key file variable - unset IPFS_SWARM_KEY_FILE - - fi - - exec ipfs "$@" diff --git a/charts/ipfs/templates/ingress.yaml b/charts/ipfs/templates/ingress.yaml deleted file mode 100644 index c8ec42f46..000000000 --- a/charts/ipfs/templates/ingress.yaml +++ /dev/null @@ -1,124 +0,0 @@ -{{- if .Values.ingress.api.enabled -}} -{{- $fullName := include "common.names.fullname" . -}} -{{- $svcPort := .Values.service.ports.api -}} -{{- if and .Values.ingress.api.className (not (semverCompare ">=1.18-0" .Capabilities.KubeVersion.GitVersion)) }} - {{- if not (hasKey .Values.ingress.api.annotations "kubernetes.io/ingress.class") }} - {{- $_ := set .Values.ingress.api.annotations "kubernetes.io/ingress.class" .Values.ingress.api.className}} - {{- end }} -{{- end }} -{{- if semverCompare ">=1.19-0" .Capabilities.KubeVersion.GitVersion -}} -apiVersion: networking.k8s.io/v1 -{{- else if semverCompare ">=1.14-0" .Capabilities.KubeVersion.GitVersion -}} -apiVersion: networking.k8s.io/v1beta1 -{{- else -}} -apiVersion: extensions/v1beta1 -{{- end }} -kind: Ingress -metadata: - name: {{ $fullName }}-api - labels: - {{- include "common.labels.standard" . | nindent 4 }} - {{- with .Values.ingress.api.annotations }} - annotations: - {{- toYaml . | nindent 4 }} - {{- end }} -spec: - {{- if and .Values.ingress.api.className (semverCompare ">=1.18-0" .Capabilities.KubeVersion.GitVersion) }} - ingressClassName: {{ .Values.ingress.api.className }} - {{- end }} - {{- if .Values.ingress.api.tls }} - tls: - {{- range .Values.ingress.api.tls }} - - hosts: - {{- range .hosts }} - - {{ . | quote }} - {{- end }} - secretName: {{ .secretName }} - {{- end }} - {{- end }} - rules: - {{- range .Values.ingress.api.hosts }} - - host: {{ .host | quote }} - http: - paths: - {{- range .paths }} - - path: {{ .path }} - {{- if and .pathType (semverCompare ">=1.18-0" $.Capabilities.KubeVersion.GitVersion) }} - pathType: {{ .pathType }} - {{- end }} - backend: - {{- if semverCompare ">=1.19-0" $.Capabilities.KubeVersion.GitVersion }} - service: - name: {{ $fullName }} - port: - number: {{ $svcPort }} - {{- else }} - serviceName: {{ $fullName }} - servicePort: {{ $svcPort }} - {{- end }} - {{- end }} - {{- end }} -{{- end }} - -{{- if .Values.ingress.gateway.enabled }} ---- -{{- $fullName := include "common.names.fullname" . -}} -{{- $svcPort := .Values.service.ports.gateway -}} -{{- if and .Values.ingress.gateway.className (not (semverCompare ">=1.18-0" .Capabilities.KubeVersion.GitVersion)) }} - {{- if not (hasKey .Values.ingress.gateway.annotations "kubernetes.io/ingress.class") }} - {{- $_ := set .Values.ingress.gateway.annotations "kubernetes.io/ingress.class" .Values.ingress.gateway.className}} - {{- end }} -{{- end }} -{{- if semverCompare ">=1.19-0" .Capabilities.KubeVersion.GitVersion -}} -apiVersion: networking.k8s.io/v1 -{{- else if semverCompare ">=1.14-0" .Capabilities.KubeVersion.GitVersion -}} -apiVersion: networking.k8s.io/v1beta1 -{{- else -}} -apiVersion: extensions/v1beta1 -{{- end }} -kind: Ingress -metadata: - name: {{ $fullName }}-gateway - labels: - {{- include "common.labels.standard" . | nindent 4 }} - {{- with .Values.ingress.gateway.annotations }} - annotations: - {{- toYaml . | nindent 4 }} - {{- end }} -spec: - {{- if and .Values.ingress.gateway.className (semverCompare ">=1.18-0" .Capabilities.KubeVersion.GitVersion) }} - ingressClassName: {{ .Values.ingress.gateway.className }} - {{- end }} - {{- if .Values.ingress.gateway.tls }} - tls: - {{- range .Values.ingress.gateway.tls }} - - hosts: - {{- range .hosts }} - - {{ . | quote }} - {{- end }} - secretName: {{ .secretName }} - {{- end }} - {{- end }} - rules: - {{- range .Values.ingress.gateway.hosts }} - - host: {{ .host | quote }} - http: - paths: - {{- range .paths }} - - path: {{ .path }} - {{- if and .pathType (semverCompare ">=1.18-0" $.Capabilities.KubeVersion.GitVersion) }} - pathType: {{ .pathType }} - {{- end }} - backend: - {{- if semverCompare ">=1.19-0" $.Capabilities.KubeVersion.GitVersion }} - service: - name: {{ $fullName }} - port: - number: {{ $svcPort }} - {{- else }} - serviceName: {{ $fullName }} - servicePort: {{ $svcPort }} - {{- end }} - {{- end }} - {{- end }} -{{- end }} diff --git a/charts/ipfs/templates/service.yaml b/charts/ipfs/templates/service.yaml deleted file mode 100644 index 6a0ffae5d..000000000 --- a/charts/ipfs/templates/service.yaml +++ /dev/null @@ -1,31 +0,0 @@ -apiVersion: v1 -kind: Service -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -spec: - type: {{ .Values.service.type }} - ports: - - port: {{ .Values.service.ports.p2p }} - targetPort: p2p-tcp - protocol: TCP - name: p2p-tcp - - port: {{ .Values.service.ports.p2p }} - targetPort: p2p-udp - protocol: UDP - name: p2p-udp - - port: {{ .Values.service.ports.api }} - targetPort: api - protocol: TCP - name: api - - port: {{ .Values.service.ports.gateway }} - targetPort: gateway - protocol: TCP - name: gateway - - port: {{ .Values.service.ports.websocket }} - targetPort: websocket - protocol: TCP - name: websocket - selector: - {{- include "common.labels.matchLabels" . | nindent 4 }} diff --git a/charts/ipfs/templates/serviceaccount.yaml b/charts/ipfs/templates/serviceaccount.yaml deleted file mode 100644 index ad5aa4d50..000000000 --- a/charts/ipfs/templates/serviceaccount.yaml +++ /dev/null @@ -1,12 +0,0 @@ -{{- if .Values.serviceAccount.create -}} -apiVersion: v1 -kind: ServiceAccount -metadata: - name: {{ include "common.names.serviceAccountName" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} - {{- with .Values.serviceAccount.annotations }} - annotations: - {{- toYaml . | nindent 4 }} - {{- end }} -{{- end }} diff --git a/charts/ipfs/templates/statefulset.yaml b/charts/ipfs/templates/statefulset.yaml deleted file mode 100644 index c708b5779..000000000 --- a/charts/ipfs/templates/statefulset.yaml +++ /dev/null @@ -1,141 +0,0 @@ -kind: StatefulSet -apiVersion: {{ include "common.capabilities.statefulset.apiVersion" . }} -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -spec: - selector: - matchLabels: - {{- include "common.labels.matchLabels" . | nindent 6 }} - serviceName: {{ include "common.names.fullname" . }} - replicas: {{ .Values.replicaCount }} - template: - metadata: - labels: - {{- include "common.labels.matchLabels" . | nindent 8 }} - spec: - {{- with .Values.affinity }} - affinity: - {{ toYaml . | nindent 8 | trim }} - {{- end }} - {{- with .Values.tolerations }} - tolerations: - {{ toYaml . | nindent 8 | trim }} - {{- end }} - {{- with .Values.nodeSelector }} - nodeSelector: - {{ toYaml . | nindent 8 | trim }} - {{- end }} - {{- with .Values.securityContext }} - securityContext: - {{ toYaml . | nindent 8 | trim }} - {{- end }} - serviceAccountName: {{ include "common.names.serviceAccountName" . }} - priorityClassName: {{ .Values.priorityClassName | quote }} - {{- if and .Values.persistence.enabled .Values.initChownData }} - initContainers: - - name: init-chown - image: "{{ .Values.initImage.repository }}:{{ .Values.initImage.tag }}" - imagePullPolicy: {{ .Values.initImage.pullPolicy }} - securityContext: - runAsUser: 0 - command: ["chown", "-R", "{{ .Values.securityContext.runAsUser }}:{{ .Values.securityContext.runAsUser }}", "{{ .Values.ipfs.path }}"] - volumeMounts: - - name: data - mountPath: {{ .Values.ipfs.path }} - {{- end }} - containers: - - name: {{ include "common.names.fullname" . }} - image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}" - imagePullPolicy: {{ .Values.image.pullPolicy }} - envFrom: - - configMapRef: - name: {{ include "common.names.fullname" . }} - ports: - - containerPort: {{ .Values.service.ports.p2p }} - name: p2p-tcp - protocol: TCP - - containerPort: {{ .Values.service.ports.p2p }} - name: p2p-udp - protocol: UDP - - containerPort: {{ .Values.service.ports.api }} - name: api - protocol: TCP - - containerPort: {{ .Values.service.ports.gateway }} - name: gateway - protocol: TCP - - containerPort: {{ .Values.service.ports.websocket }} - name: websocket - protocol: TCP - volumeMounts: - - name: data - mountPath: {{ .Values.ipfs.path }} - - name: fuse-ipfs - mountPath: /ipfs - - name: fuse-ipns - mountPath: /ipns - - name: entrypoint - subPath: start_ipfs - mountPath: /usr/local/bin/start_ipfs - livenessProbe: - httpGet: - path: /debug/metrics/prometheus - port: api - initialDelaySeconds: 15 - periodSeconds: 3 - readinessProbe: - httpGet: - path: /debug/metrics/prometheus - port: api - initialDelaySeconds: 15 - periodSeconds: 3 - {{- with .Values.resources }} - resources: - {{ toYaml . | nindent 12 | trim }} - {{- end }} - volumes: - - name: entrypoint - configMap: - name: {{ include "common.names.fullname" . }}-entrypoint - defaultMode: 0777 -{{- if (not .Values.persistence.enabled) }} - - name: data - emptyDir: {} - - name: fuse-ipfs - emptyDir: {} - - name: fuse-ipns - emptyDir: {} -{{- else }} - volumeClaimTemplates: - - metadata: - name: data - labels: - {{- include "common.labels.standard" . | nindent 10 }} - spec: - accessModes: {{ .Values.persistence.accessModes }} - storageClassName: {{ .Values.persistence.storageClassName }} - resources: - requests: - storage: {{ .Values.persistence.dataSize | quote }} - - metadata: - name: fuse-ipfs - labels: - {{- include "common.labels.standard" . | nindent 10 }} - spec: - accessModes: {{ .Values.persistence.accessModes }} - storageClassName: {{ .Values.persistence.storageClassName }} - resources: - requests: - storage: {{ .Values.persistence.fuseIpfsSize | quote }} - - metadata: - name: fuse-ipns - labels: - {{- include "common.labels.standard" . | nindent 10 }} - spec: - accessModes: {{ .Values.persistence.accessModes }} - storageClassName: {{ .Values.persistence.storageClassName }} - resources: - requests: - storage: {{ .Values.persistence.fuseIpnsSize | quote }} -{{- end }} diff --git a/charts/ipfs/templates/vpa.yaml b/charts/ipfs/templates/vpa.yaml deleted file mode 100644 index 8b579cbcb..000000000 --- a/charts/ipfs/templates/vpa.yaml +++ /dev/null @@ -1,20 +0,0 @@ -{{- if .Values.verticalAutoscaler.enabled }} -apiVersion: autoscaling.k8s.io/v1beta2 -kind: VerticalPodAutoscaler -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -spec: - targetRef: - apiVersion: "apps/v1" - kind: StatefulSet - name: {{ include "common.names.fullname" . }} - updatePolicy: - updateMode: {{ .Values.verticalAutoscaler.updateMode | default "Off" | quote }} - {{- if .Values.verticalAutoscaler.containerPolicies }} - resourcePolicy: - containerPolicies: - {{ tpl .Values.verticalAutoscaler.containerPolicies . | nindent 6 | trim }} - {{- end }} -{{- end }} diff --git a/charts/ipfs/values.yaml b/charts/ipfs/values.yaml deleted file mode 100644 index 68aa13750..000000000 --- a/charts/ipfs/values.yaml +++ /dev/null @@ -1,172 +0,0 @@ -# Default values for ipfs. -# This is a YAML-formatted file. -# Declare variables to be passed into your templates. - -global: - serviceAccount: - create: true - -## How many ipfs instances to run simultaneously -## -replicaCount: 1 - -## Pod Security Context -## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/ -## -securityContext: - fsGroup: 1001 - runAsUser: 1001 - -## Init image is used to chown data volume, initialise genesis, etc. -## -initImage: - repository: "busybox" - tag: "1.34" - pullPolicy: IfNotPresent - -image: - repository: ipfs/go-ipfs - pullPolicy: IfNotPresent - # Overrides the image tag whose default is the chart appVersion. - tag: "v0.15.0" - -imagePullSecrets: [] -nameOverride: "" -fullnameOverride: "" - -## IPFS Configuration -## -ipfs: - # Data Path - path: /data/ipfs - # The profile of your IPFS node allows you to specify which - # file-system or data-store you want to use. - # Changing these options will affect the performance of your node. - # For example, if you want to have a faster datastore for your node, - # you can use the badgerds profile. If you're running your node on - # a low-power device like a Raspberry Pi, you can use the lowpower profile. - # Profiles have been developed to customize your IPFS node to perform - # best under given conditions. - profile: server - # Sets the file descriptor limit for go-ipfs. - # If go-ipfs fails to set the file descriptor limit, it will log an error. - fdMax: "8192" - # go-ipfs tries to reuse the same source port for all connections - # to improve NAT traversal. - tcpReusePort: "true" - # Sets the log level for go-ipfs. It can be set to one of: - # CRITICAL, ERROR, WARNING, NOTICE, INFO, DEBUG - logging: error - # Sets the log message format. Can be one of: - # color, nocolor - loggingFmt: color - # Enables fuse debug logging. - fuseDebug: "false" - # Enables debug logging for the yamux stream muxer. - yamuxDebug: "false" - -serviceAccount: - # Specifies whether a service account should be created - create: true - # Annotations to add to the service account - annotations: {} - # The name of the service account to use. - # If not set and create is true, a name is generated using the fullname template - name: "" - -## Service -## ref: https://kubernetes.io/docs/concepts/services-networking/service/ -## -service: - type: ClusterIP - ports: - p2p: 4001 - api: 5001 - gateway: 8080 - websocket: 8081 - -## Ingress -## ref: https://kubernetes.io/docs/concepts/services-networking/ingress/ -## -ingress: - api: - enabled: false - className: "" - annotations: {} - # kubernetes.io/ingress.class: nginx - # kubernetes.io/tls-acme: "true" - hosts: - - host: chart-example.local - paths: - - path: / - pathType: ImplementationSpecific - tls: [] - # - secretName: chart-example-tls - # hosts: - # - chart-example.local - gateway: - enabled: false - className: "" - annotations: {} - # kubernetes.io/ingress.class: nginx - # kubernetes.io/tls-acme: "true" - hosts: - - host: chart-example.local - paths: - - path: / - pathType: ImplementationSpecific - tls: [] - # - secretName: chart-example-tls - # hosts: - # - chart-example.local - -## Vertical Pod Autoscaler config -## Ref: https://github.com/kubernetes/autoscaler/tree/master/vertical-pod-autoscaler -## -verticalAutoscaler: - ## If true a VPA object will be created for the StatefulSet - enabled: false - updateMode: Off - containerPolicies: { } - -## Configure resource requests and limits. -## http://kubernetes.io/docs/user-guide/compute-resources/ -## -resources: { } - -## If false, data ownership will not be reset at startup -## This allows the geth node to be run with an arbitrary user -## -initChownData: true - -## Whether or not to allocate persistent volume disk for the data directory. -## In case of node failure, the node data directory will still persist. -## -persistence: - enabled: true - storageClassName: "" - accessModes: - - ReadWriteOnce - dataSize: 25Gi - fuseIpfsSize: 1Gi - fuseIpnsSize: 1Gi - -## Node labels for pod assignment -## ref: https://kubernetes.io/docs/user-guide/node-selection/ -## -nodeSelector: {} - -## Tolerations for pod assignment -## ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/ -## -tolerations: [] - -## Affinity for pod assignment -## ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity -## -affinity: {} - -## used to assign priority to pods -## ref: https://kubernetes.io/docs/concepts/configuration/pod-priority-preemption/ -## -priorityClassName: "" diff --git a/charts/keeper/Chart.yaml b/charts/keeper/Chart.yaml deleted file mode 100644 index cfcd34144..000000000 --- a/charts/keeper/Chart.yaml +++ /dev/null @@ -1,22 +0,0 @@ -apiVersion: v2 -name: keeper -version: 2.8.4 -appVersion: v2.8.3 -kubeVersion: "^1.14.0-0" -description: StakeWise Keeper is used to aggregate transactions from the oracles and submit them on-chain. -type: application -keywords: - - ethereum - - blockchain - - staking -home: https://stakewise.io/ -sources: - - https://github.com/stakewise/keeper/ -maintainers: - - name: Dmitri Tsumak - email: dmitri@stakewise.io - -dependencies: -- name: common - repository: file://../common - version: 1.0.0 diff --git a/charts/keeper/README.md b/charts/keeper/README.md deleted file mode 100644 index 7bc3b9eb4..000000000 --- a/charts/keeper/README.md +++ /dev/null @@ -1,60 +0,0 @@ -# Keeper Helm Chart - -Kubernetes Helm chart for deploying keeper - -## TL;DR; - -```bash -$ helm repo add stakewise https://charts.stakewise.io -$ helm install my-release stakewise/keeper -``` - -## Introduction - -Can be used to deploy StakeWise keeper on a [Kubernetes](http://kubernetes.io) cluster using the [Helm](https://helm.sh) package manager. - -## Prerequisites - -- Kubernetes 1.16+ -- Helm 3 - -## Installing the Chart - -To install the chart with the release name `my-release`: - -```bash -$ helm repo add stakewise https://charts.stakewise.io -$ helm install my-release stakewise/keeper -``` - -The command deploys keeper on the Kubernetes cluster in the default configuration. The [configuration](#configuration) section lists various ways to override default configuration during deployment. - -> **Tip**: List all releases using `helm list` - -## Uninstalling the Chart - -To uninstall/delete the `my-release` deployment: - -```bash -$ helm delete my-release -``` - -The command removes all the Kubernetes components associated with the chart and deletes the release. - -## Configuration - -See `values.yaml` for configuration notes. Specify each parameter using the `--set key=value[,key=value]` argument to `helm install`. For example, - -```bash -$ helm install my-release ./keeper --set settings.web3Endpoint="ws://eth1-node.chain.svc.cluster.local:8546" -``` - -The above command specifies the web3 endpoint. - -Alternatively, a YAML file that specifies the values for the parameters can be provided while installing the chart. For example, - -```bash -$ helm install my-release stakewise/keeper -f values.yaml -``` - -> **Tip**: You can override the default [values.yaml](values.yaml) \ No newline at end of file diff --git a/charts/keeper/templates/configmap.yaml b/charts/keeper/templates/configmap.yaml deleted file mode 100644 index 0b830fcbf..000000000 --- a/charts/keeper/templates/configmap.yaml +++ /dev/null @@ -1,15 +0,0 @@ -apiVersion: v1 -kind: ConfigMap -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -data: - LOG_LEVEL: {{ .Values.settings.logLevel | quote }} - NETWORK: {{ .Values.settings.network | quote }} - ENABLE_HEALTH_SERVER: {{ .Values.settings.enableHealthServer | quote }} - HEALTH_SERVER_HOST: {{ .Values.settings.healthServerHost | quote }} - HEALTH_SERVER_PORT: {{ .Values.settings.healthServerPort | quote }} - KEEPER_ETH1_ENDPOINT: {{ .Values.settings.eth1Endpoint | quote }} - AWS_S3_REGION: {{ .Values.settings.awsRegion | quote }} - HARBOUR_MAINNET_SEND_TELEGRAM_NOTIFICATIONS: {{ .Values.settings.harbourMainnetSendTelegramNotifications | quote }} diff --git a/charts/keeper/templates/deployment.yaml b/charts/keeper/templates/deployment.yaml deleted file mode 100644 index d92d01cad..000000000 --- a/charts/keeper/templates/deployment.yaml +++ /dev/null @@ -1,57 +0,0 @@ -kind: Deployment -apiVersion: {{ include "common.capabilities.deployment.apiVersion" . }} -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -spec: - replicas: 1 - strategy: - type: Recreate - selector: - matchLabels: - {{- include "common.labels.matchLabels" . | nindent 6 }} - template: - metadata: - labels: - {{- include "common.labels.matchLabels" . | nindent 8 }} - annotations: - checksum/keeper-secret: {{ include (print $.Template.BasePath "/secret.yaml") . | sha256sum }} - checksum/keeper-configmap: {{ include (print $.Template.BasePath "/configmap.yaml") . | sha256sum }} - spec: - {{- with .Values.imagePullSecrets }} - imagePullSecrets: - {{- toYaml . | nindent 8 }} - {{- end }} - {{- if .Values.tolerations }} - tolerations: - {{ tpl .Values.tolerations . | nindent 8 | trim }} - {{- end }} - {{- if .Values.affinity }} - affinity: - {{ tpl .Values.affinity . | nindent 8 | trim }} - {{- end }} - {{- with .Values.securityContext }} - securityContext: - {{ toYaml . | nindent 8 | trim }} - {{- end }} - serviceAccountName: {{ include "common.names.serviceAccountName" . }} - priorityClassName: {{ .Values.priorityClassName | quote }} - {{- if .Values.terminationGracePeriodSeconds }} - terminationGracePeriodSeconds: {{ .Values.terminationGracePeriodSeconds }} - {{- end }} - containers: - - name: {{ .Chart.Name }} - image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}" - imagePullPolicy: {{ .Values.image.pullPolicy }} - command: ["python"] - args: ["oracle/keeper/main.py"] - envFrom: - - configMapRef: - name: {{ include "common.names.fullname" . }} - - secretRef: - name: {{ include "common.names.fullname" . }} - {{- with .Values.resources }} - resources: - {{ toYaml . | nindent 12 | trim }} - {{- end }} diff --git a/charts/keeper/templates/role.yaml b/charts/keeper/templates/role.yaml deleted file mode 100644 index 44bf0ea62..000000000 --- a/charts/keeper/templates/role.yaml +++ /dev/null @@ -1,17 +0,0 @@ -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -rules: - - apiGroups: [""] - resources: ["secrets"] - resourceNames: - - {{ include "common.names.fullname" . }} - verbs: ["get"] - - apiGroups: [""] - resources: ["configmaps"] - resourceNames: - - {{ include "common.names.fullname" . }} - verbs: ["get"] diff --git a/charts/keeper/templates/rolebinding.yaml b/charts/keeper/templates/rolebinding.yaml deleted file mode 100644 index 329d7b812..000000000 --- a/charts/keeper/templates/rolebinding.yaml +++ /dev/null @@ -1,14 +0,0 @@ -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -roleRef: - kind: Role - apiGroup: rbac.authorization.k8s.io - name: {{ include "common.names.fullname" . }} -subjects: - - kind: ServiceAccount - name: {{ include "common.names.fullname" . }} - namespace: {{ .Release.Namespace }} diff --git a/charts/keeper/templates/secret.yaml b/charts/keeper/templates/secret.yaml deleted file mode 100644 index 8ea61fd84..000000000 --- a/charts/keeper/templates/secret.yaml +++ /dev/null @@ -1,11 +0,0 @@ -apiVersion: v1 -kind: Secret -metadata: - name: {{ include "common.names.fullname" . }} - namespace: {{ .Release.Namespace }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -type: Opaque -data: - SENTRY_DSN: {{ .Values.settings.sentryDsn | b64enc | quote }} - ORACLE_PRIVATE_KEY: {{ .Values.settings.oraclePrivateKey | b64enc | quote }} diff --git a/charts/keeper/templates/serviceaccount.yaml b/charts/keeper/templates/serviceaccount.yaml deleted file mode 100644 index a28702d93..000000000 --- a/charts/keeper/templates/serviceaccount.yaml +++ /dev/null @@ -1,8 +0,0 @@ -{{- if or .Values.global.serviceAccount.create .Values.serviceAccount.create -}} -apiVersion: v1 -kind: ServiceAccount -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -{{- end }} diff --git a/charts/keeper/values.yaml b/charts/keeper/values.yaml deleted file mode 100644 index 5c1692a03..000000000 --- a/charts/keeper/values.yaml +++ /dev/null @@ -1,84 +0,0 @@ -# Default values for oracle. -# This is a YAML-formatted file. -# Declare variables to be passed into your templates. - -global: - serviceAccount: - create: true - -## Pod Security Context -## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/ -## -securityContext: - fsGroup: 1001 - runAsUser: 1001 - -## Termination Grace Period -## ref: https://kubernetes.io/docs/tasks/run-application/force-delete-stateful-set-pod/#delete-pods -## -terminationGracePeriodSeconds: 1800 - -## Affinity Settings -## ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity -## -affinity: { } - -## Toleration Settings -## ref: https://kubernetes.io/docs/concepts/scheduling-eviction/taint-and-toleration/ -## -tolerations: [ ] - -serviceAccount: - ## Annotations to add to the service account - ## - annotations: {} - ## The name of the service account to use. - ## If not set and create is true, a name is generated using the fullname template - ## - name: "" - -## Docker image -## -image: - repository: "europe-west4-docker.pkg.dev/stakewiselabs/public/oracle" - tag: "v2.8.3" - pullPolicy: IfNotPresent - -## Credentials to fetch images from private registry -## ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/ -## -imagePullSecrets: [] - -## Configure resource requests and limits. -## ref: http://kubernetes.io/docs/user-guide/compute-resources/ -## -resources: - requests: - cpu: 10m - memory: 200Mi - -## Used to assign priority to pod -## ref: https://kubernetes.io/docs/concepts/configuration/pod-priority-preemption/ -## -priorityClassName: "" - -settings: - logLevel: "INFO" - ## Possible values: goerli, perm_goerli, gnosis, mainnet - ## - network: "mainnet" - - eth1Endpoint: "" - - enableHealthServer: "False" - healthServerHost: "0.0.0.0" - healthServerPort: "8080" - - sentryDsn: "" - - ## Credentials - ## - oraclePrivateKey: "" - awsRegion: "" - - harbourMainnetSendTelegramNotifications: False diff --git a/charts/lighthouse/Chart.yaml b/charts/lighthouse/Chart.yaml deleted file mode 100644 index aff0dbbcd..000000000 --- a/charts/lighthouse/Chart.yaml +++ /dev/null @@ -1,24 +0,0 @@ -apiVersion: v2 -name: lighthouse -version: 2.1.5 -kubeVersion: "^1.18.0-0" -description: Rust Ethereum 2.0 Client. -type: application -keywords: - - ethereum - - blockchain - - lighthouse - - p2p -home: https://www.ethereum.org/ -sources: - - https://github.com/sigp/lighthouse -maintainers: - - name: Dmitri Tsumak - email: dmitri@stakewise.io -icon: https://raw.githubusercontent.com/ethereum/ethereum-org/master/public/images/logos/ETHEREUM-ICON_Black.png -appVersion: v3.1.2 - -dependencies: -- name: common - repository: file://../common - version: 1.0.0 diff --git a/charts/lighthouse/templates/_helpers.yaml b/charts/lighthouse/templates/_helpers.yaml deleted file mode 100644 index cb8252c4d..000000000 --- a/charts/lighthouse/templates/_helpers.yaml +++ /dev/null @@ -1,3 +0,0 @@ -{{- define "lighthouse.p2pPort" -}} -{{- printf "9000" -}} -{{- end -}} diff --git a/charts/lighthouse/templates/clusterrole.yaml b/charts/lighthouse/templates/clusterrole.yaml deleted file mode 100644 index 6d7136bd1..000000000 --- a/charts/lighthouse/templates/clusterrole.yaml +++ /dev/null @@ -1,10 +0,0 @@ -{{- if or .Values.global.rbac.create .Values.rbac.create }} -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: {{ include "common.names.clusterRoleName" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -rules: -{{- toYaml .Values.rbac.clusterRules | nindent 0 }} -{{- end }} diff --git a/charts/lighthouse/templates/clusterrolebinding.yaml b/charts/lighthouse/templates/clusterrolebinding.yaml deleted file mode 100644 index 87d636dac..000000000 --- a/charts/lighthouse/templates/clusterrolebinding.yaml +++ /dev/null @@ -1,16 +0,0 @@ -{{- if or .Values.global.rbac.create .Values.rbac.create }} -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: {{ include "common.names.clusterRoleName" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: {{ include "common.names.clusterRoleName" . }} -subjects: - - kind: ServiceAccount - name: {{ include "common.names.serviceAccountName" . }} - namespace: {{ .Release.Namespace }} -{{- end }} diff --git a/charts/lighthouse/templates/configmap.yaml b/charts/lighthouse/templates/configmap.yaml deleted file mode 100644 index e6da57c0a..000000000 --- a/charts/lighthouse/templates/configmap.yaml +++ /dev/null @@ -1,12 +0,0 @@ ---- -apiVersion: v1 -kind: ConfigMap -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -data: - execution-endpoints.txt: |- -{{- range $i, $e := .Values.global.executionEndpoints }} - {{ . }} -{{- end }} diff --git a/charts/lighthouse/templates/pdb.yaml b/charts/lighthouse/templates/pdb.yaml deleted file mode 100644 index 4ef63f0ff..000000000 --- a/charts/lighthouse/templates/pdb.yaml +++ /dev/null @@ -1,18 +0,0 @@ -{{- if .Values.podDisruptionBudget.enabled }} -apiVersion: {{ include "common.capabilities.policy.apiVersion" . }} -kind: PodDisruptionBudget -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -spec: -{{- if .Values.podDisruptionBudget.minAvailable }} - minAvailable: {{ .Values.podDisruptionBudget.minAvailable }} -{{- end }} -{{- if .Values.podDisruptionBudget.maxUnavailable }} - maxUnavailable: {{ .Values.podDisruptionBudget.maxUnavailable }} -{{- end }} - selector: - matchLabels: - {{- include "common.labels.matchLabels" . | nindent 6 }} -{{- end }} diff --git a/charts/lighthouse/templates/prometheusrules.yaml b/charts/lighthouse/templates/prometheusrules.yaml deleted file mode 100644 index 4df0b1508..000000000 --- a/charts/lighthouse/templates/prometheusrules.yaml +++ /dev/null @@ -1,51 +0,0 @@ -{{- if and (or .Values.global.metrics.enabled .Values.metrics.enabled) - (or .Values.global.metrics.prometheusRule.enabled .Values.metrics.prometheusRule.enabled) }} -apiVersion: monitoring.coreos.com/v1 -kind: PrometheusRule -metadata: - name: {{ include "common.names.fullname" . }} - {{- if .Values.metrics.prometheusRule.namespace }} - namespace: {{ .Values.metrics.prometheusRule.namespace }} - {{- else }} - namespace: {{ .Release.Namespace | quote }} - {{- end }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.metrics.prometheusRule.additionalLabels }} - {{- toYaml .Values.metrics.prometheusRule.additionalLabels | nindent 4 }} - {{- end }} -spec: - groups: - {{- with .Values.metrics.prometheusRule.rules }} - - name: {{ include "common.names.fullname" $ }} - rules: {{- tpl (toYaml .) $ | nindent 8 }} - {{- end }} - {{- if .Values.metrics.prometheusRule.default }} - - name: {{ include "common.names.fullname" $ }}-default - rules: - - alert: LighthouseBeaconNodeDown - expr: up{job='{{ include "common.names.fullname" . }}'} == 0 - for: 1m - labels: - severity: critical - annotations: - summary: Lighthouse beacon node is down - description: Check {{ printf "{{ $labels.pod }}" }} beacon node in namespace {{ printf "{{ $labels.namespace }}" }} - - alert: LighthouseBeaconNodeIsNotConnectedToEth1Node - expr: sync_eth1_connected{job='{{ include "common.names.fullname" . }}'} == 0 - for: 1m - labels: - severity: critical - annotations: - summary: Lighthouse beacon node is not connected to eth1 node - description: Check {{ printf "{{ $labels.pod }}" }} beacon node in namespace {{ printf "{{ $labels.namespace }}" }} - - alert: LighthouseBeaconNodeIsOutOfSync - expr: sync_eth2_synced{job='{{ include "common.names.fullname" . }}'} == 0 - for: 3m - labels: - severity: critical - annotations: - summary: Lighthouse beacon node is out of sync - description: Check {{ printf "{{ $labels.pod }}" }} beacon node in namespace {{ printf "{{ $labels.namespace }}" }} - {{- end }} -{{- end }} diff --git a/charts/lighthouse/templates/role.yaml b/charts/lighthouse/templates/role.yaml deleted file mode 100644 index dfbc0fe48..000000000 --- a/charts/lighthouse/templates/role.yaml +++ /dev/null @@ -1,10 +0,0 @@ -{{- if or .Values.global.rbac.create .Values.rbac.create -}} -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -rules: -{{- toYaml .Values.rbac.rules | nindent 0 }} -{{- end }} diff --git a/charts/lighthouse/templates/rolebinding.yaml b/charts/lighthouse/templates/rolebinding.yaml deleted file mode 100644 index 1fdb617ba..000000000 --- a/charts/lighthouse/templates/rolebinding.yaml +++ /dev/null @@ -1,15 +0,0 @@ -{{- if or .Values.global.rbac.create .Values.rbac.create }} -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: {{ include "common.names.serviceAccountName" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: {{ include "common.names.serviceAccountName" . }} -subjects: - - kind: ServiceAccount - name: {{ include "common.names.serviceAccountName" . }} -{{- end }} diff --git a/charts/lighthouse/templates/secret.yaml b/charts/lighthouse/templates/secret.yaml deleted file mode 100644 index 5a3f66bb5..000000000 --- a/charts/lighthouse/templates/secret.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: v1 -kind: Secret -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -type: Opaque -data: - jwtsecret: {{ .Values.global.JWTSecret | b64enc | quote }} diff --git a/charts/lighthouse/templates/service-p2p.yaml b/charts/lighthouse/templates/service-p2p.yaml deleted file mode 100644 index 15474a64b..000000000 --- a/charts/lighthouse/templates/service-p2p.yaml +++ /dev/null @@ -1,42 +0,0 @@ -{{- if .Values.p2pNodePort.enabled -}} -{{- range $i, $e := until (len .Values.global.executionEndpoints) }} -{{- $port := add $.Values.p2pNodePort.startAt $i -}} -{{- if hasKey $.Values.p2pNodePort.replicaToNodePort ($i | toString) -}} - {{ $port = index $.Values.p2pNodePort.replicaToNodePort ($i | toString) }} -{{- end }} - ---- -apiVersion: v1 -kind: Service -metadata: - name: {{ include "common.names.fullname" $ }}-{{ $i }} - labels: - {{- include "common.labels.standard" $ | nindent 4 }} - pod: "{{ include "common.names.fullname" $ }}-{{ $i }}" - type: p2p - {{- with $.Values.p2pNodePort.annotations }} - annotations: - {{- toYaml . | nindent 4 }} - {{- end }} -spec: - type: {{ $.Values.p2pNodePort.type }} - externalTrafficPolicy: Local - ports: - - name: p2p-tcp - port: {{ include "lighthouse.p2pPort" $ }} - protocol: TCP - targetPort: p2p-tcp - nodePort: {{ $port }} - {{- if eq $.Values.p2pNodePort.type "NodePort" }} - - name: p2p-udp - port: {{ include "lighthouse.p2pPort" $ }} - protocol: UDP - targetPort: p2p-udp - nodePort: {{ $port }} - {{- end }} - selector: - {{- include "common.labels.matchLabels" $ | nindent 4 }} - statefulset.kubernetes.io/pod-name: "{{ include "common.names.fullname" $ }}-{{ $i }}" - -{{- end }} -{{- end }} diff --git a/charts/lighthouse/templates/service.yaml b/charts/lighthouse/templates/service.yaml deleted file mode 100644 index 2714a048f..000000000 --- a/charts/lighthouse/templates/service.yaml +++ /dev/null @@ -1,33 +0,0 @@ ---- -apiVersion: v1 -kind: Service -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -{{- if and .Values.global.metrics.enabled .Values.metrics.svcAnnotations }} - annotations: - {{ toYaml .Values.metrics.svcAnnotations | nindent 4 | trim }} -{{- end }} -spec: - selector: - {{- include "common.labels.matchLabels" . | nindent 4 }} -{{- if .Values.sessionAffinity.enabled }} - sessionAffinity: ClientIP - sessionAffinityConfig: - clientIP: - timeoutSeconds: {{ .Values.sessionAffinity.timeoutSeconds }} -{{- end }} - type: ClusterIP -{{- if .Values.svcHeadless }} - clusterIP: None -{{- end }} - ports: - - name: {{ .Values.http.portName }} - port: {{ .Values.http.port }} - targetPort: {{ .Values.http.portName }} - {{- if .Values.global.metrics.enabled }} - - name: metrics - port: {{ .Values.metrics.port }} - targetPort: metrics - {{- end }} diff --git a/charts/lighthouse/templates/servicemonitor.yaml b/charts/lighthouse/templates/servicemonitor.yaml deleted file mode 100644 index 9ecffc6ca..000000000 --- a/charts/lighthouse/templates/servicemonitor.yaml +++ /dev/null @@ -1,42 +0,0 @@ -{{- if and (or .Values.global.metrics.enabled .Values.metrics.enabled) - (or .Values.global.metrics.serviceMonitor.enabled .Values.metrics.serviceMonitor.enabled) }} -apiVersion: monitoring.coreos.com/v1 -kind: ServiceMonitor -metadata: - name: {{ template "common.names.fullname" . }} - {{- if .Values.metrics.serviceMonitor.namespace }} - namespace: {{ .Values.metrics.serviceMonitor.namespace }} - {{- else }} - namespace: {{ .Release.Namespace | quote }} - {{- end }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.metrics.serviceMonitor.additionalLabels }} - {{- toYaml .Values.metrics.serviceMonitor.additionalLabels | nindent 4 }} - {{- end }} -spec: - endpoints: - - port: metrics - path: /metrics - {{- if .Values.metrics.serviceMonitor.interval }} - interval: {{ .Values.metrics.serviceMonitor.interval }} - {{- end }} - {{- if .Values.metrics.serviceMonitor.scrapeTimeout }} - scrapeTimeout: {{ .Values.metrics.serviceMonitor.scrapeTimeout }} - {{- end }} - {{- if .Values.metrics.serviceMonitor.honorLabels }} - honorLabels: {{ .Values.metrics.serviceMonitor.honorLabels }} - {{- end }} - {{- if .Values.metrics.serviceMonitor.relabelings }} - relabelings: {{- toYaml .Values.metrics.serviceMonitor.relabelings | nindent 6 }} - {{- end }} - {{- if .Values.metrics.serviceMonitor.metricRelabelings }} - metricRelabelings: {{- toYaml .Values.metrics.serviceMonitor.metricRelabelings | nindent 6 }} - {{- end }} - namespaceSelector: - matchNames: - - {{ .Release.Namespace }} - selector: - matchLabels: - {{- include "common.labels.matchLabels" . | nindent 6 }} -{{- end }} diff --git a/charts/lighthouse/templates/statefulset.yaml b/charts/lighthouse/templates/statefulset.yaml deleted file mode 100644 index b8710a63b..000000000 --- a/charts/lighthouse/templates/statefulset.yaml +++ /dev/null @@ -1,246 +0,0 @@ ---- -apiVersion: {{ include "common.capabilities.statefulset.apiVersion" . }} -kind: StatefulSet -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.statefulset" . | nindent 4 }} -spec: - replicas: {{ len .Values.global.executionEndpoints }} - podManagementPolicy: "Parallel" - selector: - matchLabels: - {{- include "common.labels.matchLabels" . | nindent 6 }} - serviceName: {{ include "common.names.fullname" . }} - template: - metadata: - labels: - {{- include "common.labels.matchLabels" . | nindent 8 }} - annotations: - checksum/configmap: {{ include (print $.Template.BasePath "/configmap.yaml") . | sha256sum }} - spec: - {{- with (concat .Values.imagePullSecrets .Values.global.imagePullSecrets) }} - imagePullSecrets: - {{- toYaml . | nindent 8 }} - {{- end }} - {{- with .Values.affinity }} - affinity: - {{ toYaml . | nindent 8 | trim }} - {{- end }} - {{- with .Values.tolerations }} - tolerations: - {{ toYaml . | nindent 8 | trim }} - {{- end }} - {{- with .Values.nodeSelector }} - nodeSelector: - {{ toYaml . | nindent 8 | trim }} - {{- end }} - {{- with .Values.securityContext }} - securityContext: - {{ toYaml . | nindent 8 | trim }} - {{- end }} - serviceAccountName: {{ include "common.names.serviceAccountName" . }} - priorityClassName: {{ .Values.priorityClassName | quote }} - initContainers: - - name: init - image: "{{ .Values.initImage.repository }}:{{ .Values.initImage.tag }}" - imagePullPolicy: {{ .Values.initImage.pullPolicy }} - securityContext: - runAsNonRoot: false - runAsUser: 0 - env: - - name: POD_IP - valueFrom: - fieldRef: - fieldPath: status.podIP - - name: POD_NAME - valueFrom: - fieldRef: - fieldPath: metadata.name - - name: POD_NAMESPACE - valueFrom: - fieldRef: - fieldPath: metadata.namespace - - name: NODE_NAME - valueFrom: - fieldRef: - fieldPath: spec.nodeName - command: - - sh - - -c - - > - echo "Namespace: ${POD_NAMESPACE} Pod: ${POD_NAME}"; - {{- if .Values.p2pNodePort.enabled }} - {{- if eq .Values.p2pNodePort.type "LoadBalancer" }} - until [ -n "$(kubectl -n ${POD_NAMESPACE} get svc/${POD_NAME} -o jsonpath='{.status.loadBalancer.ingress[0].ip}')" ]; do echo "Waiting for load balancer gets an IP" && sleep 10; done; - export EXTERNAL_PORT=$(kubectl -n ${POD_NAMESPACE} get services -l "pod in (${POD_NAME}), type in (p2p)" -o jsonpath='{.items[0].spec.ports[0].nodePort}'); - export EXTERNAL_IP=$(kubectl -n ${POD_NAMESPACE} get svc/${POD_NAME} -o jsonpath='{.status.loadBalancer.ingress[0].ip}'); - {{- else }} - export EXTERNAL_PORT=$(kubectl get services -l "pod in (${POD_NAME}), type in (p2p)" -o jsonpath='{.items[0].spec.ports[0].nodePort}'); - export EXTERNAL_IP=$(kubectl get nodes "${NODE_NAME}" -o jsonpath='{.status.addresses[?(@.type=="ExternalIP")].address}'); - {{- end }} - echo "EXTERNAL_PORT=$EXTERNAL_PORT" > /env/init-nodeport; - echo "EXTERNAL_IP=$EXTERNAL_IP" >> /env/init-nodeport; - cat /env/init-nodeport; - {{- end }} - {{- if and .Values.persistence.enabled .Values.initChownData }} - mkdir -p /data && chown -R {{ .Values.securityContext.runAsUser }}:{{ .Values.securityContext.runAsUser }} /data; - {{- end }} - INDEX=$((${HOSTNAME##*-}+1)); - EE=$(sed "${INDEX}q;d" /configs/execution-endpoints.txt); - echo ${EE} > /data/ee.txt; - echo "Pod will connect to the ${EE} endpoint"; - volumeMounts: - - name: env-nodeport - mountPath: /env - - name: data - mountPath: /data - - name: configs - mountPath: /configs - containers: - - name: {{ .Chart.Name }} - image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}" - imagePullPolicy: {{ .Values.image.pullPolicy }} - command: - - sh - - -ac - - > - {{- if .Values.p2pNodePort.enabled }} - . /env/init-nodeport; - {{- end }} - EE=`cat /data/ee.txt`; - echo "Pod will connect to the ${EE} endpoint"; - exec lighthouse - bn - --staking - {{- if .Values.http.enabled }} - --http - --http-port={{ .Values.http.port }} - --http-address={{ .Values.http.address }} - --http-allow-origin={{ .Values.http.allowOrigin }} - {{- end}} - --execution-endpoint=${EE} - --execution-jwt=/secret/jwtsecret - --datadir=/data - --network={{ .Values.global.network }} - --disable-upnp - --disable-enr-auto-update - --target-peers={{ .Values.targetPeers }} - --discovery-port={{ include "lighthouse.p2pPort" . }} - {{- if .Values.p2pNodePort.enabled }} - --enr-address=$EXTERNAL_IP - --enr-tcp-port=$EXTERNAL_PORT - --enr-udp-port=$EXTERNAL_PORT - {{- else }} - --enr-address=$(POD_IP) - --enr-tcp-port={{ include "lighthouse.p2pPort" . }} - --enr-udp-port={{ include "lighthouse.p2pPort" . }} - {{- end }} - {{- if .Values.global.metrics.enabled }} - {{- range .Values.metrics.flags }} - {{ . }} - {{- end }} - {{- end }} - {{- range .Values.extraFlags }} - {{ . }} - {{- end }} - env: - - name: POD_IP - valueFrom: - fieldRef: - fieldPath: status.podIP - ports: - - containerPort: {{ .Values.http.port }} - protocol: TCP - name: {{ .Values.http.portName }} - {{- if .Values.global.metrics.enabled }} - - containerPort: {{ .Values.metrics.port }} - name: metrics - protocol: TCP - {{- end }} - {{- if .Values.p2pNodePort.enabled }} - - name: p2p-tcp - containerPort: {{ include "lighthouse.p2pPort" . }} - protocol: TCP - - name: p2p-udp - containerPort: {{ include "lighthouse.p2pPort" . }} - protocol: UDP - {{- end }} - volumeMounts: - - name: data - mountPath: /data - - name: jwtsecret - mountPath: /secret - readOnly: true - - name: env-nodeport - mountPath: /env - {{- with .Values.resources }} - resources: - {{ toYaml . | nindent 12 | trim }} - {{- end }} - - name: sidecar - image: "{{ .Values.sidecar.repository }}:{{ .Values.sidecar.tag }}" - imagePullPolicy: {{ .Values.sidecar.pullPolicy }} - env: - - name: SERVER_BINDADDR - value: "{{ .Values.sidecar.bindAddr }}:{{ .Values.sidecar.bindPort }}" - - name: CLIENT_PORT - value: {{ .Values.http.port | quote }} - ports: - - containerPort: {{ .Values.sidecar.bindPort }} - name: sidecar - protocol: TCP - {{- if or .Values.global.livenessProbe.enabled .Values.livenessProbe.enabled }} - livenessProbe: - initialDelaySeconds: {{ .Values.livenessProbe.initialDelaySeconds }} - timeoutSeconds: {{ .Values.livenessProbe.timeoutSeconds }} - periodSeconds: {{ .Values.livenessProbe.periodSeconds }} - failureThreshold: {{ .Values.livenessProbe.failureThreshold }} - successThreshold: {{ .Values.livenessProbe.successThreshold }} - httpGet: - path: {{ .Values.livenessProbe.httpGet.path }} - port: {{ .Values.livenessProbe.httpGet.port }} - scheme: {{ .Values.livenessProbe.httpGet.scheme }} - {{- end }} - {{- if or .Values.global.readinessProbe.enabled .Values.readinessProbe.enabled }} - readinessProbe: - initialDelaySeconds: {{ .Values.readinessProbe.initialDelaySeconds }} - timeoutSeconds: {{ .Values.readinessProbe.timeoutSeconds }} - periodSeconds: {{ .Values.readinessProbe.periodSeconds }} - failureThreshold: {{ .Values.readinessProbe.failureThreshold }} - successThreshold: {{ .Values.readinessProbe.successThreshold }} - httpGet: - path: {{ .Values.readinessProbe.httpGet.path }} - port: {{ .Values.readinessProbe.httpGet.port }} - scheme: {{ .Values.readinessProbe.httpGet.scheme }} - {{- end }} - volumes: - - name: jwtsecret - secret: - secretName: {{ include "common.names.fullname" . }} - - name: env-nodeport - emptyDir: {} - - name: configs - configMap: - name: {{ include "common.names.fullname" . }} - {{- if not .Values.persistence.enabled }} - - name: data - emptyDir: {} - {{- end }} -{{- if .Values.persistence.enabled }} - volumeClaimTemplates: - - metadata: - name: data - labels: - {{- include "common.labels.statefulset" . | nindent 10 }} - {{- with .Values.persistence.annotations }} - annotations: - {{ toYaml . | nindent 10 | trim }} - {{- end }} - spec: - accessModes: {{ .Values.persistence.accessModes }} - storageClassName: {{ .Values.persistence.storageClassName }} - resources: - requests: - storage: {{ .Values.persistence.size | quote }} -{{- end }} diff --git a/charts/lighthouse/templates/validate.yaml b/charts/lighthouse/templates/validate.yaml deleted file mode 100644 index 75d40a4fd..000000000 --- a/charts/lighthouse/templates/validate.yaml +++ /dev/null @@ -1,8 +0,0 @@ -{{- if not .Values.global.JWTSecret }} -{{- fail ".Values.global.JWTSecret is required" }} -{{- end }} - -{{- $endpoints := uniq .Values.global.executionEndpoints -}} -{{- if lt (len $endpoints) (len .Values.global.executionEndpoints)}} -{{- fail ".Values.global.executionClients must only contain unique values, since each consensus client must be connected to a unique execution client." }} -{{- end }} diff --git a/charts/lighthouse/templates/vpa.yaml b/charts/lighthouse/templates/vpa.yaml deleted file mode 100644 index 8b579cbcb..000000000 --- a/charts/lighthouse/templates/vpa.yaml +++ /dev/null @@ -1,20 +0,0 @@ -{{- if .Values.verticalAutoscaler.enabled }} -apiVersion: autoscaling.k8s.io/v1beta2 -kind: VerticalPodAutoscaler -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -spec: - targetRef: - apiVersion: "apps/v1" - kind: StatefulSet - name: {{ include "common.names.fullname" . }} - updatePolicy: - updateMode: {{ .Values.verticalAutoscaler.updateMode | default "Off" | quote }} - {{- if .Values.verticalAutoscaler.containerPolicies }} - resourcePolicy: - containerPolicies: - {{ tpl .Values.verticalAutoscaler.containerPolicies . | nindent 6 | trim }} - {{- end }} -{{- end }} diff --git a/charts/lighthouse/values.yaml b/charts/lighthouse/values.yaml deleted file mode 100644 index 19948d34d..000000000 --- a/charts/lighthouse/values.yaml +++ /dev/null @@ -1,384 +0,0 @@ -# Default values for lighthouse. -# This is a YAML-formatted file. -# Declare variables to be passed into your templates. - -global: - ## Eth2 network ID - ## - network: mainnet - - ## JSON Web Token (JWT) authentication is used to secure the communication - ## between the beacon node and execution client. You can generate a JWT using - ## a command line tool, for example: - ## openssl rand -hex 32 > token.txt - ## - JWTSecret: "" - - ## Server endpoints for an execution layer jwt authenticated HTTP JSON-RPC connection. - ## Uses the same endpoint to populate the deposit cache. - ## A separate Statefulset will be created for each specified address - ## - ## !!!!! WARNING !!!!! - ## NEVER CHANGE THE ORDER OF ENDPOINTS AS THIS MAY BREAK - ## THE CONSENSUS AND EXECTION CLIENTS CONNECTIVITY - executionEndpoints: [] - - ## Credentials to fetch images from private registry - ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/ - ## - imagePullSecrets: [] - - ## Service account - ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ - ## Additional settings could be made in non-global section. - ## - serviceAccount: - # Specifies whether a service account should be created - create: true - - ## RBAC configuration. - ## ref: https://kubernetes.io/docs/reference/access-authn-authz/rbac/ - ## Additional settings could be made in non-global section. - ## - rbac: - ## Specifies whether RBAC resources are to be created - ## - create: true - - ## Monitoring - ## Additional settings could be made in non-global section. - ## - metrics: - ## Whether to enable metrics collection or not - ## - enabled: true - - ## Prometheus Service Monitor - ## ref: https://github.com/coreos/prometheus-operator - ## https://github.com/coreos/prometheus-operator/blob/master/Documentation/api.md#endpoint - ## - serviceMonitor: - ## Create ServiceMonitor resource(s) for scraping metrics using PrometheusOperator - ## - enabled: false - - ## Custom PrometheusRule to be defined - ## ref: https://github.com/coreos/prometheus-operator#customresourcedefinitions - ## - prometheusRule: - ## Create a custom prometheusRule Resource for scraping metrics using PrometheusOperator - ## - enabled: false - - ## Configure liveness and readiness probes - ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/ - ## NB! readinessProbe and livenessProbe must be disabled before fully synced - ## Additional settings could be made in non-global section. - ## - livenessProbe: - enabled: true - - readinessProbe: - enabled: true - -## Init image is used to chown data volume, initialise genesis, etc. -## -initImage: - repository: "bitnami/kubectl" - tag: "1.24" - pullPolicy: IfNotPresent - -## Sidecar image is used to perform Liveness/Readiness probes. -## -sidecar: - repository: "europe-west4-docker.pkg.dev/stakewiselabs/public/ethnode-sidecar" - tag: "v1.0.5" - pullPolicy: IfNotPresent - bindAddr: "0.0.0.0" - bindPort: 3000 - -## Configuration for lighthouse eth v2 beacon chain node -## ref: https://lighthouse-book.sigmaprime.io/ -## - -## Lighthouse beacon node image version -## ref: https://hub.docker.com/r/sigp/lighthouse -image: - repository: "sigp/lighthouse" - tag: "v3.1.2" - pullPolicy: IfNotPresent - -## Credentials to fetch images from private registry -## ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/ -## -imagePullSecrets: [] - -## Provide a name in place of lighthouse for `app:` labels -## -nameOverride: "" - -## Provide a name to substitute for the full names of resources -## -fullnameOverride: "" - -## Rest API Settings -## -http: - # Enables Beacon Rest API - enabled: true - # Port of the REST server - port: "5052" - # Port name for the respective k8s service - portName: "http" - # Listening address of the REST server - address: "0.0.0.0" - # Access-Control-Allow-Origin response HTTP header - allowOrigin: "*" - -## The target number of peers. -## -targetPeers: 80 - -## Extra flags for lighthouse beacon chain node -## -extraFlags: [] - -## Service account -## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ -## -serviceAccount: - # Annotations to add to the service account - annotations: {} - # The name of the service account to use. - # If not set and create is true, a name is generated using the fullname template - name: "" - -## Additional labels for all resources -## -additionalLabels: - client-type: "consensus" - -## Pod Security Context -## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/ -## -securityContext: - fsGroup: 1001 - runAsUser: 1001 - -## RBAC configuration. -## ref: https://kubernetes.io/docs/reference/access-authn-authz/rbac/ -## -rbac: - # The name of the cluster role to use. - # If not set and create is true, a name is generated using the fullname template - name: "" - ## Required ClusterRole rules - ## - clusterRules: - ## Required to obtain the nodes external IP - ## - - apiGroups: [""] - resources: - - "nodes" - verbs: - - "get" - - "list" - - "watch" - ## Required Role rules - ## - rules: - ## Required to get information about the serices nodePort. - ## - - apiGroups: [""] - resources: - - "services" - verbs: - - "get" - - "list" - - "watch" - -## Node labels for pod assignment -## ref: https://kubernetes.io/docs/user-guide/node-selection/ -## -nodeSelector: {} - -## Tolerations for pod assignment -## ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/ -## -tolerations: {} - -## Affinity for pod assignment -## ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity -## -## Example: -## affinity: -## podAntiAffinity: -## requiredDuringSchedulingIgnoredDuringExecution: -## - labelSelector: -## matchExpressions: -## - key: app.kubernetes.io/name -## operator: In -## values: -## - lighthouse -## topologyKey: kubernetes.io/hostname -## -affinity: {} - -## Used to assign priority to pods -## ref: https://kubernetes.io/docs/concepts/configuration/pod-priority-preemption/ -## -priorityClassName: "" - -## Enable pod disruption budget -## ref: https://kubernetes.io/docs/tasks/run-application/configure-pdb -## -podDisruptionBudget: - enabled: true - maxUnavailable: 1 - -## Vertical Pod Autoscaler config -## ref: https://github.com/kubernetes/autoscaler/tree/master/vertical-pod-autoscaler -## -verticalAutoscaler: - # If true a VPA object will be created for the StatefulSet - enabled: false - updateMode: Off - containerPolicies: {} - -## Configure resource requests and limits. -## ref: http://kubernetes.io/docs/user-guide/compute-resources/ -## -resources: {} - -## Configure liveness and readiness probes -## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/ -## -livenessProbe: - initialDelaySeconds: 900 - timeoutSeconds: 3 - periodSeconds: 30 - failureThreshold: 3 - successThreshold: 1 - httpGet: - path: /eth2/liveness - port: sidecar - scheme: HTTP - -readinessProbe: - initialDelaySeconds: 300 - timeoutSeconds: 3 - periodSeconds: 30 - failureThreshold: 30 - successThreshold: 2 - httpGet: - path: /eth2/readiness - port: sidecar - scheme: HTTP - -## Defines whether the service must be headless -## -svcHeadless: true - -## Configure session affinity for validator clients to hit the same beacon node -## for the period specified in `timeoutSeconds` -## ref: https://kubernetes.io/docs/concepts/services-networking/service/#proxy-mode-userspace -## -sessionAffinity: - # Whether to enable session affinity or not - enabled: false - # The session duration in seconds - timeoutSeconds: 86400 - -## When p2pNodePort is enabled, your P2P port will be exposed via service type NodePort/LoadBalancer. -## This will generate a service for each replica, with a port binding via NodePort/LoadBalancer. -## This is useful if you want to expose and announce your node to the Internet. -## -p2pNodePort: - ## @param p2pNodePort.enabled Expose P2P port via NodePort - ## - enabled: false - ## @param p2pNodePort.annotations - ## - annotations: {} - ## @param p2pNodePort.type - ## Options: NodePort, LoadBalancer - type: NodePort - ## @param p2pNodePort.startAt The ports allocation will start from this value - ## - startAt: 31300 - ## @param p2pNodePort.replicaToNodePort Overwrite a port for specific replicas - ## @default -- See `values.yaml` for example - replicaToNodePort: {} - # "0": 32345 - # "3": 32348 - -## Monitoring -## -metrics: - # Prometheus exporter port - port: 5054 - - # Extra flags to pass for collecting metrics - flags: - - "--metrics" - - "--metrics-port=5054" - - "--metrics-address=0.0.0.0" - - ## Prometheus Service Monitor - ## ref: https://github.com/coreos/prometheus-operator - ## https://github.com/coreos/prometheus-operator/blob/master/Documentation/api.md#endpoint - ## - serviceMonitor: - ## The namespace in which the ServiceMonitor will be created - ## - namespace: "" - ## The interval at which metrics should be scraped - ## - interval: 30s - ## The timeout after which the scrape is ended - ## - scrapeTimeout: "" - ## Metrics RelabelConfigs to apply to samples before scraping. - ## - relabellings: [] - ## Metrics RelabelConfigs to apply to samples before ingestion. - ## - metricRelabelings: [] - ## Specify honorLabels parameter to add the scrape endpoint - ## - honorLabels: false - ## Additional labels that can be used so ServiceMonitor resource(s) can be discovered by Prometheus - ## - additionalLabels: {} - ## Custom PrometheusRule to be defined - ## ref: https://github.com/coreos/prometheus-operator#customresourcedefinitions - ## - prometheusRule: - ## Create a default set of Alerts - ## - default: true - ## The namespace in which the prometheusRule will be created - ## - namespace: "" - ## Additional labels for the prometheusRule - ## - additionalLabels: {} - ## Custom Prometheus rules - ## - rules: [] - -## If false, data ownership will not be reset at startup -## This allows the geth node to be run with an arbitrary user -## -initChownData: true - -## Whether or not to allocate persistent volume disk for the data directory. -## In case of pod failure, the pod data directory will still persist. -## -persistence: - enabled: true - storageClassName: "" - accessModes: - - ReadWriteOnce - size: 250Gi - annotations: {} diff --git a/charts/geth/.helmignore b/charts/lodestar/.helmignore similarity index 100% rename from charts/geth/.helmignore rename to charts/lodestar/.helmignore diff --git a/charts/ssv-node/Chart.yaml b/charts/lodestar/Chart.yaml similarity index 61% rename from charts/ssv-node/Chart.yaml rename to charts/lodestar/Chart.yaml index d21b04933..c503c124a 100644 --- a/charts/ssv-node/Chart.yaml +++ b/charts/lodestar/Chart.yaml @@ -1,6 +1,6 @@ apiVersion: v2 -name: ssv-node -description: SSV Node +name: lodestar +description: A Helm chart for Kubernetes # A chart can be either an 'application' or a 'library' chart. # @@ -15,15 +15,4 @@ type: application # This is the chart version. This version number should be incremented each time you make changes # to the chart and its templates, including the app version. # Versions are expected to follow Semantic Versioning (https://semver.org/) -version: 1.0.1 - -# This is the version number of the application being deployed. This version number should be -# incremented each time you make changes to the application. Versions are not expected to -# follow Semantic Versioning. They should reflect the version the application is using. -# It is recommended to use it with quotes. -appVersion: "v0.3.1" - -dependencies: -- name: common - repository: file://../common - version: 1.0.0 +version: 0.1.0 diff --git a/charts/lodestar/templates/_helpers.tpl b/charts/lodestar/templates/_helpers.tpl new file mode 100644 index 000000000..ba8f988be --- /dev/null +++ b/charts/lodestar/templates/_helpers.tpl @@ -0,0 +1,62 @@ +{{/* +Expand the name of the chart. +*/}} +{{- define "lodestar.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 "lodestar.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 "lodestar.chart" -}} +{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }} +{{- end }} + +{{/* +Common labels +*/}} +{{- define "lodestar.labels" -}} +helm.sh/chart: {{ include "lodestar.chart" . }} +{{ include "lodestar.selectorLabels" . }} +{{- if .Chart.AppVersion }} +app.kubernetes.io/version: {{ .Chart.AppVersion | quote }} +{{- end }} +app.kubernetes.io/managed-by: {{ .Release.Service }} +{{- end }} + +{{/* +Selector labels +*/}} +{{- define "lodestar.selectorLabels" -}} +app.kubernetes.io/name: {{ include "lodestar.name" . }} +app.kubernetes.io/instance: {{ .Release.Name }} +{{- end }} + +{{/* +Create the name of the service account to use +*/}} +{{- define "lodestar.serviceAccountName" -}} +{{- if .Values.serviceAccount.create }} +{{- default (include "lodestar.fullname" .) .Values.serviceAccount.name }} +{{- else }} +{{- default "default" .Values.serviceAccount.name }} +{{- end }} +{{- end }} diff --git a/charts/lodestar/templates/configmap.yaml b/charts/lodestar/templates/configmap.yaml new file mode 100644 index 000000000..111c9e6cb --- /dev/null +++ b/charts/lodestar/templates/configmap.yaml @@ -0,0 +1,34 @@ +--- +apiVersion: v1 +kind: ConfigMap +metadata: + name: "{{ include "lodestar.fullname" . }}" + labels: + {{- include "lodestar.labels" . | nindent 4 }} +data: + run.sh: | + #!/bin/sh + + for f in /home/charon/validator_keys/keystore-*.json; do + echo "Importing key ${f}" + + # Import keystore with password. + node /usr/app/packages/cli/bin/lodestar validator import \ + --dataDir="/opt/data" \ + --network="$NETWORK" \ + --importKeystores="$f" \ + --importKeystoresPassword="${f//json/txt}" + done + + echo "Imported all keys" + + exec node /usr/app/packages/cli/bin/lodestar validator \ + --dataDir="/opt/data" \ + --network="$NETWORK" \ + --metrics=true \ + --metrics.address="0.0.0.0" \ + --metrics.port={{ .Values.service.ports.metrics }} \ + --beaconNodes="$BEACON_NODE_ADDRESS" \ + --builder="$BUILDER_API_ENABLED" \ + --builder.selection="$BUILDER_SELECTION" \ + --distributed diff --git a/charts/whitelist/templates/ingress.yaml b/charts/lodestar/templates/ingress.yaml similarity index 81% rename from charts/whitelist/templates/ingress.yaml rename to charts/lodestar/templates/ingress.yaml index 1ee5f4fe3..720a7e104 100644 --- a/charts/whitelist/templates/ingress.yaml +++ b/charts/lodestar/templates/ingress.yaml @@ -1,17 +1,23 @@ {{- if .Values.ingress.enabled -}} -{{- $fullName := include "common.names.fullname" . -}} +{{- $fullName := include "lodestar.fullname" . -}} {{- $svcPort := .Values.service.port -}} {{- if and .Values.ingress.className (not (semverCompare ">=1.18-0" .Capabilities.KubeVersion.GitVersion)) }} {{- if not (hasKey .Values.ingress.annotations "kubernetes.io/ingress.class") }} {{- $_ := set .Values.ingress.annotations "kubernetes.io/ingress.class" .Values.ingress.className}} {{- end }} {{- end }} -apiVersion: {{ include "common.capabilities.ingress.apiVersion" . }} +{{- if semverCompare ">=1.19-0" .Capabilities.KubeVersion.GitVersion -}} +apiVersion: networking.k8s.io/v1 +{{- else if semverCompare ">=1.14-0" .Capabilities.KubeVersion.GitVersion -}} +apiVersion: networking.k8s.io/v1beta1 +{{- else -}} +apiVersion: extensions/v1beta1 +{{- end }} kind: Ingress metadata: name: {{ $fullName }} labels: - {{- include "common.labels.standard" . | nindent 4 }} + {{- include "lodestar.labels" . | nindent 4 }} {{- with .Values.ingress.annotations }} annotations: {{- toYaml . | nindent 4 }} diff --git a/charts/lodestar/templates/service.yaml b/charts/lodestar/templates/service.yaml new file mode 100644 index 000000000..fb0755924 --- /dev/null +++ b/charts/lodestar/templates/service.yaml @@ -0,0 +1,24 @@ +--- +apiVersion: v1 +kind: Service +metadata: + name: "{{ include "lodestar.fullname" . }}" + labels: + {{- include "lodestar.labels" . | nindent 4 }} +spec: + type: {{ .Values.service.type }} + ports: + - port: {{ .Values.service.ports.p2p }} + targetPort: p2p + protocol: TCP + name: p2p + - port: {{ .Values.service.ports.metrics }} + targetPort: metrics + protocol: TCP + name: metrics + - port: {{ .Values.service.ports.http }} + targetPort: http + protocol: TCP + name: http + selector: + {{- include "lodestar.selectorLabels" . | nindent 4 }} diff --git a/charts/graph-node/templates/serviceaccount.yaml b/charts/lodestar/templates/serviceaccount.yaml similarity index 65% rename from charts/graph-node/templates/serviceaccount.yaml rename to charts/lodestar/templates/serviceaccount.yaml index ad5aa4d50..bb615f853 100644 --- a/charts/graph-node/templates/serviceaccount.yaml +++ b/charts/lodestar/templates/serviceaccount.yaml @@ -2,9 +2,9 @@ apiVersion: v1 kind: ServiceAccount metadata: - name: {{ include "common.names.serviceAccountName" . }} + name: {{ include "lodestar.serviceAccountName" . }} labels: - {{- include "common.labels.standard" . | nindent 4 }} + {{- include "lodestar.labels" . | nindent 4 }} {{- with .Values.serviceAccount.annotations }} annotations: {{- toYaml . | nindent 4 }} diff --git a/charts/lodestar/templates/statefulset.yaml b/charts/lodestar/templates/statefulset.yaml new file mode 100644 index 000000000..2f5f6dee6 --- /dev/null +++ b/charts/lodestar/templates/statefulset.yaml @@ -0,0 +1,83 @@ +--- +apiVersion: apps/v1 +kind: StatefulSet +metadata: + name: {{ include "lodestar.fullname" . }} + labels: + {{- include "lodestar.labels" . | nindent 4 }} +spec: + replicas: {{ .Values.replicaCount }} + selector: + matchLabels: + {{- include "lodestar.selectorLabels" . | nindent 6 }} + template: + metadata: + {{- with .Values.podAnnotations }} + annotations: + {{- toYaml . | nindent 8 }} + {{- end }} + labels: + {{- include "lodestar.selectorLabels" . | nindent 8 }} + spec: + {{- with .Values.imagePullSecrets }} + imagePullSecrets: + {{- toYaml . | nindent 8 }} + {{- end }} + serviceAccountName: {{ include "lodestar.serviceAccountName" . }} + 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 }} + command: + - "/bin/sh" + - "-c" + - "/opt/lodestar/run.sh" + ports: + - name: p2p + containerPort: {{ .Values.service.ports.p2p }} + protocol: TCP + - name: metrics + containerPort: {{ .Values.service.ports.metrics }} + protocol: TCP + - name: http + containerPort: {{ .Values.service.ports.http }} + protocol: TCP + livenessProbe: + {{- toYaml .Values.livenessProbe | nindent 12 }} + readinessProbe: + {{- toYaml .Values.readinessProbe | nindent 12 }} + resources: + {{- toYaml .Values.resources | nindent 12 }} + volumeMounts: + - mountPath: /opt/lodestar + name: data + - mountPath: /home/charon/validator_keys + name: validator-keys + env: + {{- toYaml .Values.env | 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 }} + volumes: + - name: data + configMap: + name: {{ include "lodestar.fullname" . }} + defaultMode: 0755 + - name: validator-keys + projected: + sources: + - secret: + name: {{ .Values.secrets.validatorKeys }} diff --git a/charts/lodestar/values.yaml b/charts/lodestar/values.yaml new file mode 100644 index 000000000..0d769dc5c --- /dev/null +++ b/charts/lodestar/values.yaml @@ -0,0 +1,100 @@ +# Default values for lodestar. +# This is a YAML-formatted file. +# Declare variables to be passed into your templates. + +replicaCount: 1 + +image: + repository: chainsafe/lodestar + pullPolicy: IfNotPresent + # Overrides the image tag whose default is the chart appVersion. + tag: "v1.11.3" + +imagePullSecrets: [] +nameOverride: "" +fullnameOverride: "" + +env: + - name: "BEACON_NODE_ADDRESS" + value: "" + - name: "NETWORK" + value: "holesky" + - name: "BUILDER_API_ENABLED" + value: "true" + - name: "BUILDER_SELECTION" + value: "builderonly" + +# -- Kubernetes secrets names +secrets: + # -- validators keys + validatorKeys: "validator-keys" + +serviceAccount: + # Specifies whether a service account should be created + create: true + # Annotations to add to the service account + annotations: {} + # The name of the service account to use. + # If not set and create is true, a name is generated using the fullname template + name: "" + +podAnnotations: {} + +podSecurityContext: + {} + # fsGroup: 2000 + +securityContext: + {} + # capabilities: + # drop: + # - ALL + # readOnlyRootFilesystem: true + # runAsNonRoot: true + # runAsUser: 1000 + +service: + type: ClusterIP + ports: + metrics: 5064 + p2p: 9000 + http: 9596 + +ingress: + enabled: false + className: "" + annotations: + {} + # kubernetes.io/ingress.class: nginx + # kubernetes.io/tls-acme: "true" + hosts: + - host: chart-example.local + paths: + - path: / + pathType: ImplementationSpecific + tls: [] + # - secretName: chart-example-tls + # hosts: + # - chart-example.local + +resources: + {} + # We usually recommend not to specify default resources and to leave this as a conscious + # choice for the user. This also increases chances charts run on environments with little + # resources, such as Minikube. If you do want to specify resources, uncomment the following + # lines, adjust them as necessary, and remove the curly braces after 'resources:'. + # limits: + # cpu: 100m + # memory: 128Mi + # requests: + # cpu: 100m + # memory: 128Mi + +nodeSelector: {} + +tolerations: [] + +affinity: {} + +livnessProbe: null +readinessProbe: null diff --git a/charts/mev-boost/Chart.yaml b/charts/mev-boost/Chart.yaml index 61c8fc3f8..1d8e4c27f 100644 --- a/charts/mev-boost/Chart.yaml +++ b/charts/mev-boost/Chart.yaml @@ -1,32 +1,14 @@ apiVersion: v2 name: mev-boost description: mev-boost allows proof-of-stake Ethereum consensus clients to outsource block construction +version: 1.0.0 home: https://boost.flashbots.net/ keywords: - ethereum - blockchain - mev-boost - -# A chart can be either an 'application' or a 'library' chart. -# -# Application charts are a collection of templates that can be packaged into versioned archives -# to be deployed. -# -# Library charts provide useful utilities or functions for the chart developer. They're included as -# a dependency of application charts to inject those utilities and functions into the rendering -# pipeline. Library charts do not define any templates and therefore cannot be deployed. type: application - -# This is the chart version. This version number should be incremented each time you make changes -# to the chart and its templates, including the app version. -# Versions are expected to follow Semantic Versioning (https://semver.org/) -version: 1.3.2 - -# This is the version number of the application being deployed. This version number should be -# incremented each time you make changes to the application. Versions are not expected to -# follow Semantic Versioning. They should reflect the version the application is using. -# It is recommended to use it with quotes. -appVersion: "v1.3.2" +appVersion: "1.6.0" dependencies: - name: common diff --git a/charts/mev-boost/templates/deployment.yaml b/charts/mev-boost/templates/deployment.yaml index 8c2036904..30f2ba577 100644 --- a/charts/mev-boost/templates/deployment.yaml +++ b/charts/mev-boost/templates/deployment.yaml @@ -26,17 +26,20 @@ spec: {{- end }} serviceAccountName: {{ include "common.names.serviceAccountName" . }} securityContext: - {{- toYaml .Values.podSecurityContext | nindent 8 }} + {{- toYaml .Values.global.podSecurityContext | nindent 8 }} containers: - name: {{ .Chart.Name }} securityContext: - {{- toYaml .Values.securityContext | nindent 12 }} + {{- toYaml .Values.global.securityContext | nindent 12 }} image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}" imagePullPolicy: {{ .Values.image.pullPolicy }} args: - -{{ .Values.global.network }} - - -relays - - {{ pluck .Values.global.network .Values.relays | first }} + - -relay-check + {{- range $relay := index .Values.relays .Values.global.network }} + - -relay + - "{{ $relay }}" + {{- end }} - -addr - 0.0.0.0:{{ .Values.service.port }} - -loglevel diff --git a/charts/mev-boost/templates/hpa.yaml b/charts/mev-boost/templates/hpa.yaml index b546b8826..9db6ea212 100644 --- a/charts/mev-boost/templates/hpa.yaml +++ b/charts/mev-boost/templates/hpa.yaml @@ -1,5 +1,5 @@ {{- if .Values.autoscaling.enabled }} -apiVersion: autoscaling/v2beta1 +apiVersion: autoscaling/v2 kind: HorizontalPodAutoscaler metadata: name: {{ include "common.names.fullname" . }} @@ -17,7 +17,9 @@ spec: - type: Resource resource: name: cpu - targetAverageUtilization: {{ .Values.autoscaling.targetCPUUtilizationPercentage }} + target: + type: Utilization + averageUtilization: {{ .Values.autoscaling.targetCPUUtilizationPercentage }} {{- end }} {{- if .Values.autoscaling.targetMemoryUtilizationPercentage }} - type: Resource diff --git a/charts/mev-boost/values.yaml b/charts/mev-boost/values.yaml index 2514f5175..b84a85e35 100644 --- a/charts/mev-boost/values.yaml +++ b/charts/mev-boost/values.yaml @@ -3,7 +3,7 @@ # Declare variables to be passed into your templates. global: - # Options: mainnet, goerli, ropsten, kiln, sepolia + # Options: mainnet, goerli, sepolia network: "mainnet" ## Credentials to fetch images from private registry @@ -13,14 +13,31 @@ global: serviceAccount: create: true - + ## Pod Security Context + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/ + ## + podSecurityContext: + runAsNonRoot: true + runAsUser: 10000 + fsGroup: 10000 + + securityContext: + readOnlyRootFilesystem: true + runAsNonRoot: true + runAsUser: 10000 + capabilities: + drop: + - ALL + # Relay URLs relays: - mainnet: "https://0xac6e77dfe25ecd6110b8e780608cce0dab71fdd5ebea22a16c0205200f2f8e2e3ad3b71d3499c54ad14d6c21b41a37ae@boost-relay.flashbots.net" - goerli: "https://0xafa4c6985aa049fb79dd37010438cfebeb0f2bd42b115b89dd678dab0670c1de38da0c4e9138c9290a398ecd9a0b3110@builder-relay-goerli.flashbots.net" - ropsten: "https://0xb124d80a00b80815397b4e7f1f05377ccc83aeeceb6be87963ba3649f1e6efa32ca870a88845917ec3f26a8e2aa25c77@builder-relay-ropsten.flashbots.net" - kiln: "https://0xb5246e299aeb782fbc7c91b41b3284245b1ed5206134b0028b81dfb974e5900616c67847c2354479934fc4bb75519ee1@builder-relay-kiln.flashbots.net" - sepolia: "https://0x845bd072b7cd566f02faeb0a4033ce9399e42839ced64e8b2adcfc859ed1e8e1a5a293336a49feac6d9a5edb779be53a@builder-relay-sepolia.flashbots.net" + mainnet: + # Flashbots + - "https://0xac6e77dfe25ecd6110b8e780608cce0dab71fdd5ebea22a16c0205200f2f8e2e3ad3b71d3499c54ad14d6c21b41a37ae@boost-relay.flashbots.net" + goerli: + - "https://0xafa4c6985aa049fb79dd37010438cfebeb0f2bd42b115b89dd678dab0670c1de38da0c4e9138c9290a398ecd9a0b3110@builder-relay-goerli.flashbots.net" + sepolia: + - "https://0x845bd072b7cd566f02faeb0a4033ce9399e42839ced64e8b2adcfc859ed1e8e1a5a293336a49feac6d9a5edb779be53a@builder-relay-sepolia.flashbots.net" # minimum loglevel: trace, debug, info, warn/warning, error, fatal, panic logLevel: info @@ -35,7 +52,7 @@ image: repository: flashbots/mev-boost pullPolicy: IfNotPresent # Overrides the image tag whose default is the chart appVersion. - tag: "v1.3.2" + tag: "1.6" imagePullSecrets: [] nameOverride: "" @@ -52,17 +69,6 @@ serviceAccount: podAnnotations: {} -podSecurityContext: {} - # fsGroup: 2000 - -securityContext: {} - # capabilities: - # drop: - # - ALL - # readOnlyRootFilesystem: true - # runAsNonRoot: true - # runAsUser: 1000 - service: type: ClusterIP port: 18550 diff --git a/charts/nethermind/.helmignore b/charts/nethermind/.helmignore deleted file mode 100644 index 0e8a0eb36..000000000 --- a/charts/nethermind/.helmignore +++ /dev/null @@ -1,23 +0,0 @@ -# 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/ diff --git a/charts/nethermind/Chart.lock b/charts/nethermind/Chart.lock deleted file mode 100644 index c35eb1d36..000000000 --- a/charts/nethermind/Chart.lock +++ /dev/null @@ -1,6 +0,0 @@ -dependencies: -- name: common - repository: file://../common - version: 1.0.0 -digest: sha256:07cebde439abe4ba19bb28e844b7419dab83c7f613886416aaf3ec08e8059144 -generated: "2022-03-07T12:34:15.748651288+03:00" diff --git a/charts/nethermind/Chart.yaml b/charts/nethermind/Chart.yaml deleted file mode 100644 index d90772001..000000000 --- a/charts/nethermind/Chart.yaml +++ /dev/null @@ -1,20 +0,0 @@ -apiVersion: v2 -name: nethermind -description: .NET Core Ethereum client -type: application -version: 2.1.7 -appVersion: "v1.14.3" -keywords: - - ethereum - - blockchain - - nethermind - - p2p -home: https://nethermind.io/ -sources: - - https://github.com/NethermindEth/nethermind -icon: https://raw.githubusercontent.com/ethereum/ethereum-org/master/public/images/logos/ETHEREUM-ICON_Black.png - -dependencies: -- name: common - repository: file://../common - version: 1.0.0 diff --git a/charts/nethermind/templates/_helpers.yaml b/charts/nethermind/templates/_helpers.yaml deleted file mode 100644 index 17f5cf2a9..000000000 --- a/charts/nethermind/templates/_helpers.yaml +++ /dev/null @@ -1,3 +0,0 @@ -{{- define "nethermind.p2pPort" -}} -{{- printf "30303" -}} -{{- end -}} diff --git a/charts/nethermind/templates/clusterrole.yaml b/charts/nethermind/templates/clusterrole.yaml deleted file mode 100644 index 6d7136bd1..000000000 --- a/charts/nethermind/templates/clusterrole.yaml +++ /dev/null @@ -1,10 +0,0 @@ -{{- if or .Values.global.rbac.create .Values.rbac.create }} -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: {{ include "common.names.clusterRoleName" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -rules: -{{- toYaml .Values.rbac.clusterRules | nindent 0 }} -{{- end }} diff --git a/charts/nethermind/templates/clusterrolebinding.yaml b/charts/nethermind/templates/clusterrolebinding.yaml deleted file mode 100644 index 87d636dac..000000000 --- a/charts/nethermind/templates/clusterrolebinding.yaml +++ /dev/null @@ -1,16 +0,0 @@ -{{- if or .Values.global.rbac.create .Values.rbac.create }} -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: {{ include "common.names.clusterRoleName" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: {{ include "common.names.clusterRoleName" . }} -subjects: - - kind: ServiceAccount - name: {{ include "common.names.serviceAccountName" . }} - namespace: {{ .Release.Namespace }} -{{- end }} diff --git a/charts/nethermind/templates/pdb.yaml b/charts/nethermind/templates/pdb.yaml deleted file mode 100644 index 4ef63f0ff..000000000 --- a/charts/nethermind/templates/pdb.yaml +++ /dev/null @@ -1,18 +0,0 @@ -{{- if .Values.podDisruptionBudget.enabled }} -apiVersion: {{ include "common.capabilities.policy.apiVersion" . }} -kind: PodDisruptionBudget -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -spec: -{{- if .Values.podDisruptionBudget.minAvailable }} - minAvailable: {{ .Values.podDisruptionBudget.minAvailable }} -{{- end }} -{{- if .Values.podDisruptionBudget.maxUnavailable }} - maxUnavailable: {{ .Values.podDisruptionBudget.maxUnavailable }} -{{- end }} - selector: - matchLabels: - {{- include "common.labels.matchLabels" . | nindent 6 }} -{{- end }} diff --git a/charts/nethermind/templates/prometheusrules.yaml b/charts/nethermind/templates/prometheusrules.yaml deleted file mode 100644 index ef3d505fe..000000000 --- a/charts/nethermind/templates/prometheusrules.yaml +++ /dev/null @@ -1,35 +0,0 @@ -{{- if and (or .Values.global.metrics.enabled .Values.metrics.enabled) - (or .Values.global.metrics.prometheusRule.enabled .Values.metrics.prometheusRule.enabled) }} -apiVersion: monitoring.coreos.com/v1 -kind: PrometheusRule -metadata: - name: {{ include "common.names.fullname" . }} - {{- if .Values.metrics.prometheusRule.namespace }} - namespace: {{ .Values.metrics.prometheusRule.namespace }} - {{- else }} - namespace: {{ .Release.Namespace | quote }} - {{- end }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.metrics.prometheusRule.additionalLabels }} - {{- toYaml .Values.metrics.prometheusRule.additionalLabels | nindent 4 }} - {{- end }} -spec: - groups: - {{- with .Values.metrics.prometheusRule.rules }} - - name: {{ include "common.names.fullname" $ }} - rules: {{- tpl (toYaml .) $ | nindent 8 }} - {{- end }} - {{- if .Values.metrics.prometheusRule.default }} - - name: {{ include "common.names.fullname" $ }}-default - rules: - - alert: NethermindNodeDown - expr: up{job='{{ include "common.names.fullname" . }}'} == 0 - for: 1m - labels: - severity: critical - annotations: - summary: Nethermind node is down - description: Check {{ printf "{{ $labels.pod }}" }} node in namespace {{ printf "{{ $labels.namespace }}" }} - {{- end }} -{{- end }} \ No newline at end of file diff --git a/charts/nethermind/templates/role.yaml b/charts/nethermind/templates/role.yaml deleted file mode 100644 index dfbc0fe48..000000000 --- a/charts/nethermind/templates/role.yaml +++ /dev/null @@ -1,10 +0,0 @@ -{{- if or .Values.global.rbac.create .Values.rbac.create -}} -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -rules: -{{- toYaml .Values.rbac.rules | nindent 0 }} -{{- end }} diff --git a/charts/nethermind/templates/rolebinding.yaml b/charts/nethermind/templates/rolebinding.yaml deleted file mode 100644 index 1fdb617ba..000000000 --- a/charts/nethermind/templates/rolebinding.yaml +++ /dev/null @@ -1,15 +0,0 @@ -{{- if or .Values.global.rbac.create .Values.rbac.create }} -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: {{ include "common.names.serviceAccountName" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: {{ include "common.names.serviceAccountName" . }} -subjects: - - kind: ServiceAccount - name: {{ include "common.names.serviceAccountName" . }} -{{- end }} diff --git a/charts/nethermind/templates/secret.yaml b/charts/nethermind/templates/secret.yaml deleted file mode 100644 index 2981fe224..000000000 --- a/charts/nethermind/templates/secret.yaml +++ /dev/null @@ -1,11 +0,0 @@ -{{- if .Values.global.JWTSecret }} -apiVersion: v1 -kind: Secret -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -type: Opaque -data: - jwtsecret: {{ .Values.global.JWTSecret | b64enc | quote }} -{{- end }} diff --git a/charts/nethermind/templates/service-p2p.yaml b/charts/nethermind/templates/service-p2p.yaml deleted file mode 100644 index 720b9101c..000000000 --- a/charts/nethermind/templates/service-p2p.yaml +++ /dev/null @@ -1,42 +0,0 @@ -{{- if .Values.p2pNodePort.enabled -}} -{{- range $i, $e := until (int .Values.global.replicaCount) }} -{{- $port := add $.Values.p2pNodePort.startAt $i -}} -{{- if hasKey $.Values.p2pNodePort.replicaToNodePort ($i | toString) -}} - {{ $port = index $.Values.p2pNodePort.replicaToNodePort ($i | toString) }} -{{- end }} - ---- -apiVersion: v1 -kind: Service -metadata: - name: {{ include "common.names.fullname" $ }}-{{ $i }} - labels: - {{- include "common.labels.standard" $ | nindent 4 }} - pod: "{{ include "common.names.fullname" $ }}-{{ $i }}" - type: p2p - {{- with $.Values.p2pNodePort.annotations }} - annotations: - {{- toYaml . | nindent 4 }} - {{- end }} -spec: - type: {{ $.Values.p2pNodePort.type }} - externalTrafficPolicy: Local - ports: - - name: p2p-tcp - port: {{ include "nethermind.p2pPort" $ }} - protocol: TCP - targetPort: p2p-tcp - nodePort: {{ $port }} - {{- if eq $.Values.p2pNodePort.type "NodePort" }} - - name: p2p-udp - port: {{ include "nethermind.p2pPort" $ }} - protocol: UDP - targetPort: p2p-udp - nodePort: {{ $port }} - {{- end }} - selector: - {{- include "common.labels.matchLabels" $ | nindent 4 }} - statefulset.kubernetes.io/pod-name: "{{ include "common.names.fullname" $ }}-{{ $i }}" - -{{- end }} -{{- end }} diff --git a/charts/nethermind/templates/service.yaml b/charts/nethermind/templates/service.yaml deleted file mode 100644 index 35df5a36a..000000000 --- a/charts/nethermind/templates/service.yaml +++ /dev/null @@ -1,43 +0,0 @@ ---- -apiVersion: v1 -kind: Service -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -spec: - type: {{ .Values.service.type }} -{{- if .Values.svcHeadless }} - clusterIP: None -{{- end }} -{{- if .Values.sessionAffinity.enabled }} - sessionAffinity: ClientIP - sessionAffinityConfig: - clientIP: - timeoutSeconds: {{ .Values.sessionAffinity.timeoutSeconds }} -{{- end }} - ports: - {{- if .Values.jsonrpc.enabled }} - - port: {{ .Values.jsonrpc.ports.rest }} - targetPort: json-rest - protocol: TCP - name: json-rest - - port: {{ .Values.jsonrpc.ports.websocket }} - targetPort: json-ws - protocol: TCP - name: json-ws - {{- end }} - {{- if .Values.global.JWTSecret }} - - port: {{ .Values.jsonrpc.engine.port }} - targetPort: engine - protocol: TCP - name: engine - {{- end }} - {{- if .Values.global.metrics.enabled }} - - port: {{ .Values.metrics.port }} - targetPort: metrics - protocol: TCP - name: metrics - {{- end }} - selector: - {{- include "common.labels.matchLabels" . | nindent 4 }} diff --git a/charts/nethermind/templates/servicemonitor.yaml b/charts/nethermind/templates/servicemonitor.yaml deleted file mode 100644 index 9ecffc6ca..000000000 --- a/charts/nethermind/templates/servicemonitor.yaml +++ /dev/null @@ -1,42 +0,0 @@ -{{- if and (or .Values.global.metrics.enabled .Values.metrics.enabled) - (or .Values.global.metrics.serviceMonitor.enabled .Values.metrics.serviceMonitor.enabled) }} -apiVersion: monitoring.coreos.com/v1 -kind: ServiceMonitor -metadata: - name: {{ template "common.names.fullname" . }} - {{- if .Values.metrics.serviceMonitor.namespace }} - namespace: {{ .Values.metrics.serviceMonitor.namespace }} - {{- else }} - namespace: {{ .Release.Namespace | quote }} - {{- end }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.metrics.serviceMonitor.additionalLabels }} - {{- toYaml .Values.metrics.serviceMonitor.additionalLabels | nindent 4 }} - {{- end }} -spec: - endpoints: - - port: metrics - path: /metrics - {{- if .Values.metrics.serviceMonitor.interval }} - interval: {{ .Values.metrics.serviceMonitor.interval }} - {{- end }} - {{- if .Values.metrics.serviceMonitor.scrapeTimeout }} - scrapeTimeout: {{ .Values.metrics.serviceMonitor.scrapeTimeout }} - {{- end }} - {{- if .Values.metrics.serviceMonitor.honorLabels }} - honorLabels: {{ .Values.metrics.serviceMonitor.honorLabels }} - {{- end }} - {{- if .Values.metrics.serviceMonitor.relabelings }} - relabelings: {{- toYaml .Values.metrics.serviceMonitor.relabelings | nindent 6 }} - {{- end }} - {{- if .Values.metrics.serviceMonitor.metricRelabelings }} - metricRelabelings: {{- toYaml .Values.metrics.serviceMonitor.metricRelabelings | nindent 6 }} - {{- end }} - namespaceSelector: - matchNames: - - {{ .Release.Namespace }} - selector: - matchLabels: - {{- include "common.labels.matchLabels" . | nindent 6 }} -{{- end }} diff --git a/charts/nethermind/templates/statefulset.yaml b/charts/nethermind/templates/statefulset.yaml deleted file mode 100644 index b1ddb4bbf..000000000 --- a/charts/nethermind/templates/statefulset.yaml +++ /dev/null @@ -1,264 +0,0 @@ ---- -kind: StatefulSet -apiVersion: {{ include "common.capabilities.statefulset.apiVersion" . }} -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.statefulset" . | nindent 4 }} -spec: - replicas: {{ .Values.global.replicaCount }} - podManagementPolicy: "Parallel" - selector: - matchLabels: - {{- include "common.labels.matchLabels" . | nindent 6 }} - serviceName: {{ include "common.names.fullname" . }} - template: - metadata: - labels: - {{- include "common.labels.matchLabels" . | nindent 8 }} - spec: - {{- with (concat .Values.imagePullSecrets .Values.global.imagePullSecrets) }} - imagePullSecrets: - {{- toYaml . | nindent 8 }} - {{- end }} - {{- with .Values.nodeSelector }} - nodeSelector: - {{- toYaml . | nindent 8 }} - {{- end }} - {{- with .Values.affinity }} - affinity: - {{- toYaml . | nindent 8 }} - {{- end }} - {{- with .Values.tolerations }} - tolerations: - {{- toYaml . | nindent 8 }} - {{- end }} - {{- if .Values.terminationGracePeriodSeconds }} - terminationGracePeriodSeconds: {{ .Values.terminationGracePeriodSeconds }} - {{- end }} - serviceAccountName: {{ include "common.names.serviceAccountName" . }} - priorityClassName: {{ .Values.priorityClassName | quote }} - securityContext: - {{- toYaml .Values.securityContext | nindent 8 }} - initContainers: - - name: init - image: "{{ .Values.initImage.repository }}:{{ .Values.initImage.tag }}" - imagePullPolicy: {{ .Values.initImage.pullPolicy }} - securityContext: - runAsNonRoot: false - runAsUser: 0 - env: - - name: POD_IP - valueFrom: - fieldRef: - fieldPath: status.podIP - - name: POD_NAME - valueFrom: - fieldRef: - fieldPath: metadata.name - - name: POD_NAMESPACE - valueFrom: - fieldRef: - fieldPath: metadata.namespace - - name: NODE_NAME - valueFrom: - fieldRef: - fieldPath: spec.nodeName - command: - - sh - - -c - - > - echo "Namespace: ${POD_NAMESPACE} Pod: ${POD_NAME}"; - {{- if .Values.p2pNodePort.enabled }} - {{- if eq .Values.p2pNodePort.type "LoadBalancer" }} - until [ -n "$(kubectl -n ${POD_NAMESPACE} get svc/${POD_NAME} -o jsonpath='{.status.loadBalancer.ingress[0].ip}')" ]; do echo "Waiting for load balancer gets an IP" && sleep 10; done; - export EXTERNAL_PORT=$(kubectl -n ${POD_NAMESPACE} get services -l "pod in (${POD_NAME}), type in (p2p)" -o jsonpath='{.items[0].spec.ports[0].nodePort}'); - export EXTERNAL_IP=$(kubectl -n ${POD_NAMESPACE} get svc/${POD_NAME} -o jsonpath='{.status.loadBalancer.ingress[0].ip}'); - {{- else }} - export EXTERNAL_PORT=$(kubectl get services -l "pod in (${POD_NAME}), type in (p2p)" -o jsonpath='{.items[0].spec.ports[0].nodePort}'); - export EXTERNAL_IP=$(kubectl get nodes "${NODE_NAME}" -o jsonpath='{.status.addresses[?(@.type=="ExternalIP")].address}'); - {{- end }} - echo "EXTERNAL_PORT=$EXTERNAL_PORT" > /env/init-nodeport; - echo "EXTERNAL_IP=$EXTERNAL_IP" >> /env/init-nodeport; - cat /env/init-nodeport; - {{- end }} - {{- if and .Values.persistence.enabled .Values.initChownData }} - mkdir -p /data && chown -R {{ .Values.securityContext.runAsUser }}:{{ .Values.securityContext.runAsUser }} /data; - {{- end }} - volumeMounts: - - name: env-nodeport - mountPath: /env - containers: - - name: {{ .Chart.Name }} - image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}" - imagePullPolicy: {{ .Values.image.pullPolicy }} - workingDir: /data/nethermind - command: - - sh - - -ac - - > - {{- if .Values.p2pNodePort.enabled }} - . /env/init-nodeport; - {{- end }} - exec /nethermind/Nethermind.Runner - {{- if eq .Values.global.network "gnosis" }} - --config=xdai - {{- else }} - --config={{ .Values.global.network }} - {{- end }} - --datadir=/data/nethermind - {{- if .Values.jsonrpc.enabled }} - --JsonRpc.Enabled={{ .Values.jsonrpc.enabled }} - --JsonRpc.EnabledModules={{ .Values.jsonrpc.modules | join "," }} - --JsonRpc.Host={{ .Values.jsonrpc.host }} - --JsonRpc.Port={{ .Values.jsonrpc.ports.rest }} - --JsonRpc.WebSocketsPort={{ .Values.jsonrpc.ports.websocket }} - {{- end }} - {{- if .Values.global.JWTSecret }} - --JsonRpc.JwtSecretFile=/secret/jwtsecret - --JsonRpc.EnginePort={{ .Values.jsonrpc.engine.port }} - --JsonRpc.EngineHost={{ .Values.jsonrpc.engine.host }} - --JsonRpc.EngineEnabledModules={{ .Values.jsonrpc.engine.modules | join "," }} - {{- end }} - {{- if .Values.global.metrics.enabled }} - --Metrics.Enabled={{ .Values.global.metrics.enabled }} - --Metrics.ExposePort={{ .Values.metrics.port }} - {{- end }} - {{- if .Values.p2pNodePort.enabled }} - --Network.ExternalIp=$EXTERNAL_IP - --Network.P2PPort=$EXTERNAL_PORT - --Network.DiscoveryPort=$EXTERNAL_PORT - {{- else }} - --Network.ExternalIp=$(POD_IP) - --Network.P2PPort={{ include "nethermind.p2pPort" . }} - --Network.DiscoveryPort={{ include "nethermind.p2pPort" . }} - {{- end }} - {{- if .Values.merge.enabled }} - --Merge.Enabled=true - {{- if .Values.merge.feeRecipient }} - --Merge.FeeRecipient={{ .Values.merge.feeRecipient }} - {{- end }} - {{- if .Values.merge.builderRelayUrl }} - --Merge.BuilderRelayUrl={{ .Values.merge.builderRelayUrl }} - {{- end }} - {{- if .Values.merge.finalTotalDifficulty }} - --Merge.FinalTotalDifficulty={{ .Values.merge.finalTotalDifficulty }} - {{- end }} - {{- if .Values.merge.terminalTotalDifficulty }} - --Merge.TerminalTotalDifficulty={{ .Values.merge.terminalTotalDifficulty }} - {{- end }} - {{- end }} - {{- range .Values.extraFlags }} - {{ . | quote }} - {{- end }} - ports: - {{- if .Values.jsonrpc.enabled }} - - name: json-rest - containerPort: {{ .Values.jsonrpc.ports.rest }} - protocol: TCP - - name: json-ws - containerPort: {{ .Values.jsonrpc.ports.websocket }} - protocol: TCP - {{- end }} - {{- if .Values.global.JWTSecret }} - - name: engine - protocol: TCP - containerPort: {{ .Values.jsonrpc.engine.port }} - {{- end }} - {{- if .Values.global.metrics.enabled }} - - name: metrics - containerPort: {{ .Values.metrics.port }} - protocol: TCP - {{- end }} - {{- if .Values.p2pNodePort.enabled }} - - name: p2p-tcp - containerPort: {{ include "nethermind.p2pPort" . }} - protocol: TCP - - name: p2p-udp - containerPort: {{ include "nethermind.p2pPort" . }} - protocol: UDP - {{- end }} - volumeMounts: - - name: data - mountPath: /data/nethermind - {{- if .Values.global.JWTSecret }} - - name: jwtsecret - mountPath: /secret - readOnly: true - {{- end }} - - name: env-nodeport - mountPath: /env - resources: - {{- toYaml .Values.resources | nindent 12 }} - {{- if .Values.jsonrpc.enabled }} - - name: sidecar - image: "{{ .Values.sidecar.repository }}:{{ .Values.sidecar.tag }}" - imagePullPolicy: {{ .Values.sidecar.pullPolicy }} - env: - - name: SERVER_BINDADDR - value: "{{ .Values.sidecar.bindAddr }}:{{ .Values.sidecar.bindPort }}" - - name: CLIENT_PORT - value: {{ .Values.jsonrpc.ports.rest | quote }} - {{- if .Values.global.JWTSecret }} - - name: CLIENT_AUTHORIZATIONTYPE - value: "bearer" - - name: CLIENT_JWTSECRET - value: {{ .Values.global.JWTSecret | quote }} - {{- end }} - ports: - - containerPort: {{ .Values.sidecar.bindPort }} - name: sidecar - protocol: TCP - {{- if or .Values.global.livenessProbe.enabled .Values.livenessProbe.enabled }} - livenessProbe: - initialDelaySeconds: {{ .Values.livenessProbe.initialDelaySeconds }} - timeoutSeconds: {{ .Values.livenessProbe.timeoutSeconds }} - periodSeconds: {{ .Values.livenessProbe.periodSeconds }} - failureThreshold: {{ .Values.livenessProbe.failureThreshold }} - successThreshold: {{ .Values.livenessProbe.successThreshold }} - httpGet: - path: {{ .Values.livenessProbe.httpGet.path }} - port: {{ .Values.livenessProbe.httpGet.port }} - scheme: {{ .Values.livenessProbe.httpGet.scheme }} - {{- end }} - {{- if or .Values.global.readinessProbe.enabled .Values.readinessProbe.enabled }} - readinessProbe: - initialDelaySeconds: {{ .Values.readinessProbe.initialDelaySeconds }} - timeoutSeconds: {{ .Values.readinessProbe.timeoutSeconds }} - periodSeconds: {{ .Values.readinessProbe.periodSeconds }} - failureThreshold: {{ .Values.readinessProbe.failureThreshold }} - successThreshold: {{ .Values.readinessProbe.successThreshold }} - httpGet: - path: {{ .Values.readinessProbe.httpGet.path }} - port: {{ .Values.readinessProbe.httpGet.port }} - scheme: {{ .Values.readinessProbe.httpGet.scheme }} - {{- end }} - {{- end }} - volumes: - {{- if .Values.global.JWTSecret }} - - name: jwtsecret - secret: - secretName: {{ include "common.names.fullname" . }} - {{- end }} - - name: env-nodeport - emptyDir: {} -{{- if (not .Values.persistence.enabled) }} - - name: data - emptyDir: {} -{{- else }} - volumeClaimTemplates: - - metadata: - name: data - labels: - {{- include "common.labels.statefulset" . | nindent 10 }} - {{- with .Values.persistence.annotations }} - annotations: - {{ toYaml . | nindent 10 | trim }} - {{- end }} - spec: - accessModes: {{ .Values.persistence.accessModes }} - storageClassName: {{ .Values.persistence.storageClassName }} - resources: - requests: - storage: {{ .Values.persistence.size | quote }} - {{- end }} diff --git a/charts/nethermind/templates/vpa.yaml b/charts/nethermind/templates/vpa.yaml deleted file mode 100644 index 3a4fe8f2f..000000000 --- a/charts/nethermind/templates/vpa.yaml +++ /dev/null @@ -1,20 +0,0 @@ -{{- if and .Values.enabled .Values.verticalAutoscaler.enabled }} -apiVersion: autoscaling.k8s.io/v1beta2 -kind: VerticalPodAutoscaler -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -spec: - targetRef: - apiVersion: "apps/v1" - kind: StatefulSet - name: {{ include "common.names.fullname" . }} - updatePolicy: - updateMode: {{ .Values.verticalAutoscaler.updateMode | default "Off" | quote }} - {{- if .Values.verticalAutoscaler.containerPolicies }} - resourcePolicy: - containerPolicies: - {{ tpl .Values.verticalAutoscaler.containerPolicies . | nindent 6 | trim }} - {{- end }} -{{- end }} diff --git a/charts/nethermind/values.yaml b/charts/nethermind/values.yaml deleted file mode 100644 index a82e34be4..000000000 --- a/charts/nethermind/values.yaml +++ /dev/null @@ -1,404 +0,0 @@ -# Default values for nethermind. -# This is a YAML-formatted file. -# Declare variables to be passed into your templates. - -global: - replicaCount: 1 - - ## Eth2 network ID - ## - network: mainnet - - ## JSON Web Token (JWT) authentication is used to secure the communication - ## between the beacon node and execution client. You can generate a JWT using - ## a command line tool, for example: - ## openssl rand -hex 32 > token.txt - ## - JWTSecret: "" - - ## Credentials to fetch images from private registry - ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/ - ## - imagePullSecrets: [] - - ## Service account - ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ - ## Additional settings could be made in non-global section. - ## - serviceAccount: - # Specifies whether a service account should be created - create: true - - ## RBAC configuration. - ## ref: https://kubernetes.io/docs/reference/access-authn-authz/rbac/ - ## Additional settings could be made in non-global section. - ## - rbac: - ## Specifies whether RBAC resources are to be created - ## - create: true - - ## Monitoring - ## Additional settings could be made in non-global section. - ## - metrics: - ## Whether to enable metrics collection or not - ## - enabled: true - - ## Prometheus Service Monitor - ## ref: https://github.com/coreos/prometheus-operator - ## https://github.com/coreos/prometheus-operator/blob/master/Documentation/api.md#endpoint - ## - serviceMonitor: - ## Create ServiceMonitor resource(s) for scraping metrics using PrometheusOperator - ## - enabled: false - - ## Custom PrometheusRule to be defined - ## ref: https://github.com/coreos/prometheus-operator#customresourcedefinitions - ## - prometheusRule: - ## Create a custom prometheusRule Resource for scraping metrics using PrometheusOperator - ## - enabled: false - - ## Configure liveness and readiness probes - ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/ - ## NB! readinessProbe and livenessProbe must be disabled before fully synced - ## Additional settings could be made in non-global section. - ## - livenessProbe: - enabled: true - - readinessProbe: - enabled: true - -## Init image is used to chown data volume, initialise genesis, etc. -## -initImage: - repository: "bitnami/kubectl" - tag: "1.24" - pullPolicy: IfNotPresent - -## Sidecar image is used to perform Liveness/Readiness probes. -## -sidecar: - repository: "europe-west4-docker.pkg.dev/stakewiselabs/public/ethnode-sidecar" - tag: "v1.0.5" - pullPolicy: IfNotPresent - bindAddr: "0.0.0.0" - bindPort: 3000 - -## Nethermind Image -## -image: - repository: nethermind/nethermind - pullPolicy: IfNotPresent - # Overrides the image tag whose default is the chart appVersion. - tag: "1.14.3" - -## Credentials to fetch images from private registry -## ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/ -## -imagePullSecrets: [] -nameOverride: "" -fullnameOverride: "" - -## Nethermind Settings -## - -## Extra flags to pass to the node -## -extraFlags: [] - -jsonrpc: - enabled: true - # Defines which RPC modules should be enabled. - # Built in modules are: Admin, Baseline, Clique, Consensus, - # Db, Debug, Deposit, Erc20, Eth, Evm, - # Health Mev, NdmConsumer, NdmProvider, - # Net, Nft, Parity, Personal, Proof, Subscribe, - # Trace, TxPool, Vault, Web3. - modules: - - Eth - - Subscribe - - Trace - - TxPool - - Web3 - - Personal - - Proof - - Net - - Parity - - Health - - Engine - host: "0.0.0.0" - ports: - rest: "8545" - websocket: "8546" - engine: - port: "8551" - host: "0.0.0.0" - modules: - - Net - - Eth - - Subscribe - - Engine - - Web3 - - Client - -merge: - # Defines whether the Merge plugin is enabled bundles are allowed. - enabled: false - # Account to be used by the block author. - # If it is not specified the address zero will be used. - feeRecipient: "" - # URL to Builder Relay. If set when building blocks nethermind will send them to the relay. - builderRelayUrl: "" - # Final total difficulty is total difficulty of the last PoW block. - # FinalTotalDifficulty >= TerminalTotalDifficulty. - finalTotalDifficulty: "" - # Terminal total difficulty used for transition process. - terminalTotalDifficulty: "" - -serviceAccount: - # Annotations to add to the service account - annotations: {} - # The name of the service account to use. - # If not set and create is true, a name is generated using the fullname template - name: "" - -## Additional labels for all resources -## -additionalLabels: - client-type: "execution" - -## Termination Grace Period -## ref: https://kubernetes.io/docs/tasks/run-application/force-delete-stateful-set-pod/#delete-pods -## -terminationGracePeriodSeconds: 300 - -## Pod Security Context -## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/ -## -securityContext: - fsGroup: 1000 - runAsUser: 1000 - -## RBAC configuration. -## ref: https://kubernetes.io/docs/reference/access-authn-authz/rbac/ -## -rbac: - # The name of the cluster role to use. - # If not set and create is true, a name is generated using the fullname template - name: "" - ## Required ClusterRole rules - ## - clusterRules: - ## Required to obtain the nodes external IP - ## - - apiGroups: [""] - resources: - - "nodes" - verbs: - - "get" - - "list" - - "watch" - ## Required Role rules - ## - rules: - ## Required to get information about the serices nodePort. - ## - - apiGroups: [""] - resources: - - "services" - verbs: - - "get" - - "list" - - "watch" - -service: - type: ClusterIP - -## Defines whether the service must be headless -## -svcHeadless: true - -## Configure session affinity for validator clients to hit the same beacon node -## for the period specified in `timeoutSeconds` -## ref: https://kubernetes.io/docs/concepts/services-networking/service/#proxy-mode-userspace -## -sessionAffinity: - # Whether to enable session affinity or not - enabled: false - # The session duration in seconds - timeoutSeconds: 86400 - -## When p2pNodePort is enabled, your P2P port will be exposed via service type NodePort. -## This will generate a service for each replica, with a port binding via NodePort. -## This is useful if you want to expose and announce your node to the Internet. -## -p2pNodePort: - ## @param p2pNodePort.enabled Expose P2P port via NodePort - ## - enabled: false - ## @param p2pNodePort.annotations - ## - annotations: {} - ## @param p2pNodePort.type - ## Options: NodePort, LoadBalancer - type: NodePort - ## @param p2pNodePort.startAt The ports allocation will start from this value - ## - startAt: 31200 - ## @param p2pNodePort.replicaToNodePort Overwrite a port for specific replicas - ## @default -- See `values.yaml` for example - replicaToNodePort: {} - # "0": 32345 - # "3": 32348 - -resources: {} - # We usually recommend not to specify default resources and to leave this as a conscious - # choice for the user. This also increases chances charts run on environments with little - # resources, such as Minikube. If you do want to specify resources, uncomment the following - # lines, adjust them as necessary, and remove the curly braces after 'resources:'. - # limits: - # cpu: 100m - # memory: 128Mi - # requests: - # cpu: 100m - # memory: 128Mi - -## Used to assign priority to pods -## ref: https://kubernetes.io/docs/concepts/configuration/pod-priority-preemption/ -## -priorityClassName: "" - -## Enable pod disruption budget -## ref: https://kubernetes.io/docs/tasks/run-application/configure-pdb -## -podDisruptionBudget: - enabled: true - maxUnavailable: 1 - -## Vertical Pod Autoscaler config -## ref: https://github.com/kubernetes/autoscaler/tree/master/vertical-pod-autoscaler -## -verticalAutoscaler: - # If true a VPA object will be created for the StatefulSet - enabled: false - updateMode: Off - containerPolicies: {} - -nodeSelector: {} - -tolerations: [] - -## Affinity for pod assignment -## ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity -## -## Example: -## affinity: -## podAntiAffinity: -## requiredDuringSchedulingIgnoredDuringExecution: -## - labelSelector: -## matchExpressions: -## - key: app.kubernetes.io/name -## operator: In -## values: -## - nethermind -## topologyKey: kubernetes.io/hostname -## -affinity: {} - -## Configure liveness and readiness probes -## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/ -## NB! readinessProbe and livenessProbe must be disabled before genesis -## -livenessProbe: - initialDelaySeconds: 900 - timeoutSeconds: 3 - periodSeconds: 30 - failureThreshold: 3 - successThreshold: 1 - httpGet: - path: /eth1/liveness - port: sidecar - scheme: HTTP - -readinessProbe: - initialDelaySeconds: 60 - timeoutSeconds: 3 - periodSeconds: 30 - failureThreshold: 30 - successThreshold: 2 - httpGet: - path: /eth1/readiness - port: sidecar - scheme: HTTP - -## If false, data ownership will not be reset at startup -## This allows the nethermind node to be run with an arbitrary user -## -initChownData: true - -## Whether or not to allocate persistent volume disk for the data directory. -## In case of pod failure, the pod data directory will still persist. -## -persistence: - enabled: true - storageClassName: "" - accessModes: - - ReadWriteOnce - size: 250Gi - annotations: {} - -## Monitoring -## -metrics: - ## Metrics port to expose metrics for Prometheus - ## - port: 8008 - - ## Prometheus Service Monitor - ## ref: https://github.com/coreos/prometheus-operator - ## https://github.com/coreos/prometheus-operator/blob/master/Documentation/api.md#endpoint - ## - serviceMonitor: - ## The namespace in which the ServiceMonitor will be created - ## - namespace: "" - ## The interval at which metrics should be scraped - ## - interval: 30s - ## The timeout after which the scrape is ended - ## - scrapeTimeout: "" - ## Metrics RelabelConfigs to apply to samples before scraping. - ## - relabellings: [] - ## Metrics RelabelConfigs to apply to samples before ingestion. - ## - metricRelabelings: [] - ## Specify honorLabels parameter to add the scrape endpoint - ## - honorLabels: false - ## Additional labels that can be used so ServiceMonitor resource(s) can be discovered by Prometheus - ## - additionalLabels: {} - ## Custom PrometheusRule to be defined - ## ref: https://github.com/coreos/prometheus-operator#customresourcedefinitions - ## - prometheusRule: - ## Create a default set of Alerts - ## - default: true - ## The namespace in which the prometheusRule will be created - ## - namespace: "" - ## Additional labels for the prometheusRule - ## - additionalLabels: {} - ## Custom Prometheus rules - ## - rules: [] diff --git a/charts/nimbus/.helmignore b/charts/nimbus/.helmignore deleted file mode 100644 index 0e8a0eb36..000000000 --- a/charts/nimbus/.helmignore +++ /dev/null @@ -1,23 +0,0 @@ -# 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/ diff --git a/charts/nimbus/Chart.lock b/charts/nimbus/Chart.lock deleted file mode 100644 index 7763e5f58..000000000 --- a/charts/nimbus/Chart.lock +++ /dev/null @@ -1,6 +0,0 @@ -dependencies: -- name: common - repository: file://../common - version: 1.0.0 -digest: sha256:07cebde439abe4ba19bb28e844b7419dab83c7f613886416aaf3ec08e8059144 -generated: "2022-03-07T12:38:53.953740393+03:00" diff --git a/charts/nimbus/Chart.yaml b/charts/nimbus/Chart.yaml deleted file mode 100644 index 12f8dbc99..000000000 --- a/charts/nimbus/Chart.yaml +++ /dev/null @@ -1,39 +0,0 @@ -apiVersion: v2 -name: nimbus -description: Nimbus - an Ethereum 2.0 Client for Resource-Restricted Devices -icon: https://raw.githubusercontent.com/ethereum/ethereum-org/master/public/images/logos/ETHEREUM-ICON_Black.png -home: https://stakewise.io/ -sources: - - https://github.com/status-im/nimbus-eth2 - -# A chart can be either an 'application' or a 'library' chart. -# -# Application charts are a collection of templates that can be packaged into versioned archives -# to be deployed. -# -# Library charts provide useful utilities or functions for the chart developer. They're included as -# a dependency of application charts to inject those utilities and functions into the rendering -# pipeline. Library charts do not define any templates and therefore cannot be deployed. -type: application - -# This is the chart version. This version number should be incremented each time you make changes -# to the chart and its templates, including the app version. -# Versions are expected to follow Semantic Versioning (https://semver.org/) -version: 2.1.2 - -# This is the version number of the application being deployed. This version number should be -# incremented each time you make changes to the application. Versions are not expected to -# follow Semantic Versioning. They should reflect the version the application is using. -# It is recommended to use it with quotes. -appVersion: "multiarch-v22.7.0" - -keywords: - - ethereum - - blockchain - - nimbus - - p2p - -dependencies: -- name: common - repository: file://../common - version: 1.0.0 diff --git a/charts/nimbus/templates/_helpers.yaml b/charts/nimbus/templates/_helpers.yaml deleted file mode 100644 index e3a820e39..000000000 --- a/charts/nimbus/templates/_helpers.yaml +++ /dev/null @@ -1,3 +0,0 @@ -{{- define "nimbus.p2pPort" -}} -{{- printf "9000" -}} -{{- end -}} diff --git a/charts/nimbus/templates/clusterrole.yaml b/charts/nimbus/templates/clusterrole.yaml deleted file mode 100644 index 6d7136bd1..000000000 --- a/charts/nimbus/templates/clusterrole.yaml +++ /dev/null @@ -1,10 +0,0 @@ -{{- if or .Values.global.rbac.create .Values.rbac.create }} -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: {{ include "common.names.clusterRoleName" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -rules: -{{- toYaml .Values.rbac.clusterRules | nindent 0 }} -{{- end }} diff --git a/charts/nimbus/templates/clusterrolebinding.yaml b/charts/nimbus/templates/clusterrolebinding.yaml deleted file mode 100644 index 87d636dac..000000000 --- a/charts/nimbus/templates/clusterrolebinding.yaml +++ /dev/null @@ -1,16 +0,0 @@ -{{- if or .Values.global.rbac.create .Values.rbac.create }} -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: {{ include "common.names.clusterRoleName" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: {{ include "common.names.clusterRoleName" . }} -subjects: - - kind: ServiceAccount - name: {{ include "common.names.serviceAccountName" . }} - namespace: {{ .Release.Namespace }} -{{- end }} diff --git a/charts/nimbus/templates/pdb.yaml b/charts/nimbus/templates/pdb.yaml deleted file mode 100644 index 4ef63f0ff..000000000 --- a/charts/nimbus/templates/pdb.yaml +++ /dev/null @@ -1,18 +0,0 @@ -{{- if .Values.podDisruptionBudget.enabled }} -apiVersion: {{ include "common.capabilities.policy.apiVersion" . }} -kind: PodDisruptionBudget -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -spec: -{{- if .Values.podDisruptionBudget.minAvailable }} - minAvailable: {{ .Values.podDisruptionBudget.minAvailable }} -{{- end }} -{{- if .Values.podDisruptionBudget.maxUnavailable }} - maxUnavailable: {{ .Values.podDisruptionBudget.maxUnavailable }} -{{- end }} - selector: - matchLabels: - {{- include "common.labels.matchLabels" . | nindent 6 }} -{{- end }} diff --git a/charts/nimbus/templates/prometheusrules.yaml b/charts/nimbus/templates/prometheusrules.yaml deleted file mode 100644 index 91264e829..000000000 --- a/charts/nimbus/templates/prometheusrules.yaml +++ /dev/null @@ -1,37 +0,0 @@ -{{- if and (or .Values.global.metrics.enabled .Values.metrics.enabled) - (or .Values.global.metrics.prometheusRule.enabled .Values.metrics.prometheusRule.enabled) }} -apiVersion: monitoring.coreos.com/v1 -kind: PrometheusRule -metadata: - name: {{ include "common.names.fullname" . }} - {{- if .Values.metrics.prometheusRule.namespace }} - namespace: {{ .Values.metrics.prometheusRule.namespace }} - {{- else }} - namespace: {{ .Release.Namespace | quote }} - {{- end }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.metrics.prometheusRule.additionalLabels }} - {{- toYaml .Values.metrics.prometheusRule.additionalLabels | nindent 4 }} - {{- end }} -spec: - groups: - {{- range $i, $e := until (len .Values.global.executionEndpoints) }} - {{- with $.Values.metrics.prometheusRule.rules }} - - name: {{ include "common.names.fullname" $ }}-{{ $i }} - rules: {{- tpl (toYaml .) $ | nindent 8 }} - {{- end }} - {{- if $.Values.metrics.prometheusRule.default }} - - name: {{ include "common.names.fullname" $ }}-{{ $i }}-default - rules: - - alert: NimbusBeaconNodeDown - expr: up{job='{{ include "common.names.fullname" $ }}-{{ $i }}'} == 0 - for: 1m - labels: - severity: critical - annotations: - summary: Nimbus beacon node is down - description: Check {{ printf "{{ $labels.pod }}" }} beacon node in namespace {{ printf "{{ $labels.namespace }}" }} - {{- end }} - {{- end }} -{{- end }} diff --git a/charts/nimbus/templates/role.yaml b/charts/nimbus/templates/role.yaml deleted file mode 100644 index dfbc0fe48..000000000 --- a/charts/nimbus/templates/role.yaml +++ /dev/null @@ -1,10 +0,0 @@ -{{- if or .Values.global.rbac.create .Values.rbac.create -}} -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -rules: -{{- toYaml .Values.rbac.rules | nindent 0 }} -{{- end }} diff --git a/charts/nimbus/templates/rolebinding.yaml b/charts/nimbus/templates/rolebinding.yaml deleted file mode 100644 index 1fdb617ba..000000000 --- a/charts/nimbus/templates/rolebinding.yaml +++ /dev/null @@ -1,15 +0,0 @@ -{{- if or .Values.global.rbac.create .Values.rbac.create }} -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: {{ include "common.names.serviceAccountName" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: {{ include "common.names.serviceAccountName" . }} -subjects: - - kind: ServiceAccount - name: {{ include "common.names.serviceAccountName" . }} -{{- end }} diff --git a/charts/nimbus/templates/secret.yaml b/charts/nimbus/templates/secret.yaml deleted file mode 100644 index 5a3f66bb5..000000000 --- a/charts/nimbus/templates/secret.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: v1 -kind: Secret -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -type: Opaque -data: - jwtsecret: {{ .Values.global.JWTSecret | b64enc | quote }} diff --git a/charts/nimbus/templates/service-p2p.yaml b/charts/nimbus/templates/service-p2p.yaml deleted file mode 100644 index 36f99c8ba..000000000 --- a/charts/nimbus/templates/service-p2p.yaml +++ /dev/null @@ -1,42 +0,0 @@ -{{- if .Values.p2pNodePort.enabled -}} -{{- range $i, $e := until (len .Values.global.executionEndpoints) }} -{{- $port := add $.Values.p2pNodePort.startAt $i -}} -{{- if hasKey $.Values.p2pNodePort.replicaToNodePort ($i | toString) -}} - {{ $port = index $.Values.p2pNodePort.replicaToNodePort ($i | toString) }} -{{- end }} - ---- -apiVersion: v1 -kind: Service -metadata: - name: {{ include "common.names.fullname" $ }}-{{ $i }} - labels: - {{- include "common.labels.standard" $ | nindent 4 }} - replicaID: {{ $i | quote }} - type: p2p - {{- with $.Values.p2pNodePort.annotations }} - annotations: - {{- toYaml . | nindent 4 }} - {{- end }} -spec: - type: {{ $.Values.p2pNodePort.type }} - externalTrafficPolicy: Local - ports: - - name: p2p-tcp - port: {{ include "nimbus.p2pPort" $ }} - protocol: TCP - targetPort: p2p-tcp - nodePort: {{ $port }} - {{- if eq $.Values.p2pNodePort.type "NodePort" }} - - name: p2p-udp - port: {{ include "nimbus.p2pPort" $ }} - protocol: UDP - targetPort: p2p-udp - nodePort: {{ $port }} - {{- end }} - selector: - {{- include "common.labels.matchLabels" $ | nindent 4 }} - replicaID: {{ $i | quote }} - -{{- end }} -{{- end }} diff --git a/charts/nimbus/templates/service.yaml b/charts/nimbus/templates/service.yaml deleted file mode 100644 index 223efaaa3..000000000 --- a/charts/nimbus/templates/service.yaml +++ /dev/null @@ -1,40 +0,0 @@ -{{- if or .Values.rest.enabled .Values.global.metrics.enabled }} -{{- $root := . -}} -{{- range $i, $e := until (len .Values.global.executionEndpoints) }} ---- -apiVersion: v1 -kind: Service -metadata: - name: {{ include "common.names.fullname" $root }}-{{ $i }} - labels: - {{- include "common.labels.standard" $root | nindent 4 }} - replicaID: {{ $i | quote }} -spec: - type: "ClusterIP" -{{- if $root.Values.svcHeadless }} - clusterIP: None -{{- end }} -{{- if $root.Values.sessionAffinity.enabled }} - sessionAffinity: ClientIP - sessionAffinityConfig: - clientIP: - timeoutSeconds: {{ $root.Values.sessionAffinity.timeoutSeconds }} -{{- end }} - ports: - {{- if $root.Values.rest.enabled }} - - port: {{ $root.Values.rest.port }} - targetPort: {{ $root.Values.rest.portName }} - protocol: TCP - name: {{ $root.Values.rest.portName }} - {{- end }} - {{- if $root.Values.metrics.enabled }} - - port: {{ $root.Values.metrics.port }} - targetPort: metrics - protocol: TCP - name: metrics - {{- end }} - selector: - {{- include "common.labels.matchLabels" $root | nindent 4 }} - replicaID: {{ $i | quote }} -{{- end }} -{{- end }} diff --git a/charts/nimbus/templates/servicemonitor.yaml b/charts/nimbus/templates/servicemonitor.yaml deleted file mode 100644 index b1eb04d35..000000000 --- a/charts/nimbus/templates/servicemonitor.yaml +++ /dev/null @@ -1,42 +0,0 @@ -{{- if and (or .Values.global.metrics.enabled .Values.metrics.enabled) - (or .Values.global.metrics.serviceMonitor.enabled .Values.metrics.serviceMonitor.enabled) }} -apiVersion: monitoring.coreos.com/v1 -kind: ServiceMonitor -metadata: - name: {{ include "common.names.fullname" . }} - {{- if .Values.metrics.serviceMonitor.namespace }} - namespace: {{ .Values.metrics.serviceMonitor.namespace }} - {{- else }} - namespace: {{ .Release.Namespace | quote }} - {{- end }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.metrics.serviceMonitor.additionalLabels }} - {{- toYaml .Values.metrics.serviceMonitor.additionalLabels | nindent 4 }} - {{- end }} -spec: - endpoints: - - port: metrics - path: /metrics - {{- if .Values.metrics.serviceMonitor.interval }} - interval: {{ .Values.metrics.serviceMonitor.interval }} - {{- end }} - {{- if .Values.metrics.serviceMonitor.scrapeTimeout }} - scrapeTimeout: {{ .Values.metrics.serviceMonitor.scrapeTimeout }} - {{- end }} - {{- if .Values.metrics.serviceMonitor.honorLabels }} - honorLabels: {{ .Values.metrics.serviceMonitor.honorLabels }} - {{- end }} - {{- if .Values.metrics.serviceMonitor.relabelings }} - relabelings: {{- toYaml .Values.metrics.serviceMonitor.relabelings | nindent 6 }} - {{- end }} - {{- if .Values.metrics.serviceMonitor.metricRelabelings }} - metricRelabelings: {{- toYaml .Values.metrics.serviceMonitor.metricRelabelings | nindent 6 }} - {{- end }} - namespaceSelector: - matchNames: - - {{ .Release.Namespace }} - selector: - matchLabels: - {{- include "common.labels.matchLabels" . | nindent 6 }} -{{- end }} diff --git a/charts/nimbus/templates/statefulset.yaml b/charts/nimbus/templates/statefulset.yaml deleted file mode 100644 index e42d2cf4d..000000000 --- a/charts/nimbus/templates/statefulset.yaml +++ /dev/null @@ -1,229 +0,0 @@ -{{- $root := . -}} -{{- range $i, $e := until (len .Values.global.executionEndpoints) }} ---- -kind: StatefulSet -apiVersion: {{ include "common.capabilities.statefulset.apiVersion" $root }} -metadata: - name: {{ include "common.names.fullname" $root }}-{{ $i }} - labels: - {{- include "common.labels.standard" $root | nindent 4 }} - replicaID: {{ $i | quote }} -spec: - replicas: 1 - selector: - matchLabels: - {{- include "common.labels.matchLabels" $root | nindent 6 }} - replicaID: {{ $i | quote }} - serviceName: {{ include "common.names.fullname" $root }} - template: - metadata: - labels: - {{- include "common.labels.matchLabels" $root | nindent 8 }} - replicaID: {{ $i | quote }} - spec: - {{- with (concat $root.Values.imagePullSecrets $root.Values.global.imagePullSecrets) }} - imagePullSecrets: - {{- toYaml . | nindent 8 }} - {{- end }} - {{- with $root.Values.nodeSelector }} - nodeSelector: - {{- toYaml . | nindent 8 }} - {{- end }} - {{- with $root.Values.affinity }} - affinity: - {{- toYaml . | nindent 8 }} - {{- end }} - {{- with $root.Values.tolerations }} - tolerations: - {{- toYaml . | nindent 8 }} - {{- end }} - serviceAccountName: {{ include "common.names.serviceAccountName" $root }} - priorityClassName: {{ $root.Values.priorityClassName | quote }} - securityContext: - {{- toYaml $root.Values.securityContext | nindent 8 }} - {{- if or (and $root.Values.persistence.enabled $root.Values.initChownData) ($root.Values.p2pNodePort.enabled) }} - initContainers: - {{- if $root.Values.p2pNodePort.enabled }} - - name: init-nodeport - image: "{{ $root.Values.p2pNodePort.initContainer.image.repository }}:{{ $root.Values.p2pNodePort.initContainer.image.tag }}" - imagePullPolicy: {{ $root.Values.p2pNodePort.initContainer.image.pullPolicy }} - securityContext: - runAsNonRoot: false - runAsUser: 0 - env: - - name: POD_NAME - valueFrom: - fieldRef: - fieldPath: metadata.name - - name: POD_NAMESPACE - valueFrom: - fieldRef: - fieldPath: metadata.namespace - - name: NODE_NAME - valueFrom: - fieldRef: - fieldPath: spec.nodeName - command: - - sh - - -c - - > - echo "Namespace: ${POD_NAMESPACE} Pod: ${POD_NAME}"; - {{- if eq $root.Values.p2pNodePort.type "LoadBalancer" }} - until [ -n "$(kubectl -n ${POD_NAMESPACE} get svc/${POD_NAME} -o jsonpath='{.status.loadBalancer.ingress[0].ip}')" ]; do echo "Waiting for load balancer gets an IP" && sleep 10; done; - export EXTERNAL_PORT=$(kubectl -n ${POD_NAMESPACE} get services -l "pod in (${POD_NAME}), type in (p2p)" -o jsonpath='{.items[0].spec.ports[0].nodePort}'); - export EXTERNAL_IP=$(kubectl -n ${POD_NAMESPACE} get svc/${POD_NAME} -o jsonpath='{.status.loadBalancer.ingress[0].ip}'); - {{- else }} - export EXTERNAL_PORT=$(kubectl get services -l "pod in (${POD_NAME}), type in (p2p)" -o jsonpath='{.items[0].spec.ports[0].nodePort}'); - export EXTERNAL_IP=$(kubectl get nodes "${NODE_NAME}" -o jsonpath='{.status.addresses[?(@.type=="ExternalIP")].address}'); - {{- end }} - echo "EXTERNAL_PORT=$EXTERNAL_PORT" > /env/init-nodeport; - echo "EXTERNAL_IP=$EXTERNAL_IP" >> /env/init-nodeport; - cat /env/init-nodeport; - volumeMounts: - - name: env-nodeport - mountPath: /env - {{- end }} - {{- if and $root.Values.persistence.enabled $root.Values.initChownData }} - - name: init-chown - image: "{{ $root.Values.initImage.repository }}:{{ $root.Values.initImage.tag }}" - imagePullPolicy: {{ $root.Values.initImage.pullPolicy }} - securityContext: - runAsUser: 0 - command: - - /bin/sh - - -c - - mkdir -p /data/nimbus && chown -R {{ $root.Values.securityContext.runAsUser }}:{{ $root.Values.securityContext.runAsUser }} /data/nimbus && chmod 700 /data/nimbus - volumeMounts: - - name: data - mountPath: /data/nimbus - {{- end }} - {{- end }} - containers: - - name: {{ $root.Chart.Name }} - image: "{{ $root.Values.image.repository }}:{{ $root.Values.image.tag | default $root.Chart.AppVersion }}" - imagePullPolicy: {{ $root.Values.image.pullPolicy }} - args: - - --network={{ $root.Values.global.network }} - - --data-dir=/data/nimbus - - --non-interactive - - --jwt-secret=/secret/jwtsecret - - --web3-url={{ index $root.Values.global.executionEndpoints $i }} - {{- if $root.Values.rest.enabled }} - - --rest - - --rest-port={{ $root.Values.rest.port }} - - --rest-address={{ $root.Values.rest.address }} - - --rest-allow-origin={{ $root.Values.rest.allowOrigin }} - {{- end }} - {{- if $root.Values.metrics.enabled }} - - --metrics - - --metrics-address={{ $root.Values.metrics.address }} - - --metrics-port={{ $root.Values.metrics.port }} - {{- end }} - {{- range $root.Values.extraFlags }} - - {{ . | quote }} - {{- end }} - {{- if or $root.Values.rest.enabled $root.Values.metrics.enabled }} - ports: - {{- if $root.Values.rest.enabled }} - - name: {{ $root.Values.rest.portName }} - containerPort: {{ $root.Values.rest.port }} - protocol: TCP - {{- end }} - {{- if $root.Values.global.metrics.enabled }} - - name: metrics - containerPort: {{ $root.Values.metrics.port }} - protocol: TCP - {{- end }} - {{- if $root.Values.p2pNodePort.enabled }} - - name: p2p-tcp - containerPort: {{ include "nimbus.p2pPort" $root }} - protocol: TCP - - name: p2p-udp - containerPort: {{ include "nimbus.p2pPort" $root }} - protocol: UDP - {{- end }} - {{- end }} - env: - - name: POD_IP - valueFrom: - fieldRef: - fieldPath: status.podIP - volumeMounts: - - name: data - mountPath: /data/nimbus - - name: jwtsecret - mountPath: /secret - readOnly: true - {{- if $root.Values.p2pNodePort.enabled }} - - name: env-nodeport - mountPath: /env - {{- end }} - resources: - {{- toYaml $root.Values.resources | nindent 12 }} - {{- if $root.Values.rest.enabled }} - - name: sidecar - image: "{{ $root.Values.sidecar.repository }}:{{ $root.Values.sidecar.tag }}" - imagePullPolicy: {{ $root.Values.sidecar.pullPolicy }} - env: - - name: SERVER_BINDADDR - value: "{{ $root.Values.sidecar.bindAddr }}:{{ $root.Values.sidecar.bindPort }}" - - name: CLIENT_PORT - value: {{ $root.Values.rest.port | quote }} - ports: - - containerPort: {{ $root.Values.sidecar.bindPort }} - name: sidecar - protocol: TCP - {{- if or $root.Values.global.livenessProbe.enabled $root.Values.livenessProbe.enabled }} - livenessProbe: - initialDelaySeconds: {{ $root.Values.livenessProbe.initialDelaySeconds }} - timeoutSeconds: {{ $root.Values.livenessProbe.timeoutSeconds }} - periodSeconds: {{ $root.Values.livenessProbe.periodSeconds }} - failureThreshold: {{ $root.Values.livenessProbe.failureThreshold }} - successThreshold: {{ $root.Values.livenessProbe.successThreshold }} - httpGet: - path: {{ $root.Values.livenessProbe.httpGet.path }} - port: {{ $root.Values.livenessProbe.httpGet.port }} - scheme: {{ $root.Values.livenessProbe.httpGet.scheme }} - {{- end }} - {{- if or $root.Values.global.readinessProbe.enabled $root.Values.readinessProbe.enabled }} - readinessProbe: - initialDelaySeconds: {{ $root.Values.readinessProbe.initialDelaySeconds }} - timeoutSeconds: {{ $root.Values.readinessProbe.timeoutSeconds }} - periodSeconds: {{ $root.Values.readinessProbe.periodSeconds }} - failureThreshold: {{ $root.Values.readinessProbe.failureThreshold }} - successThreshold: {{ $root.Values.readinessProbe.successThreshold }} - httpGet: - path: {{ $root.Values.readinessProbe.httpGet.path }} - port: {{ $root.Values.readinessProbe.httpGet.port }} - scheme: {{ $root.Values.readinessProbe.httpGet.scheme }} - {{- end }} - {{- end }} - volumes: - - name: jwtsecret - secret: - secretName: {{ include "common.names.fullname" $root }} - {{- if $root.Values.p2pNodePort.enabled }} - - name: env-nodeport - emptyDir: {} - {{- end }} - {{- if (not $root.Values.persistence.enabled) }} - - name: data - emptyDir: {} - {{- else }} - volumeClaimTemplates: - - metadata: - name: data - labels: - {{- include "common.labels.standard" $root | nindent 10 }} - {{- with $root.Values.persistence.annotations }} - annotations: - {{ toYaml . | nindent 10 | trim }} - {{- end }} - spec: - accessModes: {{ $root.Values.persistence.accessModes }} - storageClassName: {{ $root.Values.persistence.storageClassName }} - resources: - requests: - storage: {{ $root.Values.persistence.size | quote }} - {{- end }} -{{- end }} diff --git a/charts/nimbus/templates/validate.yaml b/charts/nimbus/templates/validate.yaml deleted file mode 100644 index 75d40a4fd..000000000 --- a/charts/nimbus/templates/validate.yaml +++ /dev/null @@ -1,8 +0,0 @@ -{{- if not .Values.global.JWTSecret }} -{{- fail ".Values.global.JWTSecret is required" }} -{{- end }} - -{{- $endpoints := uniq .Values.global.executionEndpoints -}} -{{- if lt (len $endpoints) (len .Values.global.executionEndpoints)}} -{{- fail ".Values.global.executionClients must only contain unique values, since each consensus client must be connected to a unique execution client." }} -{{- end }} diff --git a/charts/nimbus/templates/vpa.yaml b/charts/nimbus/templates/vpa.yaml deleted file mode 100644 index b04681257..000000000 --- a/charts/nimbus/templates/vpa.yaml +++ /dev/null @@ -1,20 +0,0 @@ -{{- if and .Values.enabled .Values.verticalAutoscaler.enabled }} -apiVersion: autoscaling.k8s.io/v1beta2 -kind: VerticalPodAutoscaler -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels" . | nindent 4 }} -spec: - targetRef: - apiVersion: "apps/v1" - kind: StatefulSet - name: {{ include "common.names.fullname" . }} - updatePolicy: - updateMode: {{ .Values.verticalAutoscaler.updateMode | default "Off" | quote }} - {{- if .Values.verticalAutoscaler.containerPolicies }} - resourcePolicy: - containerPolicies: - {{ tpl .Values.verticalAutoscaler.containerPolicies . | nindent 6 | trim }} - {{- end }} -{{- end }} diff --git a/charts/nimbus/values.yaml b/charts/nimbus/values.yaml deleted file mode 100644 index 62eace330..000000000 --- a/charts/nimbus/values.yaml +++ /dev/null @@ -1,380 +0,0 @@ -# Default values for nimbus. -# This is a YAML-formatted file. -# Declare variables to be passed into your templates. - -global: - ## Eth2 network ID - ## - network: mainnet - - ## JSON Web Token (JWT) authentication is used to secure the communication - ## between the beacon node and execution client. You can generate a JWT using - ## a command line tool, for example: - ## openssl rand -hex 32 > token.txt - ## - JWTSecret: "" - - ## Server endpoints for an execution layer jwt authenticated HTTP JSON-RPC connection. - ## Uses the same endpoint to populate the deposit cache. - ## A separate Statefulset will be created for each specified address - ## - executionEndpoints: [] - - ## Credentials to fetch images from private registry - ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/ - ## - imagePullSecrets: [] - - ## Service account - ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ - ## Additional settings could be made in non-global section. - ## - serviceAccount: - # Specifies whether a service account should be created - create: true - - ## RBAC configuration. - ## ref: https://kubernetes.io/docs/reference/access-authn-authz/rbac/ - ## Additional settings could be made in non-global section. - ## - rbac: - ## Specifies whether RBAC resources are to be created - ## - create: true - - ## Monitoring - ## Additional settings could be made in non-global section. - ## - metrics: - ## Whether to enable metrics collection or not - ## - enabled: true - - ## Prometheus Service Monitor - ## ref: https://github.com/coreos/prometheus-operator - ## https://github.com/coreos/prometheus-operator/blob/master/Documentation/api.md#endpoint - ## - serviceMonitor: - ## Create ServiceMonitor resource(s) for scraping metrics using PrometheusOperator - ## - enabled: false - - ## Custom PrometheusRule to be defined - ## ref: https://github.com/coreos/prometheus-operator#customresourcedefinitions - ## - prometheusRule: - ## Create a custom prometheusRule Resource for scraping metrics using PrometheusOperator - ## - enabled: false - - ## Configure liveness and readiness probes - ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/ - ## NB! readinessProbe and livenessProbe must be disabled before fully synced - ## Additional settings could be made in non-global section. - ## - livenessProbe: - enabled: true - - readinessProbe: - enabled: true - -## Init image is used to chown data volume, initialise genesis, etc. -## -initImage: - repository: "busybox" - tag: "1.35" - pullPolicy: IfNotPresent - -## Sidecar image is used to perform Liveness/Readiness probes. -## -sidecar: - repository: "europe-west4-docker.pkg.dev/stakewiselabs/public/ethnode-sidecar" - tag: "v1.0.5" - pullPolicy: IfNotPresent - bindAddr: "0.0.0.0" - bindPort: 3000 - -image: - repository: statusim/nimbus-eth2 - pullPolicy: IfNotPresent - # Overrides the image tag whose default is the chart appVersion. - tag: "multiarch-v22.7.0" - -## Credentials to fetch images from private registry -## ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/ -## -imagePullSecrets: [] - -## Provide a name in place of lighthouse for `app:` labels -## -nameOverride: "" - -## Provide a name to substitute for the full names of resources -## -fullnameOverride: "" - -# REST Server settings -rest: - enabled: true - # Port of the REST server - port: "5052" - # Port name for the respective k8s service - portName: "rest" - # Listening address of the REST server - address: "0.0.0.0" - # Limit the access to the REST API to a particular hostname - allowOrigin: "*" - -## Extra flags to pass to the node -## -extraFlags: [] - -## Service account -## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ -## -serviceAccount: - # Annotations to add to the service account - annotations: {} - # The name of the service account to use. - # If not set and create is true, a name is generated using the fullname template - name: "" - -## Pod Security Context -## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/ -## -securityContext: - fsGroup: 1000 - runAsUser: 1000 - -## RBAC configuration. -## ref: https://kubernetes.io/docs/reference/access-authn-authz/rbac/ -## -rbac: - # The name of the cluster role to use. - # If not set and create is true, a name is generated using the fullname template - name: "" - ## Required ClusterRole rules - ## - clusterRules: - ## Required to obtain the nodes external IP - ## - - apiGroups: [""] - resources: - - "nodes" - verbs: - - "get" - - "list" - - "watch" - ## Required Role rules - ## - rules: - ## Required to get information about the serices nodePort. - ## - - apiGroups: [""] - resources: - - "services" - verbs: - - "get" - - "list" - - "watch" - -## Node labels for pod assignment -## ref: https://kubernetes.io/docs/user-guide/node-selection/ -## -nodeSelector: {} - -## Tolerations for pod assignment -## ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/ -## -tolerations: {} - -## Affinity for pod assignment -## ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity -## -affinity: {} - -## Used to assign priority to pods -## ref: https://kubernetes.io/docs/concepts/configuration/pod-priority-preemption/ -## -priorityClassName: "" - -## Enable pod disruption budget -## ref: https://kubernetes.io/docs/tasks/run-application/configure-pdb -## -podDisruptionBudget: - enabled: true - maxUnavailable: 1 - -## Vertical Pod Autoscaler config -## ref: https://github.com/kubernetes/autoscaler/tree/master/vertical-pod-autoscaler -## -verticalAutoscaler: - # If true a VPA object will be created for the StatefulSet - enabled: false - updateMode: Off - containerPolicies: {} - -resources: {} - # We usually recommend not to specify default resources and to leave this as a conscious - # choice for the user. This also increases chances charts run on environments with little - # resources, such as Minikube. If you do want to specify resources, uncomment the following - # lines, adjust them as necessary, and remove the curly braces after 'resources:'. - # limits: - # cpu: 100m - # memory: 128Mi - # requests: - # cpu: 100m - # memory: 128Mi - -## Configure liveness and readiness probes -## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/ -## NB! readinessProbe and livenessProbe must be disabled before genesis -## -livenessProbe: - initialDelaySeconds: 900 - timeoutSeconds: 3 - periodSeconds: 30 - failureThreshold: 3 - successThreshold: 1 - httpGet: - path: /eth2/liveness - port: sidecar - scheme: HTTP - -readinessProbe: - initialDelaySeconds: 300 - timeoutSeconds: 3 - periodSeconds: 30 - failureThreshold: 30 - successThreshold: 2 - httpGet: - path: /eth2/readiness - port: sidecar - scheme: HTTP - -## Defines whether the service must be headless -## -svcHeadless: false - -## Configure session affinity for validator clients to hit the same beacon node -## for the period specified in `timeoutSeconds` -## ref: https://kubernetes.io/docs/concepts/services-networking/service/#proxy-mode-userspace -## -sessionAffinity: - # Whether to enable session affinity or not - enabled: true - # The session duration in seconds - timeoutSeconds: 86400 - -## When p2pNodePort is enabled, your P2P port will be exposed via service type NodePort/LoadBalancer. -## This will generate a service for each replica, with a port binding via NodePort/LoadBalancer. -## This is useful if you want to expose and announce your node to the Internet. -## -p2pNodePort: - ## @param p2pNodePort.enabled Expose P2P port via NodePort - ## - enabled: false - ## @param p2pNodePort.annotations - ## - annotations: {} - ## @param p2pNodePort.type - ## Options: NodePort, LoadBalancer - type: NodePort - ## @param p2pNodePort.startAt The ports allocation will start from this value - ## - startAt: 31600 - ## @param p2pNodePort.replicaToNodePort Overwrite a port for specific replicas - ## @default -- See `values.yaml` for example - replicaToNodePort: {} - # "0": 32345 - # "3": 32348 - initContainer: - image: - ## @param p2pNodePort.initContainer.repository Container image to fetch nodeport information - ## - repository: bitnami/kubectl - ## @param p2pNodePort.initContainer.tag Container tag - ## - tag: "1.24" - ## @param p2pNodePort.initContainer.pullPolicy Container pull policy - ## - pullPolicy: IfNotPresent - -## Monitoring -## -metrics: - ## Whether to enable metrics collection or not - ## - enabled: true - - # Listening address of the metrics server - address: "0.0.0.0" - - ## Listening HTTP port of the metrics server - ## - port: 8008 - - ## Prometheus Service Monitor - ## ref: https://github.com/coreos/prometheus-operator - ## https://github.com/coreos/prometheus-operator/blob/master/Documentation/api.md#endpoint - ## - serviceMonitor: - ## @param metrics.serviceMonitor.enabled Create ServiceMonitor resource(s) for scraping metrics using PrometheusOperator - ## - enabled: false - ## @param metrics.serviceMonitor.namespace The namespace in which the ServiceMonitor will be created - ## - namespace: "" - ## @param metrics.serviceMonitor.interval The interval at which metrics should be scraped - ## - interval: 30s - ## @param metrics.serviceMonitor.scrapeTimeout The timeout after which the scrape is ended - ## - scrapeTimeout: "" - ## @param metrics.serviceMonitor.relabellings Metrics RelabelConfigs to apply to samples before scraping. - ## - relabelings: [] - ## @param metrics.serviceMonitor.metricRelabelings Metrics RelabelConfigs to apply to samples before ingestion. - ## - metricRelabelings: [] - ## @param metrics.serviceMonitor.honorLabels Specify honorLabels parameter to add the scrape endpoint - ## - honorLabels: false - ## @param metrics.serviceMonitor.additionalLabels Additional labels that can be used so ServiceMonitor resource(s) can be discovered by Prometheus - ## - additionalLabels: {} - ## Custom PrometheusRule to be defined - ## ref: https://github.com/coreos/prometheus-operator#customresourcedefinitions - ## - prometheusRule: - ## @param metrics.prometheusRule.enabled Create a custom prometheusRule Resource for scraping metrics using PrometheusOperator - ## - enabled: false - ## @param metrics.prometheusRule.default Create a default set of Alerts - ## - default: true - ## @param metrics.prometheusRule.namespace The namespace in which the prometheusRule will be created - ## - namespace: "" - ## @param metrics.prometheusRule.additionalLabels Additional labels for the prometheusRule - ## - additionalLabels: {} - ## @param metrics.prometheusRule.rules Custom Prometheus rules - ## - rules: [] - -## If false, data ownership will not be reset at startup -## This allows the geth node to be run with an arbitrary user -## -initChownData: true - -## Whether or not to allocate persistent volume disk for the data directory. -## In case of pod failure, the pod data directory will still persist. -## -persistence: - enabled: true - storageClassName: "" - accessModes: - - ReadWriteOnce - size: 300Gi - annotations: {} diff --git a/charts/oracle/Chart.lock b/charts/oracle/Chart.lock deleted file mode 100644 index 5579bf919..000000000 --- a/charts/oracle/Chart.lock +++ /dev/null @@ -1,6 +0,0 @@ -dependencies: -- name: common - repository: file://../common - version: 1.0.0 -digest: sha256:07cebde439abe4ba19bb28e844b7419dab83c7f613886416aaf3ec08e8059144 -generated: "2022-03-07T12:52:26.163275694+03:00" diff --git a/charts/oracle/Chart.yaml b/charts/oracle/Chart.yaml deleted file mode 100644 index 24a187681..000000000 --- a/charts/oracle/Chart.yaml +++ /dev/null @@ -1,22 +0,0 @@ -apiVersion: v2 -name: oracle -version: 2.8.5 -appVersion: v2.8.3 -kubeVersion: "^1.14.0-0" -description: The StakeWise application for submitting off-chain data to smart contracts. -type: application -keywords: - - ethereum - - blockchain - - staking -home: https://stakewise.io/ -sources: - - https://github.com/stakewise/oracle/ -maintainers: - - name: Dmitri Tsumak - email: dmitri@stakewise.io - -dependencies: -- name: common - repository: file://../common - version: 1.0.0 diff --git a/charts/oracle/README.md b/charts/oracle/README.md deleted file mode 100644 index 49dfd2ae3..000000000 --- a/charts/oracle/README.md +++ /dev/null @@ -1,61 +0,0 @@ -# Oracle Helm Chart - -Kubernetes Helm chart for deploying oracle - the entity which is responsible for reading StakeWise pool validators data from beacon chain and submitting -it to the [Oracles](https://github.com/stakewise/contracts/blob/master/contracts/Oracles.sol) smart contract. - -## TL;DR; - -```bash -$ helm repo add stakewise https://charts.stakewise.io -$ helm install my-release --set settings.web3Endpoint="ws://eth1-node.chain.svc.cluster.local:8546" --set settings.beaconChainRpcEndpoint="eth2-beacon.chain.svc.cluster.local:4000" stakewise/oracle -``` - -## Introduction - -Can be used to deploy StakeWise oracles on a [Kubernetes](http://kubernetes.io) cluster using the [Helm](https://helm.sh) package manager. - -## Prerequisites - -- Kubernetes 1.14+ -- Helm 3 - -## Installing the Chart - -To install the chart with the release name `my-release`: - -```bash -$ helm repo add stakewise https://charts.stakewise.io -$ helm install my-release --set settings.awsAccessKeyID="XXXXXXXX" --set settings.awsSecretAccessKey="XXXXXXXX" stakewise/oracle -``` - -The command deploys oracle on the Kubernetes cluster in the default configuration. The [configuration](#configuration) section lists various ways to override default configuration during deployment. - -> **Tip**: List all releases using `helm list` - -## Uninstalling the Chart - -To uninstall/delete the `my-release` deployment: - -```bash -$ helm delete my-release -``` - -The command removes all the Kubernetes components associated with the chart and deletes the release. - -## Configuration - -See `values.yaml` for configuration notes. Specify each parameter using the `--set key=value[,key=value]` argument to `helm install`. For example, - -```bash -$ helm install my-release stakewise/oracle --set settings.awsAccessKeyID="XXXXXXXX" --set settings.awsSecretAccessKey="XXXXXXXX" -``` - -The above command specifies the web3 endpoint. - -Alternatively, a YAML file that specifies the values for the parameters can be provided while installing the chart. For example, - -```bash -$ helm install my-release stakewise/oracle -f values.yaml -``` - -> **Tip**: You can override the default [values.yaml](values.yaml) \ No newline at end of file diff --git a/charts/oracle/templates/configmap.yaml b/charts/oracle/templates/configmap.yaml deleted file mode 100644 index be88f8233..000000000 --- a/charts/oracle/templates/configmap.yaml +++ /dev/null @@ -1,23 +0,0 @@ -apiVersion: v1 -kind: ConfigMap -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -data: - LOG_LEVEL: {{ .Values.settings.logLevel | quote }} - NETWORK: {{ .Values.settings.network | quote }} - ENABLE_HEALTH_SERVER: {{ .Values.settings.enableHealthServer | quote }} - HEALTH_SERVER_HOST: {{ .Values.settings.healthServerHost | quote }} - HEALTH_SERVER_PORT: {{ .Values.settings.healthServerPort | quote }} - IPFS_PIN_ENDPOINTS: {{ .Values.settings.ipfsPinEndpoints | quote }} - IPFS_FETCH_ENDPOINTS: {{ .Values.settings.ipfsFetchEndpoints | quote }} - IPFS_PINATA_PIN_ENDPOINT: {{ .Values.settings.ipfsPinataPinEndpoint | quote }} - ETH2_ENDPOINT: {{ .Values.settings.eth2Endpoint | quote }} - STAKEWISE_SUBGRAPH_URLS: {{ .Values.settings.stakewiseSubgraphUrls | quote }} - ETHEREUM_SUBGRAPH_URLS: {{ .Values.settings.ethereumSubgraphUrls | quote }} - UNISWAP_V3_SUBGRAPH_URLS: {{ .Values.settings.uniswapV3SubgraphUrls | quote }} - AWS_S3_REGION: {{ .Values.settings.awsRegion | quote }} - VALIDATORS_BATCH_SIZE: {{ .Values.settings.validatorsBatchSize | quote }} - VALIDATORS_FETCH_CHUNK_SIZE: {{ .Values.settings.validatorsFetchChunkSize | quote }} - HARBOUR_MAINNET_SEND_TELEGRAM_NOTIFICATIONS: {{ .Values.settings.harbourMainnetSendTelegramNotifications | quote }} diff --git a/charts/oracle/templates/deployment.yaml b/charts/oracle/templates/deployment.yaml deleted file mode 100644 index 0a911abc9..000000000 --- a/charts/oracle/templates/deployment.yaml +++ /dev/null @@ -1,53 +0,0 @@ -kind: Deployment -apiVersion: {{ include "common.capabilities.deployment.apiVersion" . }} -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -spec: - replicas: 1 - strategy: - type: Recreate - selector: - matchLabels: - {{- include "common.labels.matchLabels" . | nindent 6 }} - template: - metadata: - labels: - {{- include "common.labels.matchLabels" . | nindent 8 }} - annotations: - checksum/oracle-secret: {{ include (print $.Template.BasePath "/secret.yaml") . | sha256sum }} - checksum/oracle-configmap: {{ include (print $.Template.BasePath "/configmap.yaml") . | sha256sum }} - spec: - {{- if .Values.tolerations }} - tolerations: - {{ tpl .Values.tolerations . | nindent 8 | trim }} - {{- end }} - {{- if .Values.affinity }} - affinity: - {{ tpl .Values.affinity . | nindent 8 | trim }} - {{- end }} - {{- with .Values.securityContext }} - securityContext: - {{ toYaml . | nindent 8 | trim }} - {{- end }} - serviceAccountName: {{ include "common.names.fullname" . }} - priorityClassName: {{ .Values.priorityClassName | quote }} - {{- if .Values.terminationGracePeriodSeconds }} - terminationGracePeriodSeconds: {{ .Values.terminationGracePeriodSeconds }} - {{- end }} - containers: - - name: {{ .Chart.Name }} - image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}" - imagePullPolicy: {{ .Values.image.pullPolicy }} - command: ["python"] - args: ["oracle/oracle/main.py"] - envFrom: - - configMapRef: - name: {{ include "common.names.fullname" . }} - - secretRef: - name: {{ include "common.names.fullname" . }} - {{- with .Values.resources }} - resources: - {{ toYaml . | nindent 12 | trim }} - {{- end }} diff --git a/charts/oracle/templates/role.yaml b/charts/oracle/templates/role.yaml deleted file mode 100644 index 44bf0ea62..000000000 --- a/charts/oracle/templates/role.yaml +++ /dev/null @@ -1,17 +0,0 @@ -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -rules: - - apiGroups: [""] - resources: ["secrets"] - resourceNames: - - {{ include "common.names.fullname" . }} - verbs: ["get"] - - apiGroups: [""] - resources: ["configmaps"] - resourceNames: - - {{ include "common.names.fullname" . }} - verbs: ["get"] diff --git a/charts/oracle/templates/rolebinding.yaml b/charts/oracle/templates/rolebinding.yaml deleted file mode 100644 index 329d7b812..000000000 --- a/charts/oracle/templates/rolebinding.yaml +++ /dev/null @@ -1,14 +0,0 @@ -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -roleRef: - kind: Role - apiGroup: rbac.authorization.k8s.io - name: {{ include "common.names.fullname" . }} -subjects: - - kind: ServiceAccount - name: {{ include "common.names.fullname" . }} - namespace: {{ .Release.Namespace }} diff --git a/charts/oracle/templates/secret.yaml b/charts/oracle/templates/secret.yaml deleted file mode 100644 index 4d84a9f21..000000000 --- a/charts/oracle/templates/secret.yaml +++ /dev/null @@ -1,17 +0,0 @@ -apiVersion: v1 -kind: Secret -metadata: - name: {{ include "common.names.fullname" . }} - namespace: {{ .Release.Namespace }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -type: Opaque -data: - IPFS_PINATA_API_KEY: {{ .Values.settings.ipfsPinataApiKey | b64enc | quote }} - IPFS_PINATA_SECRET_KEY: {{ .Values.settings.ipfsPinataSecretKey | b64enc | quote }} - SENTRY_DSN: {{ .Values.settings.sentryDsn | b64enc | quote }} - ORACLE_PRIVATE_KEY: {{ .Values.settings.oraclePrivateKey | b64enc | quote }} - AWS_ACCESS_KEY_ID: {{ .Values.settings.awsAccessKeyID | b64enc | quote }} - AWS_SECRET_ACCESS_KEY: {{ .Values.settings.awsSecretAccessKey | b64enc | quote }} - INFURA_IPFS_CLIENT_USERNAME: {{ .Values.settings.infuraIpfsClientUsername | b64enc | quote }} - INFURA_IPFS_CLIENT_PASSWORD: {{ .Values.settings.infuraIpfsClientPassword | b64enc | quote }} diff --git a/charts/oracle/templates/serviceaccount.yaml b/charts/oracle/templates/serviceaccount.yaml deleted file mode 100644 index 65d30421c..000000000 --- a/charts/oracle/templates/serviceaccount.yaml +++ /dev/null @@ -1,8 +0,0 @@ -{{- if or .Values.global.serviceAccount.create .Values.serviceAccount.create -}} -apiVersion: v1 -kind: ServiceAccount -metadata: - name: {{ template "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -{{- end }} \ No newline at end of file diff --git a/charts/oracle/values.yaml b/charts/oracle/values.yaml deleted file mode 100644 index d597af2b1..000000000 --- a/charts/oracle/values.yaml +++ /dev/null @@ -1,124 +0,0 @@ -# Default values for oracle. -# This is a YAML-formatted file. -# Declare variables to be passed into your templates. - -global: - serviceAccount: - create: true - -## Pod Security Context -## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/ -## -securityContext: - fsGroup: 1001 - runAsUser: 1001 - -## Termination Grace Period -## ref: https://kubernetes.io/docs/tasks/run-application/force-delete-stateful-set-pod/#delete-pods -## -terminationGracePeriodSeconds: 1800 - -## Affinity Settings -## ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity -## -affinity: { } - -## Toleration Settings -## ref: https://kubernetes.io/docs/concepts/scheduling-eviction/taint-and-toleration/ -## -tolerations: [ ] - -serviceAccount: - ## Annotations to add to the service account - ## - annotations: {} - ## The name of the service account to use. - ## If not set and create is true, a name is generated using the fullname template - ## - name: "" - -## Docker image -## -image: - repository: "europe-west4-docker.pkg.dev/stakewiselabs/public/oracle" - tag: "v2.8.3" - pullPolicy: IfNotPresent - -## Configure resource requests and limits. -## http://kubernetes.io/docs/user-guide/compute-resources/ -## -resources: - requests: - cpu: 10m - memory: 200Mi - -## Used to assign priority to pod -## ref: https://kubernetes.io/docs/concepts/configuration/pod-priority-preemption/ -## -priorityClassName: "" - -settings: - logLevel: "INFO" - ## Possible values: goerli, perm_goerli, gnosis, mainnet - ## - network: "mainnet" - - ipfsPinEndpoints: "/dns/ipfs.infura.io/tcp/5001/https" - ipfsFetchEndpoints: "https://gateway.pinata.cloud,http://cloudflare-ipfs.com,https://ipfs.io" - ipfsPinataPinEndpoint: "https://api.pinata.cloud/pinning/pinJSONToIPFS" - infuraIpfsClientUsername: "" - infuraIpfsClientPassword: "" - - sentryDsn: "" - - ## ETH2 - ## - eth2Endpoint: "" - - enableHealthServer: "False" - healthServerHost: "0.0.0.0" - healthServerPort: "8080" - - ## Graph - ## Options: - ## mainnet: "https://api.thegraph.com/subgraphs/name/stakewise/stakewise-mainnet" - ## goerli: "https://api.thegraph.com/subgraphs/name/stakewise/stakewise-goerli" - ## permGoerli: "https://api.thegraph.com/subgraphs/name/stakewise/stakewise-perm-goerli" - ## gnosis: "https://api.thegraph.com/subgraphs/name/stakewise/stakewise-gnosis" - ## harbourMainnet: "https://api.thegraph.com/subgraphs/name/stakewise/stakewise-harbour-mainnet" - ## harbourGoerli: "https://api.thegraph.com/subgraphs/name/stakewise/stakewise-perm-goerli" - stakewiseSubgraphUrls: "https://graph.stakewise.io/subgraphs/name/stakewise/stakewise,https://api.thegraph.com/subgraphs/name/stakewise/stakewise-mainnet" - - ## Options: - ## mainnet: "https://api.thegraph.com/subgraphs/name/stakewise/uniswap-v3-mainnet" - ## goerli: "https://api.thegraph.com/subgraphs/name/stakewise/uniswap-v3-goerli" - uniswapV3SubgraphUrls: "https://graph.stakewise.io/subgraphs/name/stakewise/uniswap-v3,https://api.thegraph.com/subgraphs/name/stakewise/uniswap-v3-mainnet" - - ## Options: - ## mainnet: "https://api.thegraph.com/subgraphs/name/stakewise/ethereum-mainnet" - ## goerli: "https://api.thegraph.com/subgraphs/name/stakewise/ethereum-goerli" - ## permGoerli: "https://api.thegraph.com/subgraphs/name/stakewise/ethereum-goerli" - ## gnosis: "https://api.thegraph.com/subgraphs/name/stakewise/ethereum-gnosis" - ## harbourMainnet: "https://api.thegraph.com/subgraphs/name/stakewise/ethereum-mainnet" - ## harbourGoerli: "https://api.thegraph.com/subgraphs/name/stakewise/ethereum-goerli" - ethereumSubgraphUrls: "https://graph.stakewise.io/subgraphs/name/stakewise/ethereum,https://api.thegraph.com/subgraphs/name/stakewise/ethereum-mainnet" - - ## Credentials - ## - ipfsPinataApiKey: "" - ipfsPinataSecretKey: "" - - oraclePrivateKey: "" - awsAccessKeyID: "" - awsSecretAccessKey: "" - awsRegion: "" - - ## The chunk size for fetching validators' balances - ## - validatorsFetchChunkSize: "100" - - ## Max number of validators to register in a single transaction - ## - validatorsBatchSize: "10" - - harbourMainnetSendTelegramNotifications: False diff --git a/charts/grafana-stakewise-dashboards/.helmignore b/charts/posmoni/.helmignore similarity index 100% rename from charts/grafana-stakewise-dashboards/.helmignore rename to charts/posmoni/.helmignore diff --git a/charts/grafana-stakewise-dashboards/Chart.lock b/charts/posmoni/Chart.lock similarity index 76% rename from charts/grafana-stakewise-dashboards/Chart.lock rename to charts/posmoni/Chart.lock index c7087d1ff..bf2e36019 100644 --- a/charts/grafana-stakewise-dashboards/Chart.lock +++ b/charts/posmoni/Chart.lock @@ -3,4 +3,4 @@ dependencies: repository: file://../common version: 1.0.0 digest: sha256:07cebde439abe4ba19bb28e844b7419dab83c7f613886416aaf3ec08e8059144 -generated: "2022-04-20T16:28:22.724706135+03:00" +generated: "2022-05-02T13:36:12.005448244+03:00" diff --git a/charts/posmoni/Chart.yaml b/charts/posmoni/Chart.yaml new file mode 100644 index 000000000..8d211bfbe --- /dev/null +++ b/charts/posmoni/Chart.yaml @@ -0,0 +1,16 @@ +apiVersion: v2 +name: posmoni +description: A Helm chart for installing and configuring Posmoni +type: application +version: 1.0.0 +appVersion: "v0.0.1" + +keywords: + - ethereum + +home: https://nethermind.io/ + +dependencies: +- name: common + repository: file://../common + version: 1.0.0 diff --git a/charts/posmoni/templates/_helpers.tpl b/charts/posmoni/templates/_helpers.tpl new file mode 100644 index 000000000..b1177e68a --- /dev/null +++ b/charts/posmoni/templates/_helpers.tpl @@ -0,0 +1,62 @@ +{{/* +Expand the name of the chart. +*/}} +{{- define "posmoni.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 "posmoni.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 "posmoni.chart" -}} +{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }} +{{- end }} + +{{/* +Common labels +*/}} +{{- define "posmoni.labels" -}} +helm.sh/chart: {{ include "posmoni.chart" . }} +{{ include "posmoni.selectorLabels" . }} +{{- if .Chart.AppVersion }} +app.kubernetes.io/version: {{ .Chart.AppVersion | quote }} +{{- end }} +app.kubernetes.io/managed-by: {{ .Release.Service }} +{{- end }} + +{{/* +Selector labels +*/}} +{{- define "posmoni.selectorLabels" -}} +app.kubernetes.io/name: {{ include "posmoni.name" . }} +app.kubernetes.io/instance: {{ .Release.Name }} +{{- end }} + +{{/* +Create the name of the service account to use +*/}} +{{- define "posmoni.serviceAccountName" -}} +{{- if .Values.serviceAccount.create }} +{{- default (include "posmoni.fullname" .) .Values.serviceAccount.name }} +{{- else }} +{{- default "default" .Values.serviceAccount.name }} +{{- end }} +{{- end }} diff --git a/charts/web3signer/templates/secret.yaml b/charts/posmoni/templates/configmap.yaml similarity index 65% rename from charts/web3signer/templates/secret.yaml rename to charts/posmoni/templates/configmap.yaml index 970bf9a6b..b4e021516 100644 --- a/charts/web3signer/templates/secret.yaml +++ b/charts/posmoni/templates/configmap.yaml @@ -1,8 +1,10 @@ apiVersion: v1 -kind: Secret +kind: ConfigMap metadata: name: {{ include "common.names.fullname" . }} labels: {{- include "common.labels.standard" . | nindent 4 }} data: - DECRYPTION_KEY: {{ .Values.decryptionKey | b64enc | quote }} \ No newline at end of file + config.yaml: | + {{- toYaml .Values.posmoni | nindent 4 }} + diff --git a/charts/posmoni/templates/service.yaml b/charts/posmoni/templates/service.yaml new file mode 100644 index 000000000..d35d35539 --- /dev/null +++ b/charts/posmoni/templates/service.yaml @@ -0,0 +1,15 @@ +apiVersion: v1 +kind: Service +metadata: + name: {{ include "posmoni.fullname" . }} + labels: + {{- include "posmoni.labels" . | nindent 4 }} +spec: + type: {{ .Values.service.type }} + ports: + - port: {{ .Values.metricsPort }} + targetPort: metrics + protocol: TCP + name: metrics + selector: + {{- include "posmoni.selectorLabels" . | nindent 4 }} diff --git a/charts/geth/templates/serviceaccount.yaml b/charts/posmoni/templates/serviceaccount.yaml similarity index 100% rename from charts/geth/templates/serviceaccount.yaml rename to charts/posmoni/templates/serviceaccount.yaml diff --git a/charts/validator-monitor/templates/servicemonitor.yaml b/charts/posmoni/templates/servicemonitor.yaml similarity index 89% rename from charts/validator-monitor/templates/servicemonitor.yaml rename to charts/posmoni/templates/servicemonitor.yaml index 0095c8639..bd99c3387 100644 --- a/charts/validator-monitor/templates/servicemonitor.yaml +++ b/charts/posmoni/templates/servicemonitor.yaml @@ -1,5 +1,4 @@ {{- if .Values.serviceMonitor.enabled }} ---- apiVersion: monitoring.coreos.com/v1 kind: ServiceMonitor metadata: @@ -27,8 +26,8 @@ spec: {{- if .Values.serviceMonitor.honorLabels }} honorLabels: {{ .Values.serviceMonitor.honorLabels }} {{- end }} - {{- if .Values.serviceMonitor.relabellings }} - relabelings: {{- toYaml .Values.serviceMonitor.relabellings | nindent 6 }} + {{- if .Values.serviceMonitor.relabelings }} + relabelings: {{- toYaml .Values.serviceMonitor.relabelings | nindent 6 }} {{- end }} {{- if .Values.serviceMonitor.metricRelabelings }} metricRelabelings: {{- toYaml .Values.serviceMonitor.metricRelabelings | nindent 6 }} @@ -39,4 +38,4 @@ spec: selector: matchLabels: {{- include "common.labels.matchLabels" . | nindent 6 }} -{{- end }} +{{- end }} \ No newline at end of file diff --git a/charts/validator-monitor/templates/deployment.yaml b/charts/posmoni/templates/statefulset.yaml similarity index 65% rename from charts/validator-monitor/templates/deployment.yaml rename to charts/posmoni/templates/statefulset.yaml index d465153c6..e49cefd8e 100644 --- a/charts/validator-monitor/templates/deployment.yaml +++ b/charts/posmoni/templates/statefulset.yaml @@ -1,5 +1,5 @@ -apiVersion: {{ include "common.capabilities.deployment.apiVersion" . }} -kind: Deployment +apiVersion: {{ include "common.capabilities.statefulset.apiVersion" . }} +kind: StatefulSet metadata: name: {{ include "common.names.fullname" . }} labels: @@ -9,6 +9,7 @@ spec: selector: matchLabels: {{- include "common.labels.matchLabels" . | nindent 6 }} + serviceName: {{ include "common.names.fullname" . }} template: metadata: {{- with .Values.podAnnotations }} @@ -18,11 +19,23 @@ spec: labels: {{- include "common.labels.matchLabels" . | nindent 8 }} spec: + {{- with .Values.nodeSelector }} + nodeSelector: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with .Values.affinity }} + affinity: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with .Values.tolerations }} + tolerations: + {{- toYaml . | nindent 8 }} + {{- end }} {{- with .Values.imagePullSecrets }} imagePullSecrets: {{- toYaml . | nindent 8 }} {{- end }} - serviceAccountName: {{ include "common.names.serviceAccountName" . }} + serviceAccountName: {{ include "posmoni.serviceAccountName" . }} securityContext: {{- toYaml .Values.podSecurityContext | nindent 8 }} containers: @@ -31,40 +44,38 @@ spec: {{- toYaml .Values.securityContext | nindent 12 }} image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}" imagePullPolicy: {{ .Values.image.pullPolicy }} - env: - - name: BIND_ADDRESS - value: "0.0.0.0:{{ .Values.service.port }}" - - name: GRAPH_NODE_URL - value: {{ .Values.graphNodeUrl | quote }} - - name: BEACON_NODE_URL - value: {{ .Values.beaconNodeUrl | quote }} - - name: INDEX_CHUNCK_SIZE - value: {{ .Values.indexChunckSize | quote }} - - name: OPERATOR_WALLETS - value: {{ join "," .Values.operatorWallets | quote }} + args: + - ethereum + - --config + - /config/config.yaml ports: - name: metrics - containerPort: {{ .Values.service.port }} + containerPort: {{ .Values.metricsPort }} protocol: TCP livenessProbe: httpGet: path: /metrics port: metrics + initialDelaySeconds: 900 + timeoutSeconds: 3 + periodSeconds: 30 + failureThreshold: 3 + successThreshold: 1 readinessProbe: httpGet: path: /metrics port: metrics + initialDelaySeconds: 60 + timeoutSeconds: 3 + periodSeconds: 30 + failureThreshold: 3 + successThreshold: 1 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 }} + volumeMounts: + - name: config + mountPath: /config + volumes: + - name: config + configMap: + name: {{ include "common.names.fullname" . }} diff --git a/charts/validator-monitor/values.yaml b/charts/posmoni/values.yaml similarity index 67% rename from charts/validator-monitor/values.yaml rename to charts/posmoni/values.yaml index 4d22b7c24..f12656b36 100644 --- a/charts/validator-monitor/values.yaml +++ b/charts/posmoni/values.yaml @@ -1,4 +1,4 @@ -# Default values for validator-monitor. +# Default values for web3signer. # This is a YAML-formatted file. # Declare variables to be passed into your templates. @@ -6,28 +6,24 @@ global: serviceAccount: create: true -# Validator Monitor Settings -# Options: -# mainnet: https://api.thegraph.com/subgraphs/name/stakewise/stakewise-mainnet -# goerli: https://api.thegraph.com/subgraphs/name/stakewise/stakewise-goerli -# gnosis: https://api.thegraph.com/subgraphs/name/stakewise/stakewise-gnosis -graphNodeUrl: https://api.thegraph.com/subgraphs/name/stakewise/stakewise-mainnet -beaconNodeUrl: http://localhost:5052 -indexChunckSize: 800 -operatorWallets: [] - replicaCount: 1 image: - repository: europe-west4-docker.pkg.dev/stakewiselabs/public/validator-monitor + repository: nethermindeth/posmoni pullPolicy: IfNotPresent - # Overrides the image tag whose default is the chart appVersion. - tag: "v1.0.0" + tag: "enable-monitoring" + +posmoni: + logs: + logLevel: INFO + validators: [1,2,3] + consensus: http://localhost:4000 + execution: http://localhost:8545 -imagePullSecrets: [] -nameOverride: "" -fullnameOverride: "" +metricsPort: 2112 +## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ +## serviceAccount: # Annotations to add to the service account annotations: {} @@ -37,8 +33,10 @@ serviceAccount: podAnnotations: {} +## Pod Security Context +## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/ +## podSecurityContext: {} - # fsGroup: 2000 securityContext: {} # capabilities: @@ -50,8 +48,11 @@ securityContext: {} service: type: ClusterIP - port: 9000 + port: 80 +## Configure resource requests and limits. +## ref: http://kubernetes.io/docs/user-guide/compute-resources/ +## resources: {} # We usually recommend not to specify default resources and to leave this as a conscious # choice for the user. This also increases chances charts run on environments with little @@ -64,10 +65,19 @@ resources: {} # cpu: 100m # memory: 128Mi +## Node labels for pod assignment +## ref: https://kubernetes.io/docs/user-guide/node-selection/ +## nodeSelector: {} -tolerations: [] +## Tolerations for pod assignment +## ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/ +## +tolerations: {} +## Affinity for pod assignment +## ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity +## affinity: {} ## Prometheus Service Monitor @@ -77,7 +87,7 @@ affinity: {} serviceMonitor: ## @param metrics.serviceMonitor.enabled Create ServiceMonitor resource(s) for scraping metrics using PrometheusOperator ## - enabled: true + enabled: false ## @param metrics.serviceMonitor.namespace The namespace in which the ServiceMonitor will be created ## namespace: "" @@ -99,20 +109,3 @@ serviceMonitor: ## @param metrics.serviceMonitor.additionalLabels Additional labels that can be used so ServiceMonitor resource(s) can be discovered by Prometheus ## additionalLabels: {} - -## Define custom PrometheusRule -## ref: https://github.com/coreos/prometheus-operator#customresourcedefinitions -## -prometheusRule: - ## Create a default set of Alerts - ## - default: true - ## The namespace in which the prometheusRule will be created - ## - namespace: "" - ## Additional labels for the prometheusRule - ## - additionalLabels: {} - ## Custom Prometheus rules - ## - rules: [] diff --git a/charts/prysm/Chart.lock b/charts/prysm/Chart.lock deleted file mode 100644 index 5f9291223..000000000 --- a/charts/prysm/Chart.lock +++ /dev/null @@ -1,6 +0,0 @@ -dependencies: -- name: common - repository: file://../common - version: 1.0.0 -digest: sha256:07cebde439abe4ba19bb28e844b7419dab83c7f613886416aaf3ec08e8059144 -generated: "2022-03-07T13:18:51.623299606+03:00" diff --git a/charts/prysm/Chart.yaml b/charts/prysm/Chart.yaml deleted file mode 100644 index 2b0ebb385..000000000 --- a/charts/prysm/Chart.yaml +++ /dev/null @@ -1,24 +0,0 @@ -apiVersion: v2 -name: prysm -version: 3.2.2 -appVersion: v3.1.0 -kubeVersion: "^1.18.0-0" -description: Go implementation of Ethereum proof of stake. -type: application -keywords: - - ethereum - - blockchain - - prysm - - p2p -home: https://www.ethereum.org/ -sources: - - https://github.com/prysmaticlabs/prysm -maintainers: - - name: Dmitri Tsumak - email: dmitri@stakewise.io -icon: https://raw.githubusercontent.com/ethereum/ethereum-org/master/public/images/logos/ETHEREUM-ICON_Black.png - -dependencies: -- name: common - repository: file://../common - version: 1.0.0 diff --git a/charts/prysm/templates/_helpers.yaml b/charts/prysm/templates/_helpers.yaml deleted file mode 100644 index d63e7960c..000000000 --- a/charts/prysm/templates/_helpers.yaml +++ /dev/null @@ -1,3 +0,0 @@ -{{- define "prysm.p2pPort" -}} -{{- printf "13000" -}} -{{- end -}} diff --git a/charts/prysm/templates/clusterrole.yaml b/charts/prysm/templates/clusterrole.yaml deleted file mode 100644 index 6d7136bd1..000000000 --- a/charts/prysm/templates/clusterrole.yaml +++ /dev/null @@ -1,10 +0,0 @@ -{{- if or .Values.global.rbac.create .Values.rbac.create }} -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: {{ include "common.names.clusterRoleName" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -rules: -{{- toYaml .Values.rbac.clusterRules | nindent 0 }} -{{- end }} diff --git a/charts/prysm/templates/clusterrolebinding.yaml b/charts/prysm/templates/clusterrolebinding.yaml deleted file mode 100644 index 87d636dac..000000000 --- a/charts/prysm/templates/clusterrolebinding.yaml +++ /dev/null @@ -1,16 +0,0 @@ -{{- if or .Values.global.rbac.create .Values.rbac.create }} -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: {{ include "common.names.clusterRoleName" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: {{ include "common.names.clusterRoleName" . }} -subjects: - - kind: ServiceAccount - name: {{ include "common.names.serviceAccountName" . }} - namespace: {{ .Release.Namespace }} -{{- end }} diff --git a/charts/prysm/templates/configmap.yaml b/charts/prysm/templates/configmap.yaml deleted file mode 100644 index b776b9d21..000000000 --- a/charts/prysm/templates/configmap.yaml +++ /dev/null @@ -1,202 +0,0 @@ -apiVersion: v1 -kind: ConfigMap -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -data: - entrypoint.sh: | - #!/bin/sh -{{- if eq .Values.global.network "prater" }} - if ! [ -f /data/genesis.ssz ]; then - curl --output /data/genesis.ssz "https://raw.githubusercontent.com/eth2-clients/eth2-networks/32dcce003694ea17e04bc17cc56de2f7909a1d95/shared/prater/genesis.ssz" - fi -{{- end }} -{{- if eq .Values.global.network "ropsten" }} - if ! [ -f /data/genesis.ssz ]; then - curl --output /data/genesis.ssz "https://raw.githubusercontent.com/eth-clients/merge-testnets/main/ropsten-beacon-chain/genesis.ssz" - fi -{{- end }} -{{- if eq .Values.global.network "sepolia" }} - if ! [ -f /data/genesis.ssz ]; then - curl --output /data/genesis.ssz "https://raw.githubusercontent.com/eth-clients/merge-testnets/main/sepolia/genesis.ssz" - fi -{{- end }} - execution-endpoints.txt: |- -{{- range $i, $e := .Values.global.executionEndpoints }} - {{ . }} -{{- end }} - -{{- if eq .Values.global.network "gnosis" }} ---- -apiVersion: v1 -kind: ConfigMap -metadata: - name: {{ include "common.names.fullname" . }}-gnosis - labels: - {{- include "common.labels.standard" . | nindent 4 }} -data: - bootnodes.yaml: | - - "enr:-IS4QGmLwm7gFd0L0CEisllrb1op3v-wAGSc7_pwSMGgN3bOS9Fz7m1dWbwuuPHKqeETz9MbhjVuoWk0ohkyRv98kVoBgmlkgnY0gmlwhGjtlgaJc2VjcDI1NmsxoQLMdh0It9fJbuiLydZ9fpF6MRzgNle0vODaDiMqhbC7WIN1ZHCCIyg" - - "enr:-IS4QFUVG3dvLPCUEI7ycRvFm0Ieg_ITa5tALmJ9LI7dJ6ieT3J4fF9xLRjOoB4ApV-Rjp7HeLKzyTWG1xRdbFBNZPQBgmlkgnY0gmlwhErP5weJc2VjcDI1NmsxoQOBbaJBvx0-w_pyZUhQl9A510Ho2T0grE0K8JevzES99IN1ZHCCIyg" - - "enr:-Ku4QOQk8V-Hu2gxFzRXmLYIO4AvWDZhoMFwTf3n3DYm_mbsWv0ZitoqiN6JZUUj6Li6e1Jk1w2zFSVHKPMUP1g5tsgBh2F0dG5ldHOIAAAAAAAAAACEZXRoMpD5Jd3FAAAAZP__________gmlkgnY0gmlwhC1PTpmJc2VjcDI1NmsxoQL1Ynt5PoA0UOcHa1Rfn98rmnRlLzNuWTePPP4m4qHVroN1ZHCCKvg" - - "enr:-Ku4QFaTwgoms-EiiRIfHUH3FXprWUFgjHg4UuWvilqoUQtDbmTszVIxUEOwQUmA2qkiP-T9wXjc_rVUuh9cU7WgwbgBh2F0dG5ldHOIAAAAAAAAAACEZXRoMpD5Jd3FAAAAZP__________gmlkgnY0gmlwhC0hBmCJc2VjcDI1NmsxoQOpsg1XCrXmCwZKcSTcycLwldoKUMHPUpMEVGeg_EEhuYN1ZHCCKvg" - config.yaml: | - CONFIG_NAME: gnosis - PRESET_BASE: gnosis - - # Misc - # --------------------------------------------------------------- - # 2**6 (= 64) - MAX_COMMITTEES_PER_SLOT: 64 - # 2**7 (= 128) - TARGET_COMMITTEE_SIZE: 128 - # 2**11 (= 2,048) - MAX_VALIDATORS_PER_COMMITTEE: 2048 - # 2**2 (= 4) - MIN_PER_EPOCH_CHURN_LIMIT: 4 - # 2**12 (= 4096) - CHURN_LIMIT_QUOTIENT: 4096 - # See issue 563 - SHUFFLE_ROUND_COUNT: 90 - # `2**12` (= 4096) - MIN_GENESIS_ACTIVE_VALIDATOR_COUNT: 4096 - # Dec 08, 2021, 13:00 UTC - MIN_GENESIS_TIME: 1638968400 - # 4 - HYSTERESIS_QUOTIENT: 4 - # 1 (minus 0.25) - HYSTERESIS_DOWNWARD_MULTIPLIER: 1 - # 5 (plus 1.25) - HYSTERESIS_UPWARD_MULTIPLIER: 5 - # Fork Choice - # --------------------------------------------------------------- - # 2**3 (= 8) - SAFE_SLOTS_TO_UPDATE_JUSTIFIED: 8 - # Validator - # --------------------------------------------------------------- - # 2**10 (= 1024) ~1.4 hour - ETH1_FOLLOW_DISTANCE: 1024 - # 2**4 (= 16) - TARGET_AGGREGATORS_PER_COMMITTEE: 16 - # 2**0 (= 1) - RANDOM_SUBNETS_PER_VALIDATOR: 1 - # 2**8 (= 256) - EPOCHS_PER_RANDOM_SUBNET_SUBSCRIPTION: 256 - # 6 (estimate from xDai mainnet) - SECONDS_PER_ETH1_BLOCK: 6 - - # Deposit contract - # --------------------------------------------------------------- - # xDai Mainnet - DEPOSIT_CHAIN_ID: 100 - DEPOSIT_NETWORK_ID: 100 - # GBC deposit contract on xDai Mainnet - DEPOSIT_CONTRACT_ADDRESS: 0x0B98057eA310F4d31F2a452B414647007d1645d9 - # Gwei values - # --------------------------------------------------------------- - # 2**0 * 10**9 (= 1,000,000,000) Gwei - MIN_DEPOSIT_AMOUNT: 1000000000 - # 2**5 * 10**9 (= 32,000,000,000) Gwei - MAX_EFFECTIVE_BALANCE: 32000000000 - # 2**4 * 10**9 (= 16,000,000,000) Gwei - EJECTION_BALANCE: 16000000000 - # 2**0 * 10**9 (= 1,000,000,000) Gwei - EFFECTIVE_BALANCE_INCREMENT: 1000000000 - # Initial values - # --------------------------------------------------------------- - # GBC area code - GENESIS_FORK_VERSION: 0x00000064 - BLS_WITHDRAWAL_PREFIX: 0x00 - # Time parameters - # --------------------------------------------------------------- - # Customized for GBC: ~1 hour - GENESIS_DELAY: 6000 - # 5 seconds - SECONDS_PER_SLOT: 5 - # 2**0 (= 1) slots 12 seconds - MIN_ATTESTATION_INCLUSION_DELAY: 1 - # 2**4 (= 16) slots 1.87 minutes - SLOTS_PER_EPOCH: 16 - # 2**0 (= 1) epochs 1.87 minutes - MIN_SEED_LOOKAHEAD: 1 - # 2**2 (= 4) epochs 7.47 minutes - MAX_SEED_LOOKAHEAD: 4 - # 2**6 (= 64) epochs ~2 hours - EPOCHS_PER_ETH1_VOTING_PERIOD: 64 - # 2**13 (= 8,192) slots ~15.9 hours - SLOTS_PER_HISTORICAL_ROOT: 8192 - # 2**8 (= 256) epochs ~8 hours - MIN_VALIDATOR_WITHDRAWABILITY_DELAY: 256 - # 2**8 (= 256) epochs ~8 hours - SHARD_COMMITTEE_PERIOD: 256 - # 2**2 (= 4) epochs 7.47 minutes - MIN_EPOCHS_TO_INACTIVITY_PENALTY: 4 - - # State vector lengths - # --------------------------------------------------------------- - # 2**16 (= 65,536) epochs ~85 days - EPOCHS_PER_HISTORICAL_VECTOR: 65536 - # 2**13 (= 8,192) epochs ~10.6 days - EPOCHS_PER_SLASHINGS_VECTOR: 8192 - # 2**24 (= 16,777,216) historical roots, ~15,243 years - HISTORICAL_ROOTS_LIMIT: 16777216 - # 2**40 (= 1,099,511,627,776) validator spots - VALIDATOR_REGISTRY_LIMIT: 1099511627776 - # Reward and penalty quotients - # --------------------------------------------------------------- - # 25 - BASE_REWARD_FACTOR: 25 - # 2**9 (= 512) - WHISTLEBLOWER_REWARD_QUOTIENT: 512 - # 2**3 (= 8) - PROPOSER_REWARD_QUOTIENT: 8 - # 2**26 (= 67,108,864) - INACTIVITY_PENALTY_QUOTIENT: 67108864 - # 2**7 (= 128) (lower safety margin at Phase 0 genesis) - MIN_SLASHING_PENALTY_QUOTIENT: 128 - # 1 (lower safety margin at Phase 0 genesis) - PROPORTIONAL_SLASHING_MULTIPLIER: 1 - # Max operations per block - # --------------------------------------------------------------- - # 2**4 (= 16) - MAX_PROPOSER_SLASHINGS: 16 - # 2**1 (= 2) - MAX_ATTESTER_SLASHINGS: 2 - # 2**7 (= 128) - MAX_ATTESTATIONS: 128 - # 2**4 (= 16) - MAX_DEPOSITS: 16 - # 2**4 (= 16) - MAX_VOLUNTARY_EXITS: 16 - # Signature domains - # --------------------------------------------------------------- - DOMAIN_BEACON_PROPOSER: 0x00000000 - DOMAIN_BEACON_ATTESTER: 0x01000000 - DOMAIN_RANDAO: 0x02000000 - DOMAIN_DEPOSIT: 0x03000000 - DOMAIN_VOLUNTARY_EXIT: 0x04000000 - DOMAIN_SELECTION_PROOF: 0x05000000 - DOMAIN_AGGREGATE_AND_PROOF: 0x06000000 - DOMAIN_SYNC_COMMITTEE: 0x07000000 - DOMAIN_SYNC_COMMITTEE_SELECTION_PROOF: 0x08000000 - DOMAIN_CONTRIBUTION_AND_PROOF: 0x09000000 - - ALTAIR_FORK_VERSION: 0x01000064 - ALTAIR_FORK_EPOCH: 512 - - INACTIVITY_SCORE_BIAS: 4 - # 2**4 (= 16) - INACTIVITY_SCORE_RECOVERY_RATE: 16 - INACTIVITY_PENALTY_QUOTIENT_ALTAIR: 50331648 - MIN_SLASHING_PENALTY_QUOTIENT_ALTAIR: 64 - PROPORTIONAL_SLASHING_MULTIPLIER_ALTAIR: 2 - - # Sync committee - # --------------------------------------------------------------- - # 2**9 (= 512) - SYNC_COMMITTEE_SIZE: 512 - # 2**9 (= 512) - # assert EPOCHS_PER_SYNC_COMMITTEE_PERIOD * SLOTS_PER_EPOCH <= SLOTS_PER_HISTORICAL_ROOT - EPOCHS_PER_SYNC_COMMITTEE_PERIOD: 512 -{{- end }} diff --git a/charts/prysm/templates/pdb.yaml b/charts/prysm/templates/pdb.yaml deleted file mode 100644 index 4ef63f0ff..000000000 --- a/charts/prysm/templates/pdb.yaml +++ /dev/null @@ -1,18 +0,0 @@ -{{- if .Values.podDisruptionBudget.enabled }} -apiVersion: {{ include "common.capabilities.policy.apiVersion" . }} -kind: PodDisruptionBudget -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -spec: -{{- if .Values.podDisruptionBudget.minAvailable }} - minAvailable: {{ .Values.podDisruptionBudget.minAvailable }} -{{- end }} -{{- if .Values.podDisruptionBudget.maxUnavailable }} - maxUnavailable: {{ .Values.podDisruptionBudget.maxUnavailable }} -{{- end }} - selector: - matchLabels: - {{- include "common.labels.matchLabels" . | nindent 6 }} -{{- end }} diff --git a/charts/prysm/templates/prometheusrules.yaml b/charts/prysm/templates/prometheusrules.yaml deleted file mode 100644 index 4e757e521..000000000 --- a/charts/prysm/templates/prometheusrules.yaml +++ /dev/null @@ -1,59 +0,0 @@ -{{- if and (or .Values.global.metrics.enabled .Values.metrics.enabled) - (or .Values.global.metrics.prometheusRule.enabled .Values.metrics.prometheusRule.enabled) }} -apiVersion: monitoring.coreos.com/v1 -kind: PrometheusRule -metadata: - name: {{ include "common.names.fullname" . }} - {{- if .Values.metrics.prometheusRule.namespace }} - namespace: {{ .Values.metrics.prometheusRule.namespace }} - {{- else }} - namespace: {{ .Release.Namespace | quote }} - {{- end }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.metrics.prometheusRule.additionalLabels }} - {{- toYaml .Values.metrics.prometheusRule.additionalLabels | nindent 4 }} - {{- end }} -spec: - groups: - {{- with .Values.metrics.prometheusRule.rules }} - - name: {{ include "common.names.fullname" $ }} - rules: {{- tpl (toYaml .) $ | nindent 8 }} - {{- end }} - {{- if .Values.metrics.prometheusRule.default }} - - name: {{ include "common.names.fullname" $ }}-default - rules: - - alert: PrysmBeaconNodeDown - expr: up{job='{{ include "common.names.fullname" . }}'} == 0 - for: 1m - labels: - severity: critical - annotations: - summary: Prysm beacon node is down - description: Check {{ printf "{{ $labels.pod }}" }} beacon node in namespace {{ printf "{{ $labels.namespace }}" }} - - alert: Prysm50SlotsBehind - expr: beacon_clock_time_slot{job='{{ include "common.names.fullname" . }}'}-beacon_head_slot{job='{{ include "common.names.fullname" . }}'} > 50 - for: 2m - labels: - severity: critical - annotations: - summary: Prysm beacon node is out of sync - description: Check {{ printf "{{ $labels.pod }}" }} beacon node in namespace {{ printf "{{ $labels.namespace }}" }} - - alert: PrysmParticipationRateLessThen66Percent - expr: beacon_prev_epoch_target_gwei{job='{{ include "common.names.fullname" . }}'}/beacon_prev_epoch_active_gwei{job='{{ include "common.names.fullname" . }}'}*100 < 66 - for: 5m - labels: - severity: critical - annotations: - summary: Prysm beacon node participation rate less then 66% - description: Check {{ printf "{{ $labels.pod }}" }} beacon node in namespace {{ printf "{{ $labels.namespace }}" }} - - alert: PrysmBeaconNodeRestarted - expr: (time()-process_start_time_seconds{job='{{ include "common.names.fullname" . }}'})/3600 < 0.1 - for: 1m - labels: - severity: warning - annotations: - summary: Prysm beacon node was restarted - description: Check {{ printf "{{ $labels.pod }}" }} beacon node in namespace {{ printf "{{ $labels.namespace }}" }} - {{- end }} -{{- end }} diff --git a/charts/prysm/templates/role.yaml b/charts/prysm/templates/role.yaml deleted file mode 100644 index dfbc0fe48..000000000 --- a/charts/prysm/templates/role.yaml +++ /dev/null @@ -1,10 +0,0 @@ -{{- if or .Values.global.rbac.create .Values.rbac.create -}} -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -rules: -{{- toYaml .Values.rbac.rules | nindent 0 }} -{{- end }} diff --git a/charts/prysm/templates/rolebinding.yaml b/charts/prysm/templates/rolebinding.yaml deleted file mode 100644 index 1fdb617ba..000000000 --- a/charts/prysm/templates/rolebinding.yaml +++ /dev/null @@ -1,15 +0,0 @@ -{{- if or .Values.global.rbac.create .Values.rbac.create }} -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: {{ include "common.names.serviceAccountName" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: {{ include "common.names.serviceAccountName" . }} -subjects: - - kind: ServiceAccount - name: {{ include "common.names.serviceAccountName" . }} -{{- end }} diff --git a/charts/prysm/templates/secret.yaml b/charts/prysm/templates/secret.yaml deleted file mode 100644 index 5a3f66bb5..000000000 --- a/charts/prysm/templates/secret.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: v1 -kind: Secret -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -type: Opaque -data: - jwtsecret: {{ .Values.global.JWTSecret | b64enc | quote }} diff --git a/charts/prysm/templates/service-p2p.yaml b/charts/prysm/templates/service-p2p.yaml deleted file mode 100644 index 6f8dd84aa..000000000 --- a/charts/prysm/templates/service-p2p.yaml +++ /dev/null @@ -1,42 +0,0 @@ -{{- if .Values.p2pNodePort.enabled -}} -{{- range $i, $e := until (len .Values.global.executionEndpoints) }} -{{- $port := add $.Values.p2pNodePort.startAt $i -}} -{{- if hasKey $.Values.p2pNodePort.replicaToNodePort ($i | toString) -}} - {{ $port = index $.Values.p2pNodePort.replicaToNodePort ($i | toString) }} -{{- end }} - ---- -apiVersion: v1 -kind: Service -metadata: - name: {{ include "common.names.fullname" $ }}-{{ $i }} - labels: - {{- include "common.labels.standard" $ | nindent 4 }} - pod: "{{ include "common.names.fullname" $ }}-{{ $i }}" - type: p2p - {{- with $.Values.p2pNodePort.annotations }} - annotations: - {{- toYaml . | nindent 4 }} - {{- end }} -spec: - type: {{ $.Values.p2pNodePort.type }} - externalTrafficPolicy: Local - ports: - - name: p2p-tcp - port: {{ include "prysm.p2pPort" $ }} - protocol: TCP - targetPort: p2p-tcp - nodePort: {{ $port }} - {{- if eq $.Values.p2pNodePort.type "NodePort" }} - - name: p2p-udp - port: {{ include "prysm.p2pPort" $ }} - protocol: UDP - targetPort: p2p-udp - nodePort: {{ $port }} - {{- end }} - selector: - {{- include "common.labels.matchLabels" $ | nindent 4 }} - statefulset.kubernetes.io/pod-name: "{{ include "common.names.fullname" $ }}-{{ $i }}" - -{{- end }} -{{- end }} diff --git a/charts/prysm/templates/service.yaml b/charts/prysm/templates/service.yaml deleted file mode 100644 index 64dcf93cc..000000000 --- a/charts/prysm/templates/service.yaml +++ /dev/null @@ -1,38 +0,0 @@ ---- -apiVersion: v1 -kind: Service -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -{{- if and .Values.metrics.enabled .Values.metrics.svcAnnotations }} - annotations: - {{ toYaml .Values.metrics.svcAnnotations | nindent 4 | trim }} -{{- end }} -spec: -{{- if .Values.sessionAffinity.enabled }} - sessionAffinity: ClientIP - sessionAffinityConfig: - clientIP: - timeoutSeconds: {{ .Values.sessionAffinity.timeoutSeconds }} -{{- end }} - type: ClusterIP -{{- if .Values.svcHeadless }} - clusterIP: None -{{- end }} - ports: - - name: {{ .Values.rpc.portName }} - port: {{ .Values.rpc.port }} - targetPort: {{ .Values.rpc.portName }} - {{- if .Values.http.enabled }} - - name: http - port: {{ .Values.http.port }} - targetPort: http - {{- end }} - {{- if .Values.metrics.enabled }} - - name: metrics - port: {{ .Values.metrics.port }} - targetPort: metrics - {{- end }} - selector: - {{- include "common.labels.matchLabels" . | nindent 4 }} diff --git a/charts/prysm/templates/serviceaccount.yaml b/charts/prysm/templates/serviceaccount.yaml deleted file mode 100644 index cb2edd11f..000000000 --- a/charts/prysm/templates/serviceaccount.yaml +++ /dev/null @@ -1,12 +0,0 @@ -{{- if or .Values.global.serviceAccount.create .Values.serviceAccount.create -}} -apiVersion: v1 -kind: ServiceAccount -metadata: - name: {{ include "common.names.serviceAccountName" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} - {{- with .Values.serviceAccount.annotations }} - annotations: - {{- toYaml . | nindent 4 }} - {{- end }} -{{- end }} diff --git a/charts/prysm/templates/servicemonitor.yaml b/charts/prysm/templates/servicemonitor.yaml deleted file mode 100644 index 9ecffc6ca..000000000 --- a/charts/prysm/templates/servicemonitor.yaml +++ /dev/null @@ -1,42 +0,0 @@ -{{- if and (or .Values.global.metrics.enabled .Values.metrics.enabled) - (or .Values.global.metrics.serviceMonitor.enabled .Values.metrics.serviceMonitor.enabled) }} -apiVersion: monitoring.coreos.com/v1 -kind: ServiceMonitor -metadata: - name: {{ template "common.names.fullname" . }} - {{- if .Values.metrics.serviceMonitor.namespace }} - namespace: {{ .Values.metrics.serviceMonitor.namespace }} - {{- else }} - namespace: {{ .Release.Namespace | quote }} - {{- end }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.metrics.serviceMonitor.additionalLabels }} - {{- toYaml .Values.metrics.serviceMonitor.additionalLabels | nindent 4 }} - {{- end }} -spec: - endpoints: - - port: metrics - path: /metrics - {{- if .Values.metrics.serviceMonitor.interval }} - interval: {{ .Values.metrics.serviceMonitor.interval }} - {{- end }} - {{- if .Values.metrics.serviceMonitor.scrapeTimeout }} - scrapeTimeout: {{ .Values.metrics.serviceMonitor.scrapeTimeout }} - {{- end }} - {{- if .Values.metrics.serviceMonitor.honorLabels }} - honorLabels: {{ .Values.metrics.serviceMonitor.honorLabels }} - {{- end }} - {{- if .Values.metrics.serviceMonitor.relabelings }} - relabelings: {{- toYaml .Values.metrics.serviceMonitor.relabelings | nindent 6 }} - {{- end }} - {{- if .Values.metrics.serviceMonitor.metricRelabelings }} - metricRelabelings: {{- toYaml .Values.metrics.serviceMonitor.metricRelabelings | nindent 6 }} - {{- end }} - namespaceSelector: - matchNames: - - {{ .Release.Namespace }} - selector: - matchLabels: - {{- include "common.labels.matchLabels" . | nindent 6 }} -{{- end }} diff --git a/charts/prysm/templates/statefulset.yaml b/charts/prysm/templates/statefulset.yaml deleted file mode 100644 index 754f8c700..000000000 --- a/charts/prysm/templates/statefulset.yaml +++ /dev/null @@ -1,290 +0,0 @@ ---- -apiVersion: {{ include "common.capabilities.statefulset.apiVersion" . }} -kind: StatefulSet -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.statefulset" . | nindent 4 }} -spec: - replicas: {{ len .Values.global.executionEndpoints }} - podManagementPolicy: "Parallel" - selector: - matchLabels: - {{- include "common.labels.matchLabels" . | nindent 6 }} - serviceName: {{ include "common.names.fullname" . }} - template: - metadata: - labels: - {{- include "common.labels.matchLabels" . | nindent 8 }} - annotations: - checksum/configmap: {{ include (print $.Template.BasePath "/configmap.yaml") . | sha256sum }} - spec: - {{- with (concat .Values.imagePullSecrets .Values.global.imagePullSecrets) }} - imagePullSecrets: - {{- toYaml . | nindent 8 }} - {{- end }} - {{- with .Values.affinity }} - affinity: - {{ toYaml . | nindent 8 | trim }} - {{- end }} - {{- with .Values.tolerations }} - tolerations: - {{ toYaml . | nindent 8 | trim }} - {{- end }} - {{- with .Values.nodeSelector }} - nodeSelector: - {{ toYaml . | nindent 8 | trim }} - {{- end }} - {{- with .Values.securityContext }} - securityContext: - {{ toYaml . | nindent 8 | trim }} - {{- end }} - serviceAccountName: {{ include "common.names.fullname" . }} - priorityClassName: {{ .Values.priorityClassName | quote }} - initContainers: - - name: init - image: "{{ .Values.initImage.repository }}:{{ .Values.initImage.tag }}" - imagePullPolicy: {{ .Values.initImage.pullPolicy }} - securityContext: - runAsNonRoot: false - runAsUser: 0 - env: - - name: POD_IP - valueFrom: - fieldRef: - fieldPath: status.podIP - - name: POD_NAME - valueFrom: - fieldRef: - fieldPath: metadata.name - - name: POD_NAMESPACE - valueFrom: - fieldRef: - fieldPath: metadata.namespace - - name: NODE_NAME - valueFrom: - fieldRef: - fieldPath: spec.nodeName - command: - - sh - - -c - - > - echo "Namespace: ${POD_NAMESPACE} Pod: ${POD_NAME}"; - {{- if .Values.p2pNodePort.enabled }} - {{- if eq .Values.p2pNodePort.type "LoadBalancer" }} - until [ -n "$(kubectl -n ${POD_NAMESPACE} get svc/${POD_NAME} -o jsonpath='{.status.loadBalancer.ingress[0].ip}')" ]; do echo "Waiting for load balancer gets an IP" && sleep 10; done; - export EXTERNAL_PORT=$(kubectl -n ${POD_NAMESPACE} get services -l "pod in (${POD_NAME}), type in (p2p)" -o jsonpath='{.items[0].spec.ports[0].nodePort}'); - export EXTERNAL_IP=$(kubectl -n ${POD_NAMESPACE} get svc/${POD_NAME} -o jsonpath='{.status.loadBalancer.ingress[0].ip}'); - {{- else }} - export EXTERNAL_PORT=$(kubectl get services -l "pod in (${POD_NAME}), type in (p2p)" -o jsonpath='{.items[0].spec.ports[0].nodePort}'); - export EXTERNAL_IP=$(kubectl get nodes "${NODE_NAME}" -o jsonpath='{.status.addresses[?(@.type=="ExternalIP")].address}'); - {{- end }} - echo "p2p-host-ip: $EXTERNAL_IP" > /config/config.yaml; - echo "p2p-tcp-port: $EXTERNAL_PORT" >> /config/config.yaml; - echo "p2p-udp-port: $EXTERNAL_PORT" >> /config/config.yaml; - {{- else }} - echo "p2p-host-ip: $POD_IP" > /config/config.yaml; - echo 'p2p-tcp-port: {{ include "prysm.p2pPort" . }}' >> /config/config.yaml; - echo 'p2p-udp-port: {{ include "prysm.p2pPort" . }}' >> /config/config.yaml; - {{- end }} - INDEX=$((${HOSTNAME##*-}+1)); - EE=$(sed "${INDEX}q;d" /data/scripts/execution-endpoints.txt); - echo "http-web3provider: ${EE}" >> /config/config.yaml; - echo "Pod will connect to the ${EE} endpoint"; - cat /config/config.yaml; - {{- if and .Values.persistence.enabled .Values.initChownData }} - chown -R {{ .Values.securityContext.runAsUser }}:{{ .Values.securityContext.runAsUser }} /data | true; - {{- end }} - volumeMounts: - - name: config - mountPath: /config - - name: data - mountPath: /data - - name: scripts - mountPath: /data/scripts - {{- if or (eq .Values.global.network "prater") (eq .Values.global.network "ropsten") (eq .Values.global.network "sepolia") }} - - name: download-genesis-state - image: "curlimages/curl:latest" - imagePullPolicy: {{ .Values.initImage.pullPolicy }} - command: ['/bin/sh', '/data/scripts/entrypoint.sh'] - volumeMounts: - - name: data - mountPath: /data - - name: scripts - mountPath: /data/scripts - {{- end }} - containers: - - name: {{ include "common.names.fullname" . }} - {{- if ne .Values.global.network "gnosis" }} - image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}" - imagePullPolicy: {{ .Values.image.pullPolicy }} - {{- else }} - image: "{{ .Values.imageGnosis.repository }}:{{ .Values.imageGnosis.tag }}" - imagePullPolicy: {{ .Values.imageGnosis.pullPolicy }} - {{- end }} - args: - - "--datadir=/data" - - "--rpc-host={{ .Values.rpc.host }}" - - "--rpc-port={{ .Values.rpc.port }}" - - "--accept-terms-of-use" - - "--config-file=/config/config.yaml" - - "--jwt-secret=/secret/jwtsecret" - {{- if .Values.httpMevRelay }} - - "--http-mev-relay={{ .Values.httpMevRelay }}" - {{- end }} - - {{- if .Values.suggestedFeeRecipient }} - - "--suggested-fee-recipient={{ .Values.suggestedFeeRecipient }}" - {{- end }} - - {{- if .Values.totalDifficultyOverride }} - - "--terminal-total-difficulty-override={{ .Values.totalDifficultyOverride }}" - {{- end }} - - {{- if or (eq .Values.global.network "prater") (eq .Values.global.network "ropsten") (eq .Values.global.network "sepolia") }} - - "--genesis-state=/data/genesis.ssz" - {{- end }} - - {{- if ne .Values.global.network "gnosis" }} - - "--{{ .Values.global.network }}" - {{- else }} - - "--contract-deployment-block=19469077" - - "--bootstrap-node=/data/gnosis-config/bootnodes.yaml" - - "--config-file=/data/gnosis-config/config.yaml" - - "--chain-config-file=/data/gnosis-config/config.yaml" - {{- end }} - - {{- range .Values.extraFlags }} - - {{ . | quote }} - {{- end }} - - {{- if .Values.metrics.enabled }} - - "--monitoring-port={{ .Values.metrics.port }}" - - "--monitoring-host=0.0.0.0" - {{- else }} - - "--disable-monitoring" - {{- end }} - - {{- if .Values.http.enabled }} - - "--grpc-gateway-host=0.0.0.0" - - "--grpc-gateway-port={{ .Values.http.port }}" - {{- else }} - - "--disable-grpc-gateway" - {{- end }} - env: - - name: POD_IP - valueFrom: - fieldRef: - fieldPath: status.podIP - ports: - - containerPort: {{ .Values.rpc.port }} - name: {{ .Values.rpc.portName }} - protocol: TCP - {{- if .Values.p2pNodePort.enabled }} - - name: p2p-tcp - containerPort: {{ include "prysm.p2pPort" . }} - protocol: TCP - - name: p2p-udp - containerPort: {{ include "prysm.p2pPort" . }} - protocol: UDP - {{- end }} - {{- if .Values.http.enabled }} - - containerPort: {{ .Values.http.port }} - name: http - protocol: TCP - {{- end }} - {{- if .Values.metrics.enabled }} - - containerPort: {{ .Values.metrics.port }} - name: metrics - protocol: TCP - {{- end }} - volumeMounts: - - name: data - mountPath: /data - - name: jwtsecret - mountPath: /secret - readOnly: true - - name: config - mountPath: /config - {{- if eq .Values.global.network "gnosis" }} - - name: gnosis-config - mountPath: /data/gnosis-config - {{- end }} - {{- with .Values.resources }} - resources: - {{ toYaml . | nindent 12 | trim }} - {{- end }} - {{- if .Values.http.enabled }} - - name: sidecar - image: "{{ .Values.sidecar.repository }}:{{ .Values.sidecar.tag }}" - imagePullPolicy: {{ .Values.sidecar.pullPolicy }} - env: - - name: SERVER_BINDADDR - value: "{{ .Values.sidecar.bindAddr }}:{{ .Values.sidecar.bindPort }}" - - name: CLIENT_PORT - value: {{ .Values.http.port | quote }} - ports: - - containerPort: {{ .Values.sidecar.bindPort }} - name: sidecar - protocol: TCP - {{- if or .Values.global.livenessProbe.enabled .Values.livenessProbe.enabled }} - livenessProbe: - initialDelaySeconds: {{ .Values.livenessProbe.initialDelaySeconds }} - timeoutSeconds: {{ .Values.livenessProbe.timeoutSeconds }} - periodSeconds: {{ .Values.livenessProbe.periodSeconds }} - failureThreshold: {{ .Values.livenessProbe.failureThreshold }} - successThreshold: {{ .Values.livenessProbe.successThreshold }} - httpGet: - path: {{ .Values.livenessProbe.httpGet.path }} - port: {{ .Values.livenessProbe.httpGet.port }} - scheme: {{ .Values.livenessProbe.httpGet.scheme }} - {{- end }} - {{- if or .Values.global.readinessProbe.enabled .Values.readinessProbe.enabled }} - readinessProbe: - initialDelaySeconds: {{ .Values.readinessProbe.initialDelaySeconds }} - timeoutSeconds: {{ .Values.readinessProbe.timeoutSeconds }} - periodSeconds: {{ .Values.readinessProbe.periodSeconds }} - failureThreshold: {{ .Values.readinessProbe.failureThreshold }} - successThreshold: {{ .Values.readinessProbe.successThreshold }} - httpGet: - path: {{ .Values.readinessProbe.httpGet.path }} - port: {{ .Values.readinessProbe.httpGet.port }} - scheme: {{ .Values.readinessProbe.httpGet.scheme }} - {{- end }} - {{- end }} - volumes: - - name: jwtsecret - secret: - secretName: {{ include "common.names.fullname" . }} - - name: config - emptyDir: {} - {{- if eq .Values.global.network "gnosis" }} - - name: gnosis-config - configMap: - name: {{ include "common.names.fullname" . }}-gnosis - {{- end }} - {{- if or (eq .Values.global.network "prater") (eq .Values.global.network "ropsten") (eq .Values.global.network "sepolia") }} - - name: scripts - configMap: - name: {{ include "common.names.fullname" . }} - {{- end }} -{{- if (not .Values.persistence.enabled) }} - - name: data - emptyDir: {} -{{- else }} - volumeClaimTemplates: - - metadata: - name: data - labels: - {{- include "common.labels.statefulset" . | nindent 10 }} - {{- with .Values.persistence.annotations }} - annotations: - {{ toYaml . | nindent 10 | trim }} - {{- end }} - spec: - accessModes: {{ .Values.persistence.accessModes }} - storageClassName: {{ .Values.persistence.storageClassName }} - resources: - requests: - storage: {{ .Values.persistence.size | quote }} -{{- end }} diff --git a/charts/prysm/templates/tests/test-connection.yaml b/charts/prysm/templates/tests/test-connection.yaml deleted file mode 100644 index d3b320e37..000000000 --- a/charts/prysm/templates/tests/test-connection.yaml +++ /dev/null @@ -1,15 +0,0 @@ -apiVersion: v1 -kind: Pod -metadata: - name: "{{ include "common.names.fullname" . }}-test-connection" - labels: - {{- include "common.labels.standard" . | nindent 4 }} - annotations: - "helm.sh/hook": test -spec: - containers: - - name: wget - image: busybox - command: ['wget'] - args: ['{{ include "common.names.fullname" . }}:{{ .Values.rpc.port }}'] - restartPolicy: Never diff --git a/charts/prysm/templates/validate.yaml b/charts/prysm/templates/validate.yaml deleted file mode 100644 index 75d40a4fd..000000000 --- a/charts/prysm/templates/validate.yaml +++ /dev/null @@ -1,8 +0,0 @@ -{{- if not .Values.global.JWTSecret }} -{{- fail ".Values.global.JWTSecret is required" }} -{{- end }} - -{{- $endpoints := uniq .Values.global.executionEndpoints -}} -{{- if lt (len $endpoints) (len .Values.global.executionEndpoints)}} -{{- fail ".Values.global.executionClients must only contain unique values, since each consensus client must be connected to a unique execution client." }} -{{- end }} diff --git a/charts/prysm/values.yaml b/charts/prysm/values.yaml deleted file mode 100644 index 8fbfbe05c..000000000 --- a/charts/prysm/values.yaml +++ /dev/null @@ -1,397 +0,0 @@ -# Default values for prysm. -# This is a YAML-formatted file. -# Declare variables to be passed into your templates. - -global: - ## Eth2 network ID - ## - network: mainnet - - ## JSON Web Token (JWT) authentication is used to secure the communication - ## between the beacon node and execution client. You can generate a JWT using - ## a command line tool, for example: - ## openssl rand -hex 32 > token.txt - ## - JWTSecret: "" - - ## Server endpoints for an execution layer jwt authenticated HTTP JSON-RPC connection. - ## Uses the same endpoint to populate the deposit cache. - ## A separate Statefulset will be created for each specified address - ## - ## !!!!! WARNING !!!!! - ## NEVER CHANGE THE ORDER OF ENDPOINTS AS THIS MAY BREAK - ## THE CONSENSUS AND EXECTION CLIENTS CONNECTIVITY - executionEndpoints: [] - - ## Credentials to fetch images from private registry - ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/ - ## - imagePullSecrets: [] - - ## Service account - ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ - ## Additional settings could be made in non-global section. - ## - serviceAccount: - # Specifies whether a service account should be created - create: true - - ## RBAC configuration. - ## ref: https://kubernetes.io/docs/reference/access-authn-authz/rbac/ - ## Additional settings could be made in non-global section. - ## - rbac: - ## Specifies whether RBAC resources are to be created - ## - create: true - - ## Monitoring - ## Additional settings could be made in non-global section. - ## - metrics: - ## Whether to enable metrics collection or not - ## - enabled: true - - ## Prometheus Service Monitor - ## ref: https://github.com/coreos/prometheus-operator - ## https://github.com/coreos/prometheus-operator/blob/master/Documentation/api.md#endpoint - ## - serviceMonitor: - ## Create ServiceMonitor resource(s) for scraping metrics using PrometheusOperator - ## - enabled: false - - ## Custom PrometheusRule to be defined - ## ref: https://github.com/coreos/prometheus-operator#customresourcedefinitions - ## - prometheusRule: - ## Create a custom prometheusRule Resource for scraping metrics using PrometheusOperator - ## - enabled: false - - ## Configure liveness and readiness probes - ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/ - ## NB! readinessProbe and livenessProbe must be disabled before fully synced - ## Additional settings could be made in non-global section. - ## - livenessProbe: - enabled: true - - readinessProbe: - enabled: true - -## Provide a name in place of prysm for `app:` labels -## -nameOverride: "" - -## Provide a name to substitute for the full names of resources -## -fullnameOverride: "" - -## Service account -## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ -## -serviceAccount: - # Annotations to add to the service account - annotations: {} - # The name of the service account to use. - # If not set and create is true, a name is generated using the fullname template - name: "" - -## Additional labels for all resources -## -additionalLabels: - client-type: "consensus" - -## Pod Security Context -## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/ -## -securityContext: - fsGroup: 1001 - runAsUser: 1001 - -## RBAC configuration. -## ref: https://kubernetes.io/docs/reference/access-authn-authz/rbac/ -## -rbac: - # The name of the cluster role to use. - # If not set and create is true, a name is generated using the fullname template - name: "" - ## Required ClusterRole rules - ## - clusterRules: - ## Required to obtain the nodes external IP - ## - - apiGroups: [""] - resources: - - "nodes" - verbs: - - "get" - - "list" - - "watch" - ## Required Role rules - ## - rules: - ## Required to get information about the serices nodePort. - ## - - apiGroups: [""] - resources: - - "services" - verbs: - - "get" - - "list" - - "watch" - -## Init image is used to chown data volume, initialise genesis, etc. -## -initImage: - repository: "bitnami/kubectl" - tag: "1.24" - pullPolicy: IfNotPresent - -## Sidecar image is used to perform Liveness/Readiness probes. -## -sidecar: - repository: "europe-west4-docker.pkg.dev/stakewiselabs/public/ethnode-sidecar" - tag: "v1.0.5" - pullPolicy: IfNotPresent - bindAddr: "0.0.0.0" - bindPort: 3000 - -## Configuration for prysm eth v2 beacon chain node -## ref: https://docs.prylabs.network/docs/getting-started/ -## - -## Prysm beacon node image version -## ref: https://gcr.io/prysmaticlabs/prysm/beacon-chain -## -image: - repository: "gcr.io/prysmaticlabs/prysm/beacon-chain" - tag: "v3.1.0" - pullPolicy: IfNotPresent -imageGnosis: - repository: "ghcr.io/gnosischain/gbc-prysm-beacon-chain" - tag: "v2.1.2-gbc" - pullPolicy: IfNotPresent - -## Credentials to fetch images from private registry -## ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/ -## -imagePullSecrets: [] - -## When p2pNodePort is enabled, your P2P port will be exposed via service type NodePort/LoadBalancer. -## This will generate a service for each replica, with a port binding via NodePort/LoadBalancer. -## This is useful if you want to expose and announce your node to the Internet. -## -p2pNodePort: - ## @param p2pNodePort.enabled Expose P2P port via NodePort - ## - enabled: false - ## @param p2pNodePort.annotations - ## - annotations: {} - ## @param p2pNodePort.type - ## Options: NodePort, LoadBalancer - type: NodePort - ## @param p2pNodePort.startAt The ports allocation will start from this value - ## - startAt: 31400 - ## @param p2pNodePort.replicaToNodePort Overwrite a port for specific replicas - ## @default -- See `values.yaml` for example - replicaToNodePort: {} - # "0": 32345 - # "3": 32348 - -## Settings for gRPC (beacon client api) -## -rpc: - # Port number for beacon client rpc connection - port: "4000" - # Host on which the RPC server should listen - host: "0.0.0.0" - # Port name for the respective k8s service - portName: "rpc" - -## HTTP Port -## -http: - enabled: true - port: "8080" - -## Ethereum 1 node endpoints. -## -eth1Endpoints: [] - -## MEV Boost endpoint -## -httpMevRelay: "" - -## Post bellatrix, this address will receive the transaction fees produced -## by any blocks from this node. Default to junk whilst bellatrix is in development state. -## Validator client can override this value through the preparebeaconproposer api. -## -suggestedFeeRecipient: "" - -## Sets the total difficulty to manual overrides the default -## TERMINAL_TOTAL_DIFFICULTY value. WARNING: This flag should be used only if you -## have a clear understanding that community has decided to override the terminal difficulty. -## Incorrect usage will result in your node experience consensus failure. -totalDifficultyOverride: "" - -## Extra flags for prysm beacon chain node -## -extraFlags: - # p2p options - - "--p2p-max-peers=160" - - "--enable-peer-scorer" - -## Node labels for pod assignment -## ref: https://kubernetes.io/docs/user-guide/node-selection/ -## -nodeSelector: {} - -## Tolerations for pod assignment -## ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/ -## -tolerations: {} - -## Affinity for pod assignment -## ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity -## -## Example: -## affinity: -## podAntiAffinity: -## requiredDuringSchedulingIgnoredDuringExecution: -## - labelSelector: -## matchExpressions: -## - key: app.kubernetes.io/name -## operator: In -## values: -## - prysm -## topologyKey: kubernetes.io/hostname -## -affinity: {} - -## Used to assign priority to pods -## ref: https://kubernetes.io/docs/concepts/configuration/pod-priority-preemption/ -## -priorityClassName: "" - -## Enable pod disruption budget -## ref: https://kubernetes.io/docs/tasks/run-application/configure-pdb -## -podDisruptionBudget: - enabled: true - maxUnavailable: 1 - -## Monitoring -## -metrics: - ## Prometheus exporter port - ## - port: 9090 - - ## Prometheus Service Monitor - ## ref: https://github.com/coreos/prometheus-operator - ## https://github.com/coreos/prometheus-operator/blob/master/Documentation/api.md#endpoint - ## - serviceMonitor: - ## The namespace in which the ServiceMonitor will be created - ## - namespace: "" - ## The interval at which metrics should be scraped - ## - interval: 30s - ## The timeout after which the scrape is ended - ## - scrapeTimeout: "" - ## Metrics RelabelConfigs to apply to samples before scraping. - ## - relabellings: [] - ## Metrics RelabelConfigs to apply to samples before ingestion. - ## - metricRelabelings: [] - ## Specify honorLabels parameter to add the scrape endpoint - ## - honorLabels: false - ## Additional labels that can be used so ServiceMonitor resource(s) can be discovered by Prometheus - ## - additionalLabels: {} - ## Custom PrometheusRule to be defined - ## ref: https://github.com/coreos/prometheus-operator#customresourcedefinitions - ## - prometheusRule: - ## Create a default set of Alerts - ## - default: true - ## The namespace in which the prometheusRule will be created - ## - namespace: "" - ## Additional labels for the prometheusRule - ## - additionalLabels: {} - ## Custom Prometheus rules - ## - rules: [] - -## Defines whether the service must be headless -## -svcHeadless: true - -## Configure session affinity for validator clients to hit the same beacon node -## for the period specified in `timeoutSeconds` -## ref: https://kubernetes.io/docs/concepts/services-networking/service/#proxy-mode-userspace -## -sessionAffinity: - # Whether to enable session affinity or not - enabled: false - # The session duration in seconds - timeoutSeconds: 86400 - -## Configure resource requests and limits. -## ref: http://kubernetes.io/docs/user-guide/compute-resources/ -## -resources: {} - -## Configure liveness and readiness probes -## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/ -## NB! readinessProbe and livenessProbe must be disabled before genesis -## -livenessProbe: - initialDelaySeconds: 900 - timeoutSeconds: 3 - periodSeconds: 30 - failureThreshold: 3 - successThreshold: 1 - httpGet: - path: /eth2/liveness - port: sidecar - scheme: HTTP - -readinessProbe: - initialDelaySeconds: 300 - timeoutSeconds: 3 - periodSeconds: 30 - failureThreshold: 30 - successThreshold: 2 - httpGet: - path: /eth2/readiness - port: sidecar - scheme: HTTP - -## If false, data ownership will not be reset at startup -## This allows the geth node to be run with an arbitrary user -## -initChownData: true - -## Whether or not to allocate persistent volume disk for the data directory. -## In case of pod failure, the pod data directory will still persist. -## -persistence: - enabled: true - storageClassName: "" - accessModes: - - ReadWriteOnce - size: 300Gi - annotations: {} diff --git a/charts/ssv-node/.helmignore b/charts/ssv-node/.helmignore deleted file mode 100644 index 0e8a0eb36..000000000 --- a/charts/ssv-node/.helmignore +++ /dev/null @@ -1,23 +0,0 @@ -# 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/ diff --git a/charts/ssv-node/Chart.lock b/charts/ssv-node/Chart.lock deleted file mode 100644 index 3e76d73a9..000000000 --- a/charts/ssv-node/Chart.lock +++ /dev/null @@ -1,6 +0,0 @@ -dependencies: -- name: common - repository: file://../common - version: 1.0.0 -digest: sha256:07cebde439abe4ba19bb28e844b7419dab83c7f613886416aaf3ec08e8059144 -generated: "2022-03-07T13:22:32.595848755+03:00" diff --git a/charts/ssv-node/templates/configmap.yaml b/charts/ssv-node/templates/configmap.yaml deleted file mode 100644 index 21c6a188c..000000000 --- a/charts/ssv-node/templates/configmap.yaml +++ /dev/null @@ -1,20 +0,0 @@ -apiVersion: v1 -kind: ConfigMap -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -data: - config.yaml: | - global: - LogLevel: "error" - LogFormat: "json" - db: - Path: {{ .Values.dbPath }} - eth2: - Network: {{ .Values.network }} - BeaconNodeAddr: {{ .Values.beaconNodeAddr }} - eth1: - ETH1Addr: {{ .Values.eth1Addr }} - RegistryContractAddr: {{ .Values.registryContractAddr }} - OperatorPrivateKey: {{ .Values.operatorPrivateKey }} \ No newline at end of file diff --git a/charts/ssv-node/templates/service.yaml b/charts/ssv-node/templates/service.yaml deleted file mode 100644 index 12ace443d..000000000 --- a/charts/ssv-node/templates/service.yaml +++ /dev/null @@ -1,31 +0,0 @@ -apiVersion: v1 -kind: Service -metadata: - name: {{ include "common.names.fullname" . }}-tcp - labels: - {{- include "common.labels.standard" . | nindent 4 }} -spec: - type: {{ .Values.service.type }} - ports: - - port: 13000 - targetPort: discovery-tcp - protocol: TCP - name: discovery-tcp - selector: - {{- include "common.labels.matchLabels" . | nindent 4 }} ---- -apiVersion: v1 -kind: Service -metadata: - name: {{ include "common.names.fullname" . }}-udp - labels: - {{- include "common.labels.standard" . | nindent 4 }} -spec: - type: {{ .Values.service.type }} - ports: - - port: 12000 - targetPort: discovery-udp - protocol: UDP - name: discovery-udp - selector: - {{- include "common.labels.matchLabels" . | nindent 4 }} diff --git a/charts/ssv-node/templates/serviceaccount.yaml b/charts/ssv-node/templates/serviceaccount.yaml deleted file mode 100644 index ad5aa4d50..000000000 --- a/charts/ssv-node/templates/serviceaccount.yaml +++ /dev/null @@ -1,12 +0,0 @@ -{{- if .Values.serviceAccount.create -}} -apiVersion: v1 -kind: ServiceAccount -metadata: - name: {{ include "common.names.serviceAccountName" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} - {{- with .Values.serviceAccount.annotations }} - annotations: - {{- toYaml . | nindent 4 }} - {{- end }} -{{- end }} diff --git a/charts/ssv-node/templates/statefulset.yaml b/charts/ssv-node/templates/statefulset.yaml deleted file mode 100644 index 4787b82db..000000000 --- a/charts/ssv-node/templates/statefulset.yaml +++ /dev/null @@ -1,98 +0,0 @@ -kind: StatefulSet -apiVersion: {{ include "common.capabilities.statefulset.apiVersion" . }} -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -spec: - selector: - matchLabels: - {{- include "common.labels.matchLabels" . | nindent 6 }} - serviceName: {{ include "common.names.fullname" . }} - replicas: {{ .Values.replicaCount }} - template: - metadata: - labels: - {{- include "common.labels.matchLabels" . | nindent 8 }} - spec: - {{- with .Values.affinity }} - affinity: - {{ toYaml . | nindent 8 | trim }} - {{- end }} - {{- with .Values.tolerations }} - tolerations: - {{ toYaml . | nindent 8 | trim }} - {{- end }} - {{- with .Values.nodeSelector }} - nodeSelector: - {{ toYaml . | nindent 8 | trim }} - {{- end }} - {{- with .Values.securityContext }} - securityContext: - {{ toYaml . | nindent 8 | trim }} - {{- end }} - serviceAccountName: {{ include "common.names.serviceAccountName" . }} - priorityClassName: {{ .Values.priorityClassName | quote }} - {{- if and .Values.persistence.enabled .Values.initChownData }} - initContainers: - - name: init-chown - image: "{{ .Values.initImage.repository }}:{{ .Values.initImage.tag }}" - imagePullPolicy: {{ .Values.initImage.pullPolicy }} - securityContext: - runAsUser: 0 - command: ["chown", "-R", "{{ .Values.securityContext.runAsUser }}:{{ .Values.securityContext.runAsUser }}", "/data"] - volumeMounts: - - name: data - mountPath: /data - {{- end }} - containers: - - name: node - image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}" - imagePullPolicy: {{ .Values.image.pullPolicy }} - command: ['make'] - args: ['start-node'] - env: - - name: CONFIG_PATH - value: /data/configs/config.yaml - - name: BUILD_PATH - value: /go/bin/ssvnode - ports: - - containerPort: 13000 - name: discovery-tcp - protocol: TCP - - containerPort: 12000 - name: discovery-udp - protocol: UDP - volumeMounts: - - name: data - mountPath: /data - - name: configs - mountPath: /data/configs - {{- with .Values.resources }} - resources: - {{ toYaml . | nindent 12 | trim }} - {{- end }} - volumes: - - name: configs - configMap: - name: {{ include "common.names.fullname" . }} - {{- if (not .Values.persistence.enabled) }} - - name: data - emptyDir: {} - {{- else }} - volumeClaimTemplates: - - metadata: - name: data - labels: - {{- include "common.labels.standard" . | nindent 10 }} - {{- with .Values.persistence.annotations }} - annotations: - {{ toYaml . | nindent 10 | trim }} - {{- end }} - spec: - accessModes: {{ .Values.persistence.accessModes }} - storageClassName: {{ .Values.persistence.storageClassName }} - resources: - requests: - storage: {{ .Values.persistence.size | quote }} - {{- end }} diff --git a/charts/ssv-node/values.yaml b/charts/ssv-node/values.yaml deleted file mode 100644 index bc7d75e88..000000000 --- a/charts/ssv-node/values.yaml +++ /dev/null @@ -1,98 +0,0 @@ -# Default values for ssv-node. -# This is a YAML-formatted file. -# Declare variables to be passed into your templates. - -replicaCount: 1 - -## Init image is used to chown data volume, initialise genesis, etc. -## -initImage: - repository: "busybox" - tag: "1.34" - pullPolicy: IfNotPresent - -image: - repository: bloxstaking/ssv-node - pullPolicy: IfNotPresent - # Overrides the image tag whose default is the chart appVersion. - tag: "v0.3.1" - -imagePullSecrets: [] -nameOverride: "" -fullnameOverride: "" - -dbPath: ./data/db/node_1 -network: prater -beaconNodeAddr: "" -eth1Addr: "" -registryContractAddr: 0x687fb596F3892904F879118e2113e1EEe8746C2E -operatorPrivateKey: "" - -serviceAccount: - # Specifies whether a service account should be created - create: true - # Annotations to add to the service account - annotations: {} - # The name of the service account to use. - # If not set and create is true, a name is generated using the fullname template - name: "" - -## Pod Security Context -## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/ -## -securityContext: - fsGroup: 1001 - runAsUser: 1001 - -service: - type: LoadBalancer - -## Vertical Pod Autoscaler config -## Ref: https://github.com/kubernetes/autoscaler/tree/master/vertical-pod-autoscaler -## -verticalAutoscaler: - # If true a VPA object will be created for the StatefulSet - enabled: false - updateMode: Off - containerPolicies: { } - -## Configure resource requests and limits. -## http://kubernetes.io/docs/user-guide/compute-resources/ -## -resources: { } - -## If false, data ownership will not be reset at startup -## This allows the ssv node node to be run with an arbitrary user -## -initChownData: true - -## Whether or not to allocate persistent volume disk for the data directory. -## In case of node failure, the node data directory will still persist. -## -persistence: - enabled: true - storageClassName: "" - accessModes: - - ReadWriteOnce - size: 5Gi - annotations: {} - -## Node labels for pod assignment -## ref: https://kubernetes.io/docs/user-guide/node-selection/ -## -nodeSelector: {} - -## Tolerations for pod assignment -## ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/ -## -tolerations: [] - -## Affinity for pod assignment -## ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity -## -affinity: {} - -## used to assign priority to pods -## ref: https://kubernetes.io/docs/concepts/configuration/pod-priority-preemption/ -## -priorityClassName: "" diff --git a/charts/teku/.helmignore b/charts/teku/.helmignore deleted file mode 100644 index 0e8a0eb36..000000000 --- a/charts/teku/.helmignore +++ /dev/null @@ -1,23 +0,0 @@ -# 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/ diff --git a/charts/teku/Chart.lock b/charts/teku/Chart.lock deleted file mode 100644 index 841897137..000000000 --- a/charts/teku/Chart.lock +++ /dev/null @@ -1,6 +0,0 @@ -dependencies: -- name: common - repository: file://../common - version: 1.0.0 -digest: sha256:07cebde439abe4ba19bb28e844b7419dab83c7f613886416aaf3ec08e8059144 -generated: "2022-03-07T13:51:53.662835433+03:00" diff --git a/charts/teku/Chart.yaml b/charts/teku/Chart.yaml deleted file mode 100644 index 3e1f722f8..000000000 --- a/charts/teku/Chart.yaml +++ /dev/null @@ -1,39 +0,0 @@ -apiVersion: v2 -name: teku -description: Teku is an open-source Ethereum 2.0 client written in Java. -icon: https://raw.githubusercontent.com/ethereum/ethereum-org/master/public/images/logos/ETHEREUM-ICON_Black.png -home: https://stakewise.io/ -sources: - - https://github.com/ConsenSys/teku - -# A chart can be either an 'application' or a 'library' chart. -# -# Application charts are a collection of templates that can be packaged into versioned archives -# to be deployed. -# -# Library charts provide useful utilities or functions for the chart developer. They're included as -# a dependency of application charts to inject those utilities and functions into the rendering -# pipeline. Library charts do not define any templates and therefore cannot be deployed. -type: application - -# This is the chart version. This version number should be incremented each time you make changes -# to the chart and its templates, including the app version. -# Versions are expected to follow Semantic Versioning (https://semver.org/) -version: 2.2.5 - -# This is the version number of the application being deployed. This version number should be -# incremented each time you make changes to the application. Versions are not expected to -# follow Semantic Versioning. They should reflect the version the application is using. -# It is recommended to use it with quotes. -appVersion: "22.10.1" - -keywords: - - ethereum - - blockchain - - teku - - p2p - -dependencies: -- name: common - repository: file://../common - version: 1.0.0 diff --git a/charts/teku/templates/_helpers.yaml b/charts/teku/templates/_helpers.yaml deleted file mode 100644 index a84dc1d62..000000000 --- a/charts/teku/templates/_helpers.yaml +++ /dev/null @@ -1,3 +0,0 @@ -{{- define "teku.p2pPort" -}} -{{- printf "9000" -}} -{{- end -}} diff --git a/charts/teku/templates/clusterrole.yaml b/charts/teku/templates/clusterrole.yaml deleted file mode 100644 index 6d7136bd1..000000000 --- a/charts/teku/templates/clusterrole.yaml +++ /dev/null @@ -1,10 +0,0 @@ -{{- if or .Values.global.rbac.create .Values.rbac.create }} -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRole -metadata: - name: {{ include "common.names.clusterRoleName" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -rules: -{{- toYaml .Values.rbac.clusterRules | nindent 0 }} -{{- end }} diff --git a/charts/teku/templates/clusterrolebinding.yaml b/charts/teku/templates/clusterrolebinding.yaml deleted file mode 100644 index 87d636dac..000000000 --- a/charts/teku/templates/clusterrolebinding.yaml +++ /dev/null @@ -1,16 +0,0 @@ -{{- if or .Values.global.rbac.create .Values.rbac.create }} -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: {{ include "common.names.clusterRoleName" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: {{ include "common.names.clusterRoleName" . }} -subjects: - - kind: ServiceAccount - name: {{ include "common.names.serviceAccountName" . }} - namespace: {{ .Release.Namespace }} -{{- end }} diff --git a/charts/teku/templates/configmap.yaml b/charts/teku/templates/configmap.yaml deleted file mode 100644 index 902ba14b7..000000000 --- a/charts/teku/templates/configmap.yaml +++ /dev/null @@ -1,11 +0,0 @@ -apiVersion: v1 -kind: ConfigMap -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -data: - execution-endpoints.txt: |- -{{- range $i, $e := .Values.global.executionEndpoints }} - {{ . }} -{{- end }} diff --git a/charts/teku/templates/pdb.yaml b/charts/teku/templates/pdb.yaml deleted file mode 100644 index 4ef63f0ff..000000000 --- a/charts/teku/templates/pdb.yaml +++ /dev/null @@ -1,18 +0,0 @@ -{{- if .Values.podDisruptionBudget.enabled }} -apiVersion: {{ include "common.capabilities.policy.apiVersion" . }} -kind: PodDisruptionBudget -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -spec: -{{- if .Values.podDisruptionBudget.minAvailable }} - minAvailable: {{ .Values.podDisruptionBudget.minAvailable }} -{{- end }} -{{- if .Values.podDisruptionBudget.maxUnavailable }} - maxUnavailable: {{ .Values.podDisruptionBudget.maxUnavailable }} -{{- end }} - selector: - matchLabels: - {{- include "common.labels.matchLabels" . | nindent 6 }} -{{- end }} diff --git a/charts/teku/templates/prometheusrules.yaml b/charts/teku/templates/prometheusrules.yaml deleted file mode 100644 index 9277046e0..000000000 --- a/charts/teku/templates/prometheusrules.yaml +++ /dev/null @@ -1,43 +0,0 @@ -{{- if and (or .Values.global.metrics.enabled .Values.metrics.enabled) - (or .Values.global.metrics.prometheusRule.enabled .Values.metrics.prometheusRule.enabled) }} -apiVersion: monitoring.coreos.com/v1 -kind: PrometheusRule -metadata: - name: {{ include "common.names.fullname" . }} - {{- if .Values.metrics.prometheusRule.namespace }} - namespace: {{ .Values.metrics.prometheusRule.namespace }} - {{- else }} - namespace: {{ .Release.Namespace | quote }} - {{- end }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.metrics.prometheusRule.additionalLabels }} - {{- toYaml .Values.metrics.prometheusRule.additionalLabels | nindent 4 }} - {{- end }} -spec: - groups: - {{- with .Values.metrics.prometheusRule.rules }} - - name: {{ include "common.names.fullname" $ }} - rules: {{- tpl (toYaml .) $ | nindent 8 }} - {{- end }} - {{- if .Values.metrics.prometheusRule.default }} - - name: {{ include "common.names.fullname" $ }}-default - rules: - - alert: TekuBeaconNodeDown - expr: up{job='{{ include "common.names.fullname" . }}'} == 0 - for: 1m - labels: - severity: critical - annotations: - summary: Teku beacon node is down - description: Check {{ printf "{{ $labels.pod }}" }} beacon node in namespace {{ printf "{{ $labels.namespace }}" }} - - alert: Teku50SlotsBehind - expr: beacon_slot{job='{{ include "common.names.fullname" . }}'}-beacon_head_slot{job='{{ include "common.names.fullname" . }}'} > 50 - for: 2m - labels: - severity: critical - annotations: - summary: Teku beacon node is out of sync - description: Check {{ printf "{{ $labels.pod }}" }} beacon node in namespace {{ printf "{{ $labels.namespace }}" }} - {{- end }} -{{- end }} diff --git a/charts/teku/templates/role.yaml b/charts/teku/templates/role.yaml deleted file mode 100644 index dfbc0fe48..000000000 --- a/charts/teku/templates/role.yaml +++ /dev/null @@ -1,10 +0,0 @@ -{{- if or .Values.global.rbac.create .Values.rbac.create -}} -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -rules: -{{- toYaml .Values.rbac.rules | nindent 0 }} -{{- end }} diff --git a/charts/teku/templates/rolebinding.yaml b/charts/teku/templates/rolebinding.yaml deleted file mode 100644 index 1fdb617ba..000000000 --- a/charts/teku/templates/rolebinding.yaml +++ /dev/null @@ -1,15 +0,0 @@ -{{- if or .Values.global.rbac.create .Values.rbac.create }} -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: {{ include "common.names.serviceAccountName" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: {{ include "common.names.serviceAccountName" . }} -subjects: - - kind: ServiceAccount - name: {{ include "common.names.serviceAccountName" . }} -{{- end }} diff --git a/charts/teku/templates/secret.yaml b/charts/teku/templates/secret.yaml deleted file mode 100644 index 5a3f66bb5..000000000 --- a/charts/teku/templates/secret.yaml +++ /dev/null @@ -1,9 +0,0 @@ -apiVersion: v1 -kind: Secret -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -type: Opaque -data: - jwtsecret: {{ .Values.global.JWTSecret | b64enc | quote }} diff --git a/charts/teku/templates/service-p2p.yaml b/charts/teku/templates/service-p2p.yaml deleted file mode 100644 index 7a001afb2..000000000 --- a/charts/teku/templates/service-p2p.yaml +++ /dev/null @@ -1,42 +0,0 @@ -{{- if .Values.p2pNodePort.enabled -}} -{{- range $i, $e := until (len .Values.global.executionEndpoints) }} -{{- $port := add $.Values.p2pNodePort.startAt $i -}} -{{- if hasKey $.Values.p2pNodePort.replicaToNodePort ($i | toString) -}} - {{ $port = index $.Values.p2pNodePort.replicaToNodePort ($i | toString) }} -{{- end }} - ---- -apiVersion: v1 -kind: Service -metadata: - name: {{ include "common.names.fullname" $ }}-{{ $i }} - labels: - {{- include "common.labels.standard" $ | nindent 4 }} - pod: "{{ include "common.names.fullname" $ }}-{{ $i }}" - type: p2p - {{- with $.Values.p2pNodePort.annotations }} - annotations: - {{- toYaml . | nindent 4 }} - {{- end }} -spec: - type: {{ $.Values.p2pNodePort.type }} - externalTrafficPolicy: Local - ports: - - name: p2p-tcp - port: {{ include "teku.p2pPort" $ }} - protocol: TCP - targetPort: p2p-tcp - nodePort: {{ $port }} - {{- if eq $.Values.p2pNodePort.type "NodePort" }} - - name: p2p-udp - port: {{ include "teku.p2pPort" $ }} - protocol: UDP - targetPort: p2p-udp - nodePort: {{ $port }} - {{- end }} - selector: - {{- include "common.labels.matchLabels" $ | nindent 4 }} - statefulset.kubernetes.io/pod-name: "{{ include "common.names.fullname" $ }}-{{ $i }}" - -{{- end }} -{{- end }} diff --git a/charts/teku/templates/service.yaml b/charts/teku/templates/service.yaml deleted file mode 100644 index a4da7e203..000000000 --- a/charts/teku/templates/service.yaml +++ /dev/null @@ -1,35 +0,0 @@ -{{- if or .Values.restApi.enabled .Values.global.metrics.enabled }} ---- -apiVersion: v1 -kind: Service -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -spec: - type: {{ .Values.service.type }} -{{- if .Values.svcHeadless }} - clusterIP: None -{{- end }} -{{- if .Values.sessionAffinity.enabled }} - sessionAffinity: ClientIP - sessionAffinityConfig: - clientIP: - timeoutSeconds: {{ .Values.sessionAffinity.timeoutSeconds }} -{{- end }} - ports: - {{- if .Values.restApi.enabled }} - - port: {{ .Values.restApi.port }} - targetPort: {{ .Values.restApi.portName }} - protocol: TCP - name: {{ .Values.restApi.portName }} - {{- end }} - {{- if .Values.global.metrics.enabled }} - - port: {{ .Values.metrics.port }} - targetPort: metrics - protocol: TCP - name: metrics - {{- end }} - selector: - {{- include "common.labels.matchLabels" . | nindent 4 }} -{{- end }} diff --git a/charts/teku/templates/serviceaccount.yaml b/charts/teku/templates/serviceaccount.yaml deleted file mode 100644 index cb2edd11f..000000000 --- a/charts/teku/templates/serviceaccount.yaml +++ /dev/null @@ -1,12 +0,0 @@ -{{- if or .Values.global.serviceAccount.create .Values.serviceAccount.create -}} -apiVersion: v1 -kind: ServiceAccount -metadata: - name: {{ include "common.names.serviceAccountName" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} - {{- with .Values.serviceAccount.annotations }} - annotations: - {{- toYaml . | nindent 4 }} - {{- end }} -{{- end }} diff --git a/charts/teku/templates/servicemonitor.yaml b/charts/teku/templates/servicemonitor.yaml deleted file mode 100644 index 9ecffc6ca..000000000 --- a/charts/teku/templates/servicemonitor.yaml +++ /dev/null @@ -1,42 +0,0 @@ -{{- if and (or .Values.global.metrics.enabled .Values.metrics.enabled) - (or .Values.global.metrics.serviceMonitor.enabled .Values.metrics.serviceMonitor.enabled) }} -apiVersion: monitoring.coreos.com/v1 -kind: ServiceMonitor -metadata: - name: {{ template "common.names.fullname" . }} - {{- if .Values.metrics.serviceMonitor.namespace }} - namespace: {{ .Values.metrics.serviceMonitor.namespace }} - {{- else }} - namespace: {{ .Release.Namespace | quote }} - {{- end }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.metrics.serviceMonitor.additionalLabels }} - {{- toYaml .Values.metrics.serviceMonitor.additionalLabels | nindent 4 }} - {{- end }} -spec: - endpoints: - - port: metrics - path: /metrics - {{- if .Values.metrics.serviceMonitor.interval }} - interval: {{ .Values.metrics.serviceMonitor.interval }} - {{- end }} - {{- if .Values.metrics.serviceMonitor.scrapeTimeout }} - scrapeTimeout: {{ .Values.metrics.serviceMonitor.scrapeTimeout }} - {{- end }} - {{- if .Values.metrics.serviceMonitor.honorLabels }} - honorLabels: {{ .Values.metrics.serviceMonitor.honorLabels }} - {{- end }} - {{- if .Values.metrics.serviceMonitor.relabelings }} - relabelings: {{- toYaml .Values.metrics.serviceMonitor.relabelings | nindent 6 }} - {{- end }} - {{- if .Values.metrics.serviceMonitor.metricRelabelings }} - metricRelabelings: {{- toYaml .Values.metrics.serviceMonitor.metricRelabelings | nindent 6 }} - {{- end }} - namespaceSelector: - matchNames: - - {{ .Release.Namespace }} - selector: - matchLabels: - {{- include "common.labels.matchLabels" . | nindent 6 }} -{{- end }} diff --git a/charts/teku/templates/statefulset.yaml b/charts/teku/templates/statefulset.yaml deleted file mode 100644 index 0edf7c99a..000000000 --- a/charts/teku/templates/statefulset.yaml +++ /dev/null @@ -1,248 +0,0 @@ ---- -apiVersion: {{ include "common.capabilities.statefulset.apiVersion" . }} -kind: StatefulSet -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.statefulset" . | nindent 4 }} -spec: - replicas: {{ len .Values.global.executionEndpoints }} - podManagementPolicy: "Parallel" - selector: - matchLabels: - {{- include "common.labels.matchLabels" . | nindent 6 }} - serviceName: {{ include "common.names.fullname" . }} - template: - metadata: - labels: - {{- include "common.labels.matchLabels" . | nindent 8 }} - annotations: - checksum/configmap: {{ include (print $.Template.BasePath "/configmap.yaml") . | sha256sum }} - spec: - {{- with (concat .Values.imagePullSecrets .Values.global.imagePullSecrets) }} - imagePullSecrets: - {{- toYaml . | nindent 8 }} - {{- end }} - {{- with .Values.nodeSelector }} - nodeSelector: - {{- toYaml . | nindent 8 }} - {{- end }} - {{- with .Values.affinity }} - affinity: - {{- toYaml . | nindent 8 }} - {{- end }} - {{- with .Values.tolerations }} - tolerations: - {{- toYaml . | nindent 8 }} - {{- end }} - serviceAccountName: {{ include "common.names.serviceAccountName" . }} - priorityClassName: {{ .Values.priorityClassName | quote }} - securityContext: - {{- toYaml .Values.securityContext | nindent 8 }} - initContainers: - - name: init - image: "{{ .Values.initImage.repository }}:{{ .Values.initImage.tag }}" - imagePullPolicy: {{ .Values.initImage.pullPolicy }} - securityContext: - runAsNonRoot: false - runAsUser: 0 - env: - - name: POD_IP - valueFrom: - fieldRef: - fieldPath: status.podIP - - name: POD_NAME - valueFrom: - fieldRef: - fieldPath: metadata.name - - name: POD_NAMESPACE - valueFrom: - fieldRef: - fieldPath: metadata.namespace - - name: NODE_NAME - valueFrom: - fieldRef: - fieldPath: spec.nodeName - command: - - sh - - -c - - > - echo "Namespace: ${POD_NAMESPACE} Pod: ${POD_NAME}"; - {{- if .Values.p2pNodePort.enabled }} - {{- if eq .Values.p2pNodePort.type "LoadBalancer" }} - until [ -n "$(kubectl -n ${POD_NAMESPACE} get svc/${POD_NAME} -o jsonpath='{.status.loadBalancer.ingress[0].ip}')" ]; do echo "Waiting for load balancer gets an IP" && sleep 10; done; - export EXTERNAL_PORT=$(kubectl -n ${POD_NAMESPACE} get services -l "pod in (${POD_NAME}), type in (p2p)" -o jsonpath='{.items[0].spec.ports[0].nodePort}'); - export EXTERNAL_IP=$(kubectl -n ${POD_NAMESPACE} get svc/${POD_NAME} -o jsonpath='{.status.loadBalancer.ingress[0].ip}'); - {{- else }} - export EXTERNAL_PORT=$(kubectl get services -l "pod in (${POD_NAME}), type in (p2p)" -o jsonpath='{.items[0].spec.ports[0].nodePort}'); - export EXTERNAL_IP=$(kubectl get nodes "${NODE_NAME}" -o jsonpath='{.status.addresses[?(@.type=="ExternalIP")].address}'); - {{- end }} - echo "p2p-enabled: true" > /data/config.yaml; - echo 'p2p-port: {{ include "teku.p2pPort" . }}' >> /data/config.yaml; - echo "p2p-advertised-port: $EXTERNAL_PORT" >> /data/config.yaml; - echo "p2p-advertised-ip: $EXTERNAL_IP" >> /data/config.yaml; - {{- else }} - echo "p2p-enabled: true" > /data/config.yaml; - echo 'p2p-port: {{ include "teku.p2pPort" . }}' >> /data/config.yaml; - echo 'p2p-advertised-port: {{ include "teku.p2pPort" . }}' >> /data/config.yaml; - echo "p2p-advertised-ip: $POD_IP" >> /data/config.yaml; - {{- end }} - INDEX=$((${HOSTNAME##*-}+1)); - EE=$(sed "${INDEX}q;d" /configs/execution-endpoints.txt); - echo "ee-endpoint: ${EE}" >> /data/config.yaml; - echo "Pod will connect to the ${EE} endpoint"; - cat /data/config.yaml; - {{- if and .Values.persistence.enabled .Values.initChownData }} - chown -R {{ .Values.securityContext.runAsUser }}:{{ .Values.securityContext.runAsUser }} /data | true; - {{- end }} - volumeMounts: - - name: env-nodeport - mountPath: /env - - name: data - mountPath: /data - - name: configs - mountPath: /configs - containers: - - name: {{ .Chart.Name }} - image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}" - imagePullPolicy: {{ .Values.image.pullPolicy }} - command: - - sh - - -ac - - > - {{- if .Values.p2pNodePort.enabled }} - . /env/init-nodeport; - {{- end }} - exec /opt/teku/bin/teku - --network={{ .Values.global.network }} - --config-file=/data/teku/config.yaml - --data-beacon-path=/data/teku/beacon - --data-path=/data/teku - --data-storage-archive-frequency={{ .Values.dataStorageArchiveFrequency }} - --data-storage-mode={{ .Values.dataStorageMode }} - --data-storage-non-canonical-blocks-enabled={{ .Values.dataStorageNonCanonicalBlocksEnabled }} - --ee-jwt-secret-file=/secret/jwtsecret - {{- if .Values.builderEndpoint }} - --builder-endpoint={{ .Values.builderEndpoint }} - {{- end }} - {{- if .Values.restApi.enabled }} - --rest-api-enabled={{ .Values.restApi.enabled }} - --rest-api-host-allowlist={{ .Values.restApi.hostAllowList | join "," }} - --rest-api-interface={{ .Values.restApi.interface }} - --rest-api-port={{ .Values.restApi.port }} - --rest-api-cors-origins={{ .Values.restApi.corsOrigins | join "," }} - --rest-api-docs-enabled={{ .Values.restApi.docsEnabled }} - {{- end }} - {{- if .Values.global.metrics.enabled }} - --metrics-enabled={{ .Values.global.metrics.enabled }} - --metrics-categories={{ .Values.metrics.categories | join "," }} - --metrics-host-allowlist={{ .Values.metrics.hostAllowList | join "," }} - --metrics-interface={{ .Values.metrics.interface }} - --metrics-port={{ .Values.metrics.port }} - {{- end }} - {{- range .Values.extraFlags }} - {{ . | quote }} - {{- end }} - {{- if or .Values.restApi.enabled .Values.global.metrics.enabled }} - ports: - {{- if .Values.restApi.enabled }} - - name: {{ .Values.restApi.portName }} - containerPort: {{ .Values.restApi.port }} - protocol: TCP - {{- end }} - {{- if .Values.global.metrics.enabled }} - - name: metrics - containerPort: {{ .Values.metrics.port }} - protocol: TCP - {{- end }} - {{- if .Values.p2pNodePort.enabled }} - - name: p2p-tcp - containerPort: {{ include "teku.p2pPort" . }} - protocol: TCP - - name: p2p-udp - containerPort: {{ include "teku.p2pPort" . }} - protocol: UDP - {{- end }} - {{- end }} - env: - - name: POD_IP - valueFrom: - fieldRef: - fieldPath: status.podIP - volumeMounts: - - name: data - mountPath: /data/teku - - name: jwtsecret - mountPath: /secret - readOnly: true - - name: env-nodeport - mountPath: /env - resources: - {{- toYaml .Values.resources | nindent 12 }} - {{- if .Values.restApi.enabled }} - - name: sidecar - image: "{{ .Values.sidecar.repository }}:{{ .Values.sidecar.tag }}" - imagePullPolicy: {{ .Values.sidecar.pullPolicy }} - env: - - name: SERVER_BINDADDR - value: "{{ .Values.sidecar.bindAddr }}:{{ .Values.sidecar.bindPort }}" - - name: CLIENT_PORT - value: {{ .Values.restApi.port | quote }} - ports: - - containerPort: {{ .Values.sidecar.bindPort }} - name: sidecar - protocol: TCP - {{- if or .Values.global.livenessProbe.enabled .Values.livenessProbe.enabled }} - livenessProbe: - initialDelaySeconds: {{ .Values.livenessProbe.initialDelaySeconds }} - timeoutSeconds: {{ .Values.livenessProbe.timeoutSeconds }} - periodSeconds: {{ .Values.livenessProbe.periodSeconds }} - failureThreshold: {{ .Values.livenessProbe.failureThreshold }} - successThreshold: {{ .Values.livenessProbe.successThreshold }} - httpGet: - path: {{ .Values.livenessProbe.httpGet.path }} - port: {{ .Values.livenessProbe.httpGet.port }} - scheme: {{ .Values.livenessProbe.httpGet.scheme }} - {{- end }} - {{- if or .Values.global.readinessProbe.enabled .Values.readinessProbe.enabled }} - readinessProbe: - initialDelaySeconds: {{ .Values.readinessProbe.initialDelaySeconds }} - timeoutSeconds: {{ .Values.readinessProbe.timeoutSeconds }} - periodSeconds: {{ .Values.readinessProbe.periodSeconds }} - failureThreshold: {{ .Values.readinessProbe.failureThreshold }} - successThreshold: {{ .Values.readinessProbe.successThreshold }} - httpGet: - path: {{ .Values.readinessProbe.httpGet.path }} - port: {{ .Values.readinessProbe.httpGet.port }} - scheme: {{ .Values.readinessProbe.httpGet.scheme }} - {{- end }} - {{- end }} - volumes: - - name: jwtsecret - secret: - secretName: {{ include "common.names.fullname" . }} - - name: configs - configMap: - name: {{ include "common.names.fullname" . }} - - name: env-nodeport - emptyDir: {} - {{- if (not .Values.persistence.enabled) }} - - name: data - emptyDir: {} - {{- else }} - volumeClaimTemplates: - - metadata: - name: data - labels: - {{- include "common.labels.statefulset" . | nindent 10 }} - {{- with .Values.persistence.annotations }} - annotations: - {{ toYaml . | nindent 10 | trim }} - {{- end }} - spec: - accessModes: {{ .Values.persistence.accessModes }} - storageClassName: {{ .Values.persistence.storageClassName }} - resources: - requests: - storage: {{ .Values.persistence.size | quote }} - {{- end }} diff --git a/charts/teku/templates/tests/test-connection.yaml b/charts/teku/templates/tests/test-connection.yaml deleted file mode 100644 index 9a90c3fe5..000000000 --- a/charts/teku/templates/tests/test-connection.yaml +++ /dev/null @@ -1,17 +0,0 @@ -{{ if .Values.restApi.enabled }} -apiVersion: v1 -kind: Pod -metadata: - name: "{{ include "common.names.fullname" . }}-test-connection" - labels: - {{- include "common.labels.standard" . | nindent 4 }} - annotations: - "helm.sh/hook": test -spec: - containers: - - name: wget - image: busybox - command: ['wget'] - args: ['{{ include "common.names.fullname" . }}:{{ .Values.restApi.port }}'] - restartPolicy: Never -{{ end }} diff --git a/charts/teku/templates/validate.yaml b/charts/teku/templates/validate.yaml deleted file mode 100644 index 75d40a4fd..000000000 --- a/charts/teku/templates/validate.yaml +++ /dev/null @@ -1,8 +0,0 @@ -{{- if not .Values.global.JWTSecret }} -{{- fail ".Values.global.JWTSecret is required" }} -{{- end }} - -{{- $endpoints := uniq .Values.global.executionEndpoints -}} -{{- if lt (len $endpoints) (len .Values.global.executionEndpoints)}} -{{- fail ".Values.global.executionClients must only contain unique values, since each consensus client must be connected to a unique execution client." }} -{{- end }} diff --git a/charts/teku/values.yaml b/charts/teku/values.yaml deleted file mode 100644 index 2a4337c8f..000000000 --- a/charts/teku/values.yaml +++ /dev/null @@ -1,415 +0,0 @@ -# Default values for teku. -# This is a YAML-formatted file. -# Declare variables to be passed into your templates. - -global: - ## Eth2 network ID - ## - network: mainnet - - ## JSON Web Token (JWT) authentication is used to secure the communication - ## between the beacon node and execution client. You can generate a JWT using - ## a command line tool, for example: - ## openssl rand -hex 32 > token.txt - ## - JWTSecret: "" - - ## Server endpoints for an execution layer jwt authenticated HTTP JSON-RPC connection. - ## Uses the same endpoint to populate the deposit cache. - ## A separate Statefulset will be created for each specified address - ## - ## !!!!! WARNING !!!!! - ## NEVER CHANGE THE ORDER OF ENDPOINTS AS THIS MAY BREAK - ## THE CONSENSUS AND EXECTION CLIENTS CONNECTIVITY - executionEndpoints: [] - - ## Credentials to fetch images from private registry - ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/ - ## - imagePullSecrets: [] - - ## Service account - ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ - ## Additional settings could be made in non-global section. - ## - serviceAccount: - # Specifies whether a service account should be created - create: true - - ## RBAC configuration. - ## ref: https://kubernetes.io/docs/reference/access-authn-authz/rbac/ - ## Additional settings could be made in non-global section. - ## - rbac: - ## Specifies whether RBAC resources are to be created - ## - create: true - - ## Monitoring - ## Additional settings could be made in non-global section. - ## - metrics: - ## Whether to enable metrics collection or not - ## - enabled: true - - ## Prometheus Service Monitor - ## ref: https://github.com/coreos/prometheus-operator - ## https://github.com/coreos/prometheus-operator/blob/master/Documentation/api.md#endpoint - ## - serviceMonitor: - ## Create ServiceMonitor resource(s) for scraping metrics using PrometheusOperator - ## - enabled: false - - ## Custom PrometheusRule to be defined - ## ref: https://github.com/coreos/prometheus-operator#customresourcedefinitions - ## - prometheusRule: - ## Create a custom prometheusRule Resource for scraping metrics using PrometheusOperator - ## - enabled: false - - ## Configure liveness and readiness probes - ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/ - ## NB! readinessProbe and livenessProbe must be disabled before fully synced - ## Additional settings could be made in non-global section. - ## - livenessProbe: - enabled: true - - readinessProbe: - enabled: true - -## Init image is used to chown data volume, initialise genesis, etc. -## -initImage: - repository: "bitnami/kubectl" - tag: "1.24" - pullPolicy: IfNotPresent - -## Sidecar image is used to perform Liveness/Readiness probes. -## -sidecar: - repository: "europe-west4-docker.pkg.dev/stakewiselabs/public/ethnode-sidecar" - tag: "v1.0.5" - pullPolicy: IfNotPresent - bindAddr: "0.0.0.0" - bindPort: 3000 - -## Teku image -## -image: - repository: consensys/teku - pullPolicy: IfNotPresent - # Overrides the image tag whose default is the chart appVersion. - tag: "22.10.1" - -imagePullSecrets: [] -nameOverride: "" -fullnameOverride: "" - -serviceAccount: - # Annotations to add to the service account - annotations: {} - # The name of the service account to use. - # If not set and create is true, a name is generated using the fullname template - name: "" - -## Additional labels for all resources -## -additionalLabels: - client-type: "consensus" - -## Pod Security Context -## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/ -## -securityContext: - fsGroup: 1000 - runAsUser: 1000 - -## RBAC configuration. -## ref: https://kubernetes.io/docs/reference/access-authn-authz/rbac/ -## -rbac: - # The name of the cluster role to use. - # If not set and create is true, a name is generated using the fullname template - name: "" - ## Required ClusterRole rules - ## - clusterRules: - ## Required to obtain the nodes external IP - ## - - apiGroups: [""] - resources: - - "nodes" - verbs: - - "get" - - "list" - - "watch" - ## Required Role rules - ## - rules: - ## Required to get information about the serices nodePort. - ## - - apiGroups: [""] - resources: - - "services" - verbs: - - "get" - - "list" - - "watch" - -service: - type: ClusterIP - -## Defines whether the service must be headless -## -svcHeadless: true - -## Configure session affinity for validator clients to hit the same beacon node -## for the period specified in `timeoutSeconds` -## ref: https://kubernetes.io/docs/concepts/services-networking/service/#proxy-mode-userspace -## -sessionAffinity: - # Whether to enable session affinity or not - enabled: false - # The session duration in seconds - timeoutSeconds: 86400 - -## When p2pNodePort is enabled, your P2P port will be exposed via service type NodePort/LoadBalancer. -## This will generate a service for each replica, with a port binding via NodePort/LoadBalancer. -## This is useful if you want to expose and announce your node to the Internet. -## -p2pNodePort: - ## @param p2pNodePort.enabled Expose P2P port via NodePort - ## - enabled: false - ## @param p2pNodePort.annotations - ## - annotations: {} - ## @param p2pNodePort.type - ## Options: NodePort, LoadBalancer - type: NodePort - ## @param p2pNodePort.startAt The ports allocation will start from this value - ## - startAt: 31500 - ## @param p2pNodePort.replicaToNodePort Overwrite a port for specific replicas - ## @default -- See `values.yaml` for example - replicaToNodePort: {} - # "0": 32345 - # "3": 32348 - -resources: {} - # We usually recommend not to specify default resources and to leave this as a conscious - # choice for the user. This also increases chances charts run on environments with little - # resources, such as Minikube. If you do want to specify resources, uncomment the following - # lines, adjust them as necessary, and remove the curly braces after 'resources:'. - # limits: - # cpu: 100m - # memory: 128Mi - # requests: - # cpu: 100m - # memory: 128Mi - -## Used to assign priority to pods -## ref: https://kubernetes.io/docs/concepts/configuration/pod-priority-preemption/ -## -priorityClassName: "" - -## Enable pod disruption budget -## ref: https://kubernetes.io/docs/tasks/run-application/configure-pdb -## -podDisruptionBudget: - enabled: true - maxUnavailable: 1 - -## Node labels for pod assignment -## ref: https://kubernetes.io/docs/user-guide/node-selection/ -## -nodeSelector: {} - -## Tolerations for pod assignment -## ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/ -## -tolerations: {} - -## Affinity for pod assignment -## ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity -## -## Example: -## affinity: -## podAntiAffinity: -## requiredDuringSchedulingIgnoredDuringExecution: -## - labelSelector: -## matchExpressions: -## - key: app.kubernetes.io/name -## operator: In -## values: -## - teku -## topologyKey: kubernetes.io/hostname -## -affinity: {} - -## Configure liveness and readiness probes -## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/ -## NB! readinessProbe and livenessProbe must be disabled before genesis -## -livenessProbe: - initialDelaySeconds: 900 - timeoutSeconds: 3 - periodSeconds: 30 - failureThreshold: 3 - successThreshold: 1 - httpGet: - path: /eth2/liveness - port: sidecar - scheme: HTTP - -readinessProbe: - initialDelaySeconds: 300 - timeoutSeconds: 3 - periodSeconds: 30 - failureThreshold: 30 - successThreshold: 2 - httpGet: - path: /eth2/readiness - port: sidecar - scheme: HTTP - -## If false, data ownership will not be reset at startup -## This allows the node to be run with an arbitrary user -## -initChownData: true - -## Whether or not to allocate persistent volume disk for the data directory. -## In case of pod failure, the pod data directory will still persist. -## -persistence: - enabled: true - storageClassName: "" - accessModes: - - ReadWriteOnce - size: 300Gi - annotations: {} - - -## Teku is an open-source Ethereum 2.0 client written in Java. -## Teku contains a full Beacon node implementation and a validator -## client for participating in consensus. - -# URLs for Eth1 nodes -eth1Endpoints: [] - -# URL for Execution Engine node -eeEndpoint: "" - -# MEV-Boost Endpoint -builderEndpoint: "" - -## Extra flags for teku beacon chain node -## -extraFlags: [] - -# Sets the frequency, in slots, at which to store -# finalized states to disk. This option is ignored -# if --data-storage-mode is set to PRUNE -dataStorageArchiveFrequency: "2048" -# Sets the strategy for handling historical chain data -# (Valid values: ARCHIVE, PRUNE) -dataStorageMode: PRUNE -# Store non-canonical blocks -dataStorageNonCanonicalBlocksEnabled: false -# Rest API Settings -restApi: - # Enables Beacon Rest API - enabled: true - # Comma-separated list of hostnames to allow, or * - # to allow any host - hostAllowList: - - "*" - # Interface of Beacon Rest API - interface: "0.0.0.0" - # Port number of Beacon Rest API - port: "5051" - # Port name for the respective k8s service - portName: "rest-api" - # Comma separated list of origins to allow, or * to - # allow any origin - corsOrigins: - - "*" - # Enable swagger-docs and swagger-ui endpoints - docsEnabled: false - -## Monitoring -## -metrics: - # Metric categories to enable - categories: - - JVM - - PROCESS - - BEACON - - DISCOVERY - - EVENTBUS - - EXECUTOR - - NETWORK - - STORAGE - - STORAGE_HOT_DB - - STORAGE_FINALIZED_DB - - REMOTE_VALIDATOR - - VALIDATOR - - VALIDATOR_PERFORMANCE - - # List of hostnames to allow, or * to allow any host - hostAllowList: - - "*" - - # Metrics network interface to expose metrics for Prometheus - interface: "0.0.0.0" - - ## Metrics port to expose metrics for Prometheus - ## - port: 8008 - - ## Prometheus Service Monitor - ## ref: https://github.com/coreos/prometheus-operator - ## https://github.com/coreos/prometheus-operator/blob/master/Documentation/api.md#endpoint - ## - serviceMonitor: - ## The namespace in which the ServiceMonitor will be created - ## - namespace: "" - ## The interval at which metrics should be scraped - ## - interval: 30s - ## The timeout after which the scrape is ended - ## - scrapeTimeout: "" - ## Metrics RelabelConfigs to apply to samples before scraping. - ## - relabellings: [] - ## Metrics RelabelConfigs to apply to samples before ingestion. - ## - metricRelabelings: [] - ## Specify honorLabels parameter to add the scrape endpoint - ## - honorLabels: false - ## Additional labels that can be used so ServiceMonitor resource(s) can be discovered by Prometheus - ## - additionalLabels: {} - ## Custom PrometheusRule to be defined - ## ref: https://github.com/coreos/prometheus-operator#customresourcedefinitions - ## - prometheusRule: - ## Create a default set of Alerts - ## - default: true - ## The namespace in which the prometheusRule will be created - ## - namespace: "" - ## Additional labels for the prometheusRule - ## - additionalLabels: {} - ## Custom Prometheus rules - ## - rules: [] diff --git a/charts/graph-node/.helmignore b/charts/validator-ejector/.helmignore similarity index 100% rename from charts/graph-node/.helmignore rename to charts/validator-ejector/.helmignore diff --git a/charts/ipfs/Chart.lock b/charts/validator-ejector/Chart.lock similarity index 76% rename from charts/ipfs/Chart.lock rename to charts/validator-ejector/Chart.lock index b3bb3e787..bf2e36019 100644 --- a/charts/ipfs/Chart.lock +++ b/charts/validator-ejector/Chart.lock @@ -3,4 +3,4 @@ dependencies: repository: file://../common version: 1.0.0 digest: sha256:07cebde439abe4ba19bb28e844b7419dab83c7f613886416aaf3ec08e8059144 -generated: "2022-03-07T12:21:38.507972391+03:00" +generated: "2022-05-02T13:36:12.005448244+03:00" diff --git a/charts/validator-ejector/Chart.yaml b/charts/validator-ejector/Chart.yaml new file mode 100644 index 000000000..09ed578a7 --- /dev/null +++ b/charts/validator-ejector/Chart.yaml @@ -0,0 +1,19 @@ +apiVersion: v2 +name: validator-ejector +description: A Helm chart for installing and configuring Lido's validator-ejector +type: application +version: 1.0.0 +appVersion: "v0.0.1" + +keywords: + - ethereum + - lido + - validators + - exits + +home: https://nethermind.io/ + +dependencies: +- name: common + repository: file://../common + version: 1.0.0 diff --git a/charts/validator-ejector/templates/_helpers.tpl b/charts/validator-ejector/templates/_helpers.tpl new file mode 100644 index 000000000..0290a7598 --- /dev/null +++ b/charts/validator-ejector/templates/_helpers.tpl @@ -0,0 +1,62 @@ +{{/* +Expand the name of the chart. +*/}} +{{- define "ejector.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 "ejector.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 "ejector.chart" -}} +{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }} +{{- end }} + +{{/* +Common labels +*/}} +{{- define "ejector.labels" -}} +helm.sh/chart: {{ include "ejector.chart" . }} +{{ include "ejector.selectorLabels" . }} +{{- if .Chart.AppVersion }} +app.kubernetes.io/version: {{ .Chart.AppVersion | quote }} +{{- end }} +app.kubernetes.io/managed-by: {{ .Release.Service }} +{{- end }} + +{{/* +Selector labels +*/}} +{{- define "ejector.selectorLabels" -}} +app.kubernetes.io/name: {{ include "ejector.name" . }} +app.kubernetes.io/instance: {{ .Release.Name }} +{{- end }} + +{{/* +Create the name of the service account to use +*/}} +{{- define "ejector.serviceAccountName" -}} +{{- if .Values.serviceAccount.create }} +{{- default (include "ejector.fullname" .) .Values.serviceAccount.name }} +{{- else }} +{{- default "default" .Values.serviceAccount.name }} +{{- end }} +{{- end }} \ No newline at end of file diff --git a/charts/validator-ejector/templates/external-secret.yaml b/charts/validator-ejector/templates/external-secret.yaml new file mode 100644 index 000000000..8adf62f98 --- /dev/null +++ b/charts/validator-ejector/templates/external-secret.yaml @@ -0,0 +1,18 @@ +{{- if .Values.global.externalSecrets.enabled }} +apiVersion: external-secrets.io/v1beta1 +kind: ExternalSecret +metadata: + name: eso-{{ include "common.names.fullname" . }} + labels: + {{- include "common.labels.standard" . | nindent 4 }} +spec: + refreshInterval: 10m + secretStoreRef: + name: {{ .Values.global.externalSecrets.secretStoreRef.name }} + kind: {{ .Values.global.externalSecrets.secretStoreRef.kind }} + target: + name: eso-{{ include "common.names.fullname" . }} + creationPolicy: Owner + data: + {{- .Values.global.externalSecrets.data | toYaml | trim | nindent 2 }} +{{- end }} \ No newline at end of file diff --git a/charts/validator-ejector/templates/service.yaml b/charts/validator-ejector/templates/service.yaml new file mode 100644 index 000000000..e87b596b5 --- /dev/null +++ b/charts/validator-ejector/templates/service.yaml @@ -0,0 +1,15 @@ +apiVersion: v1 +kind: Service +metadata: + name: {{ include "ejector.fullname" . }} + labels: + {{- include "ejector.labels" . | nindent 4 }} +spec: + type: {{ .Values.service.type }} + ports: + - port: {{ .Values.ejector.httpPort }} + targetPort: metrics + protocol: TCP + name: metrics + selector: + {{- include "ejector.selectorLabels" . | nindent 4 }} diff --git a/charts/lighthouse/templates/serviceaccount.yaml b/charts/validator-ejector/templates/serviceaccount.yaml similarity index 100% rename from charts/lighthouse/templates/serviceaccount.yaml rename to charts/validator-ejector/templates/serviceaccount.yaml diff --git a/charts/validator-ejector/templates/servicemonitor.yaml b/charts/validator-ejector/templates/servicemonitor.yaml new file mode 100644 index 000000000..bd99c3387 --- /dev/null +++ b/charts/validator-ejector/templates/servicemonitor.yaml @@ -0,0 +1,41 @@ +{{- if .Values.serviceMonitor.enabled }} +apiVersion: monitoring.coreos.com/v1 +kind: ServiceMonitor +metadata: + name: {{ include "common.names.fullname" . }} + {{- if .Values.serviceMonitor.namespace }} + namespace: {{ .Values.serviceMonitor.namespace }} + {{- else }} + namespace: {{ .Release.Namespace | quote }} + {{- end }} + labels: + {{- include "common.labels.standard" . | nindent 4 }} + {{- if .Values.serviceMonitor.additionalLabels }} + {{- toYaml .Values.serviceMonitor.additionalLabels | nindent 4 }} + {{- end }} +spec: + endpoints: + - port: metrics + path: /metrics + {{- if .Values.serviceMonitor.interval }} + interval: {{ .Values.serviceMonitor.interval }} + {{- end }} + {{- if .Values.serviceMonitor.scrapeTimeout }} + scrapeTimeout: {{ .Values.serviceMonitor.scrapeTimeout }} + {{- end }} + {{- if .Values.serviceMonitor.honorLabels }} + honorLabels: {{ .Values.serviceMonitor.honorLabels }} + {{- end }} + {{- if .Values.serviceMonitor.relabelings }} + relabelings: {{- toYaml .Values.serviceMonitor.relabelings | nindent 6 }} + {{- end }} + {{- if .Values.serviceMonitor.metricRelabelings }} + metricRelabelings: {{- toYaml .Values.serviceMonitor.metricRelabelings | nindent 6 }} + {{- end }} + namespaceSelector: + matchNames: + - {{ .Release.Namespace }} + selector: + matchLabels: + {{- include "common.labels.matchLabels" . | nindent 6 }} +{{- end }} \ No newline at end of file diff --git a/charts/validator-ejector/templates/statefulset.yaml b/charts/validator-ejector/templates/statefulset.yaml new file mode 100644 index 000000000..e52428190 --- /dev/null +++ b/charts/validator-ejector/templates/statefulset.yaml @@ -0,0 +1,201 @@ +apiVersion: {{ include "common.capabilities.statefulset.apiVersion" . }} +kind: StatefulSet +metadata: + name: {{ include "common.names.fullname" . }} + labels: + {{- include "common.labels.standard" . | nindent 4 }} +spec: + replicas: {{ .Values.global.replicaCount }} + selector: + matchLabels: + {{- include "common.labels.matchLabels" . | nindent 6 }} + serviceName: {{ include "common.names.fullname" . }} + template: + metadata: + {{- with .Values.podAnnotations }} + annotations: + {{- toYaml . | nindent 8 }} + {{- end }} + labels: + {{- include "common.labels.matchLabels" . | nindent 8 }} + spec: + {{- with .Values.nodeSelector }} + nodeSelector: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with .Values.affinity }} + affinity: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with .Values.tolerations }} + tolerations: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with .Values.imagePullSecrets }} + imagePullSecrets: + {{- toYaml . | nindent 8 }} + {{- end }} + serviceAccountName: {{ include "ejector.serviceAccountName" . }} + securityContext: + {{- toYaml .Values.podSecurityContext | nindent 8 }} + containers: + - name: loader + image: "{{ .Values.global.loader.repository }}:{{ .Values.global.loader.tag }}" + imagePullPolicy: {{ .Values.global.loader.pullPolicy }} + securityContext: + runAsNonRoot: false + runAsUser: 0 + env: + - name: EIP2335_PASSWORD + valueFrom: + secretKeyRef: + name: eso-{{ include "common.names.fullname" . }} + key: MESSAGES_PASSWORD + - name: ENCRYPTION + value: {{ .Values.loader.ENCRYPTION | quote }} + - name: ENCRYPT_WITH_METADATA + value: {{ .Values.loader.ENCRYPT_WITH_METADATA | quote }} + - name: BEACON_ENDPOINT + value: {{ .Values.loader.BEACON_ENDPOINT | quote }} + - name: CUSTODIAN_WEB3SIGNER_MAPPER + value: {{ .Values.loader.CUSTODIAN_WEB3SIGNER_MAPPER | quote }} + - name: STORAGE_LOCATION + value: {{ .Values.loader.STORAGE_LOCATION | quote }} + - name: FETCH_INTERVAL + value: {{ .Values.loader.FETCH_INTERVAL | quote }} + - name: LOADER_MAPPER + value: {{ .Values.loader.LOADER_MAPPER | quote }} + - name: SIGNER_MAPPER + value: {{ .Values.loader.SIGNER_MAPPER | quote }} + - name: KEY_LOADER_TYPE + value: {{ .Values.loader.KEY_LOADER_TYPE | quote }} + - name: ENCRYPTION_TYPE + value: {{ .Values.loader.ENCRYPTION_TYPE | quote }} + - name: LidoKAPI_OPERATOR_ID + value: {{ .Values.loader.LidoKAPI_OPERATOR_ID | quote }} + - name: LidoKAPI_KEYS_PERCENT + value: {{ .Values.loader.LidoKAPI_KEYS_PERCENT | quote }} + volumeMounts: + - name: data-ejector + mountPath: /data +# - name: init-ejector +# image: "{{ .Values.global.initImage.repository }}:{{ .Values.global.initImage.tag }}" +# imagePullPolicy: {{ .Values.global.initImage.pullPolicy }} +# securityContext: +# runAsNonRoot: false +# runAsUser: 0 +# env: +# - name: POD_NAME +# valueFrom: +# fieldRef: +# fieldPath: metadata.name +# - name: POD_NAMESPACE +# valueFrom: +# fieldRef: +# fieldPath: metadata.namespace +# command: +# - sh +# - -c +# - > +# echo "Namespace: ${POD_NAMESPACE} Pod: ${POD_NAME}"; +# {{- if and .Values.persistence.enabled .Values.initChownData }} +# chown -R {{ .Values.global.securityContext.runAsUser }}:{{ .Values.global.securityContext.runAsUser }} /data | true; +# {{- end }} +# echo "Loading encrypted messages from eth-exit-messages" +# volumeMounts: +# - name: data-ejector +# mountPath: /data + - name: {{ .Chart.Name }} + securityContext: + {{- toYaml .Values.securityContext | nindent 12 }} + image: "{{ .Values.global.image.repository }}:{{ .Values.global.image.tag | default .Chart.AppVersion }}" + imagePullPolicy: {{ .Values.global.image.pullPolicy }} + env: + - name: EXECUTION_NODE + value: "{{ .Values.ejector.execution }}" + - name: CONSENSUS_NODE + value: "{{ .Values.ejector.consensus }}" + - name: LOCATOR_ADDRESS + value: "{{ .Values.ejector.locatorAddress }}" + - name: STAKING_MODULE_ID + value: "{{ .Values.ejector.stakingModuleId }}" + - name: OPERATOR_ID + value: "{{ .Values.ejector.operatorId }}" + - name: MESSAGES_LOCATION + value: "{{ .Values.ejector.messagesLocation }}" + - name: VALIDATOR_EXIT_WEBHOOK + value: "{{ .Values.ejector.validatorExitWebhook }}" + - name: BLOCKS_PRELOAD + value: "{{ .Values.ejector.blocksPreload }}" + - name: BLOCKS_LOOP + value: "{{ .Values.ejector.blocksLoop }}" + - name: JOB_INTERVAL + value: "{{ .Values.ejector.jobInterval }}" + - name: HTTP_PORT + value: "{{ .Values.ejector.httpPort }}" + - name: RUN_METRICS + value: "{{ .Values.ejector.runMetrics }}" + - name: RUN_HEALTH_CHECK + value: "{{ .Values.ejector.runHealthCheck }}" + - name: LOGGER_LEVEL + value: "{{ .Values.ejector.loggerLevel }}" + - name: LOGGER_FORMAT + value: "{{ .Values.ejector.loggerFormat }}" + - name: DRY_RUN + value: "{{ .Values.ejector.dryRun }}" + {{- if .Values.global.externalSecrets.enabled }} + envFrom: + - secretRef: + name: eso-{{ include "common.names.fullname" . }} + {{- end }} + {{- if .Values.ejector.runMetrics }} + ports: + - name: metrics + containerPort: {{ .Values.ejector.httpPort }} + protocol: TCP + {{- if .Values.ejector.runHealthCheckDISABLED }} + livenessProbe: + httpGet: + path: /metrics + port: metrics + initialDelaySeconds: 30 + timeoutSeconds: 3 + periodSeconds: 30 + failureThreshold: 3 + successThreshold: 1 + readinessProbe: + httpGet: + path: /metrics + port: metrics + initialDelaySeconds: 15 + timeoutSeconds: 3 + periodSeconds: 30 + failureThreshold: 3 + successThreshold: 1 + {{- end }} + {{- end }} + resources: + {{- toYaml .Values.resources | nindent 12 }} + volumeMounts: + - name: data-ejector + mountPath: /data + volumes: + {{- if (not .Values.persistence.enabled) }} + - name: data-ejector + emptyDir: {} + {{- end }} + volumeClaimTemplates: + - metadata: + name: data-ejector + labels: + {{- include "common.labels.statefulset" . | nindent 10 }} + {{- with .Values.persistence.annotations }} + annotations: + {{ toYaml . | nindent 10 | trim }} + {{- end }} + spec: + accessModes: {{ .Values.persistence.accessModes }} + storageClassName: {{ .Values.persistence.storageClassName }} + resources: + requests: + storage: {{ .Values.persistence.size | quote }} \ No newline at end of file diff --git a/charts/validator-ejector/values.yaml b/charts/validator-ejector/values.yaml new file mode 100644 index 000000000..e25966103 --- /dev/null +++ b/charts/validator-ejector/values.yaml @@ -0,0 +1,191 @@ +# Default values for web3signer. +# This is a YAML-formatted file. +# Declare variables to be passed into your templates. + +global: + serviceAccount: + create: true + + replicaCount: 1 + + externalSecrets: + enabled: false + secretStoreRef: secretStoreRef + data: + - secretKey: MESSAGES_PASSWORD + remoteRef: + key: validatorEjectorSecrets + property: message + - secretKey: LOGGER_SECRETS + remoteRef: + key: validatorEjectorSecrets + property: loggerSecrets + - secretKey: ORACLE_ADDRESSES_ALLOWLIST + remoteRef: + key: validatorEjectorSecrets + property: oracleAddressesAllowlist + + initImage: + repository: "bitnami/kubectl" + tag: "1.28" + pullPolicy: IfNotPresent + + image: + repository: lidofinance/validator-ejector + pullPolicy: IfNotPresent + tag: "1.2.0" + + loader: + repository: nethermindeth/eth-exit-messages + pullPolicy: IfNotPresent + tag: "v0.0.26" + +loader: + EIP2335_PASSWORD: "test" + ENCRYPTION: "EIP2335" + ENCRYPT_WITH_METADATA: "false" + BEACON_ENDPOINT: "http://192.168.11.104:5052" + CUSTODIAN_WEB3SIGNER_MAPPER: '{"custodian1/second": "http://192.168.11.104:9110"}' + STORAGE_LOCATION: "local/" + FETCH_INTERVAL: "60" + SIGNER_MAPPER: '{}' + LOADER_MAPPER: '{}' + KEY_LOADER_TYPE: "WEB3SIGNER" + ENCRYPTION_TYPE: "EIP2335" + LidoKAPI_OPERATOR_ID: "" + LidoKAPI_KEYS_PERCENT: "5" + +ejector: + ## Ethereum Consensus Node endpoint + consensus: "http://localhost:4000" + ## Ethereum Execution Node endpoint + execution: "http://localhost:8545" + ## Address of the Locator contract, can be found in the lido-dao repo + locatorAddress: "0x12cd349E19Ab2ADBE478Fc538A66C059Cf40CFeC" + ## Staking Module ID for which operator ID is set + stakingModuleId: "123" + ## Operator ID in the Node Operators registry, easiest to get from Operators UI + operatorId: "123" + ## Folder to load json exit message files from + messagesLocation: "messages" + ## POST validator info to an endpoint instead of sending out an exit message in order to initiate an exit. + ## Required if you are using webhook mode + validatorExitWebhook: "" + ## Amount of blocks to load events from on start. + ## Increase if daemon was not running for some time. Defaults to a day of blocks + blocksPreload: 7200 + ## Amount of blocks to load events from on every poll. Defaults to 1 epoch + blocksLoop: 32 + ## Time interval in milliseconds to run checks. Defaults to time of 1 epoch + jobInterval: 384000 + ## Port to serve metrics and health check on + httpPort: 2122 + ## Enable metrics endpoint + runMetrics: true + ## Enable health check endpoint + runHealthCheck: true + ## Severity level from which to start showing errors eg info will hide debug messages + loggerLevel: "info" + ## Simple or JSON log output: simple/json + loggerFormat: "simple" + ## Run the service without actually sending out exit messages + dryRun: false + +## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ +## +serviceAccount: + # Annotations to add to the service account + annotations: {} + # The name of the service account to use. + # If not set and create is true, a name is generated using the fullname template + name: "" + +podAnnotations: {} + +## Pod Security Context +## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/ +## +podSecurityContext: {} + +## Whether or not to allocate persistent volume disk for the data directory. +## In case of node failure, the node data directory will still persist. +## +persistence: + enabled: true + storageClassName: "" + accessModes: + - ReadWriteOnce + size: 5Gi + annotations: {} + +securityContext: {} + # capabilities: + # drop: + # - ALL + # readOnlyRootFilesystem: true + # runAsNonRoot: true + # runAsUser: 1000 + +service: + type: ClusterIP + port: 80 + +## Configure resource requests and limits. +## ref: http://kubernetes.io/docs/user-guide/compute-resources/ +## +resources: {} + # We usually recommend not to specify default resources and to leave this as a conscious + # choice for the user. This also increases chances charts run on environments with little + # resources, such as Minikube. If you do want to specify resources, uncomment the following + # lines, adjust them as necessary, and remove the curly braces after 'resources:'. + # limits: + # cpu: 100m + # memory: 128Mi + # requests: + # cpu: 100m + # memory: 128Mi + +## Node labels for pod assignment +## ref: https://kubernetes.io/docs/user-guide/node-selection/ +## +nodeSelector: {} + +## Tolerations for pod assignment +## ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/ +## +tolerations: {} + +## Affinity for pod assignment +## ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity +## +affinity: {} + +## Prometheus Service Monitor +## ref: https://github.com/coreos/prometheus-operator +## https://github.com/coreos/prometheus-operator/blob/master/Documentation/api.md#endpoint +## +serviceMonitor: + ## @param metrics.serviceMonitor.enabled Create ServiceMonitor resource(s) for scraping metrics using PrometheusOperator + ## + enabled: false + ## @param metrics.serviceMonitor.namespace The namespace in which the ServiceMonitor will be created + ## + namespace: "" + ## @param metrics.serviceMonitor.interval The interval at which metrics should be scraped + ## + interval: 30s + ## @param metrics.serviceMonitor.scrapeTimeout The timeout after which the scrape is ended + ## + scrapeTimeout: "" + ## @param metrics.serviceMonitor.relabellings Metrics RelabelConfigs to apply to samples before scraping. + ## + relabellings: [] + ## @param metrics.serviceMonitor.metricRelabelings Metrics RelabelConfigs to apply to samples before ingestion. + ## + metricRelabelings: [] + ## @param metrics.serviceMonitor.honorLabels Specify honorLabels parameter to add the scrape endpoint + ## + honorLabels: false + ## @param metrics.serviceMonitor.additionalLabels Additional labels that can be used so ServiceMonitor resource(s) can be discovered by Prometheus + ## + additionalLabels: {} diff --git a/charts/ipfs/.helmignore b/charts/validator-kapi/.helmignore similarity index 100% rename from charts/ipfs/.helmignore rename to charts/validator-kapi/.helmignore diff --git a/charts/validator-kapi/Chart.lock b/charts/validator-kapi/Chart.lock new file mode 100644 index 000000000..5d0847921 --- /dev/null +++ b/charts/validator-kapi/Chart.lock @@ -0,0 +1,9 @@ +dependencies: +- name: common + repository: file://../common + version: 1.0.0 +- name: postgresql + repository: https://charts.bitnami.com/bitnami/ + version: 12.2.6 +digest: sha256:10931c3310ac282e9608cc8d77176b6e16cf8ee299bba34b75d0d96d12145778 +generated: "2023-03-28T21:51:52.672669+02:00" diff --git a/charts/validator-kapi/Chart.yaml b/charts/validator-kapi/Chart.yaml new file mode 100644 index 000000000..c49f011ed --- /dev/null +++ b/charts/validator-kapi/Chart.yaml @@ -0,0 +1,23 @@ +apiVersion: v2 +name: validator-kapi +description: A Helm chart for installing and configuring Lido's validator-kapi +type: application +version: 1.0.0 +appVersion: "v0.0.1" + +keywords: + - ethereum + - lido + - validators + - exits + +home: https://nethermind.io/ + +dependencies: +- name: common + repository: file://../common + version: 1.0.0 +- name: postgresql + version: 13.2.23 + repository: https://charts.bitnami.com/bitnami/ + condition: postgresql.enabled diff --git a/charts/validator-kapi/templates/_helpers.tpl b/charts/validator-kapi/templates/_helpers.tpl new file mode 100644 index 000000000..88702ceb0 --- /dev/null +++ b/charts/validator-kapi/templates/_helpers.tpl @@ -0,0 +1,62 @@ +{{/* +Expand the name of the chart. +*/}} +{{- define "kapi.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 "kapi.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 "kapi.chart" -}} +{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }} +{{- end }} + +{{/* +Common labels +*/}} +{{- define "kapi.labels" -}} +helm.sh/chart: {{ include "kapi.chart" . }} +{{ include "kapi.selectorLabels" . }} +{{- if .Chart.AppVersion }} +app.kubernetes.io/version: {{ .Chart.AppVersion | quote }} +{{- end }} +app.kubernetes.io/managed-by: {{ .Release.Service }} +{{- end }} + +{{/* +Selector labels +*/}} +{{- define "kapi.selectorLabels" -}} +app.kubernetes.io/name: {{ include "kapi.name" . }} +app.kubernetes.io/instance: {{ .Release.Name }} +{{- end }} + +{{/* +Create the name of the service account to use +*/}} +{{- define "kapi.serviceAccountName" -}} +{{- if .Values.serviceAccount.create }} +{{- default (include "kapi.fullname" .) .Values.serviceAccount.name }} +{{- else }} +{{- default "default" .Values.serviceAccount.name }} +{{- end }} +{{- end }} diff --git a/charts/validator-kapi/templates/external-secret.yaml b/charts/validator-kapi/templates/external-secret.yaml new file mode 100644 index 000000000..8adf62f98 --- /dev/null +++ b/charts/validator-kapi/templates/external-secret.yaml @@ -0,0 +1,18 @@ +{{- if .Values.global.externalSecrets.enabled }} +apiVersion: external-secrets.io/v1beta1 +kind: ExternalSecret +metadata: + name: eso-{{ include "common.names.fullname" . }} + labels: + {{- include "common.labels.standard" . | nindent 4 }} +spec: + refreshInterval: 10m + secretStoreRef: + name: {{ .Values.global.externalSecrets.secretStoreRef.name }} + kind: {{ .Values.global.externalSecrets.secretStoreRef.kind }} + target: + name: eso-{{ include "common.names.fullname" . }} + creationPolicy: Owner + data: + {{- .Values.global.externalSecrets.data | toYaml | trim | nindent 2 }} +{{- end }} \ No newline at end of file diff --git a/charts/validator-kapi/templates/service.yaml b/charts/validator-kapi/templates/service.yaml new file mode 100644 index 000000000..20e08f080 --- /dev/null +++ b/charts/validator-kapi/templates/service.yaml @@ -0,0 +1,15 @@ +apiVersion: v1 +kind: Service +metadata: + name: {{ include "kapi.fullname" . }} + labels: + {{- include "kapi.labels" . | nindent 4 }} +spec: + type: {{ .Values.service.type }} + ports: + - port: {{ .Values.kapi.port }} + targetPort: api + protocol: TCP + name: api + selector: + {{- include "kapi.selectorLabels" . | nindent 4 }} diff --git a/charts/nethermind/templates/serviceaccount.yaml b/charts/validator-kapi/templates/serviceaccount.yaml similarity index 100% rename from charts/nethermind/templates/serviceaccount.yaml rename to charts/validator-kapi/templates/serviceaccount.yaml diff --git a/charts/validator-kapi/templates/servicemonitor.yaml b/charts/validator-kapi/templates/servicemonitor.yaml new file mode 100644 index 000000000..bd99c3387 --- /dev/null +++ b/charts/validator-kapi/templates/servicemonitor.yaml @@ -0,0 +1,41 @@ +{{- if .Values.serviceMonitor.enabled }} +apiVersion: monitoring.coreos.com/v1 +kind: ServiceMonitor +metadata: + name: {{ include "common.names.fullname" . }} + {{- if .Values.serviceMonitor.namespace }} + namespace: {{ .Values.serviceMonitor.namespace }} + {{- else }} + namespace: {{ .Release.Namespace | quote }} + {{- end }} + labels: + {{- include "common.labels.standard" . | nindent 4 }} + {{- if .Values.serviceMonitor.additionalLabels }} + {{- toYaml .Values.serviceMonitor.additionalLabels | nindent 4 }} + {{- end }} +spec: + endpoints: + - port: metrics + path: /metrics + {{- if .Values.serviceMonitor.interval }} + interval: {{ .Values.serviceMonitor.interval }} + {{- end }} + {{- if .Values.serviceMonitor.scrapeTimeout }} + scrapeTimeout: {{ .Values.serviceMonitor.scrapeTimeout }} + {{- end }} + {{- if .Values.serviceMonitor.honorLabels }} + honorLabels: {{ .Values.serviceMonitor.honorLabels }} + {{- end }} + {{- if .Values.serviceMonitor.relabelings }} + relabelings: {{- toYaml .Values.serviceMonitor.relabelings | nindent 6 }} + {{- end }} + {{- if .Values.serviceMonitor.metricRelabelings }} + metricRelabelings: {{- toYaml .Values.serviceMonitor.metricRelabelings | nindent 6 }} + {{- end }} + namespaceSelector: + matchNames: + - {{ .Release.Namespace }} + selector: + matchLabels: + {{- include "common.labels.matchLabels" . | nindent 6 }} +{{- end }} \ No newline at end of file diff --git a/charts/validator-kapi/templates/statefulset.yaml b/charts/validator-kapi/templates/statefulset.yaml new file mode 100644 index 000000000..c6ad0580a --- /dev/null +++ b/charts/validator-kapi/templates/statefulset.yaml @@ -0,0 +1,102 @@ +apiVersion: {{ include "common.capabilities.statefulset.apiVersion" . }} +kind: StatefulSet +metadata: + name: {{ include "common.names.fullname" . }} + labels: + {{- include "common.labels.standard" . | nindent 4 }} +spec: + replicas: {{ .Values.global.replicaCount }} + selector: + matchLabels: + {{- include "common.labels.matchLabels" . | nindent 6 }} + serviceName: {{ include "common.names.fullname" . }} + template: + metadata: + {{- with .Values.podAnnotations }} + annotations: + {{- toYaml . | nindent 8 }} + {{- end }} + labels: + {{- include "common.labels.matchLabels" . | nindent 8 }} + spec: + {{- with .Values.nodeSelector }} + nodeSelector: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with .Values.affinity }} + affinity: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with .Values.tolerations }} + tolerations: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with .Values.imagePullSecrets }} + imagePullSecrets: + {{- toYaml . | nindent 8 }} + {{- end }} + serviceAccountName: {{ include "kapi.serviceAccountName" . }} + securityContext: + {{- toYaml .Values.podSecurityContext | nindent 8 }} + containers: + - name: {{ .Chart.Name }} + securityContext: + {{- toYaml .Values.securityContext | nindent 12 }} + image: "{{ .Values.global.image.repository }}:{{ .Values.global.image.tag | default .Chart.AppVersion }}" + imagePullPolicy: {{ .Values.global.image.pullPolicy }} + env: + - name: NODE_ENV + value: "{{ .Values.kapi.env }}" + - name: PORT + value: "{{ .Values.kapi.port }}" + {{- with .Values.postgresql }} + - name: DB_NAME + value: "{{ .auth.database }}" + - name: DB_HOST + value: "{{ .hostname }}" + - name: DB_USER + value: "{{ .auth.username }}" + - name: DB_PASSWORD + value: "{{ .auth.postgresPassword }}" + - name: DB_PORT + value: "{{ .service.ports.postgresql }}" + {{- end }} + - name: CORS_WHITELIST_REGEXP + value: "{{ .Values.kapi.corsWhitelistRegexp }}" + - name: JOB_INTERVAL_REGISTRY + value: "{{ .Values.kapi.jobIntervalRegistry }}" + - name: JOB_INTERVAL_VALIDATORS_REGISTRY + value: "{{ .Values.kapi.jobIntervalValidatorsRegistry }}" + - name: PROVIDER_JSON_RPC_MAX_BATCH_SIZE + value: "{{ .Values.kapi.providerJsonRpcMaxBatchSize }}" + - name: PROVIDER_CONCURRENT_REQUESTS + value: "{{ .Values.kapi.providerConcurrentRequests }}" + - name: PROVIDER_BATCH_AGGREGATION_WAIT_MS + value: "{{ .Values.kapi.providerBatchAggregationWaitMs }}" + - name: LOG_LEVEL + value: "{{ .Values.kapi.logLevel }}" + - name: LOG_FORMAT + value: "{{ .Values.kapi.logFormat }}" + - name: CHAIN_ID + value: "{{ .Values.kapi.chainId }}" + - name: PROVIDERS_URLS + value: "{{ .Values.kapi.execution }}" + - name: CL_API_URLS + value: "{{ .Values.kapi.consensus }}" + - name: GLOBAL_THROTTLE_TTL + value: "{{ .Values.kapi.globalThrottleTTL }}" + - name: GLOBAL_THROTTLE_LIMIT + value: "{{ .Values.kapi.globalThrottleLimit }}" + - name: GLOBAL_CACHE_TTL + value: "{{ .Values.kapi.globalCacheTTL }}" + {{- if .Values.global.externalSecrets.enabled }} + envFrom: + - secretRef: + name: eso-{{ include "common.names.fullname" . }} + {{- end }} + ports: + - name: api + containerPort: {{ .Values.kapi.port }} + protocol: TCP + resources: + {{- toYaml .Values.resources | nindent 12 }} \ No newline at end of file diff --git a/charts/validator-kapi/values.yaml b/charts/validator-kapi/values.yaml new file mode 100644 index 000000000..d42607063 --- /dev/null +++ b/charts/validator-kapi/values.yaml @@ -0,0 +1,220 @@ +# Default values for web3signer. +# This is a YAML-formatted file. +# Declare variables to be passed into your templates. + +global: + serviceAccount: + create: true + + replicaCount: 1 + + externalSecrets: + enabled: false + secretStoreRef: secretStoreRef + data: + - secretKey: DB_NAME + remoteRef: + key: validatorKapiSecrets + property: dbName + - secretKey: DB_PORT + remoteRef: + key: validatorKapiSecrets + property: dbPort + - secretKey: DB_HOST + remoteRef: + key: validatorKapiSecrets + property: dbHost + - secretKey: DB_USER + remoteRef: + key: validatorKapiSecrets + property: dbUser + - secretKey: DB_PASSWORD + remoteRef: + key: validatorKapiSecrets + property: dbPassword + + image: + repository: lidofinance/lido-keys-api + pullPolicy: IfNotPresent + tag: "0.10.1" + +kapi: + env: "production" + # Application port + port: 3000 + # The number of seconds that each request will last in storage + corsWhitelistRegexp: "" + jobIntervalRegistry: "*/5 * * * * *" + jobIntervalValidatorsRegistry: "*/10 * * * * *" + globlaThrottleTTL: 5 + # FallbackProviderModule request policy parameters + # values below are default + providerJsonRpcMaxBatchSize: 100 + providerConcurrentRequests: 5 + providerBatchAggregationWaitMs: 10 + # The maximum number of requests within the TTL limit + globalThrottleLimit: 100 + # Cache expiration time in seconds + globalCacheTTL: 1 + # Log level: debug, info, notice, warning or error + logLevel: debug + # Log format: simple or json + logFormat: json + # EL Node provider + # You could provide few providers for fallback + execution: http://your_el_node1,http://your_el_node2 + # chain id + chainId: 1 + # It is possible to enable/disable collecting of validators + # value below is default + validatorRegistryEnable: true + # CL api urls + # if VALIDATOR_REGISTRY_ENABLE=false , there are no need to provide CL_API_URLS + consensus: http://your_cl_node1,http://your_cl_node2 + +## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ +## +serviceAccount: + # Annotations to add to the service account + annotations: {} + # The name of the service account to use. + # If not set and create is true, a name is generated using the fullname template + name: "" + +podAnnotations: {} + +## Pod Security Context +## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/ +## +podSecurityContext: {} + +securityContext: {} + # capabilities: + # drop: + # - ALL + # readOnlyRootFilesystem: true + # runAsNonRoot: true + # runAsUser: 1000 + +service: + type: ClusterIP + port: 80 + +## PostgreSQL Server +## ref: https://github.com/bitnami/charts/tree/master/bitnami/postgresql +## +postgresql: + enabled: true + volumePermissions: + enabled: true + image: + registry: docker.io + repository: bitnami/bitnami-shell + tag: 11-debian-11-r99 + pullPolicy: Always + securityContext: + runAsUser: 0 + securityContext: + enabled: true + fsGroup: 1001 + containerSecurityContext: + enabled: true + runAsUser: 1001 + rbac: + create: false + hostname: postgresql + audit: + logHostname: true + auth: + username: "postgres" + password: "kapi" + database: "kapi" + postgresPassword: "kapi-admin" + existingSecret: "" + secretKeys: + adminPasswordKey: "" + userPasswordKey: "" + replicationPasswordKey: "" + service: + ports: + postgresql: 5432 + primary: + persistence: + enabled: true + mountPath: /bitnami/postgresql + subPath: '' + accessModes: + - ReadWriteOnce + size: 20Gi + annotations: { } + selector: { } + resources: + requests: + memory: 384Mi + cpu: 250m + networkPolicy: + enabled: false + tls: + enabled: false + metrics: + enabled: true + +## Configure resource requests and limits. +## ref: http://kubernetes.io/docs/user-guide/compute-resources/ +## +resources: {} + # We usually recommend not to specify default resources and to leave this as a conscious + # choice for the user. This also increases chances charts run on environments with little + # resources, such as Minikube. If you do want to specify resources, uncomment the following + # lines, adjust them as necessary, and remove the curly braces after 'resources:'. + # limits: + # cpu: 100m + # memory: 128Mi + # requests: + # cpu: 100m + # memory: 128Mi + +## Node labels for pod assignment +## ref: https://kubernetes.io/docs/user-guide/node-selection/ +## +nodeSelector: {} + +## Tolerations for pod assignment +## ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/ +## +tolerations: {} + +## Affinity for pod assignment +## ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity +## +affinity: {} + +## Prometheus Service Monitor +## ref: https://github.com/coreos/prometheus-operator +## https://github.com/coreos/prometheus-operator/blob/master/Documentation/api.md#endpoint +## +serviceMonitor: + ## @param metrics.serviceMonitor.enabled Create ServiceMonitor resource(s) for scraping metrics using PrometheusOperator + ## + enabled: false + ## @param metrics.serviceMonitor.namespace The namespace in which the ServiceMonitor will be created + ## + namespace: "" + ## @param metrics.serviceMonitor.interval The interval at which metrics should be scraped + ## + interval: 30s + ## @param metrics.serviceMonitor.scrapeTimeout The timeout after which the scrape is ended + ## + scrapeTimeout: "" + ## @param metrics.serviceMonitor.relabellings Metrics RelabelConfigs to apply to samples before scraping. + ## + relabellings: [] + ## @param metrics.serviceMonitor.metricRelabelings Metrics RelabelConfigs to apply to samples before ingestion. + ## + metricRelabelings: [] + ## @param metrics.serviceMonitor.honorLabels Specify honorLabels parameter to add the scrape endpoint + ## + honorLabels: false + ## @param metrics.serviceMonitor.additionalLabels Additional labels that can be used so ServiceMonitor resource(s) can be discovered by Prometheus + ## + additionalLabels: {} diff --git a/charts/validator-monitor/.helmignore b/charts/validator-monitor/.helmignore deleted file mode 100644 index 0e8a0eb36..000000000 --- a/charts/validator-monitor/.helmignore +++ /dev/null @@ -1,23 +0,0 @@ -# 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/ diff --git a/charts/validator-monitor/Chart.yaml b/charts/validator-monitor/Chart.yaml deleted file mode 100644 index a37db105a..000000000 --- a/charts/validator-monitor/Chart.yaml +++ /dev/null @@ -1,29 +0,0 @@ -apiVersion: v2 -name: validator-monitor -description: A Helm chart for monitoring validator effectiveness - -# A chart can be either an 'application' or a 'library' chart. -# -# Application charts are a collection of templates that can be packaged into versioned archives -# to be deployed. -# -# Library charts provide useful utilities or functions for the chart developer. They're included as -# a dependency of application charts to inject those utilities and functions into the rendering -# pipeline. Library charts do not define any templates and therefore cannot be deployed. -type: application - -# This is the chart version. This version number should be incremented each time you make changes -# to the chart and its templates, including the app version. -# Versions are expected to follow Semantic Versioning (https://semver.org/) -version: 1.0.3 - -# This is the version number of the application being deployed. This version number should be -# incremented each time you make changes to the application. Versions are not expected to -# follow Semantic Versioning. They should reflect the version the application is using. -# It is recommended to use it with quotes. -appVersion: "v1.0.0" - -dependencies: -- name: common - repository: file://../common - version: 1.0.0 diff --git a/charts/validator-monitor/templates/prometheusrules.yaml b/charts/validator-monitor/templates/prometheusrules.yaml deleted file mode 100644 index 03b3f5eda..000000000 --- a/charts/validator-monitor/templates/prometheusrules.yaml +++ /dev/null @@ -1,22 +0,0 @@ -{{- if .Values.prometheusRule.enabled }} -apiVersion: monitoring.coreos.com/v1 -kind: PrometheusRule -metadata: - name: {{ include "common.names.fullname" . }} - {{- if .Values.prometheusRule.namespace }} - namespace: {{ .Values.prometheusRule.namespace }} - {{- else }} - namespace: {{ .Release.Namespace | quote }} - {{- end }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} - {{- if .Values.prometheusRule.additionalLabels }} - {{- toYaml .Values.prometheusRule.additionalLabels | nindent 4 }} - {{- end }} -spec: - groups: - {{- with .Values.prometheusRule.rules }} - - name: {{ include "common.names.fullname" $ }} - rules: {{- tpl (toYaml .) $ | nindent 8 }} - {{- end }} -{{- end }} diff --git a/charts/validator-monitor/templates/service.yaml b/charts/validator-monitor/templates/service.yaml deleted file mode 100644 index 29a8e126e..000000000 --- a/charts/validator-monitor/templates/service.yaml +++ /dev/null @@ -1,15 +0,0 @@ -apiVersion: v1 -kind: Service -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -spec: - type: {{ .Values.service.type }} - ports: - - port: {{ .Values.service.port }} - targetPort: metrics - protocol: TCP - name: metrics - selector: - {{- include "common.labels.matchLabels" . | nindent 4 }} diff --git a/charts/validator-monitor/templates/serviceaccount.yaml b/charts/validator-monitor/templates/serviceaccount.yaml deleted file mode 100644 index cb2edd11f..000000000 --- a/charts/validator-monitor/templates/serviceaccount.yaml +++ /dev/null @@ -1,12 +0,0 @@ -{{- if or .Values.global.serviceAccount.create .Values.serviceAccount.create -}} -apiVersion: v1 -kind: ServiceAccount -metadata: - name: {{ include "common.names.serviceAccountName" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} - {{- with .Values.serviceAccount.annotations }} - annotations: - {{- toYaml . | nindent 4 }} - {{- end }} -{{- end }} diff --git a/charts/validators/CHANGELOG.md b/charts/validators/CHANGELOG.md deleted file mode 100644 index 0042184bd..000000000 --- a/charts/validators/CHANGELOG.md +++ /dev/null @@ -1,22 +0,0 @@ -# Changelog -All notable changes to this project will be documented in this file. - -The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), -and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). - -## [2.2.0] - 2022.02 -### Added -- Support for multiple beaconChainRpcEndpoints -### Changed -- All dependencies are now installed separately to simplify the installation and maintenance process -- beaconChainRpcEndpoint changed from string to list with ability to specify multiple eth2 endpoints -- vaultEndpoint should be specified manually in all cases -### Removed -- geth, erigon, prysm, lighthouse, teku, vault dependencies - -## [2.0.1] - 2022.01 -### Added -- Gnosis Chain Support -### Changed -- Added Gnosis Chain compatible binaries to Dockerfile -- Added Gnosis Chain support to validator init script diff --git a/charts/validators/Chart.yaml b/charts/validators/Chart.yaml index 7d1d11792..fbd7d342b 100644 --- a/charts/validators/Chart.yaml +++ b/charts/validators/Chart.yaml @@ -1,27 +1,9 @@ apiVersion: v2 name: validators description: A Helm chart for installing validators with the web3signer. - -# A chart can be either an 'application' or a 'library' chart. -# -# Application charts are a collection of templates that can be packaged into versioned archives -# to be deployed. -# -# Library charts provide useful utilities or functions for the chart developer. They're included as -# a dependency of application charts to inject those utilities and functions into the rendering -# pipeline. Library charts do not define any templates and therefore cannot be deployed. type: application - -# This is the chart version. This version number should be incremented each time you make changes -# to the chart and its templates, including the app version. -# Versions are expected to follow Semantic Versioning (https://semver.org/) -version: 3.0.6 - -# This is the version number of the application being deployed. This version number should be -# incremented each time you make changes to the application. Versions are not expected to -# follow Semantic Versioning. They should reflect the version the application is using. -# It is recommended to use it with quotes. -appVersion: "v3.0.6" +version: 1.0.0 +appVersion: "v1.0.0" keywords: - ethereum @@ -29,6 +11,5 @@ keywords: - lighthouse - prysm - teku - - stakewise + - validators -home: https://stakewise.io/ diff --git a/charts/validators/README.md b/charts/validators/README.md deleted file mode 100644 index b05c64f86..000000000 --- a/charts/validators/README.md +++ /dev/null @@ -1,36 +0,0 @@ -# README - -> :book: **Check out the full documentation on the** [doc.stakewise.io](https://docs.stakewise.io/node-operator/infrastructure) - -## Prerequisites - -To use the charts here, [Helm](https://helm.sh/) must be configured for your -Kubernetes cluster. Setting up Kubernetes and Helm is outside the scope of -this README. Please refer to the Kubernetes and Helm documentation. - - * At least three nodes in the Kubernetes cluster with 8 CPU/16 GB RAM configuration. -1000 GB of Persistent Storage per node (SSD). - * Helm 3.0+ - This is the earliest version of Helm tested. Charts may work with earlier versions but it is untested. - * Kubernetes 1.18+ - This is the earliest version of Kubernetes tested. Charts may work with earlier versions but it is untested. - * PV provisioner support in the underlying infrastructure - -## Usage - -To install the latest version of this chart, add dependent helm repositories -and run `helm install`: - -```console -$ helm repo add stakewise https://charts.stakewise.io - -$ helm repo update - -$ helm upgrade --install validators stakewise/validators \ - --namespace validators \ - --set key=value... -``` - -**Please see the options supported in the `values.yaml` file.** The full documentation is available at https://docs.stakewise.io/node-operator/stakewise-infra-package/usage - -## Changelog - -Please refer to the `CHANGELOG.md` file. diff --git a/charts/validators/templates/_helpers.tpl b/charts/validators/templates/_helpers.tpl index a55b0bc5a..39d38bbf7 100644 --- a/charts/validators/templates/_helpers.tpl +++ b/charts/validators/templates/_helpers.tpl @@ -23,6 +23,19 @@ If release name contains chart name it will be used as a full name. {{- end }} {{- end }} +{{/* +Extract the last part of a string after the hyphen ("-"). Defining the validators owner. +*/}} +{{- define "validators.ownership" -}} +{{- $fullname := .Values.fullnameOverride }} +{{- if not $fullname }} +{{- $name := default .Chart.Name .Values.nameOverride }} +{{- $fullname = printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" }} +{{- end }} +{{- $parts := split "-" $fullname }} +{{- index $parts (sub (len $parts) 1) }} +{{- end }} + {{/* Create chart name and version as used by the chart label. */}} @@ -91,12 +104,13 @@ Validator beacon node {{- else if eq $.Values.type "lighthouse" }} - "--beacon-nodes={{ $.Values.beaconChainRpcEndpoints | join "," }}" {{- else if eq $.Values.type "teku" }} -{{- $beaconChainRpcEndpointsLen := len $.Values.beaconChainRpcEndpoints }} -{{- if gt $beaconChainRpcEndpointsLen 1 }} -- "--beacon-node-api-endpoints={{ $.Values.beaconChainRpcEndpoints | join "," }}" -{{- else }} - "--beacon-node-api-endpoint={{ $.Values.beaconChainRpcEndpoints | join "," }}" +{{- else if eq $.Values.type "nimbus" }} +{{- range $.Values.beaconChainRpcEndpoints }} +- "--beacon-node={{ . }}" {{- end }} +{{- else if eq $.Values.type "lodestar" }} +- --beaconNodes={{ $.Values.beaconChainRpcEndpoints | join "," }} {{- end }} {{- end }} @@ -105,14 +119,19 @@ Validator graffiti */}} {{- define "validator-graffiti" -}} {{- if $.Values.graffiti }} -{{- if or (eq $.Values.type "prysm") (eq $.Values.type "lighthouse") }} -- "--graffiti={{ $.Values.graffiti }}" -{{- else if eq $.Values.type "teku" }} +{{- if eq $.Values.type "teku" }} - "--validators-graffiti={{ $.Values.graffiti }}" +{{- else }} +- "--graffiti={{ $.Values.graffiti }}" {{- end }} {{- end }} {{- end }} +{{- define "web3signer" -}} +{{- if $.Values.web3signerEndpoint }}{{ $.Values.web3signerEndpoint }}{{- else }}http://{{ $.Values.global.project }}-{{ $.Values.global.label }}-web3signer:6174 +{{- end }} +{{- end }} + {{- define "flatten_list" -}} {{- $output := list -}} {{- range . -}} diff --git a/charts/validators/templates/configmap.yaml b/charts/validators/templates/configmap.yaml index 841812d65..cfafa4c6f 100644 --- a/charts/validators/templates/configmap.yaml +++ b/charts/validators/templates/configmap.yaml @@ -1,8 +1,9 @@ +{{- if .Values.enableWatcher }} --- apiVersion: v1 kind: ConfigMap metadata: - name: {{ template "validators.fullname" . }}-gnosis-prysm + name: {{ template "validators.fullname" . }}-watcher labels: {{- include "validators.labels" . | nindent 4 }} annotations: @@ -10,181 +11,5 @@ metadata: "helm.sh/hook": pre-install,pre-upgrade "helm.sh/hook-weight": "-5" data: - config.yaml: |- - CONFIG_NAME: gnosis - PRESET_BASE: mainnet - - # Misc - # --------------------------------------------------------------- - # 2**6 (= 64) - MAX_COMMITTEES_PER_SLOT: 64 - # 2**7 (= 128) - TARGET_COMMITTEE_SIZE: 128 - # 2**11 (= 2,048) - MAX_VALIDATORS_PER_COMMITTEE: 2048 - # 2**2 (= 4) - MIN_PER_EPOCH_CHURN_LIMIT: 4 - # 2**12 (= 4096) - CHURN_LIMIT_QUOTIENT: 4096 - # See issue 563 - SHUFFLE_ROUND_COUNT: 90 - # `2**12` (= 4096) - MIN_GENESIS_ACTIVE_VALIDATOR_COUNT: 4096 - # Dec 08, 2021, 13:00 UTC - MIN_GENESIS_TIME: 1638968400 - # 4 - HYSTERESIS_QUOTIENT: 4 - # 1 (minus 0.25) - HYSTERESIS_DOWNWARD_MULTIPLIER: 1 - # 5 (plus 1.25) - HYSTERESIS_UPWARD_MULTIPLIER: 5 - # Fork Choice - # --------------------------------------------------------------- - # 2**3 (= 8) - SAFE_SLOTS_TO_UPDATE_JUSTIFIED: 8 - # Validator - # --------------------------------------------------------------- - # 2**10 (= 1024) ~1.4 hour - ETH1_FOLLOW_DISTANCE: 1024 - # 2**4 (= 16) - TARGET_AGGREGATORS_PER_COMMITTEE: 16 - # 2**0 (= 1) - RANDOM_SUBNETS_PER_VALIDATOR: 1 - # 2**8 (= 256) - EPOCHS_PER_RANDOM_SUBNET_SUBSCRIPTION: 256 - # 6 (estimate from xDai mainnet) - SECONDS_PER_ETH1_BLOCK: 6 - - # Deposit contract - # --------------------------------------------------------------- - # xDai Mainnet - DEPOSIT_CHAIN_ID: 100 - DEPOSIT_NETWORK_ID: 100 - # GBC deposit contract on xDai Mainnet - DEPOSIT_CONTRACT_ADDRESS: 0x0B98057eA310F4d31F2a452B414647007d1645d9 - # Gwei values - # --------------------------------------------------------------- - # 2**0 * 10**9 (= 1,000,000,000) Gwei - MIN_DEPOSIT_AMOUNT: 1000000000 - # 2**5 * 10**9 (= 32,000,000,000) Gwei - MAX_EFFECTIVE_BALANCE: 32000000000 - # 2**4 * 10**9 (= 16,000,000,000) Gwei - EJECTION_BALANCE: 16000000000 - # 2**0 * 10**9 (= 1,000,000,000) Gwei - EFFECTIVE_BALANCE_INCREMENT: 1000000000 - # Initial values - # --------------------------------------------------------------- - # GBC area code - GENESIS_FORK_VERSION: 0x00000064 - BLS_WITHDRAWAL_PREFIX: 0x00 - # Time parameters - # --------------------------------------------------------------- - # Customized for GBC: ~1 hour - GENESIS_DELAY: 6000 - # 5 seconds - SECONDS_PER_SLOT: 5 - # 2**0 (= 1) slots 12 seconds - MIN_ATTESTATION_INCLUSION_DELAY: 1 - # 2**4 (= 16) slots 1.87 minutes - SLOTS_PER_EPOCH: 16 - # 2**0 (= 1) epochs 1.87 minutes - MIN_SEED_LOOKAHEAD: 1 - # 2**2 (= 4) epochs 7.47 minutes - MAX_SEED_LOOKAHEAD: 4 - # 2**6 (= 64) epochs ~2 hours - EPOCHS_PER_ETH1_VOTING_PERIOD: 64 - # 2**13 (= 8,192) slots ~15.9 hours - SLOTS_PER_HISTORICAL_ROOT: 8192 - # 2**8 (= 256) epochs ~8 hours - MIN_VALIDATOR_WITHDRAWABILITY_DELAY: 256 - # 2**8 (= 256) epochs ~8 hours - SHARD_COMMITTEE_PERIOD: 256 - # 2**2 (= 4) epochs 7.47 minutes - MIN_EPOCHS_TO_INACTIVITY_PENALTY: 4 - - # State vector lengths - # --------------------------------------------------------------- - # 2**16 (= 65,536) epochs ~85 days - EPOCHS_PER_HISTORICAL_VECTOR: 65536 - # 2**13 (= 8,192) epochs ~10.6 days - EPOCHS_PER_SLASHINGS_VECTOR: 8192 - # 2**24 (= 16,777,216) historical roots, ~15,243 years - HISTORICAL_ROOTS_LIMIT: 16777216 - # 2**40 (= 1,099,511,627,776) validator spots - VALIDATOR_REGISTRY_LIMIT: 1099511627776 - # Reward and penalty quotients - # --------------------------------------------------------------- - # 25 - BASE_REWARD_FACTOR: 25 - # 2**9 (= 512) - WHISTLEBLOWER_REWARD_QUOTIENT: 512 - # 2**3 (= 8) - PROPOSER_REWARD_QUOTIENT: 8 - # 2**26 (= 67,108,864) - INACTIVITY_PENALTY_QUOTIENT: 67108864 - # 2**7 (= 128) (lower safety margin at Phase 0 genesis) - MIN_SLASHING_PENALTY_QUOTIENT: 128 - # 1 (lower safety margin at Phase 0 genesis) - PROPORTIONAL_SLASHING_MULTIPLIER: 1 - # Max operations per block - # --------------------------------------------------------------- - # 2**4 (= 16) - MAX_PROPOSER_SLASHINGS: 16 - # 2**1 (= 2) - MAX_ATTESTER_SLASHINGS: 2 - # 2**7 (= 128) - MAX_ATTESTATIONS: 128 - # 2**4 (= 16) - MAX_DEPOSITS: 16 - # 2**4 (= 16) - MAX_VOLUNTARY_EXITS: 16 - # Signature domains - # --------------------------------------------------------------- - DOMAIN_BEACON_PROPOSER: 0x00000000 - DOMAIN_BEACON_ATTESTER: 0x01000000 - DOMAIN_RANDAO: 0x02000000 - DOMAIN_DEPOSIT: 0x03000000 - DOMAIN_VOLUNTARY_EXIT: 0x04000000 - DOMAIN_SELECTION_PROOF: 0x05000000 - DOMAIN_AGGREGATE_AND_PROOF: 0x06000000 - DOMAIN_SYNC_COMMITTEE: 0x07000000 - DOMAIN_SYNC_COMMITTEE_SELECTION_PROOF: 0x08000000 - DOMAIN_CONTRIBUTION_AND_PROOF: 0x09000000 - - ALTAIR_FORK_VERSION: 0x01000064 - ALTAIR_FORK_EPOCH: 512 - - BELLATRIX_FORK_VERSION: 0x02000064 - BELLATRIX_FORK_EPOCH: 18446744073709551615 - - INACTIVITY_SCORE_BIAS: 4 - # 2**4 (= 16) - INACTIVITY_SCORE_RECOVERY_RATE: 16 - INACTIVITY_PENALTY_QUOTIENT_ALTAIR: 50331648 - MIN_SLASHING_PENALTY_QUOTIENT_ALTAIR: 64 - PROPORTIONAL_SLASHING_MULTIPLIER_ALTAIR: 2 - - # Sync committee - # --------------------------------------------------------------- - # 2**9 (= 512) - SYNC_COMMITTEE_SIZE: 512 - # 2**9 (= 512) - # assert EPOCHS_PER_SYNC_COMMITTEE_PERIOD * SLOTS_PER_EPOCH <= SLOTS_PER_HISTORICAL_ROOT - EPOCHS_PER_SYNC_COMMITTEE_PERIOD: 512 - -{{- if .Values.feeOverride }} ---- -apiVersion: v1 -kind: ConfigMap -metadata: - name: {{ template "validators.fullname" . }}-override-fee-recipient - labels: - {{- include "validators.labels" . | nindent 4 }} - annotations: - "helm.sh/resource-policy": keep - "helm.sh/hook": pre-install,pre-upgrade - "helm.sh/hook-weight": "-5" -data: - feeOverride.json: |- - {{- .Values.feeOverride | nindent 4 }} +{{ (.Files.Glob "watcher.sh").AsConfig | indent 2 }} {{- end }} \ No newline at end of file diff --git a/charts/validators/templates/external-secret.yaml b/charts/validators/templates/external-secret.yaml new file mode 100644 index 000000000..20892cd43 --- /dev/null +++ b/charts/validators/templates/external-secret.yaml @@ -0,0 +1,30 @@ +{{- if .Values.externalSecrets.enabled }} +apiVersion: external-secrets.io/v1beta1 +kind: ExternalSecret +metadata: + name: eso-{{ template "validators.fullname" . }} + labels: + {{- include "validators.labels" . | nindent 4 }} +spec: + refreshInterval: 10m + secretStoreRef: + name: {{ .Values.externalSecrets.secretStoreRef.name }} + kind: {{ .Values.externalSecrets.secretStoreRef.kind }} + target: + name: eso-{{ template "validators.fullname" . }} + creationPolicy: Owner + data: + {{- if empty .Values.externalSecrets.data }} + - secretKey: ESO_DB_KEYSTORE_URL + remoteRef: + key: staking-{{ .Values.global.label }}-external-secrets + property: dbKeystoreUrl + {{- else }} + {{- range .Values.externalSecrets.data }} + - secretKey: {{ .secretKey }} + remoteRef: + key: {{ .remoteRef.key }} + property: {{ .remoteRef.property }} + {{- end }} +{{- end }} +{{- end }} \ No newline at end of file diff --git a/charts/validators/templates/role.yaml b/charts/validators/templates/role.yaml new file mode 100644 index 000000000..e82e23cc5 --- /dev/null +++ b/charts/validators/templates/role.yaml @@ -0,0 +1,10 @@ +{{- if .Values.rbac.create -}} +apiVersion: rbac.authorization.k8s.io/v1 +kind: Role +metadata: + name: {{ template "validators.fullname" . }} + labels: + {{- include "validators.labels" . | nindent 4 }} +rules: +{{- toYaml .Values.rbac.rules | nindent 0 }} +{{- end }} diff --git a/charts/validators/templates/rolebinding.yaml b/charts/validators/templates/rolebinding.yaml new file mode 100644 index 000000000..25b3c960a --- /dev/null +++ b/charts/validators/templates/rolebinding.yaml @@ -0,0 +1,15 @@ +{{- if .Values.rbac.create }} +apiVersion: rbac.authorization.k8s.io/v1 +kind: RoleBinding +metadata: + name: {{ template "validators.fullname" . }}-binding + labels: + {{- include "validators.labels" . | nindent 4 }} +roleRef: + apiGroup: rbac.authorization.k8s.io + kind: Role + name: {{ template "validators.fullname" . }} +subjects: + - kind: ServiceAccount + name: {{ include "validators.serviceAccountName" . }} +{{- end }} diff --git a/charts/validators/templates/serviceaccount.yaml b/charts/validators/templates/serviceaccount.yaml index b3d7e740b..c083b02b5 100644 --- a/charts/validators/templates/serviceaccount.yaml +++ b/charts/validators/templates/serviceaccount.yaml @@ -3,11 +3,11 @@ apiVersion: v1 kind: ServiceAccount metadata: - name: validators + name: {{ template "validators.serviceAccountName" . }} labels: {{- include "validators.labels" . | nindent 4 }} {{- with .Values.serviceAccount.annotations }} annotations: {{- toYaml . | nindent 4 }} {{- end }} -{{- end }} \ No newline at end of file +{{- end }} diff --git a/charts/validators/templates/statefulset.yaml b/charts/validators/templates/statefulset.yaml index 210c55728..78b9c45d4 100644 --- a/charts/validators/templates/statefulset.yaml +++ b/charts/validators/templates/statefulset.yaml @@ -1,6 +1,7 @@ {{- if .Values.enabled }} {{- $root := . -}} {{- $counter := 0 }} + {{- range (untilStep (int .Values.validatorsKeyIndex) (int (add .Values.validatorsKeyIndex .Values.validatorsCount)) 1) }} {{ $rpcEndpoints := list }} @@ -10,6 +11,12 @@ {{ $rpcList = append $rpcList (index $.Values.beaconChainRpcEndpointsRandomized .) }} {{- end }} {{ $rpcList = append $rpcList $.Values.beaconChainRpcEndpointsRandomized }} + +# Appending the failover endpoints to the rpcList before flattening +{{- if $.Values.fallbackRpcEndpoints }} + {{- $rpcList = append $rpcList $.Values.fallbackRpcEndpoints }} +{{- end }} + {{ $rpcEndpoints = include "flatten" $rpcList }} {{- if ge $counter (len $.Values.beaconChainRpcEndpointsRandomized) }} {{- $counter = 1 }} @@ -57,117 +64,184 @@ spec: nodeSelector: {{ toYaml . | nindent 8 | trim }} {{- end }} - {{- with $root.Values.securityContext }} securityContext: - {{ toYaml . | nindent 8 | trim }} - {{- end }} - serviceAccountName: "validators" + {{- toYaml $root.Values.global.podSecurityContext | nindent 8 }} + serviceAccountName: {{ template "validators.serviceAccountName" $root }} priorityClassName: {{ $root.Values.priorityClassName | quote }} initContainers: - name: get-configs image: "{{ $root.Values.cliImage.repository }}:{{ $root.Values.cliImage.tag }}" imagePullPolicy: {{ $root.Values.cliImage.pullPolicy }} securityContext: - runAsUser: 0 + {{- toYaml $root.Values.global.securityContext | nindent 12 }} env: - name: WEB3SIGNER_URL - value: {{ $root.Values.web3signerEndpoint }} + value: {{ include "web3signer" $root }} + - name: ESO_DB_KEYSTORE_URL + valueFrom: + secretKeyRef: + name: eso-{{ template "validators.fullname" $root }} + key: ESO_DB_KEYSTORE_URL args: - "sync-validator-keys" - "--db-url" - - "{{ $root.Values.dbKeystoreUrl }}" + - "$(ESO_DB_KEYSTORE_URL)" - "--output-dir" - "/data" - "--index" - "{{ . }}" - - "--network" - - "{{ $root.Values.network }}" - {{- if $root.Values.feeOverride }} - - "--solo-fees-file" - - "/fee/feeOverride.json" - {{- end }} - {{- if not $root.Values.enableBuilder }} - - "--proposal-builder-enabled" - - "false" - {{- end }} + - "--no-of-keys" + - "{{ $root.Values.validatorsNoOfKeys }}" + {{- if not $root.Values.strictFeeRecipientCheck }} + - "--no-strict-fee-recipient-check" + {{- end }} + {{- if eq $.Values.type "lodestar" }} + - "--graffiti" + - "{{ $root.Values.graffiti }}" + {{- end }} + {{- if not $root.Values.enableBuilder }} + - "--no-proposal-builder-enabled" + {{- end }} + {{- if $root.Values.gasLimit }} + - "--gas-limit" + - "{{ $root.Values.gasLimit }}" + {{- end }} volumeMounts: - name: data mountPath: /data - {{- if $root.Values.feeOverride }} - - name: fee-override - mountPath: /fee - {{- end }} - name: prepare image: "{{ $root.Values.initImageBusybox.repository }}:{{ $root.Values.initImageBusybox.tag }}" imagePullPolicy: {{ $root.Values.initImageBusybox.pullPolicy }} securityContext: - runAsUser: 0 + {{- toYaml $root.Values.global.securityContext | nindent 12 }} command: - sh - -c - > - ls -lha /data; mkdir -p /data/lighthouse/validators; cp /data/validator_definitions.yml /data/lighthouse/validators/validator_definitions.yml; - cp /mnt/gnosis-prysm/config.yaml /data/config_gnosis_prysm; cat /data/signer_keys.yml > /data/config; cat /data/config; cat /data/proposerConfig.json; - echo "" >> - cat /data/signer_keys.yml >> /data/config_gnosis_prysm; - cat /data/config_gnosis_prysm; - chown -R {{ $root.Values.securityContext.runAsUser }}:{{ $root.Values.securityContext.runAsUser }} /data; + cat /data/proposerConfig.yaml; + formatted_content=$(cat /data/signer_keys.yml | grep -o '".*"' | sed -e 's/"//g' | tr ',' '\n'); + echo "$formatted_content" > /data/pubkeys.txt; + echo '{"externalSigner.pubkeys": ['"$(awk '{printf "%s\"%s\"", (NR==1 ? "" : ", "), $0}' /data/pubkeys.txt)"']}' > /data/rcconfig.json; + cat /data/rcconfig.json; + ls -lha /data; + {{- if eq $root.Values.type "nimbus" }} + find /data/nimbus -type d -name '0x*' -exec chmod 0600 {}/remote_keystore.json \; + {{- end }} volumeMounts: - name: data mountPath: /data - - name: gnosis-prysm - mountPath: /mnt/gnosis-prysm containers: + {{- if $root.Values.enableWatcher }} + - name: watcher + image: "{{ $root.Values.cliImage.repository }}:{{ $root.Values.cliImage.tag }}" + imagePullPolicy: {{ $root.Values.cliImage.pullPolicy }} + securityContext: + {{- toYaml $root.Values.global.securityContext | nindent 12 }} + env: + - name: WEB3SIGNER_URL + value: {{ include "web3signer" $root }} + - name: ESO_DB_KEYSTORE_URL + valueFrom: + secretKeyRef: + name: eso-{{ template "validators.fullname" $root }} + key: ESO_DB_KEYSTORE_URL + - name: POD_NAME + valueFrom: + fieldRef: + fieldPath: metadata.name + command: [ "/bin/bash" ] + args: ["/scripts/watcher.sh", "{{ . }}", "{{ $root.Values.validatorsNoOfKeys }}"] + volumeMounts: + - name: data + mountPath: /data + {{- if $root.Values.enableWatcher }} + - name: watcher + mountPath: /scripts + {{- end }} + {{- end }} - name: validator image: "{{ (pluck $root.Values.type $root.Values.image | first ).repository }}:{{ (pluck $root.Values.type $root.Values.image | first ).tag }}" imagePullPolicy: {{ $root.Values.image.pullPolicy }} + securityContext: + readOnlyRootFilesystem: false + runAsNonRoot: true + runAsUser: 10000 + capabilities: + drop: + - ALL + {{- if eq $root.Values.type "lodestar" }} + command: + - sh + - -c + - > + node ./packages/cli/bin/lodestar + {{- range (pluck $root.Values.type $root.Values.flags | first) }} + {{ . }} + {{- end }} + --network={{ $root.Values.network }} + --proposerSettingsFile=/data/proposerConfig.yaml + --externalSigner.url={{ include "web3signer" $root }} + --rcConfig=/data/rcconfig.json + {{- if $.Values.beaconChainRpcEndpointsRandomized }} + --beaconNodes={{ $rpcEndpoints }} + {{- else }} + {{- include "beacon-rpc-node" $ | nindent 12 }} + {{- end }} + {{- if $root.Values.metrics.enabled }} + {{- range (pluck $root.Values.type $root.Values.metrics.flags | first) }} + {{ . }} + {{- end }} + {{- end }} + + {{- range (pluck $root.Values.type $root.Values.extraFlags | first) }} + {{ . }} + {{- end }} + {{- else }} args: {{- range (pluck $root.Values.type $root.Values.flags | first) }} - {{ . | quote }} {{- end -}} - {{- if and (eq $root.Values.type "prysm") (ne $root.Values.network "gnosis") }} + {{- if eq $root.Values.type "prysm" }} - "--{{ $root.Values.network }}" - "--config-file=/data/config" - - "--validators-external-signer-url={{ $.Values.web3signerEndpoint }}" - {{- else if and (eq $root.Values.type "prysm") (eq $root.Values.network "gnosis") }} - - "--config-file /data/config_gnosis_prysm" - - "--chain-config-file /data/config_gnosis_prysm" - - "--validators-external-signer-url={{ $.Values.web3signerEndpoint }}" + - "--validators-external-signer-url={{ include "web3signer" $root }}" - "--proposer-settings-file=/data/proposerConfig.json" {{- else if eq $root.Values.type "lighthouse" }} - "--network={{ $root.Values.network }}" {{- else if eq $root.Values.type "teku" }} - "--network=auto" - "--config-file=/data/config" - - "--validators-external-signer-url={{ $.Values.web3signerEndpoint }}" + - "--validators-external-signer-url={{ include "web3signer" $root }}" - "--validators-proposer-config=/data/proposerConfig.json" + {{- if $root.Values.enableBuilder }} + - "--validators-proposer-blinded-blocks-enabled=true" + {{- end }} + {{- else if eq $root.Values.type "nimbus" }} + - "--validators-dir=/data/nimbus" + {{- if $root.Values.enableBuilder }} + - "--payload-builder=true" {{- end }} - - {{- if eq $root.Values.type "teku" }} - - "--validators-proposer-default-fee-recipient={{ $.Values.suggestedFeeRecipient }}" - {{- else }} - - "--suggested-fee-recipient={{ $.Values.suggestedFeeRecipient }}" {{- end }} {{- include "validator-graffiti" $ | nindent 12 }} - {{- if $.Values.beaconChainRpcEndpointsRandomized }} + {{- if $root.Values.beaconChainRpcEndpointsRandomized }} {{- if eq $.Values.type "prysm" }} - "--beacon-rpc-provider={{ $rpcEndpoints }}" {{- else if eq $.Values.type "lighthouse" }} - "--beacon-nodes={{ $rpcEndpoints }}" {{- else if eq $.Values.type "teku" }} - {{- $beaconChainRpcEndpointsLen := len $.Values.beaconChainRpcEndpointsRandomized }} - {{- if gt $beaconChainRpcEndpointsLen 1 }} - - "--beacon-node-api-endpoints={{ $rpcEndpoints | join "," }}" - {{- else }} - - "--beacon-node-api-endpoint={{ $rpcEndpoints }}" + - "--beacon-node-api-endpoints={{ $rpcEndpoints }}" + {{- else if eq $.Values.type "nimbus" }} + {{- $valuesList := split "," $rpcEndpoints }} + {{- range $endpoint := $valuesList }} + - "--beacon-node={{ $endpoint }}" {{- end }} {{- end }} {{- else }} @@ -206,16 +280,13 @@ spec: - name: data mountPath: /data volumes: - - name: gnosis-prysm - configMap: - name: {{ template "validators.fullname" $root }}-gnosis-prysm - {{- if $root.Values.feeOverride }} - - name: fee-override + {{- if $root.Values.enableWatcher }} + - name: watcher configMap: - name: {{ template "validators.fullname" $root }}-override-fee-recipient + name: {{ template "validators.fullname" $root }}-watcher {{- end }} - name: data emptyDir: {} - {{- end }} {{- end }} +{{- end }} \ No newline at end of file diff --git a/charts/validators/templates/validate.yaml b/charts/validators/templates/validate.yaml deleted file mode 100644 index a8ca517d4..000000000 --- a/charts/validators/templates/validate.yaml +++ /dev/null @@ -1,7 +0,0 @@ -{{- if and (not .Values.beaconChainRpcEndpoints) (not .Values.beaconChainRpcEndpointsRandomized) }} -{{- fail ".Values.beaconChainRpcEndpoints is empty" }} -{{- end }} - -{{- if not .Values.suggestedFeeRecipient }} -{{- fail ".Values.suggestedFeeRecipient is empty" }} -{{- end }} \ No newline at end of file diff --git a/charts/validators/values.yaml b/charts/validators/values.yaml index cc28fa3f5..9ebdfe2c4 100644 --- a/charts/validators/values.yaml +++ b/charts/validators/values.yaml @@ -3,8 +3,25 @@ # Declare variables to be passed into your templates. global: + owner: "" + project: "" imagePullSecrets: [] network: mainnet + ## Pod Security Context + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/ + ## + podSecurityContext: + runAsNonRoot: true + runAsUser: 10000 + fsGroup: 10000 + + securityContext: + readOnlyRootFilesystem: true + runAsNonRoot: true + runAsUser: 10000 + capabilities: + drop: + - ALL ## Provide a name in place of operator for `app:` labels ## @@ -14,36 +31,42 @@ nameOverride: "" ## fullnameOverride: "" -## Pod Security Context -## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/ -## -securityContext: - fsGroup: 1001 - runAsUser: 1001 - ## RBAC configuration. ## ref: https://kubernetes.io/docs/reference/access-authn-authz/rbac/ ## rbac: create: true + name: "" + rules: + - apiGroups: [""] + resources: + - "services" + - "pods" + verbs: + - "list" + - "get" + - "patch" ## Init image is used to chown data volume, initialise genesis, etc. ## initImageBusybox: repository: "busybox" - tag: "1.35" + tag: "1.36" pullPolicy: IfNotPresent ## CLI image is used to fetch public keys. ## cliImage: - repository: europe-west4-docker.pkg.dev/stakewiselabs/public/cli - tag: "v1.2.7" + repository: nethermindeth/keystores-cli + tag: "v1.0.0" pullPolicy: IfNotPresent -## Database connection string, ex. 'postgresql://username:pass@hostname/dbname' -## -dbKeystoreUrl: "" +externalSecrets: + enabled: true + secretStoreRef: + name: secretStoreName + kind: secretStoreKind + data: [] ## Configuration for validators ## ref: https://lighthouse-book.sigmaprime.io/validator-management.html @@ -57,10 +80,10 @@ dbKeystoreUrl: "" enabled: true ## What type of validator to use. -## Options for Ethereum: prysm, lighthouse, teku -## Options for Gnosis: prysm, lighthouse +## Options for Ethereum: prysm, lighthouse, teku, nimbus, lodestar +## Options for Gnosis: teku, lighthouse, nimbus ## -type: prysm +type: teku ## If you want to run multiple validator types (e.g lighouse, teku,...) ## you need to adjust the key index to prevent double signing. @@ -90,37 +113,40 @@ validatorsKeyIndex: 0 ## validatorsCount: 0 -## Default fee recipient for all validator keys. -## -suggestedFeeRecipient: "" +validatorsNoOfKeys: 100 ## Whether a builder should be used for proposalConfig enableBuilder: false +gasLimit: + ## Validators image version ## ref: https://gcr.io/prysmaticlabs/prysm/validator ## ref: https://hub.docker.com/r/sigp/lighthouse image: pullPolicy: IfNotPresent - prysm: - repository: "gcr.io/prysmaticlabs/prysm/validator" - tag: "v3.1.1" - prysmGnosis: - repository: "ghcr.io/gnosischain/gbc-prysm-validator" - tag: "v2.1.2-gbc" - lighthouse: - repository: "sigp/lighthouse" - tag: "v3.1.2" - teku: + prysm: + repository: "gcr.io/prylabs-dev/prysm/validator" + tag: "v4.1.1" + teku: repository: "consensys/teku" - tag: "22.10.1" + tag: "23.11.0" + lighthouse: + repository: "sigp/lighthouse" + tag: "v4.5.0" + nimbus: + repository: "statusim/nimbus-validator-client" + tag: "multiarch-v23.11.0" + lodestar: + repository: "chainsafe/lodestar" + tag: "v1.12.0" ## Credentials to fetch images from private registry ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/ ## imagePullSecrets: [] -terminationGracePeriodSeconds: 300 +terminationGracePeriodSeconds: 120 ## Spearate service account per validator. ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ @@ -128,6 +154,7 @@ terminationGracePeriodSeconds: 300 serviceAccount: # Specifies whether a service account should be created create: true + name: "" # Annotations to add to the service account annotations: {} @@ -177,6 +204,15 @@ flags: - "validator-client" - "--log-destination=CONSOLE" - "--data-base-path=/data" + nimbus: + - "--data-dir=/data/nimbus" + - "--non-interactive" + - "--log-level=INFO" + - "--doppelganger-detection=off" + lodestar: + - "validator" + - "--dataDir=/data/lodestar" + - "--logLevel=info" ## Validators extra flags ## @@ -184,10 +220,12 @@ extraFlags: prysm: [] lighthouse: [] teku: [] + nimbus: [] + lodestar: [] ## Web3Signer Endpoint ## -web3signerEndpoint: http://web3signer:6174 +web3signerEndpoint: "" ## List of Beacon Chain node addresses ## @@ -200,16 +238,23 @@ beaconChainRpcEndpoints: [] ## beaconChainRpcEndpointsRandomized: [] +## if using beaconChainRpcEndpointsRandomized +## fallbackRpcEndpoints will be appended to the list +## always serving as the last, failover endpoint +## +fallbackRpcEndpoints: [] + ## You can use the graffiti to add a string to your proposed blocks, ## which will be seen on the block explorer. ## ref: https://docs.prylabs.network/docs/prysm-usage/parameters#validator-configuration ## graffiti: "" -## Override fees for solo validators -## used for stakewise solo validators only -## -feeOverride: "" +enableWatcher: false + +## Lodestar specific setting +## Enables strict checking of the validator's feeRecipient with the one returned by engine +strictFeeRecipientCheck: false ## Monitoring ## @@ -234,6 +279,14 @@ metrics: - "--metrics-host-allowlist=*" - "--metrics-interface=0.0.0.0" - "--metrics-port=9090" + nimbus: + - "--metrics" + - "--metrics-port=9090" + - "--metrics-address=0.0.0.0" + lodestar: + - "--metrics" + - "--metrics.address=0.0.0.0" + - "--metrics.port=9090" ## Prometheus Service Monitor ## ref: https://github.com/coreos/prometheus-operator @@ -341,6 +394,26 @@ readinessProbe: path: /metrics port: metrics scheme: HTTP + nimbus: + initialDelaySeconds: 60 + timeoutSeconds: 1 + periodSeconds: 60 + failureThreshold: 3 + successThreshold: 1 + httpGet: + path: /metrics + port: metrics + scheme: HTTP + lodestar: + initialDelaySeconds: 60 + timeoutSeconds: 1 + periodSeconds: 60 + failureThreshold: 3 + successThreshold: 1 + httpGet: + path: /metrics + port: metrics + scheme: HTTP livenessProbe: prysm: initialDelaySeconds: 60 @@ -372,3 +445,23 @@ livenessProbe: path: /metrics port: metrics scheme: HTTP + nimbus: + initialDelaySeconds: 60 + timeoutSeconds: 1 + periodSeconds: 60 + failureThreshold: 3 + successThreshold: 1 + httpGet: + path: /metrics + port: metrics + scheme: HTTP + lodestar: + initialDelaySeconds: 60 + timeoutSeconds: 1 + periodSeconds: 60 + failureThreshold: 3 + successThreshold: 1 + httpGet: + path: /metrics + port: metrics + scheme: HTTP diff --git a/charts/validators/watcher.sh b/charts/validators/watcher.sh new file mode 100644 index 000000000..5301d0fe6 --- /dev/null +++ b/charts/validators/watcher.sh @@ -0,0 +1,23 @@ +#!/bin/bash +set -euo pipefail +IFS=$'\n\t' + +die_func() { + exit 0 +} +trap die_func TERM + +mkdir -p /tmp/data + +while true; +do + poetry run keystore-cli \ + sync-validator-keys \ + --db-url "$ESO_DB_KEYSTORE_URL" \ + --output-dir /tmp/data \ + --index "$1" \ + --no-of-keys "$2"; + if ! diff /tmp/data/validator_definitions.yml /data/validator_definitions.yml; then kubectl delete pod "$POD_NAME"; fi; + sleep 60 & + wait $!; +done \ No newline at end of file diff --git a/charts/lighthouse/.helmignore b/charts/vouch/.helmignore similarity index 100% rename from charts/lighthouse/.helmignore rename to charts/vouch/.helmignore diff --git a/charts/keeper/Chart.lock b/charts/vouch/Chart.lock similarity index 76% rename from charts/keeper/Chart.lock rename to charts/vouch/Chart.lock index 6cc1c2aea..bf2e36019 100644 --- a/charts/keeper/Chart.lock +++ b/charts/vouch/Chart.lock @@ -3,4 +3,4 @@ dependencies: repository: file://../common version: 1.0.0 digest: sha256:07cebde439abe4ba19bb28e844b7419dab83c7f613886416aaf3ec08e8059144 -generated: "2022-03-07T12:25:41.502834258+03:00" +generated: "2022-05-02T13:36:12.005448244+03:00" diff --git a/charts/vouch/Chart.yaml b/charts/vouch/Chart.yaml new file mode 100644 index 000000000..9b9995d8f --- /dev/null +++ b/charts/vouch/Chart.yaml @@ -0,0 +1,21 @@ +apiVersion: v2 +name: vouch +description: A Helm chart for installing and configuring large scale ETH staking infrastructure on top of the Kubernetes +type: application +version: 1.1.0 +appVersion: "1.7.6" + +keywords: + - ethereum + - blockchain + - lighthouse + - prysm + - teku + - stakewise + +home: https://stakewise.io/ + +dependencies: +- name: common + repository: file://../common + version: 1.0.0 diff --git a/charts/vouch/scripts/generate_cert.sh b/charts/vouch/scripts/generate_cert.sh new file mode 100644 index 000000000..c2f103bd0 --- /dev/null +++ b/charts/vouch/scripts/generate_cert.sh @@ -0,0 +1,46 @@ +#!/bin/bash +set -euo pipefail +IFS=$'\n\t' + +set -x + + +generate_certs() { +LOCATION=$1 +CA_CERT_NAME=$2 +CERT_NAME=$3 + +mkdir -p "${LOCATION}" +pushd "${LOCATION}" + +if [ ! -f "${CA_CERT_NAME}.key" ] +then + echo "Generating authority key" + openssl genrsa -des3 -out "${CA_CERT_NAME}_pass.key" 4096 + openssl rsa -in "${CA_CERT_NAME}_pass.key" -out "${CA_CERT_NAME}.key" +fi + +if [ ! -f "${CA_CERT_NAME}.crt" ] +then + echo "Generating authority crt" + openssl req -x509 -new -nodes -key "${CA_CERT_NAME}.key" -sha256 -days 1825 -out "${CA_CERT_NAME}.crt" +fi + +cat >"${CERT_NAME}.ext" < + mkdir -p {{ .Values.vouchDataDir }}/{{ include "common.names.fullname" . }}/certs/; + cp /config/vouch.yaml {{ .Values.vouchDataDir }}/; + printenv CA_CRT | base64 -d > {{ .Values.vouchDataDir }}/{{ include "common.names.fullname" . }}/certs/ca.crt; + printenv CA_KEY | base64 -d > {{ .Values.vouchDataDir }}/{{ include "common.names.fullname" . }}/certs/ca.key; + bash /scripts/generate_cert.sh {{ .Values.vouchDataDir }}/{{ include "common.names.fullname" . }}/certs/ ca {{ include "common.names.fullname" . }}; + chown -R {{ .Values.global.podSecurityContext.runAsUser }}:{{ .Values.global.podSecurityContext.fsGroup }} {{ .Values.vouchDataDir }}; + envFrom: + - secretRef: + name: eso-{{ include "common.names.fullname" . }} + volumeMounts: + - name: data + mountPath: /data + - name: config + mountPath: /config + - name: scripts + mountPath: /scripts + - name: sync-config + image: "{{ .Values.cliImage.repository }}:{{ .Values.cliImage.tag }}" + imagePullPolicy: {{ .Values.cliImage.pullPolicy }} + securityContext: + {{- toYaml .Values.global.securityContext | nindent 12 }} + envFrom: + - secretRef: + name: eso-{{ include "common.names.fullname" . }} + args: + - "sync-vouch-config" + - "--db-url-env" + - "ESO_DB_KEYSTORE_URL" + - "--vouch-dir" + - "{{ .Values.vouchDataDir }}" + - "--relays" + - '{{ join "," .Values.relays }}' + {{- if .Values.gasLimit }} + - "--gas-limit" + - "{{ .Values.gasLimit }}" + {{- end }} + volumeMounts: + - name: data + mountPath: /data + - name: config + mountPath: /config + - name: scripts + mountPath: /scripts + containers: + - name: vouch + image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}" + imagePullPolicy: {{ .Values.image.pullPolicy }} + securityContext: + {{- toYaml .Values.global.securityContext | nindent 12 }} + envFrom: + - secretRef: + name: eso-{{ include "common.names.fullname" . }} + args: [ "--base-dir", "{{ .Values.vouchDataDir }}" ] + ports: + - name: http + containerPort: {{ .Values.service.httpPort }} + protocol: TCP + - name: blockrelay + containerPort: {{ .Values.blockRelayPort }} + protocol: TCP + - name: metrics + containerPort: {{ .Values.metricsPort }} + protocol: TCP + {{- with .Values.resources }} + resources: + {{ toYaml . | nindent 12 }} + {{- end }} + volumeMounts: + - name: data + mountPath: /data + - name: config + mountPath: /config + - name: scripts + mountPath: /scripts + {{- if .Values.livenessProbe }} + {{- with .Values.livenessProbe }} + livenessProbe: + {{- toYaml . | nindent 12 }} + {{- end }} + {{- end }} + {{- if .Values.readinessProbe.enabled }} + readinessProbe: + initialDelaySeconds: {{ .Values.readinessProbe.initialDelaySeconds }} + timeoutSeconds: {{ .Values.readinessProbe.timeoutSeconds }} + periodSeconds: {{ .Values.readinessProbe.periodSeconds }} + failureThreshold: {{ .Values.readinessProbe.failureThreshold }} + successThreshold: {{ .Values.readinessProbe.successThreshold }} + httpGet: + path: {{ .Values.readinessProbe.httpGet.path }} + port: {{ .Values.readinessProbe.httpGet.port }} + scheme: {{ .Values.readinessProbe.httpGet.scheme }} + {{- end }} + - name: fetch-keys-syncer + image: "{{ .Values.cliImage.repository }}:{{ .Values.cliImage.tag }}" + imagePullPolicy: {{ .Values.cliImage.pullPolicy }} + securityContext: + {{- toYaml .Values.global.securityContext | nindent 12 }} + envFrom: + - secretRef: + name: eso-{{ include "common.names.fullname" . }} + args: + - "sync-vouch-config" + - "--db-url-env" + - "ESO_DB_KEYSTORE_URL" + - "--vouch-dir" + - "{{ .Values.vouchDataDir }}" + - "--relays" + - '{{ join "," .Values.relays }}' + - "--refresh-frequency" + - "1800" + {{- if .Values.gasLimit }} + - "--gas-limit" + - "{{ .Values.gasLimit }}" + {{- end }} + volumeMounts: + - name: data + mountPath: /data + - name: config + mountPath: /config + - name: scripts + mountPath: /scripts + volumes: + - name: config + configMap: + name: {{ include "common.names.fullname" . }} + - name: scripts + configMap: + name: {{ include "common.names.fullname" . }}-scripts + - name: data + emptyDir: + medium: Memory + sizeLimit: 128Mi diff --git a/charts/vouch/values.yaml b/charts/vouch/values.yaml new file mode 100644 index 000000000..2868f503b --- /dev/null +++ b/charts/vouch/values.yaml @@ -0,0 +1,212 @@ +# Default values for vouch. +# This is a YAML-formatted file. +# Declare variables to be passed into your templates. + +global: + serviceAccount: + create: true + ## Pod Security Context + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/ + ## + podSecurityContext: + runAsNonRoot: true + runAsUser: 10000 + fsGroup: 10000 + + securityContext: + readOnlyRootFilesystem: true + runAsNonRoot: true + runAsUser: 10000 + capabilities: + drop: + - ALL + +image: + repository: attestant/vouch + pullPolicy: IfNotPresent + # Overrides the image tag whose default is the chart appVersion. + tag: "1.8.0" + +## Init image is used to chown data volume, etc. +## +initImage: + repository: nethermindeth/bash + tag: "5.2-alpine3.19" + pullPolicy: IfNotPresent + +cliImage: + repository: nethermindeth/keystores-cli + tag: "v1.0.0" + pullPolicy: IfNotPresent + +externalSecrets: + enabled: false + secretStoreRef: + name: secretStoreRef + kind: SecretStore + dataFrom: + key: vouch + +gasLimit: + +vouchDataDir: /data/vouch + +# use vouchFullConfig: to provide all vouch.yaml values +# use vouch: to populate good defaults and to do minimal changes +vouchFullConfig: +vouch: + beaconnodeaddress: localhost:5052 + beaconnodeaddresses: + - localhost:5051 + - localhost:5052 + loglevel: 'debug' + graffiti: + static: + value: 'My graffiti' + accountmanager: + dirk: + endpoints: + - dirk-1:8881 + - dirk-2:8881 + - dirk-3:8881 + accounts: + - Validators + timeout: 1m + feerecipient: + defaultaddress: '0x0000000000000000000000000000000000000001' + metrics: + prometheus: + loglevel: 'trace' + listenaddress: '0.0.0.0:8081' + blockrelay: + listen-address: '0.0.0.0:18550' + fallbackfeerecipient: '0x0000000000000000000000000000000000000001' + tracing: + strategies: + submitter: + +relays: [] + +imagePullSecrets: [] + +## Provide a name in place of operator for `app:` labels +## +nameOverride: "" + +## Provide a name to substitute for the full names of resources +## +fullnameOverride: "" + +## Sets logging verbosity. +## Log levels are OFF, FATAL, WARN, INFO, DEBUG, TRACE, ALL. +loggingLevel: "INFO" + +## By default, Vouch's MEV-boost service listens on port 18550. Beacon nodes used by Vouch should be configured to talk directly to this, rather than other MEV-boost services or directly to relays. +blockRelayPort: 18550 + +## Port on which vouch HTTP listens. +## +httpPort: 8881 + +## The port (TCP) on which Prometheus accesses metrics +## +metricsPort: 8081 + +livenessProbe: + initialDelaySeconds: 60 + timeoutSeconds: 3 + periodSeconds: 10 + failureThreshold: 3 + successThreshold: 1 + httpGet: + path: /metrics + port: metrics + scheme: HTTP + +readinessProbe: + enabled: true + initialDelaySeconds: 10 + timeoutSeconds: 3 + periodSeconds: 5 + failureThreshold: 3 + successThreshold: 2 + httpGet: + path: /metrics + port: metrics + scheme: HTTP + + +## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ +## +serviceAccount: + # Annotations to add to the service account + annotations: {} + # The name of the service account to use. + # If not set and create is true, a name is generated using the fullname template + name: "" + +podAnnotations: {} + +service: + type: ClusterIP + httpPort: 8881 + +## Configure resource requests and limits. +## ref: http://kubernetes.io/docs/user-guide/compute-resources/ +## +resources: {} + # We usually recommend not to specify default resources and to leave this as a conscious + # choice for the user. This also increases chances charts run on environments with little + # resources, such as Minikube. If you do want to specify resources, uncomment the following + # lines, adjust them as necessary, and remove the curly braces after 'resources:'. + # limits: + # cpu: 100m + # memory: 128Mi + # requests: + # cpu: 100m + # memory: 128Mi + +## Node labels for pod assignment +## ref: https://kubernetes.io/docs/user-guide/node-selection/ +## +nodeSelector: {} + +## Tolerations for pod assignment +## ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/ +## +tolerations: {} + +## Affinity for pod assignment +## ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity +## +affinity: {} + +## Prometheus Service Monitor +## ref: https://github.com/coreos/prometheus-operator +## https://github.com/coreos/prometheus-operator/blob/master/Documentation/api.md#endpoint +## +serviceMonitor: + ## @param metrics.serviceMonitor.enabled Create ServiceMonitor resource(s) for scraping metrics using PrometheusOperator + ## + enabled: false + ## @param metrics.serviceMonitor.namespace The namespace in which the ServiceMonitor will be created + ## + namespace: "" + ## @param metrics.serviceMonitor.interval The interval at which metrics should be scraped + ## + interval: 30s + ## @param metrics.serviceMonitor.scrapeTimeout The timeout after which the scrape is ended + ## + scrapeTimeout: "" + ## @param metrics.serviceMonitor.relabellings Metrics RelabelConfigs to apply to samples before scraping. + ## + relabellings: [] + ## @param metrics.serviceMonitor.metricRelabelings Metrics RelabelConfigs to apply to samples before ingestion. + ## + metricRelabelings: [] + ## @param metrics.serviceMonitor.honorLabels Specify honorLabels parameter to add the scrape endpoint + ## + honorLabels: false + ## @param metrics.serviceMonitor.additionalLabels Additional labels that can be used so ServiceMonitor resource(s) can be discovered by Prometheus + ## + additionalLabels: {} diff --git a/charts/web3signer/Chart.yaml b/charts/web3signer/Chart.yaml index a532cb6ea..de40fc293 100644 --- a/charts/web3signer/Chart.yaml +++ b/charts/web3signer/Chart.yaml @@ -1,37 +1,17 @@ apiVersion: v2 name: web3signer -description: A Helm chart for installing and configuring large scale ETH staking infrastructure on top of the Kubernetes - -# A chart can be either an 'application' or a 'library' chart. -# -# Application charts are a collection of templates that can be packaged into versioned archives -# to be deployed. -# -# Library charts provide useful utilities or functions for the chart developer. They're included as -# a dependency of application charts to inject those utilities and functions into the rendering -# pipeline. Library charts do not define any templates and therefore cannot be deployed. +description: A Helm chart for installing and configuring Web3signer type: application - -# This is the chart version. This version number should be incremented each time you make changes -# to the chart and its templates, including the app version. -# Versions are expected to follow Semantic Versioning (https://semver.org/) -version: 1.2.1 - -# This is the version number of the application being deployed. This version number should be -# incremented each time you make changes to the application. Versions are not expected to -# follow Semantic Versioning. They should reflect the version the application is using. -# It is recommended to use it with quotes. -appVersion: "v22.10.0" +version: 1.0.0 +appVersion: "23.11.0" keywords: + - web3signer - ethereum - blockchain - lighthouse - prysm - teku - - stakewise - -home: https://stakewise.io/ dependencies: - name: common diff --git a/charts/web3signer/migrations/V00011__bigint_indexes.sql b/charts/web3signer/migrations/V00011__bigint_indexes.sql new file mode 100644 index 000000000..ba2f81d60 --- /dev/null +++ b/charts/web3signer/migrations/V00011__bigint_indexes.sql @@ -0,0 +1,7 @@ +ALTER SEQUENCE signed_attestations_id_seq AS bigint; +ALTER TABLE signed_attestations ALTER COLUMN id TYPE bigint; + +ALTER SEQUENCE signed_blocks_id_seq AS bigint; +ALTER TABLE signed_blocks ALTER COLUMN id TYPE bigint; + +UPDATE database_version SET version = 11 WHERE id = 1; \ No newline at end of file diff --git a/charts/web3signer/migrations/V00012__add_highwatermark_metadata.sql b/charts/web3signer/migrations/V00012__add_highwatermark_metadata.sql new file mode 100644 index 000000000..0b46fc2f9 --- /dev/null +++ b/charts/web3signer/migrations/V00012__add_highwatermark_metadata.sql @@ -0,0 +1,63 @@ +ALTER TABLE metadata + ADD COLUMN high_watermark_epoch NUMERIC(20), + ADD COLUMN high_watermark_slot NUMERIC(20); + +-- inserted high watermark should be above low watermark + +CREATE OR REPLACE FUNCTION check_high_watermarks() RETURNS TRIGGER AS $$ +DECLARE + max_slot NUMERIC(20); + max_epoch NUMERIC(20); +BEGIN +SELECT MAX(slot) INTO max_slot FROM low_watermarks; +SELECT GREATEST(MAX(target_epoch), MAX(source_epoch)) INTO max_epoch FROM low_watermarks; + +IF NEW.high_watermark_slot <= max_slot THEN + RAISE EXCEPTION 'Insert/Update violates constraint: high_watermark_slot must be greater than max slot in low_watermarks table'; +END IF; + +IF NEW.high_watermark_epoch <= max_epoch THEN + RAISE EXCEPTION 'Insert/Update violates constraint: high_watermark_epoch must be greater than max epoch in low_watermarks table'; +END IF; + +RETURN NEW; +END; +$$ LANGUAGE plpgsql; + +CREATE TRIGGER check_before_insert_or_update_high_watermarks + BEFORE INSERT OR UPDATE ON metadata + FOR EACH ROW EXECUTE PROCEDURE check_high_watermarks(); + + +-- inserted low watermark should be below or the same as high watermark + +CREATE OR REPLACE FUNCTION check_low_watermarks() RETURNS TRIGGER AS $$ +DECLARE + high_slot NUMERIC(20); + high_epoch NUMERIC(20); +BEGIN +SELECT MIN(high_watermark_slot) INTO high_slot FROM metadata; +SELECT MIN(high_watermark_epoch) INTO high_epoch FROM metadata; + +IF NEW.slot > high_slot THEN + RAISE EXCEPTION 'Insert/Update violates constraint: low_watermark slot must be less than or equal to high_watermark_slot in the metadata table'; +END IF; + +IF NEW.source_epoch > high_epoch THEN + RAISE EXCEPTION 'Insert/Update violates constraint: low_watermark source epoch must be less than or equal to high_watermark_epoch in the metadata table'; +END IF; + +IF NEW.target_epoch > high_epoch THEN + RAISE EXCEPTION 'Insert/Update violates constraint: low_watermark target epoch must be less than or equal to high_watermark_epoch in the metadata table'; +END IF; + +RETURN NEW; +END; +$$ LANGUAGE plpgsql; + +CREATE TRIGGER check_before_insert_or_update_low_watermarks + BEFORE INSERT OR UPDATE ON low_watermarks + FOR EACH ROW EXECUTE PROCEDURE check_low_watermarks(); + + +UPDATE database_version SET version = 12 WHERE id = 1; \ No newline at end of file diff --git a/charts/web3signer/templates/configmap.yaml b/charts/web3signer/templates/configmap.yaml index 27b2b890f..8d1cc478f 100644 --- a/charts/web3signer/templates/configmap.yaml +++ b/charts/web3signer/templates/configmap.yaml @@ -15,9 +15,6 @@ data: eth2.slashing-protection-pruning-epochs-to-keep: {{ .Values.pruningEpochToKeep }} eth2.slashing-protection-pruning-interval: {{ .Values.pruningInterval }} eth2.slashing-protection-pruning-slots-per-epoch: {{ .Values.slotsPerEpoch }} - eth2.slashing-protection-db-username: {{ .Values.dbUsername }} - eth2.slashing-protection-db-password: {{ .Values.dbPassword }} - eth2.slashing-protection-db-url: {{ .Values.dbUrl }} metrics-enabled: true metrics-host: "0.0.0.0" metrics-port: {{ .Values.metricsPort }} diff --git a/charts/web3signer/templates/external-secret.yaml b/charts/web3signer/templates/external-secret.yaml new file mode 100644 index 000000000..831ae99b9 --- /dev/null +++ b/charts/web3signer/templates/external-secret.yaml @@ -0,0 +1,46 @@ +{{- if .Values.externalSecrets.enabled }} +apiVersion: external-secrets.io/v1beta1 +kind: ExternalSecret +metadata: + name: eso-{{ include "common.names.fullname" . }} + labels: + {{- include "common.labels.standard" . | nindent 4 }} +spec: + refreshInterval: 10m + secretStoreRef: + name: {{ .Values.externalSecrets.secretStoreRef.name }} + kind: {{ .Values.externalSecrets.secretStoreRef.kind }} + target: + name: eso-{{ include "common.names.fullname" . }} + creationPolicy: Owner + data: + {{- if empty .Values.externalSecrets.data }} + - secretKey: ESO_DECRYPTION_KEY + remoteRef: + key: staking-{{ .Values.global.label }}-external-secrets + property: decryptionKey + - secretKey: ESO_DB_KEYSTORE_URL + remoteRef: + key: staking-{{ .Values.global.label }}-external-secrets + property: dbKeystoreUrl + - secretKey: ESO_DB_URL + remoteRef: + key: staking-{{ .Values.global.label }}-external-secrets + property: dbUrl + - secretKey: ESO_DB_USERNAME + remoteRef: + key: staking-{{ .Values.global.label }}-external-secrets + property: dbUsername + - secretKey: ESO_DB_PASSWORD + remoteRef: + key: staking-{{ .Values.global.label }}-external-secrets + property: dbPassword + {{- else }} + {{- range .Values.externalSecrets.data }} + - secretKey: {{ .secretKey }} + remoteRef: + key: {{ .remoteRef.key }} + property: {{ .remoteRef.property }} + {{- end }} +{{- end }} +{{- end }} diff --git a/charts/web3signer/templates/service.yaml b/charts/web3signer/templates/service.yaml index d1216e382..d20b7a78d 100644 --- a/charts/web3signer/templates/service.yaml +++ b/charts/web3signer/templates/service.yaml @@ -4,6 +4,8 @@ metadata: name: {{ include "web3signer.fullname" . }} labels: {{- include "web3signer.labels" . | nindent 4 }} + annotations: + prometheus.io/probe: "true" spec: type: {{ .Values.service.type }} ports: diff --git a/charts/web3signer/templates/statefulset.yaml b/charts/web3signer/templates/statefulset.yaml index 65fbc1dee..fb651564f 100644 --- a/charts/web3signer/templates/statefulset.yaml +++ b/charts/web3signer/templates/statefulset.yaml @@ -37,31 +37,22 @@ spec: {{- end }} serviceAccountName: {{ include "web3signer.serviceAccountName" . }} securityContext: - {{- toYaml .Values.podSecurityContext | nindent 8 }} + {{- toYaml .Values.global.podSecurityContext | nindent 8 }} initContainers: - name: init image: "{{ .Values.initImage.repository }}:{{ .Values.initImage.tag }}" imagePullPolicy: {{ .Values.initImage.pullPolicy }} securityContext: - runAsUser: 0 + {{- toYaml .Values.global.securityContext | nindent 12 }} command: - sh - -ac - > mkdir -p /data/web3signer /data/keystore; - chown -R {{ .Values.podSecurityContext.runAsUser }}:{{ .Values.podSecurityContext.fsGroup }} /data/web3signer - volumeMounts: - - name: data - mountPath: /data - - name: fetch-keys - image: "{{ .Values.cliImage.repository }}:{{ .Values.cliImage.tag }}" - imagePullPolicy: {{ .Values.cliImage.pullPolicy }} - securityContext: - runAsUser: 0 + chown -R {{ .Values.global.podSecurityContext.runAsUser }}:{{ .Values.global.podSecurityContext.fsGroup }} /data/web3signer envFrom: - secretRef: - name: {{ include "common.names.fullname" . }} - args: ["sync-web3signer-keys", "--db-url", "{{ .Values.dbKeystoreUrl }}", "--output-dir", "/data/keystore"] + name: eso-{{ include "common.names.fullname" . }} volumeMounts: - name: data mountPath: /data @@ -69,27 +60,55 @@ spec: image: "{{ .Values.flywayImage.repository }}:{{ .Values.flywayImage.tag }}" imagePullPolicy: {{ .Values.flywayImage.pullPolicy }} securityContext: - runAsUser: 0 + {{- toYaml .Values.global.securityContext | nindent 12 }} args: - - -user={{ .Values.dbUsername }} - - -password={{ .Values.dbPassword }} - - -url={{ .Values.dbUrl }} + - -user=$(ESO_DB_USERNAME) + - -password=$(ESO_DB_PASSWORD) + - -url=$(ESO_DB_URL) - migrate + envFrom: + - secretRef: + name: eso-{{ include "common.names.fullname" . }} volumeMounts: - name: migrations mountPath: /flyway/sql + - name: fetch-keys + image: "{{ .Values.cliImage.repository }}:{{ .Values.cliImage.tag }}" + imagePullPolicy: {{ .Values.cliImage.pullPolicy }} + securityContext: + {{- toYaml .Values.global.securityContext | nindent 12 }} + envFrom: + - secretRef: + name: eso-{{ include "common.names.fullname" . }} + args: ["sync-web3signer-keys", "--db-url", $(ESO_DB_KEYSTORE_URL), "--output-dir", "/data/keystore", "--decryption-key-env", "ESO_DECRYPTION_KEY"] + volumeMounts: + - name: data + mountPath: /data containers: - name: {{ .Chart.Name }} securityContext: - {{- toYaml .Values.securityContext | nindent 12 }} + readOnlyRootFilesystem: false + runAsNonRoot: true + runAsUser: 10000 + capabilities: + drop: + - ALL image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}" imagePullPolicy: {{ .Values.image.pullPolicy }} args: - --config-file=/config/config.yaml + - --logging={{ .Values.loggingLevel }} + - --idle-connection-timeout-seconds={{ .Values.idleTimeout }} - eth2 + - --slashing-protection-db-url=$(ESO_DB_URL) + - --slashing-protection-db-username=$(ESO_DB_USERNAME) + - --slashing-protection-db-password=$(ESO_DB_PASSWORD) env: - name: JAVA_OPTS value: {{ .Values.web3signerJavaOpts | quote }} + envFrom: + - secretRef: + name: eso-{{ include "common.names.fullname" . }} ports: - name: http containerPort: {{ .Values.httpPort }} @@ -122,6 +141,20 @@ spec: mountPath: /data - name: config mountPath: /config + {{- if .Values.enableReloader }} + - name: fetch-keys-reloader + image: "{{ .Values.cliImage.repository }}:{{ .Values.cliImage.tag }}" + imagePullPolicy: {{ .Values.cliImage.pullPolicy }} + securityContext: + {{- toYaml .Values.global.securityContext | nindent 12 }} + envFrom: + - secretRef: + name: eso-{{ include "common.names.fullname" . }} + args: ["sync-web3signer-keys", "--db-url", $(ESO_DB_KEYSTORE_URL), "--output-dir", "/data/keystore", "--decryption-key-env", "ESO_DECRYPTION_KEY", "--refresh-frequency", "60"] + volumeMounts: + - name: data + mountPath: /data + {{- end }} volumes: - name: config configMap: @@ -132,4 +165,4 @@ spec: - name: data emptyDir: medium: Memory - sizeLimit: 128Mi \ No newline at end of file + sizeLimit: {{ .Values.tmpfsSize }} \ No newline at end of file diff --git a/charts/web3signer/values.yaml b/charts/web3signer/values.yaml index a4e7b31a5..120cd068f 100644 --- a/charts/web3signer/values.yaml +++ b/charts/web3signer/values.yaml @@ -3,44 +3,72 @@ # Declare variables to be passed into your templates. global: + label: "" serviceAccount: create: true + ## Pod Security Context + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/ + ## + podSecurityContext: + runAsNonRoot: true + runAsUser: 10000 + fsGroup: 10000 + + securityContext: + readOnlyRootFilesystem: true + runAsNonRoot: true + runAsUser: 10000 + capabilities: + drop: + - ALL replicaCount: 3 +idleTimeout: 30 + +tmpfsSize: 128Mi + image: repository: consensys/web3signer pullPolicy: IfNotPresent # Overrides the image tag whose default is the chart appVersion. - tag: "22.10.0" + tag: "23.11.0" ## Init image is used to chown data volume, etc. ## initImage: repository: busybox - tag: "1.34" + tag: "1.36" pullPolicy: IfNotPresent ## CLI image is used to fetch private keys. ## cliImage: - repository: europe-west4-docker.pkg.dev/stakewiselabs/public/cli - tag: "v1.1.10" + repository: nethermindeth/keystores-cli + tag: "v1.0.0" pullPolicy: IfNotPresent -## Database connection string, ex. 'postgresql://username:pass@hostname/dbname' -## -dbKeystoreUrl: "" -## The key for decrypting private keys is generated with stakewise-cli sync-db command -## -decryptionKey: "" +enableReloader: false + +# dbKeystoreUrl: "postgresql://username:pass@hostname/dbname" +# decryptionKey: "generated with stakewise-cli sync-db" +# dbUrl: "jdbc:postgresql://localhost/web3signer" +# dbUsername: "" +# dbPassword: "" + +externalSecrets: + enabled: true + secretStoreRef: + name: secretStoreName + kind: secretStoreKind + data: [] ## Flyawy image is used to apply database migrations ## flywayImage: repository: flyway/flyway - tag: "8.5.8-alpine" + tag: "9.3" pullPolicy: IfNotPresent imagePullSecrets: [] @@ -79,18 +107,6 @@ pruningInterval: 24 ## slotsPerEpoch: 32 -## The Java Database Connectivity (JDBC) URL of the slashing protection database. -## -dbUrl: "jdbc:postgresql://localhost/web3signer" - -## The username to use when connecting to the slashing protection database. -## -dbUsername: "" - -## The password to connect to the slashing protection database. -## -dbPassword: "" - ## Port on which Web3Signer HTTP listens. ## httpPort: 6174 @@ -115,21 +131,6 @@ serviceAccount: podAnnotations: {} -## Pod Security Context -## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/ -## -podSecurityContext: - fsGroup: 1000 - runAsUser: 1000 - -securityContext: {} - # capabilities: - # drop: - # - ALL - # readOnlyRootFilesystem: true - # runAsNonRoot: true - # runAsUser: 1000 - service: type: ClusterIP port: 80 diff --git a/charts/whitelist/.helmignore b/charts/whitelist/.helmignore deleted file mode 100644 index 0e8a0eb36..000000000 --- a/charts/whitelist/.helmignore +++ /dev/null @@ -1,23 +0,0 @@ -# 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/ diff --git a/charts/whitelist/Chart.lock b/charts/whitelist/Chart.lock deleted file mode 100644 index 4e18ab296..000000000 --- a/charts/whitelist/Chart.lock +++ /dev/null @@ -1,6 +0,0 @@ -dependencies: -- name: common - repository: file://../common - version: 1.0.0 -digest: sha256:07cebde439abe4ba19bb28e844b7419dab83c7f613886416aaf3ec08e8059144 -generated: "2022-06-03T14:42:55.115302741+03:00" diff --git a/charts/whitelist/Chart.yaml b/charts/whitelist/Chart.yaml deleted file mode 100644 index 580f2ee61..000000000 --- a/charts/whitelist/Chart.yaml +++ /dev/null @@ -1,29 +0,0 @@ -apiVersion: v2 -name: whitelist -description: Harbour whitelist service helm chart for Kubernetes - -# A chart can be either an 'application' or a 'library' chart. -# -# Application charts are a collection of templates that can be packaged into versioned archives -# to be deployed. -# -# Library charts provide useful utilities or functions for the chart developer. They're included as -# a dependency of application charts to inject those utilities and functions into the rendering -# pipeline. Library charts do not define any templates and therefore cannot be deployed. -type: application - -# This is the chart version. This version number should be incremented each time you make changes -# to the chart and its templates, including the app version. -# Versions are expected to follow Semantic Versioning (https://semver.org/) -version: 1.0.1 - -# This is the version number of the application being deployed. This version number should be -# incremented each time you make changes to the application. Versions are not expected to -# follow Semantic Versioning. They should reflect the version the application is using. -# It is recommended to use it with quotes. -appVersion: "v1.0.3" - -dependencies: -- name: common - repository: file://../common - version: 1.0.0 diff --git a/charts/whitelist/templates/NOTES.txt b/charts/whitelist/templates/NOTES.txt deleted file mode 100644 index e19f5e56e..000000000 --- a/charts/whitelist/templates/NOTES.txt +++ /dev/null @@ -1,22 +0,0 @@ -1. Get the application URL by running these commands: -{{- if .Values.ingress.enabled }} -{{- range $host := .Values.ingress.hosts }} - {{- range .paths }} - http{{ if $.Values.ingress.tls }}s{{ end }}://{{ $host.host }}{{ .path }} - {{- end }} -{{- end }} -{{- else if contains "NodePort" .Values.service.type }} - export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include "common.names.fullname" . }}) - export NODE_IP=$(kubectl get nodes --namespace {{ .Release.Namespace }} -o jsonpath="{.items[0].status.addresses[0].address}") - echo http://$NODE_IP:$NODE_PORT -{{- else if contains "LoadBalancer" .Values.service.type }} - NOTE: It may take a few minutes for the LoadBalancer IP to be available. - You can watch the status of by running 'kubectl get --namespace {{ .Release.Namespace }} svc -w {{ include "common.names.fullname" . }}' - export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ include "common.names.fullname" . }} --template "{{"{{ range (index .status.loadBalancer.ingress 0) }}{{.}}{{ end }}"}}") - echo http://$SERVICE_IP:{{ .Values.service.port }} -{{- else if contains "ClusterIP" .Values.service.type }} - export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app.kubernetes.io/name={{ include "common.names.fullname" . }},app.kubernetes.io/instance={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}") - export CONTAINER_PORT=$(kubectl get pod --namespace {{ .Release.Namespace }} $POD_NAME -o jsonpath="{.spec.containers[0].ports[0].containerPort}") - echo "Visit http://127.0.0.1:8080 to use your application" - kubectl --namespace {{ .Release.Namespace }} port-forward $POD_NAME 8080:$CONTAINER_PORT -{{- end }} diff --git a/charts/whitelist/templates/configmap.yaml b/charts/whitelist/templates/configmap.yaml deleted file mode 100644 index da0fa9074..000000000 --- a/charts/whitelist/templates/configmap.yaml +++ /dev/null @@ -1,12 +0,0 @@ -apiVersion: v1 -kind: ConfigMap -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -data: - ENABLED_NETWORKS: {{ .Values.enabledNetworks | quote }} - CONFIRMATION_BLOCKS: {{ .Values.confirmationBlocks | quote }} - TRANSACTION_TIMEOUT: {{ .Values.transactionTimeout | quote }} - HARBOUR_MAINNET_ETH1_ENDPOINT: {{ .Values.harbourMainnetEth1Endpoint | quote }} - HARBOUR_GOERLI_ETH1_ENDPOINT: {{ .Values.harbourGoerliEth1Endpoint | quote }} diff --git a/charts/whitelist/templates/hpa.yaml b/charts/whitelist/templates/hpa.yaml deleted file mode 100644 index 1f3aa4a38..000000000 --- a/charts/whitelist/templates/hpa.yaml +++ /dev/null @@ -1,28 +0,0 @@ -{{- if .Values.autoscaling.enabled }} -apiVersion: autoscaling/v2beta1 -kind: HorizontalPodAutoscaler -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -spec: - scaleTargetRef: - apiVersion: apps/v1 - kind: Deployment - name: {{ include "common.names.fullname" . }} - minReplicas: {{ .Values.autoscaling.minReplicas }} - maxReplicas: {{ .Values.autoscaling.maxReplicas }} - metrics: - {{- if .Values.autoscaling.targetCPUUtilizationPercentage }} - - type: Resource - resource: - name: cpu - targetAverageUtilization: {{ .Values.autoscaling.targetCPUUtilizationPercentage }} - {{- end }} - {{- if .Values.autoscaling.targetMemoryUtilizationPercentage }} - - type: Resource - resource: - name: memory - targetAverageUtilization: {{ .Values.autoscaling.targetMemoryUtilizationPercentage }} - {{- end }} -{{- end }} diff --git a/charts/whitelist/templates/secret.yaml b/charts/whitelist/templates/secret.yaml deleted file mode 100644 index 72e2a7afa..000000000 --- a/charts/whitelist/templates/secret.yaml +++ /dev/null @@ -1,11 +0,0 @@ -apiVersion: v1 -kind: Secret -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -type: Opaque -data: - API_KEY: {{ .Values.apiKey | b64enc | quote }} - HARBOUR_MAINNET_PRIVATE_KEY: {{ .Values.harbourMainnetPrivateKey | b64enc | quote }} - HARBOUR_GOERLI_PRIVATE_KEY: {{ .Values.harbourGoerliPrivateKey | b64enc | quote }} diff --git a/charts/whitelist/templates/service.yaml b/charts/whitelist/templates/service.yaml deleted file mode 100644 index 0c14a8d6f..000000000 --- a/charts/whitelist/templates/service.yaml +++ /dev/null @@ -1,15 +0,0 @@ -apiVersion: v1 -kind: Service -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -spec: - type: {{ .Values.service.type }} - ports: - - port: {{ .Values.service.port }} - targetPort: http - protocol: TCP - name: http - selector: - {{- include "common.labels.matchLabels" . | nindent 4 }} diff --git a/charts/whitelist/templates/serviceaccount.yaml b/charts/whitelist/templates/serviceaccount.yaml deleted file mode 100644 index ad5aa4d50..000000000 --- a/charts/whitelist/templates/serviceaccount.yaml +++ /dev/null @@ -1,12 +0,0 @@ -{{- if .Values.serviceAccount.create -}} -apiVersion: v1 -kind: ServiceAccount -metadata: - name: {{ include "common.names.serviceAccountName" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} - {{- with .Values.serviceAccount.annotations }} - annotations: - {{- toYaml . | nindent 4 }} - {{- end }} -{{- end }} diff --git a/charts/whitelist/templates/statefulset.yaml b/charts/whitelist/templates/statefulset.yaml deleted file mode 100644 index 2a9faa2ad..000000000 --- a/charts/whitelist/templates/statefulset.yaml +++ /dev/null @@ -1,109 +0,0 @@ -apiVersion: apps/v1 -kind: StatefulSet -metadata: - name: {{ include "common.names.fullname" . }} - labels: - {{- include "common.labels.standard" . | nindent 4 }} -spec: - {{- if not .Values.autoscaling.enabled }} - replicas: {{ .Values.replicaCount }} - {{- end }} - selector: - matchLabels: - {{- include "common.labels.matchLabels" . | nindent 6 }} - serviceName: {{ include "common.names.fullname" . }} - template: - metadata: - {{- with .Values.podAnnotations }} - annotations: - {{- toYaml . | nindent 8 }} - {{- end }} - labels: - {{- include "common.labels.matchLabels" . | nindent 8 }} - spec: - {{- with .Values.imagePullSecrets }} - imagePullSecrets: - {{- toYaml . | nindent 8 }} - {{- end }} - serviceAccountName: {{ include "common.names.serviceAccountName" . }} - securityContext: - {{- toYaml .Values.podSecurityContext | nindent 8 }} - {{- if and .Values.persistence.enabled .Values.initChownData }} - initContainers: - - name: init-chown - image: "{{ .Values.initImage.repository }}:{{ .Values.initImage.tag }}" - imagePullPolicy: {{ .Values.initImage.pullPolicy }} - securityContext: - runAsUser: 0 - command: - - /bin/sh - - -c - - chown -R {{ .Values.securityContext.runAsUser }}:{{ .Values.securityContext.runAsUser }} /data - volumeMounts: - - name: data - mountPath: /data - {{- end }} - containers: - - name: {{ .Chart.Name }} - securityContext: - {{- toYaml .Values.securityContext | nindent 12 }} - image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}" - imagePullPolicy: {{ .Values.image.pullPolicy }} - env: - - name: DATABASE_PATH - value: "/data/whitelist.db" - envFrom: - - configMapRef: - name: {{ template "common.names.fullname" . }} - - secretRef: - name: {{ template "common.names.fullname" . }} - ports: - - name: http - containerPort: {{ .Values.service.port }} - protocol: TCP - livenessProbe: - httpGet: - path: /healthz - port: http - readinessProbe: - httpGet: - path: /healthz - port: http - resources: - {{- toYaml .Values.resources | nindent 12 }} - volumeMounts: - - name: data - mountPath: /data - {{- with .Values.nodeSelector }} - nodeSelector: - {{- toYaml . | nindent 8 }} - {{- end }} - {{- with .Values.affinity }} - affinity: - {{- toYaml . | nindent 8 }} - {{- end }} - {{- with .Values.tolerations }} - tolerations: - {{- toYaml . | nindent 8 }} - {{- end }} - {{- if (not .Values.persistence.enabled) }} - volumes: - - name: data - emptyDir: {} - {{- else }} - volumeClaimTemplates: - - metadata: - name: data - labels: - {{- include "common.labels.standard" . | nindent 10 }} - {{- with .Values.persistence.annotations }} - annotations: - {{ toYaml . | nindent 10 | trim }} - {{- end }} - spec: - accessModes: {{ .Values.persistence.accessModes }} - storageClassName: {{ .Values.persistence.storageClassName }} - resources: - requests: - storage: {{ .Values.persistence.size | quote }} - {{- end }} diff --git a/charts/whitelist/templates/tests/test-connection.yaml b/charts/whitelist/templates/tests/test-connection.yaml deleted file mode 100644 index 21ee05dce..000000000 --- a/charts/whitelist/templates/tests/test-connection.yaml +++ /dev/null @@ -1,15 +0,0 @@ -apiVersion: v1 -kind: Pod -metadata: - name: "{{ include "common.names.fullname" . }}-test-connection" - labels: - {{- include "common.labels.standard" . | nindent 4 }} - annotations: - "helm.sh/hook": test -spec: - containers: - - name: wget - image: busybox - command: ['wget'] - args: ['{{ include "common.names.fullname" . }}:{{ .Values.service.port }}'] - restartPolicy: Never diff --git a/charts/whitelist/values.yaml b/charts/whitelist/values.yaml deleted file mode 100644 index 2d5d5e6db..000000000 --- a/charts/whitelist/values.yaml +++ /dev/null @@ -1,130 +0,0 @@ -# Default values for whitelist. -# This is a YAML-formatted file. -# Declare variables to be passed into your templates. - -replicaCount: 1 - -image: - repository: europe-west4-docker.pkg.dev/stakewiselabs/public/whitelist - pullPolicy: IfNotPresent - ## Overrides the image tag whose default is the chart appVersion. - ## - tag: "v1.0.3" - -imagePullSecrets: [] -nameOverride: "" -fullnameOverride: "" - -## Whitelist configuration -## -apiKey: "" -enabledNetworks: "harbour_mainnet" -confirmationBlocks: "15" -transactionTimeout: "900" -harbourMainnetEth1Endpoint: "" -harbourMainnetPrivateKey: "" -harbourGoerliEth1Endpoint: "" -harbourGoerliPrivateKey: "" - -serviceAccount: - ## Specifies whether a service account should be created - ## - create: true - ## Annotations to add to the service account - ## - annotations: {} - ## The name of the service account to use. - ## If not set and create is true, a name is generated using the fullname template - ## - name: "" - -podAnnotations: {} - -podSecurityContext: {} - # fsGroup: 2000 - -securityContext: {} - # capabilities: - # drop: - # - ALL - # readOnlyRootFilesystem: true - # runAsNonRoot: true - # runAsUser: 1000 - -service: - type: ClusterIP - port: 8000 - -ingress: - enabled: false - className: "" - annotations: {} - # kubernetes.io/ingress.class: nginx - # kubernetes.io/tls-acme: "true" - hosts: - - host: chart-example.local - paths: - - path: / - pathType: ImplementationSpecific - tls: [] - # - secretName: chart-example-tls - # hosts: - # - chart-example.local - -resources: {} - ## We usually recommend not to specify default resources and to leave this as a conscious - ## choice for the user. This also increases chances charts run on environments with little - ## resources, such as Minikube. If you do want to specify resources, uncomment the following - ## lines, adjust them as necessary, and remove the curly braces after 'resources:'. - ## limits: - ## cpu: 100m - ## memory: 128Mi - ## requests: - ## cpu: 100m - ## memory: 128Mi - ## - -autoscaling: - enabled: false - minReplicas: 1 - maxReplicas: 100 - targetCPUUtilizationPercentage: 80 - # targetMemoryUtilizationPercentage: 80 - -## Node labels for pod assignment -## ref: https://kubernetes.io/docs/user-guide/node-selection/ -## -nodeSelector: {} - -## Tolerations for pod assignment -## ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/ -## -tolerations: [] - -## Affinity for pod assignment -## ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity -## -affinity: {} - -## Init image is used to chown data volume, initialise genesis, etc. -## -initImage: - repository: "busybox" - tag: "1.34" - pullPolicy: IfNotPresent - -## If false, data ownership will not be reset at startup -## This allows the geth node to be run with an arbitrary user -## -initChownData: true - -## Whether or not to allocate persistent volume disk for the data directory. -## In case of pod failure, the pod data directory will still persist. -## -persistence: - enabled: true - storageClassName: "" - accessModes: - - ReadWriteOnce - size: 1Gi - annotations: {}