github.com/smartcontractkit/chainlink-testing-framework/libs@v0.0.0-20240227141906-ec710b4eb1a3/charts/geth-prysm/templates/geth.deployment.yaml (about) 1 apiVersion: apps/v1 2 kind: Deployment 3 metadata: 4 name: {{ .Release.Name }}-{{ .Values.geth.name }} 5 spec: 6 selector: 7 matchLabels: 8 app: {{ .Release.Name }}-{{ .Values.geth.name }} 9 template: 10 metadata: 11 labels: 12 app: {{ .Release.Name }}-{{ .Values.geth.name }} 13 spec: 14 volumes: 15 - name: {{ .Release.Name }}-chain-state 16 persistentVolumeClaim: 17 claimName: {{ .Release.Name }}-{{ .Values.storage.claim }} 18 - name: {{ .Release.Name }}-geth-config 19 configMap: 20 name: {{ .Release.Name }}-geth-config 21 - name: {{ .Release.Name }}-prysm-config 22 configMap: 23 name: {{ .Release.Name }}-prysm-config 24 containers: 25 - name: {{ .Values.geth.name }} 26 image: {{ .Values.geth.image.repository }}:{{ .Values.geth.image.tag }} 27 imagePullPolicy: {{ .Values.imagePullPolicy }} 28 command: ["/bin/sh"] 29 args: 30 - "-c" 31 - "geth --http.vhosts=* --nousb --metrics --nocompaction --syncmode full --gcmode archive --http --http.corsdomain \"*\" --http.vhosts=\"*\" --http.api admin,debug,web3,eth,txpool,net --http.addr 0.0.0.0 --http.port={{ .Values.geth.ports.http }} --ws --ws.origins \"*\" --ws.api admin,debug,web3,eth,txpool,net --ws.addr 0.0.0.0 --ws.port={{ .Values.geth.ports.ws }} --authrpc.vhosts=\"*\" --authrpc.addr=0.0.0.0 --authrpc.jwtsecret={{ .Values.shared.jwtSecretFile }} --graphql --graphql.corsdomain=\"*\" --datadir={{ .Values.geth.executionDir }} --networkid={{ .Values.general.networkId }} --rpc.allow-unprotected-txs --rpc.txfeecap=0 --nodiscover --allow-insecure-unlock --unlock=0x123463a4b065722e99115d6c222f267d9cabb524 --password={{ .Values.geth.passwordFile }} --verbosity=5" 32 resources: 33 requests: 34 memory: {{ .Values.geth.resources.requests.memory }} 35 cpu: {{ .Values.geth.resources.requests.cpu }} 36 limits: 37 memory: {{ .Values.geth.resources.limits.memory }} 38 cpu: {{ .Values.geth.resources.limits.cpu }} 39 ports: 40 - name: http-rpc 41 containerPort: {{ .Values.geth.ports.http }} 42 - name: ws-rpc 43 containerPort: {{ .Values.geth.ports.ws }} 44 - name: execution-rpc 45 containerPort: {{ .Values.geth.ports.execution }} 46 - name: discovery-udp 47 containerPort: {{ .Values.geth.ports.discovery }} 48 protocol: UDP 49 - name: discovery-tcp 50 containerPort: {{ .Values.geth.ports.discovery }} 51 volumeMounts: 52 - name: {{ .Release.Name }}-geth-config 53 mountPath: {{ .Values.geth.executionDir }}/keystore/node1key 54 subPath: node1key 55 - name: {{ .Release.Name }}-geth-config 56 mountPath: {{ .Values.geth.passwordFile }} 57 subPath: password.txt 58 - name: {{ .Release.Name }}-geth-config 59 mountPath: {{ .Values.shared.jwtSecretFile }} 60 subPath: jwtsecret 61 - name: {{ .Release.Name }}-geth-config 62 mountPath: {{ .Values.geth.executionDir }}/sk.json 63 subPath: sk 64 - name: {{ .Release.Name }}-chain-state 65 mountPath: /data 66 readinessProbe: 67 exec: 68 command: ["/bin/sh", "-c", 'until nc -z -v localhost {{ .Values.geth.ports.execution }}; do sleep 2; done'] 69 initialDelaySeconds: 5 70 periodSeconds: 5 71 failureThreshold: 2 72 timeoutSeconds: 120 73 livenessProbe: 74 exec: 75 command: ["/bin/sh", "-c", 'until nc -z -v localhost {{ .Values.geth.ports.execution }}; do sleep 2; done'] 76 initialDelaySeconds: 5 77 periodSeconds: 5 78 failureThreshold: 2 79 timeoutSeconds: 10 80 initContainers: 81 - name: {{ .Release.Name }}-init-eth2-genesis 82 image: "{{ .Values.prysm.genesis.image.repository }}:{{ .Values.prysm.genesis.image.tag }}" 83 imagePullPolicy: "{{ .Values.imagePullPolicy }}" 84 args: 85 - "testnet" 86 - "generate-genesis" 87 - "--fork=capella" 88 - "--num-validators={{ .Values.prysm.shared.validators }}" 89 - "--genesis-time-delay={{ .Values.prysm.genesis.values.delaySeconds }}" 90 - "--output-ssz={{ .Values.prysm.shared.genesisFile }}" 91 - "--chain-config-file={{ .Values.prysm.shared.configFile }}" 92 - "--geth-genesis-json-in={{ .Values.geth.executionDir }}/genesis-raw.json" 93 - "--geth-genesis-json-out={{ .Values.shared.genesisFile }}" 94 volumeMounts: 95 - name: {{ .Release.Name }}-chain-state 96 mountPath: /data 97 - name: {{ .Release.Name }}-prysm-config 98 mountPath: {{ .Values.prysm.shared.configFile }} 99 subPath: config.yml 100 - name: {{ .Release.Name }}-geth-config 101 mountPath: {{ .Values.geth.executionDir }}/genesis-raw.json 102 subPath: genesis.json 103 - name: {{ .Release.Name }}-init-eth1-genesis 104 image: {{ .Values.geth.image.repository }}:{{ .Values.geth.image.tag }} 105 imagePullPolicy: {{ .Values.imagePullPolicy }} 106 command: 107 - "geth" 108 - "--datadir={{ .Values.geth.executionDir }}" 109 - "init" 110 - "{{ .Values.shared.genesisFile }}" 111 volumeMounts: 112 - name: {{ .Release.Name }}-chain-state 113 mountPath: /data