diff --git a/.github/workflows/test-charts.yaml b/.github/workflows/test-charts.yaml index e41eb5ca..c6b399c9 100644 --- a/.github/workflows/test-charts.yaml +++ b/.github/workflows/test-charts.yaml @@ -66,4 +66,5 @@ jobs: --excluded-charts beacon-metrics-gazer --excluded-charts tracoor-server --excluded-charts tracoor-agent + --excluded-charts tracoor-single --excluded-charts xatu-cl-mimicry diff --git a/README.md b/README.md index 55e4e751..35a06e10 100644 --- a/README.md +++ b/README.md @@ -93,6 +93,9 @@ Tooling - [`stubbies`](charts/stubbies) - Ethereum execution client stub for consensus layer clients. - [`testnet-faucet`](charts/testnet-faucet) - Web faucet that can be used to distribute testnet ETH to users. - [`testnet-homepage`](charts/testnet-homepage) - Simple website that can be used to display useful information about your testnet. +- [`tracoor-single`](charts/tracoor-single) - An Ethereum beacon data and execution trace explorer in single mode. +- [`tracoor-server`](charts/tracoor-server) - An Ethereum beacon data and execution trace explorer in server mode. +- [`tracoor-agent`](charts/tracoor-agent) - An Ethereum beacon data and execution trace explorer in agent mode. - [`web3signer`](charts/web3signer) - An open-source remote signing service. - [`xatu-discovery`](charts/xatu-discovery) - Ethereum p2p monitoring tool that discovers node records. - [`xatu-mimicry`](charts/xatu-mimicry) - Ethereum p2p monitoring tool that collects data from the execution layer. diff --git a/charts/assertoor/Chart.yaml b/charts/assertoor/Chart.yaml index 8ada6ba2..272d21e3 100644 --- a/charts/assertoor/Chart.yaml +++ b/charts/assertoor/Chart.yaml @@ -6,7 +6,7 @@ home: https://github.com/ethpandaops/assertoor sources: - https://github.com/ethpandaops/assertoor type: application -version: 0.0.1 +version: 0.0.4 appVersion: "1.0.0" maintainers: - name: pk910 diff --git a/charts/assertoor/README.md b/charts/assertoor/README.md index 45b18432..4903e00c 100644 --- a/charts/assertoor/README.md +++ b/charts/assertoor/README.md @@ -1,7 +1,7 @@ # assertoor -![Version: 0.0.1](https://img.shields.io/badge/Version-0.0.1-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) +![Version: 0.0.4](https://img.shields.io/badge/Version-0.0.4-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) Testing tool that is capable of doing actions and checking conditions on ethereum pos networks. @@ -69,7 +69,8 @@ assertoorTests: | extraVolumes | list | `[]` | Additional volumes | | fullnameOverride | string | `""` | Overrides the chart's computed fullname | | globalVariables | object | `{"walletPrivkey":"feedbeef12340000feedbeef12340000feedbeef12340000feedbeef12340000"}` | global assertoor variables -- global variables are passed to all tests. | -| httpPort | int | `8080` | HTTP port for assertoor interface | +| httpPort | int | `8082` | HTTP port for assertoor interface | +| httpPortAdmin | int | `8080` | HTTP port for assertoor admin interface | | image.pullPolicy | string | `"IfNotPresent"` | assertoor container pull policy | | image.repository | string | `"ethpandaops/assertoor"` | assertoor container image repository | | image.tag | string | `"latest"` | assertoor container image tag | @@ -78,6 +79,11 @@ assertoorTests: | ingress.hosts[0].host | string | `"chart-example.local"` | | | ingress.hosts[0].paths | list | `[]` | | | ingress.tls | list | `[]` | Ingress TLS | +| ingressAdmin.annotations | object | `{}` | Annotations for Ingress | +| ingressAdmin.enabled | bool | `false` | Ingress resource for the HTTP API -- This is the admin interface -- Please ensure you put this behind authorization | +| ingressAdmin.hosts[0].host | string | `"chart-example-admin.local"` | | +| ingressAdmin.hosts[0].paths | list | `[]` | | +| ingressAdmin.tls | list | `[]` | Ingress TLS | | initContainers | list | `[]` | Additional init containers | | nameOverride | string | `""` | Overrides the chart's name | | nodeSelector | object | `{}` | Node selector for pods | diff --git a/charts/assertoor/templates/_helpers.tpl b/charts/assertoor/templates/_helpers.tpl index 01d5b2d0..a903000d 100644 --- a/charts/assertoor/templates/_helpers.tpl +++ b/charts/assertoor/templates/_helpers.tpl @@ -62,5 +62,9 @@ Create the name of the service account to use {{- end }} {{- define "assertoor.httpPort" -}} +{{- printf "8082" -}} +{{- end -}} + +{{- define "assertoor.httpPortAdmin" -}} {{- printf "8080" -}} {{- end -}} diff --git a/charts/assertoor/templates/deployment.yaml b/charts/assertoor/templates/deployment.yaml index 9170a9d6..fe0c6f7f 100644 --- a/charts/assertoor/templates/deployment.yaml +++ b/charts/assertoor/templates/deployment.yaml @@ -64,6 +64,9 @@ spec: - name: http containerPort: {{ include "assertoor.httpPort" . }} protocol: TCP + - name: http-admin + containerPort: {{ include "assertoor.httpPortAdmin" . }} + protocol: TCP resources: {{- toYaml .Values.resources | nindent 12 }} env: diff --git a/charts/assertoor/templates/ingress.yaml b/charts/assertoor/templates/ingress.yaml index be5aa9c0..255b5667 100644 --- a/charts/assertoor/templates/ingress.yaml +++ b/charts/assertoor/templates/ingress.yaml @@ -1,6 +1,6 @@ {{- if .Values.ingress.enabled -}} {{- $fullName := include "assertoor.fullname" . -}} -{{- $svcPort := include "assertoor.httpPort" . -}} +{{- $svcPortPublic := include "assertoor.httpPort" . -}} {{- 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}} @@ -51,10 +51,72 @@ spec: service: name: {{ $fullName }} port: - number: {{ $svcPort }} + number: {{ $svcPortPublic }} {{- else }} serviceName: {{ $fullName }} - servicePort: {{ $svcPort }} + servicePort: {{ $svcPortPublic }} + {{- end }} + {{- end }} + {{- end }} +{{- end }} +--- +{{- if .Values.ingressAdmin.enabled -}} +{{- $fullName := include "assertoor.fullname" . -}} +{{- $svcPortAdmin := include "assertoor.httpPortAdmin" . -}} +{{- if and .Values.ingressAdmin.className (not (semverCompare ">=1.18-0" .Capabilities.KubeVersion.GitVersion)) }} + {{- if not (hasKey .Values.ingressAdmin.annotations "kubernetes.io/ingress.class") }} + {{- $_ := set .Values.ingressAdmin.annotations "kubernetes.io/ingress.class" .Values.ingressAdmin.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 }}-admin + labels: + {{- include "assertoor.labels" . | nindent 4 }} + {{- with .Values.ingressAdmin.annotations }} + annotations: + {{- toYaml . | nindent 4 }} + {{- end }} +spec: + {{- if and .Values.ingressAdmin.className (semverCompare ">=1.18-0" .Capabilities.KubeVersion.GitVersion) }} + ingressClassName: {{ .Values.ingressAdmin.className }} + {{- end }} + {{- if .Values.ingressAdmin.tls }} + tls: + {{- range .Values.ingressAdmin.tls }} + - hosts: + {{- range .hosts }} + - {{ . | quote }} + {{- end }} + secretName: {{ .secretName }} + {{- end }} + {{- end }} + rules: + {{- range .Values.ingressAdmin.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: {{ $svcPortAdmin }} + {{- else }} + serviceName: {{ $fullName }} + servicePort: {{ $svcPortAdmin }} {{- end }} {{- end }} {{- end }} diff --git a/charts/assertoor/templates/service.yaml b/charts/assertoor/templates/service.yaml index 5d048046..4537b25a 100644 --- a/charts/assertoor/templates/service.yaml +++ b/charts/assertoor/templates/service.yaml @@ -11,6 +11,10 @@ spec: targetPort: http protocol: TCP name: http + - port: {{ include "assertoor.httpPortAdmin" . }} + targetPort: http-admin + protocol: TCP + name: http-admin {{- if .Values.extraPorts }} {{ toYaml .Values.extraPorts | nindent 4}} {{- end }} diff --git a/charts/assertoor/templates/tests/test-connection.yaml b/charts/assertoor/templates/tests/test-connection.yaml index cfd651b0..c24424e1 100644 --- a/charts/assertoor/templates/tests/test-connection.yaml +++ b/charts/assertoor/templates/tests/test-connection.yaml @@ -15,5 +15,5 @@ spec: - --location - --request - GET - - '{{ include "assertoor.fullname" . }}:{{ include "assertoor.httpPort" . }}/' + - '{{ include "assertoor.fullname" . }}:{{ include "assertoor.httpPortAdmin" . }}/' restartPolicy: Never diff --git a/charts/assertoor/values.yaml b/charts/assertoor/values.yaml index 8fb875ad..449a3a97 100644 --- a/charts/assertoor/values.yaml +++ b/charts/assertoor/values.yaml @@ -26,7 +26,7 @@ ingress: annotations: {} # kubernetes.io/ingress.class: nginx # kubernetes.io/tls-acme: "true" - # -- Ingress host + # -- Ingress host for public service hosts: - host: chart-example.local paths: [] @@ -36,6 +36,25 @@ ingress: # hosts: # - chart-example.local +ingressAdmin: + # -- Ingress resource for the HTTP API + # -- This is the admin interface + # -- Please ensure you put this behind authorization + enabled: false + # -- Annotations for Ingress + annotations: {} + # kubernetes.io/ingress.class: nginx + # kubernetes.io/tls-acme: "true" + # -- Ingress host for admin service + hosts: + - host: chart-example-admin.local + paths: [] + # -- Ingress TLS + tls: [] + # - secretName: chart-example-tls + # hosts: + # - chart-example.local + service: # -- Service type type: ClusterIP @@ -135,7 +154,10 @@ extraEnv: [] # -- HTTP port for assertoor interface -httpPort: 8080 +httpPort: 8082 + +# -- HTTP port for assertoor admin interface +httpPortAdmin: 8080 # -- An array of endpoints to use for assertoor # -- executionUrl & consensusUrl are the only required fields @@ -178,6 +200,9 @@ assertoorTests: [] config: | web: server: + host: "0.0.0.0" + port: {{ .Values.httpPortAdmin }} + publicServer: host: "0.0.0.0" port: {{ .Values.httpPort }} frontend: @@ -213,7 +238,7 @@ config: | inventoryUrl: "{{ .Values.validatorNamesInventory }}" globalVars: - {{- toYaml .globalVariables | nindent 2 }} + {{- toYaml .Values.globalVariables | nindent 2 }} # Test definitions externalTests: diff --git a/charts/blockscout/Chart.yaml b/charts/blockscout/Chart.yaml index d9946849..ce7e8d9a 100644 --- a/charts/blockscout/Chart.yaml +++ b/charts/blockscout/Chart.yaml @@ -8,7 +8,7 @@ icon: https://github.com/blockscout/blockscout/raw/master/apps/block_scout_web/a sources: - https://github.com/blockscout/blockscout/ type: application -version: 0.2.1 +version: 0.2.2 maintainers: - name: skylenet email: rafael@skyle.net diff --git a/charts/blockscout/README.md b/charts/blockscout/README.md index 3cc3d655..767b0b6c 100644 --- a/charts/blockscout/README.md +++ b/charts/blockscout/README.md @@ -1,7 +1,7 @@ # blockscout -![Version: 0.2.1](https://img.shields.io/badge/Version-0.2.1-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) +![Version: 0.2.2](https://img.shields.io/badge/Version-0.2.2-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) BlockScout provides a comprehensive, easy-to-use interface for users to view, confirm, and inspect transactions on EVM (Ethereum Virtual Machine) blockchains @@ -60,9 +60,9 @@ BlockScout provides a comprehensive, easy-to-use interface for users to view, co | postgresql.image.registry | string | `"docker.io"` | | | postgresql.image.repository | string | `"bitnami/postgresql"` | | | postgresql.image.tag | string | `"15.3.0-debian-11-r7"` | | -| postgresql.persistence.enabled | bool | `true` | | -| postgresql.persistence.size | string | `"8Gi"` | | | postgresql.primary.extendedConfiguration | string | `"max_connections = 1024\n"` | | +| postgresql.primary.persistence.enabled | bool | `true` | | +| postgresql.primary.persistence.size | string | `"8Gi"` | | | postgresql.pullPolicy | string | `"IfNotPresent"` | | | priorityClassName | string | `nil` | Pod priority class | | readinessProbe | object | See `values.yaml` | Readiness probe | diff --git a/charts/blockscout/values.yaml b/charts/blockscout/values.yaml index 1bcac5df..31bae496 100644 --- a/charts/blockscout/values.yaml +++ b/charts/blockscout/values.yaml @@ -259,9 +259,9 @@ postgresql: primary: extendedConfiguration: | max_connections = 1024 - persistence: - enabled: true - size: 8Gi + persistence: + enabled: true + size: 8Gi redis: enabled: false diff --git a/charts/blutgang/Chart.yaml b/charts/blutgang/Chart.yaml index 1998f22c..37f35a67 100644 --- a/charts/blutgang/Chart.yaml +++ b/charts/blutgang/Chart.yaml @@ -8,6 +8,7 @@ sources: - https://github.com/rainshowerLabs/blutgang type: application version: 0.1.0 +version: 0.0.11 maintainers: - name: barnabasbusa email: busa.barnabas@gmail.com diff --git a/charts/blutgang/templates/deployment.yaml b/charts/blutgang/templates/deployment.yaml index a676fde3..30b50c9e 100644 --- a/charts/blutgang/templates/deployment.yaml +++ b/charts/blutgang/templates/deployment.yaml @@ -110,7 +110,8 @@ spec: name: {{ include "blutgang.fullname" . }} {{- if not .Values.persistence.enabled }} - name: storage - emptyDir: {} + emptyDir: + medium: Memory {{- else if .Values.persistence.existingClaim }} - name: storage persistentVolumeClaim: diff --git a/charts/blutgang/templates/poddisruptionbudget.yaml b/charts/blutgang/templates/poddisruptionbudget.yaml new file mode 100644 index 00000000..5e08cd04 --- /dev/null +++ b/charts/blutgang/templates/poddisruptionbudget.yaml @@ -0,0 +1,18 @@ +{{- if .Values.podDisruptionBudget }} +apiVersion: policy/v1 +kind: PodDisruptionBudget +metadata: + name: {{ include "blutgang.fullname" . }} + labels: + {{- include "blutgang.labels" . | nindent 4 }} +spec: +{{- if .Values.podDisruptionBudget.minAvailable }} + minAvailable: {{ .Values.podDisruptionBudget.minAvailable }} +{{- end }} +{{- if .Values.podDisruptionBudget.maxUnavailable }} + maxUnavailable: {{ .Values.podDisruptionBudget.maxUnavailable }} +{{- end }} + selector: + matchLabels: + {{- include "blutgang.selectorLabels" . | nindent 6 }} +{{- end }} diff --git a/charts/dugtrio/Chart.yaml b/charts/dugtrio/Chart.yaml index 1f37a984..2af65d57 100644 --- a/charts/dugtrio/Chart.yaml +++ b/charts/dugtrio/Chart.yaml @@ -6,7 +6,7 @@ home: https://github.com/ethpandaops/dugtrio sources: - https://github.com/ethpandaops/dugtrio type: application -version: 0.0.5 +version: 0.0.6 appVersion: "1.0.0" maintainers: - name: pk910 diff --git a/charts/dugtrio/README.md b/charts/dugtrio/README.md index c837fc9f..a8532261 100644 --- a/charts/dugtrio/README.md +++ b/charts/dugtrio/README.md @@ -1,7 +1,7 @@ # dugtrio -![Version: 0.0.5](https://img.shields.io/badge/Version-0.0.5-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) +![Version: 0.0.6](https://img.shields.io/badge/Version-0.0.6-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) Fault tolerant load balancer for beacon chain RPC apis @@ -50,7 +50,7 @@ endpoints: | dugtrioProxyBlockedPaths | list | `[]` | blocked proxy paths (regular expressions, eg. "^/eth/v[0-9]+/debug/.*") | | dugtrioProxyCallRateBurst | int | `1000` | dugtrio call rate burst (burst number of calls per ip) | | dugtrioProxyCallRateLimit | int | `100` | dugtrio call rate limit (number of calls per second per ip) | -| dugtrioProxyCallTimeout | string | `"55s"` | timeout for dugtrio proxy calls | +| dugtrioProxyCallTimeout | string | `"10m"` | timeout for dugtrio proxy calls | | dugtrioProxyCount | int | `1` | number of HTTP proxies in front of dugtrio | | dugtrioProxySessionTimeout | string | `"10m"` | timeout for dugtrio sessions (used for rate limiting & endpoint stickiness) | | dugtrioProxyStickyEndpoint | bool | `true` | reuse the same endpoint for sessions as long as available | diff --git a/charts/dugtrio/values.yaml b/charts/dugtrio/values.yaml index 4c7ca475..07103092 100644 --- a/charts/dugtrio/values.yaml +++ b/charts/dugtrio/values.yaml @@ -189,7 +189,7 @@ dugtrioPoolMaxHeadDistance: 2 dugtrioProxyCount: 1 # -- timeout for dugtrio proxy calls -dugtrioProxyCallTimeout: 55s +dugtrioProxyCallTimeout: 10m # -- timeout for dugtrio sessions (used for rate limiting & endpoint stickiness) dugtrioProxySessionTimeout: 10m diff --git a/charts/ethereum-address-metrics-exporter/Chart.yaml b/charts/ethereum-address-metrics-exporter/Chart.yaml index fd789cd4..1d622aed 100644 --- a/charts/ethereum-address-metrics-exporter/Chart.yaml +++ b/charts/ethereum-address-metrics-exporter/Chart.yaml @@ -3,7 +3,7 @@ name: ethereum-address-metrics-exporter description: A prometheus exporter for Ethereum externally owned account and contract addresses home: https://github.com/ethpandaops/ethereum-address-metrics-exporter type: application -version: 0.1.4 +version: 0.1.5 maintainers: - name: savid email: andrew.davis@ethereum.org diff --git a/charts/ethereum-address-metrics-exporter/README.md b/charts/ethereum-address-metrics-exporter/README.md index 95f00f14..883dc7d4 100644 --- a/charts/ethereum-address-metrics-exporter/README.md +++ b/charts/ethereum-address-metrics-exporter/README.md @@ -1,7 +1,7 @@ # ethereum-address-metrics-exporter -![Version: 0.1.4](https://img.shields.io/badge/Version-0.1.4-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) +![Version: 0.1.5](https://img.shields.io/badge/Version-0.1.5-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) A prometheus exporter for Ethereum externally owned account and contract addresses @@ -55,7 +55,7 @@ A prometheus exporter for Ethereum externally owned account and contract address | serviceAccount.name | string | `""` | The name of the service account to use. If not set and create is true, a name is generated using the fullname template | | serviceMonitor.annotations | object | `{}` | Additional ServiceMonitor annotations | | serviceMonitor.enabled | bool | `false` | If true, a ServiceMonitor CRD is created for a prometheus operator https://github.com/coreos/prometheus-operator | -| serviceMonitor.interval | string | `"15s"` | ServiceMonitor scrape interval | +| serviceMonitor.interval | string | `"1m"` | ServiceMonitor scrape interval | | serviceMonitor.labels | object | `{}` | Additional ServiceMonitor labels | | serviceMonitor.namespace | string | `nil` | Alternative namespace for ServiceMonitor | | serviceMonitor.path | string | `"/metrics"` | Path to scrape | diff --git a/charts/ethereum-address-metrics-exporter/values.yaml b/charts/ethereum-address-metrics-exporter/values.yaml index 160fc8bd..f8b8f5c0 100644 --- a/charts/ethereum-address-metrics-exporter/values.yaml +++ b/charts/ethereum-address-metrics-exporter/values.yaml @@ -180,7 +180,7 @@ serviceMonitor: # -- Additional ServiceMonitor annotations annotations: {} # -- ServiceMonitor scrape interval - interval: 15s + interval: 1m # -- ServiceMonitor scheme scheme: http # -- ServiceMonitor TLS configuration diff --git a/charts/ethereum-metrics-exporter/Chart.yaml b/charts/ethereum-metrics-exporter/Chart.yaml index 710acb06..95c5d823 100644 --- a/charts/ethereum-metrics-exporter/Chart.yaml +++ b/charts/ethereum-metrics-exporter/Chart.yaml @@ -3,7 +3,7 @@ name: ethereum-metrics-exporter description: A Prometheus metrics exporter for Ethereum consensus & execution nodes home: https://github.com/samcm/ethereum-metrics-exporter type: application -version: 0.1.4 +version: 0.1.5 maintainers: - name: samcm email: sam.calder-mason@ethereum.org diff --git a/charts/ethereum-metrics-exporter/README.md b/charts/ethereum-metrics-exporter/README.md index 9c82bacf..e18d0fe3 100644 --- a/charts/ethereum-metrics-exporter/README.md +++ b/charts/ethereum-metrics-exporter/README.md @@ -1,7 +1,7 @@ # ethereum-metrics-exporter -![Version: 0.1.4](https://img.shields.io/badge/Version-0.1.4-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) +![Version: 0.1.5](https://img.shields.io/badge/Version-0.1.5-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) A Prometheus metrics exporter for Ethereum consensus & execution nodes @@ -61,13 +61,13 @@ A Prometheus metrics exporter for Ethereum consensus & execution nodes | serviceAccount.name | string | `""` | The name of the service account to use. If not set and create is true, a name is generated using the fullname template | | serviceMonitor.annotations | object | `{}` | Additional ServiceMonitor annotations | | serviceMonitor.enabled | bool | `false` | If true, a ServiceMonitor CRD is created for a prometheus operator https://github.com/coreos/prometheus-operator | -| serviceMonitor.interval | string | `"15s"` | ServiceMonitor scrape interval | +| serviceMonitor.interval | string | `"30s"` | ServiceMonitor scrape interval | | serviceMonitor.labels | object | `{}` | Additional ServiceMonitor labels | | serviceMonitor.namespace | string | `nil` | Alternative namespace for ServiceMonitor | | serviceMonitor.path | string | `"/metrics"` | Path to scrape | | serviceMonitor.relabelings | list | `[]` | ServiceMonitor relabelings | | serviceMonitor.scheme | string | `"http"` | ServiceMonitor scheme | -| serviceMonitor.scrapeTimeout | string | `"30s"` | ServiceMonitor scrape timeout | +| serviceMonitor.scrapeTimeout | string | `"15s"` | ServiceMonitor scrape timeout | | serviceMonitor.tlsConfig | object | `{}` | ServiceMonitor TLS configuration | | terminationGracePeriodSeconds | int | `30` | How long to wait until the pod is forcefully terminated | | tolerations | list | `[]` | Tolerations for pods | diff --git a/charts/ethereum-metrics-exporter/values.yaml b/charts/ethereum-metrics-exporter/values.yaml index 62a7c86c..e13a71eb 100644 --- a/charts/ethereum-metrics-exporter/values.yaml +++ b/charts/ethereum-metrics-exporter/values.yaml @@ -187,12 +187,12 @@ serviceMonitor: # -- Additional ServiceMonitor annotations annotations: {} # -- ServiceMonitor scrape interval - interval: 15s + interval: 30s # -- ServiceMonitor scheme scheme: http # -- ServiceMonitor TLS configuration tlsConfig: {} # -- ServiceMonitor scrape timeout - scrapeTimeout: 30s + scrapeTimeout: 15s # -- ServiceMonitor relabelings relabelings: [] diff --git a/charts/tracoor-single/.helmignore b/charts/tracoor-single/.helmignore new file mode 100644 index 00000000..0e8a0eb3 --- /dev/null +++ b/charts/tracoor-single/.helmignore @@ -0,0 +1,23 @@ +# Patterns to ignore when building packages. +# This supports shell glob matching, relative path matching, and +# negation (prefixed with !). Only one pattern per line. +.DS_Store +# Common VCS dirs +.git/ +.gitignore +.bzr/ +.bzrignore +.hg/ +.hgignore +.svn/ +# Common backup files +*.swp +*.bak +*.tmp +*.orig +*~ +# Various IDEs +.project +.idea/ +*.tmproj +.vscode/ diff --git a/charts/tracoor-single/Chart.yaml b/charts/tracoor-single/Chart.yaml new file mode 100644 index 00000000..7afe65ee --- /dev/null +++ b/charts/tracoor-single/Chart.yaml @@ -0,0 +1,11 @@ +apiVersion: v2 +name: tracoor-single +description: Ethereum debug data capture and indexer +home: https://github.com/ethpandaops/tracoor +type: application +version: 0.0.3 +maintainers: + - name: samcm + email: sam.calder-mason@ethereum.org + - name: savid + email: andrew.davis@ethereum.org diff --git a/charts/tracoor-single/README.md b/charts/tracoor-single/README.md new file mode 100644 index 00000000..7b692a29 --- /dev/null +++ b/charts/tracoor-single/README.md @@ -0,0 +1,104 @@ + +# tracoor-single + +![Version: 0.0.3](https://img.shields.io/badge/Version-0.0.3-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) + +Ethereum debug data capture and indexer + +**Homepage:** + +## Values + +| Key | Type | Default | Description | +|-----|------|---------|-------------| +| affinity | object | `{}` | Affinity configuration for pods | +| annotations | object | `{}` | Annotations for the Deployment | +| args | list | `[]` | Command arguments | +| autoscaling.enabled | bool | `false` | Autoscaling configuration | +| autoscaling.maxReplicas | int | `3` | Maximum number of replicas | +| autoscaling.minReplicas | int | `2` | Minimum number of replicas | +| autoscaling.targetCPUUtilizationPercentage | int | `85` | Target CPU utilization percentage | +| config.agents[0].ethereum.beacon.nodeAddress | string | `"http://localhost:5052"` | | +| config.agents[0].ethereum.execution.nodeAddress | string | `"http://localhost:8545"` | | +| config.agents[0].ethereum.execution.traceDisableMemory | bool | `true` | | +| config.agents[0].ethereum.execution.traceDisableStack | bool | `true` | | +| config.agents[0].ethereum.execution.traceDisableStorage | bool | `true` | | +| config.agents[0].ethereum.overrideNetworkName | string | `"mainnet"` | | +| config.agents[0].name | string | `"instance-1"` | | +| config.server.addr | string | `":8081"` | | +| config.server.gatewayAddr | string | `":8080"` | | +| config.server.ntpServer | string | `"time.google.com"` | | +| config.server.persistence.driver_name | string | `"sqlite"` | | +| config.server.persistence.dsn | string | `"file:/data/tracoor.db"` | | +| config.server.pprofAddr | string | `":6060"` | | +| config.server.preStopSleepSeconds | int | `1` | | +| config.server.services.indexer.retention.beaconBlocks | string | `"30m"` | | +| config.server.services.indexer.retention.beaconStates | string | `"30m"` | | +| config.server.services.indexer.retention.executionBlockTraces | string | `"30m"` | | +| config.shared.indexer.address | string | `"localhost:8081"` | | +| config.shared.logging | string | `"debug"` | | +| config.shared.metricsAddr | string | `":9091"` | | +| config.shared.store.config.base_path | string | `"/data/store"` | | +| config.shared.store.type | string | `"fs"` | | +| containerSecurityContext | object | See `values.yaml` | The security context for containers | +| customArgs | list | `[]` | Custom args for the tracoor container | +| customCommand | list | `[]` | Command replacement for the tracoor container | +| extraContainers | list | `[]` | Additional containers | +| extraEnv | list | `[]` | Additional env variables | +| extraPodPorts | list | `[]` | Extra Pod ports | +| extraPorts | list | `[]` | Additional ports. Useful when using extraContainers | +| extraVolumeMounts | list | `[]` | Additional volume mounts | +| extraVolumes | list | `[]` | Additional volumes | +| fullnameOverride | string | `""` | Overrides the chart's computed fullname | +| image.pullPolicy | string | `"IfNotPresent"` | tracoor container pull policy | +| image.repository | string | `"ethpandaops/tracoor"` | tracoor container image repository | +| image.tag | string | `"latest"` | tracoor container image tag | +| imagePullSecrets | list | `[]` | Image pull secrets for Docker images | +| ingress.grpc.annotations | object | `{}` | Annotations for Ingress | +| ingress.grpc.enabled | bool | `false` | Ingress resource for GRPC | +| ingress.grpc.hosts[0].host | string | `"chart-example.local"` | | +| ingress.grpc.hosts[0].paths | list | `[]` | | +| ingress.grpc.tls | list | `[]` | Ingress TLS | +| ingress.http.annotations | object | `{}` | Annotations for Ingress | +| ingress.http.enabled | bool | `false` | Ingress resource for the HTTP API | +| ingress.http.hosts[0].host | string | `"chart-example.local"` | | +| ingress.http.hosts[0].paths | list | `[]` | | +| ingress.http.tls | list | `[]` | Ingress TLS | +| initContainers | list | `[]` | Additional init containers | +| lifecycle | object | See `values.yaml` | Lifecycle hooks | +| livenessProbe | object | See `values.yaml` | Liveness probe | +| nameOverride | string | `""` | Overrides the chart's name | +| nodeSelector | object | `{}` | Node selector for pods | +| persistence.accessModes | list | `["ReadWriteOnce"]` | Access mode for the volume claim template | +| persistence.annotations | object | `{}` | Annotations for volume claim template | +| persistence.enabled | bool | `false` | Uses an EmptyDir when not enabled | +| persistence.existingClaim | string | `nil` | Use an existing PVC when persistence.enabled | +| persistence.selector | object | `{}` | Selector for volume claim template | +| persistence.size | string | `"20Gi"` | Requested size for volume claim template | +| persistence.storageClassName | string | `nil` | Use a specific storage class E.g 'local-path' for local storage to achieve best performance Read more (https://github.com/rancher/local-path-provisioner) | +| podAnnotations | object | `{}` | Pod annotations | +| podDisruptionBudget | object | `{}` | Define the PodDisruptionBudget spec If not set then a PodDisruptionBudget will not be created | +| podLabels | object | `{}` | Pod labels | +| priorityClassName | string | `nil` | Pod priority class | +| readinessProbe | object | See `values.yaml` | Readiness probe | +| replicas | int | `1` | Number of replicas | +| resources | object | `{}` | Resource requests and limits | +| secretEnv | object | `{}` | Secret env variables injected via a created secret | +| securityContext | object | See `values.yaml` | The security context for pods | +| service.type | string | `"ClusterIP"` | Service type | +| serviceAccount.annotations | object | `{}` | Annotations to add to the service account | +| serviceAccount.create | bool | `false` | Specifies whether a service account should be created | +| serviceAccount.name | string | `""` | The name of the service account to use. If not set and create is true, a name is generated using the fullname template | +| serviceMonitor.annotations | object | `{}` | Additional ServiceMonitor annotations | +| serviceMonitor.enabled | bool | `false` | If true, a ServiceMonitor CRD is created for a prometheus operator https://github.com/coreos/prometheus-operator | +| serviceMonitor.interval | string | `"15s"` | ServiceMonitor scrape interval | +| serviceMonitor.labels | object | `{}` | Additional ServiceMonitor labels | +| serviceMonitor.namespace | string | `nil` | Alternative namespace for ServiceMonitor | +| serviceMonitor.path | string | `"/metrics"` | Path to scrape | +| serviceMonitor.relabelings | list | `[]` | ServiceMonitor relabelings | +| serviceMonitor.scheme | string | `"http"` | ServiceMonitor scheme | +| serviceMonitor.scrapeTimeout | string | `"30s"` | ServiceMonitor scrape timeout | +| serviceMonitor.tlsConfig | object | `{}` | ServiceMonitor TLS configuration | +| terminationGracePeriodSeconds | int | `90` | How long to wait until the pod is forcefully terminated | +| tolerations | list | `[]` | Tolerations for pods | +| topologySpreadConstraints | list | `[]` | Topology Spread Constraints for pods | diff --git a/charts/tracoor-single/README.md.gotmpl b/charts/tracoor-single/README.md.gotmpl new file mode 100644 index 00000000..54549956 --- /dev/null +++ b/charts/tracoor-single/README.md.gotmpl @@ -0,0 +1,15 @@ + +{{ template "chart.header" . }} +{{ template "chart.deprecationWarning" . }} + +{{ template "chart.versionBadge" . }}{{ template "chart.typeBadge" . }} + +{{ template "chart.description" . }} + +{{ template "chart.homepageLine" . }} + +{{ template "chart.sourcesSection" . }} + +{{ template "chart.requirementsSection" . }} + +{{ template "chart.valuesSection" . }} diff --git a/charts/tracoor-single/templates/NOTES.txt b/charts/tracoor-single/templates/NOTES.txt new file mode 100644 index 00000000..41212144 --- /dev/null +++ b/charts/tracoor-single/templates/NOTES.txt @@ -0,0 +1,22 @@ +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 "tracoor-single.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 "tracoor-single.fullname" . }}' + export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ include "tracoor-single.fullname" . }} --template "{{"{{ range (index .status.loadBalancer.ingress 0) }}{{.}}{{ end }}"}}") + echo http://$SERVICE_IP:{{ include "tracoor-single.httpPort" . }} +{{- else if contains "ClusterIP" .Values.service.type }} + export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app.kubernetes.io/name={{ include "tracoor-single.name" . }},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/tracoor-single/templates/_helpers.tpl b/charts/tracoor-single/templates/_helpers.tpl new file mode 100644 index 00000000..decc8a7a --- /dev/null +++ b/charts/tracoor-single/templates/_helpers.tpl @@ -0,0 +1,80 @@ +{{/* +Expand the name of the chart. +*/}} +{{- define "tracoor-single.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 "tracoor-single.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 "tracoor-single.chart" -}} +{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }} +{{- end }} + +{{/* +Common labels +*/}} +{{- define "tracoor-single.labels" -}} +helm.sh/chart: {{ include "tracoor-single.chart" . }} +{{ include "tracoor-single.selectorLabels" . }} +{{- if .Chart.AppVersion }} +app.kubernetes.io/version: {{ .Chart.AppVersion | quote }} +{{- end }} +app.kubernetes.io/managed-by: {{ .Release.Service }} +{{- end }} + +{{/* +Selector labels +*/}} +{{- define "tracoor-single.selectorLabels" -}} +app.kubernetes.io/name: {{ include "tracoor-single.name" . }} +app.kubernetes.io/instance: {{ .Release.Name }} +{{- end }} + +{{/* +Create the name of the service account to use +*/}} +{{- define "tracoor-single.serviceAccountName" -}} +{{- if .Values.serviceAccount.create }} +{{- default (include "tracoor-single.fullname" .) .Values.serviceAccount.name }} +{{- else }} +{{- default "default" .Values.serviceAccount.name }} +{{- end }} +{{- end }} + +{{- define "tracoor-single.httpPort" -}} +{{ (split ":" .Values.config.server.gatewayAddr)._1 | default "8080" }} +{{- end }} + +{{- define "tracoor-single.grpcPort" -}} +{{ (split ":" .Values.config.server.addr)._1 | default "8081" }} +{{- end }} + +{{- define "tracoor-single.metricsPort" -}} +{{ (split ":" .Values.config.shared.metricsAddr)._1 | default "9090" }} +{{- end -}} + +{{- define "tracoor-single.pprofPort" -}} +{{- if .Values.config.server.pprofAddr -}} +{{ (split ":" .Values.config.server.pprofAddr)._1 | default "6060" }} +{{- end -}} +{{- end -}} diff --git a/charts/tracoor-single/templates/configmap.yaml b/charts/tracoor-single/templates/configmap.yaml new file mode 100644 index 00000000..8c4c9b34 --- /dev/null +++ b/charts/tracoor-single/templates/configmap.yaml @@ -0,0 +1,9 @@ +apiVersion: v1 +kind: ConfigMap +metadata: + name: {{ include "tracoor-single.fullname" . }} + labels: + {{- include "tracoor-single.labels" . | nindent 4 }} +data: + config.yaml: |- + {{ toYaml .Values.config | nindent 4 }} diff --git a/charts/tracoor-single/templates/ingress-grpc.yaml b/charts/tracoor-single/templates/ingress-grpc.yaml new file mode 100644 index 00000000..f842215e --- /dev/null +++ b/charts/tracoor-single/templates/ingress-grpc.yaml @@ -0,0 +1,61 @@ +{{- if .Values.ingress.grpc.enabled -}} +{{- $fullName := include "tracoor-single.fullname" . -}} +{{- $svcPort := include "tracoor-single.grpcPort" . -}} +{{- if and .Values.ingress.grpc.className (not (semverCompare ">=1.18-0" .Capabilities.KubeVersion.GitVersion)) }} + {{- if not (hasKey .Values.ingress.grpc.annotations "kubernetes.io/ingress.class") }} + {{- $_ := set .Values.ingress.grpc.annotations "kubernetes.io/ingress.class" .Values.ingress.grpc.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 }}-grpc + labels: + {{- include "tracoor-single.labels" . | nindent 4 }} + {{- with .Values.ingress.grpc.annotations }} + annotations: + {{- toYaml . | nindent 4 }} + {{- end }} +spec: + {{- if and .Values.ingress.grpc.className (semverCompare ">=1.18-0" .Capabilities.KubeVersion.GitVersion) }} + ingressClassName: {{ .Values.ingress.grpc.className }} + {{- end }} + {{- if .Values.ingress.grpc.tls }} + tls: + {{- range .Values.ingress.grpc.tls }} + - hosts: + {{- range .hosts }} + - {{ . | quote }} + {{- end }} + secretName: {{ .secretName }} + {{- end }} + {{- end }} + rules: + {{- range .Values.ingress.grpc.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/tracoor-single/templates/ingress.yaml b/charts/tracoor-single/templates/ingress.yaml new file mode 100644 index 00000000..50c133aa --- /dev/null +++ b/charts/tracoor-single/templates/ingress.yaml @@ -0,0 +1,61 @@ +{{- if .Values.ingress.http.enabled -}} +{{- $fullName := include "tracoor-single.fullname" . -}} +{{- $svcPort := include "tracoor-single.httpPort" . -}} +{{- if and .Values.ingress.http.className (not (semverCompare ">=1.18-0" .Capabilities.KubeVersion.GitVersion)) }} + {{- if not (hasKey .Values.ingress.http.annotations "kubernetes.io/ingress.class") }} + {{- $_ := set .Values.ingress.http.annotations "kubernetes.io/ingress.class" .Values.ingress.http.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 }} + labels: + {{- include "tracoor-single.labels" . | nindent 4 }} + {{- with .Values.ingress.http.annotations }} + annotations: + {{- toYaml . | nindent 4 }} + {{- end }} +spec: + {{- if and .Values.ingress.http.className (semverCompare ">=1.18-0" .Capabilities.KubeVersion.GitVersion) }} + ingressClassName: {{ .Values.ingress.http.className }} + {{- end }} + {{- if .Values.ingress.http.tls }} + tls: + {{- range .Values.ingress.http.tls }} + - hosts: + {{- range .hosts }} + - {{ . | quote }} + {{- end }} + secretName: {{ .secretName }} + {{- end }} + {{- end }} + rules: + {{- range .Values.ingress.http.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/tracoor-single/templates/pdb.yaml b/charts/tracoor-single/templates/pdb.yaml new file mode 100644 index 00000000..522a15ca --- /dev/null +++ b/charts/tracoor-single/templates/pdb.yaml @@ -0,0 +1,18 @@ +{{- if or .Values.podDisruptionBudget.minAvailable .Values.podDisruptionBudget.maxUnavailable -}} +apiVersion: policy/v1 +kind: PodDisruptionBudget +metadata: + name: {{ include "tracoor-single.fullname" . }} + labels: + {{- include "tracoor-single.labels" . | nindent 4 }} +spec: + selector: + matchLabels: + {{- include "tracoor-single.selectorLabels" . | nindent 6 }} + {{- if .Values.podDisruptionBudget.minAvailable }} + minAvailable: {{ .Values.podDisruptionBudget.minAvailable }} + {{- end }} + {{- if .Values.podDisruptionBudget.maxUnavailable }} + maxUnavailable: {{ .Values.podDisruptionBudget.maxUnavailable }} + {{- end }} +{{- end -}} \ No newline at end of file diff --git a/charts/tracoor-single/templates/secret.yaml b/charts/tracoor-single/templates/secret.yaml new file mode 100644 index 00000000..5bad36d4 --- /dev/null +++ b/charts/tracoor-single/templates/secret.yaml @@ -0,0 +1,10 @@ +apiVersion: v1 +kind: Secret +metadata: + name: {{ include "tracoor-single.fullname" . }}-env + labels: + {{- include "tracoor-single.labels" . | nindent 4 }} +data: +{{- range $key, $value := .Values.secretEnv }} + {{ $key }}: {{ $value | b64enc }} +{{- end }} diff --git a/charts/tracoor-single/templates/service.yaml b/charts/tracoor-single/templates/service.yaml new file mode 100644 index 00000000..a61a051b --- /dev/null +++ b/charts/tracoor-single/templates/service.yaml @@ -0,0 +1,32 @@ +apiVersion: v1 +kind: Service +metadata: + name: {{ include "tracoor-single.fullname" . }} + labels: + {{- include "tracoor-single.labels" . | nindent 4 }} +spec: + type: {{ .Values.service.type }} + ports: + - port: {{ include "tracoor-single.httpPort" . }} + targetPort: http + protocol: TCP + name: http + - port: {{ include "tracoor-single.grpcPort" . }} + targetPort: grpc + protocol: TCP + name: grpc + - port: {{ include "tracoor-single.metricsPort" . }} + targetPort: metrics + protocol: TCP + name: metrics + {{- if (include "tracoor-single.pprofPort" .) }} + - port: {{ include "tracoor-single.pprofPort" . }} + targetPort: pprof + protocol: TCP + name: pprof + {{- end }} + {{- if .Values.extraPorts }} + {{ toYaml .Values.extraPorts | nindent 4}} + {{- end }} + selector: + {{- include "tracoor-single.selectorLabels" . | nindent 4 }} diff --git a/charts/tracoor-single/templates/serviceaccount.yaml b/charts/tracoor-single/templates/serviceaccount.yaml new file mode 100644 index 00000000..b6522d8e --- /dev/null +++ b/charts/tracoor-single/templates/serviceaccount.yaml @@ -0,0 +1,13 @@ +{{- if .Values.serviceAccount.create -}} +apiVersion: v1 +kind: ServiceAccount +metadata: + name: {{ include "tracoor-single.serviceAccountName" . }} + labels: + {{- include "tracoor-single.labels" . | nindent 4 }} + {{- with .Values.serviceAccount.annotations }} + annotations: + {{- toYaml . | nindent 4 }} + {{- end }} + namespace: {{ .Release.Namespace }} +{{- end }} diff --git a/charts/tracoor-single/templates/servicemonitor.yaml b/charts/tracoor-single/templates/servicemonitor.yaml new file mode 100644 index 00000000..d1d18597 --- /dev/null +++ b/charts/tracoor-single/templates/servicemonitor.yaml @@ -0,0 +1,43 @@ +{{- if .Values.serviceMonitor.enabled }} +apiVersion: monitoring.coreos.com/v1 +kind: ServiceMonitor +metadata: + name: {{ include "tracoor-single.fullname" . }} + {{- if .Values.serviceMonitor.namespace }} + namespace: {{ .Values.serviceMonitor.namespace }} + {{- end }} + labels: + {{- include "tracoor-single.labels" . | nindent 4 }} + {{- if .Values.serviceMonitor.labels }} + {{- toYaml .Values.serviceMonitor.labels | nindent 4 }} + {{- end }} + {{- if .Values.serviceMonitor.annotations }} + annotations: + {{ toYaml .Values.serviceMonitor.annotations | nindent 4 }} + {{- end }} +spec: + endpoints: + - interval: {{ .Values.serviceMonitor.interval }} + {{- if .Values.serviceMonitor.scrapeTimeout }} + scrapeTimeout: {{ .Values.serviceMonitor.scrapeTimeout }} + {{- end }} + honorLabels: true + port: metrics + path: {{ .Values.serviceMonitor.path }} + scheme: {{ .Values.serviceMonitor.scheme }} + {{- if .Values.serviceMonitor.tlsConfig }} + tlsConfig: + {{- toYaml .Values.serviceMonitor.tlsConfig | nindent 6 }} + {{- end }} + {{- if .Values.serviceMonitor.relabelings }} + relabelings: + {{- toYaml .Values.serviceMonitor.relabelings | nindent 4 }} + {{- end }} + jobLabel: "{{ .Release.Name }}" + selector: + matchLabels: + {{- include "tracoor-single.selectorLabels" . | nindent 8 }} + namespaceSelector: + matchNames: + - {{ .Release.Namespace }} +{{- end }} diff --git a/charts/tracoor-single/templates/statefulset.yaml b/charts/tracoor-single/templates/statefulset.yaml new file mode 100644 index 00000000..e1a51f1a --- /dev/null +++ b/charts/tracoor-single/templates/statefulset.yaml @@ -0,0 +1,157 @@ +apiVersion: apps/v1 +kind: StatefulSet +metadata: + name: {{ include "tracoor-single.fullname" . }} + labels: + {{- include "tracoor-single.labels" . | nindent 4 }} + annotations: + {{- toYaml .Values.annotations | nindent 4 }} +spec: + serviceName: {{ include "tracoor-single.fullname" . }} + replicas: {{ .Values.replicas }} + podManagementPolicy: {{ .Values.podManagementPolicy }} + updateStrategy: + {{- toYaml .Values.updateStrategy | nindent 4 }} + selector: + matchLabels: + {{- include "tracoor-single.selectorLabels" . | nindent 6 }} + template: + metadata: + labels: + {{- include "tracoor-single.selectorLabels" . | nindent 8 }} + {{- with .Values.podLabels }} + {{- toYaml . | nindent 8 }} + {{- end }} + annotations: + checksum/config: {{ include (print $.Template.BasePath "/configmap.yaml") . | sha256sum }} + checksum/secrets: {{ include (print $.Template.BasePath "/secret.yaml") . | sha256sum }} + {{- with .Values.podAnnotations }} + {{- toYaml . | nindent 8 }} + {{- end }} + spec: + serviceAccountName: {{ include "tracoor-single.serviceAccountName" . }} + {{- if .Values.priorityClassName }} + priorityClassName: {{ .Values.priorityClassName }} + {{- end }} + securityContext: + {{- toYaml .Values.securityContext | nindent 8 }} + initContainers: + {{- if .Values.initContainers }} + {{- toYaml .Values.initContainers | nindent 8 }} + {{- end }} + {{- with .Values.imagePullSecrets }} + imagePullSecrets: + {{- toYaml . | nindent 8 }} + {{- end }} + containers: + - name: {{ .Chart.Name }} + image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}" + imagePullPolicy: {{ .Values.image.pullPolicy }} + command: + {{- if gt (len .Values.customCommand) 0 }} + {{- toYaml .Values.customCommand | nindent 12}} + {{- else }} + - "/tracoor" + - "single" + - --single-config=/config.yaml + {{- if gt (len .Values.args) 0 }} + {{- toYaml .Values.args | nindent 12}} + {{- end }} + {{- end }} + {{- if gt (len .Values.customArgs) 0 }} + args: + {{- toYaml .Values.customArgs | nindent 12}} + {{- end }} + securityContext: + {{- toYaml .Values.containerSecurityContext | nindent 12 }} + volumeMounts: + - name: config + mountPath: "/config.yaml" + subPath: config.yaml + readOnly: true + - name: storage + mountPath: "/data" + {{- if .Values.extraVolumeMounts }} + {{ toYaml .Values.extraVolumeMounts | nindent 10}} + {{- end }} + ports: + - name: http + containerPort: {{ include "tracoor-single.httpPort" . }} + protocol: TCP + - name: metrics + containerPort: {{ include "tracoor-single.metricsPort" . }} + protocol: TCP + - name: grpc + containerPort: {{ include "tracoor-single.grpcPort" . }} + protocol: TCP + {{- if (include "tracoor-single.pprofPort" .) }} + - name: pprof + containerPort: {{ include "tracoor-single.pprofPort" . }} + protocol: TCP + {{- end }} + {{- if .Values.extraPodPorts }} + {{ toYaml .Values.extraPodPorts | nindent 10 }} + {{- end }} + livenessProbe: + {{- toYaml .Values.livenessProbe | nindent 12 }} + readinessProbe: + {{- toYaml .Values.readinessProbe | nindent 12 }} + lifecycle: + {{- toYaml .Values.lifecycle | nindent 12 }} + resources: + {{- toYaml .Values.resources | nindent 12 }} + env: + {{- range $key, $value := .Values.secretEnv }} + - name: {{ $key }} + valueFrom: + secretKeyRef: + name: {{ include "tracoor-single.fullname" $ }}-env + key: {{ $key }} + {{- end }} + {{- if .Values.extraEnv }} + {{- toYaml .Values.extraEnv | nindent 12 }} + {{- end }} + {{- if .Values.extraContainers }} + {{ toYaml .Values.extraContainers | nindent 8}} + {{- end }} + nodeSelector: + {{- toYaml .Values.nodeSelector | nindent 8 }} + affinity: + {{- toYaml .Values.affinity | nindent 8 }} + tolerations: + {{- toYaml .Values.tolerations | nindent 8 }} + topologySpreadConstraints: + {{- toYaml .Values.topologySpreadConstraints | nindent 8 }} + terminationGracePeriodSeconds: {{ .Values.terminationGracePeriodSeconds }} + volumes: + - name: config + configMap: + name: {{ include "tracoor-single.fullname" . }} + {{- if .Values.extraVolumes }} + {{ toYaml .Values.extraVolumes | nindent 8}} + {{- end }} + {{- if not .Values.persistence.enabled }} + - name: storage + emptyDir: {} + {{- else if .Values.persistence.existingClaim }} + - name: storage + persistentVolumeClaim: + claimName: {{ .Values.persistence.existingClaim }} + {{- else }} + volumeClaimTemplates: + - metadata: + name: storage + annotations: + {{- toYaml .Values.persistence.annotations | nindent 8 }} + spec: + accessModes: + {{- toYaml .Values.persistence.accessModes | nindent 8 }} + resources: + requests: + storage: {{ .Values.persistence.size | quote }} + storageClassName: {{ .Values.persistence.storageClassName }} + {{- if .Values.persistence.selector }} + selector: + {{- toYaml .Values.persistence.selector | nindent 8 }} + {{- end }} + {{- end }} diff --git a/charts/tracoor-single/values.yaml b/charts/tracoor-single/values.yaml new file mode 100644 index 00000000..f660b91a --- /dev/null +++ b/charts/tracoor-single/values.yaml @@ -0,0 +1,305 @@ +# -- Overrides the chart's name +nameOverride: "" + +# -- Overrides the chart's computed fullname +fullnameOverride: "" + +# -- Number of replicas +replicas: 1 + +autoscaling: + # -- Autoscaling configuration + enabled: false + # -- Minimum number of replicas + minReplicas: 2 + # -- Maximum number of replicas + maxReplicas: 3 + # -- Target CPU utilization percentage + targetCPUUtilizationPercentage: 85 + +image: + # -- tracoor container image repository + repository: ethpandaops/tracoor + # -- tracoor container image tag + tag: latest + # -- tracoor container pull policy + pullPolicy: IfNotPresent + +# -- Secret env variables injected via a created secret +secretEnv: {} + +# -- Command arguments +args: [] + +config: + shared: + metricsAddr: ":9091" + logging: "debug" + indexer: + address: localhost:8081 + store: + type: fs + config: + base_path: "/data/store" + + server: + addr: ":8081" + gatewayAddr: ":8080" + pprofAddr: ":6060" + preStopSleepSeconds: 1 + ntpServer: time.google.com + + persistence: + dsn: "file:/data/tracoor.db" + driver_name: sqlite + + services: + indexer: + retention: + beaconStates: 30m + executionBlockTraces: 30m + beaconBlocks: 30m + + agents: + - name: instance-1 + ethereum: + overrideNetworkName: mainnet + # features: + # fetchBeaconState: true + # fetchBeaconBlock: true + # fetchBeaconBadBlock: true + # fetchBeaconBadBlob: true + # fetchExecutionBlockTrace: true + # fetchExecutionBadBlock: true + beacon: + nodeAddress: http://localhost:5052 + # Prysm + # requires --save-invalid-block-temp and --save-invalid-blob-temp flags enabled + # Always stored in os.tmpdir(), eg. /tmp + # invalidGossipVerifiedBlocksPath: /tmp + # invalidGossipVerifiedBlobsPath: /tmp + + # Nimbus + # requires --dump flag enabled + # replace data-dir with the --data-dir flag value + # invalidGossipVerifiedBlocksPath: /data-dir/dump/invalid + + # Lighthouse + # requires --invalid-gossip-verified-blocks-path flag set eg. =/data/invalid + # invalidGossipVerifiedBlocksPath: /data/invalid + execution: + nodeAddress: http://localhost:8545 + traceDisableMemory: true + traceDisableStack: true + traceDisableStorage: true + +ingress: + grpc: + # -- Ingress resource for GRPC + enabled: false + # -- Annotations for Ingress + annotations: {} + # kubernetes.io/ingress.class: nginx + # kubernetes.io/tls-acme: "true" + # -- Ingress host + hosts: + - host: chart-example.local + paths: [] + # -- Ingress TLS + tls: [] + # - secretName: chart-example-tls + # hosts: + # - chart-example.local + http: + # -- Ingress resource for the HTTP API + enabled: false + # -- Annotations for Ingress + annotations: {} + # kubernetes.io/ingress.class: nginx + # kubernetes.io/tls-acme: "true" + # -- Ingress host + hosts: + - host: chart-example.local + paths: [] + # -- Ingress TLS + tls: [] + # - secretName: chart-example-tls + # hosts: + # - chart-example.local + +# -- Custom args for the tracoor container +customArgs: [] + +# -- Command replacement for the tracoor container +customCommand: [] # Only change this if you need to change the default command + +service: + # -- Service type + type: ClusterIP + +# -- Affinity configuration for pods +affinity: {} + +# -- Image pull secrets for Docker images +imagePullSecrets: [] + +# -- Annotations for the Deployment +annotations: {} + +# -- Liveness probe +# @default -- See `values.yaml` +livenessProbe: + tcpSocket: + port: grpc + initialDelaySeconds: 60 + periodSeconds: 120 + +# -- Readiness probe +# @default -- See `values.yaml` +readinessProbe: + tcpSocket: + port: grpc + initialDelaySeconds: 10 + periodSeconds: 10 + +# -- Node selector for pods +nodeSelector: {} + +persistence: + # -- Uses an EmptyDir when not enabled + enabled: false + # -- Use an existing PVC when persistence.enabled + existingClaim: null + # -- Access mode for the volume claim template + accessModes: + - ReadWriteOnce + # -- Requested size for volume claim template + size: 20Gi + # -- Use a specific storage class + # E.g 'local-path' for local storage to achieve best performance + # Read more (https://github.com/rancher/local-path-provisioner) + storageClassName: null + # -- Annotations for volume claim template + annotations: {} + # -- Selector for volume claim template + selector: {} + # matchLabels: + # app.kubernetes.io/name: something + +# -- Pod labels +podLabels: {} + +# -- Pod annotations +podAnnotations: {} + +# -- Extra Pod ports +extraPodPorts: [] + +# -- Pod priority class +priorityClassName: null + +# -- Resource requests and limits +resources: {} +# limits: +# cpu: 500m +# memory: 2Gi +# requests: +# cpu: 300m +# memory: 1Gi + +# -- The security context for pods +# @default -- See `values.yaml` +securityContext: + fsGroup: 10001 + runAsGroup: 10001 + runAsNonRoot: true + runAsUser: 10001 + +# -- The security context for containers +# @default -- See `values.yaml` +containerSecurityContext: {} + # capabilities: + # drop: + # - ALL + # readOnlyRootFilesystem: true + # runAsNonRoot: true + # runAsUser: 1000 + +serviceAccount: + # -- Specifies whether a service account should be created + create: false + # -- 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: "" + +# -- Lifecycle hooks +# @default -- See `values.yaml` +lifecycle: + preStop: + exec: + command: + - /bin/sleep + - "30" + +# -- How long to wait until the pod is forcefully terminated +terminationGracePeriodSeconds: 90 + +# -- Tolerations for pods +## ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/ +tolerations: [] + +# -- Topology Spread Constraints for pods +## ref: https://kubernetes.io/docs/concepts/scheduling-eviction/topology-spread-constraints/ +topologySpreadConstraints: [] + +# -- Define the PodDisruptionBudget spec +# If not set then a PodDisruptionBudget will not be created +podDisruptionBudget: {} +# minAvailable: 1 +# maxUnavailable: 1 + +# -- Additional init containers +initContainers: [] +# - name: my-init-container +# image: busybox:latest +# command: ['sh', '-c', 'echo hello'] + +# -- Additional containers +extraContainers: [] + +# -- Additional volumes +extraVolumes: [] + +# -- Additional volume mounts +extraVolumeMounts: [] + +# -- Additional ports. Useful when using extraContainers +extraPorts: [] + +# -- Additional env variables +extraEnv: [] + +serviceMonitor: + # -- If true, a ServiceMonitor CRD is created for a prometheus operator + # https://github.com/coreos/prometheus-operator + enabled: false + # -- Path to scrape + path: /metrics + # -- Alternative namespace for ServiceMonitor + namespace: null + # -- Additional ServiceMonitor labels + labels: {} + # -- Additional ServiceMonitor annotations + annotations: {} + # -- ServiceMonitor scrape interval + interval: 15s + # -- ServiceMonitor scheme + scheme: http + # -- ServiceMonitor TLS configuration + tlsConfig: {} + # -- ServiceMonitor scrape timeout + scrapeTimeout: 30s + # -- ServiceMonitor relabelings + relabelings: []