mirror of
https://github.com/logos-blockchain/logos-blockchain-testing.git
synced 2026-01-02 13:23:13 +00:00
- Update paths and orchestration for deployers (compose/k8s/local/docker) - Consolidate scripts helpers and refresh book/README docs
70 lines
2.5 KiB
YAML
70 lines
2.5 KiB
YAML
{{- $root := . -}}
|
|
{{- $nodes := default (list) .Values.validators.nodes }}
|
|
{{- range $i, $node := $nodes }}
|
|
---
|
|
apiVersion: apps/v1
|
|
kind: Deployment
|
|
metadata:
|
|
name: {{ include "nomos-runner.fullname" $root }}-validator-{{ $i }}
|
|
labels:
|
|
{{- include "nomos-runner.validatorLabels" (dict "root" $root "index" $i) | nindent 4 }}
|
|
spec:
|
|
replicas: 1
|
|
selector:
|
|
matchLabels:
|
|
{{- include "nomos-runner.validatorLabels" (dict "root" $root "index" $i) | nindent 6 }}
|
|
template:
|
|
metadata:
|
|
labels:
|
|
{{- include "nomos-runner.validatorLabels" (dict "root" $root "index" $i) | nindent 8 }}
|
|
spec:
|
|
containers:
|
|
- name: validator
|
|
image: {{ $root.Values.image }}
|
|
imagePullPolicy: {{ $root.Values.imagePullPolicy }}
|
|
command: ["/etc/nomos/scripts/run_nomos_node.sh"]
|
|
ports:
|
|
- name: http
|
|
containerPort: {{ default 18080 $node.apiPort }}
|
|
- name: testing-http
|
|
containerPort: {{ default 18081 $node.testingHttpPort }}
|
|
env:
|
|
- name: CFG_SERVER_ADDR
|
|
value: http://{{ include "nomos-runner.fullname" $root }}-cfgsync:{{ $root.Values.cfgsync.port }}
|
|
- name: NOMOS_KZGRS_PARAMS_PATH
|
|
value: '{{ if eq $root.Values.kzg.mode "inImage" }}{{ $root.Values.kzg.inImageParamsPath }}{{ else }}{{ $root.Values.kzg.hostPathParamsPath }}{{ end }}'
|
|
{{- range $key, $value := $node.env }}
|
|
- name: {{ $key }}
|
|
value: "{{ $value }}"
|
|
{{- end }}
|
|
volumeMounts:
|
|
- name: assets
|
|
mountPath: /etc/nomos
|
|
readOnly: true
|
|
{{- if eq $root.Values.kzg.mode "hostPath" }}
|
|
- name: kzg-params
|
|
mountPath: /kzgrs_test_params
|
|
readOnly: true
|
|
{{- end }}
|
|
volumes:
|
|
- name: assets
|
|
configMap:
|
|
name: {{ include "nomos-runner.fullname" $root }}-assets
|
|
defaultMode: 0755
|
|
items:
|
|
- key: cfgsync.yaml
|
|
path: cfgsync.yaml
|
|
- key: run_cfgsync.sh
|
|
path: scripts/run_cfgsync.sh
|
|
- key: run_nomos.sh
|
|
path: scripts/run_nomos.sh
|
|
- key: run_nomos_node.sh
|
|
path: scripts/run_nomos_node.sh
|
|
{{- if eq $root.Values.kzg.mode "hostPath" }}
|
|
- name: kzg-params
|
|
persistentVolumeClaim:
|
|
claimName: {{ include "nomos-runner.fullname" $root }}-kzg
|
|
readOnly: true
|
|
{{- end }}
|
|
{{- end }}
|