|
| 1 | +apiVersion: apps/v1 |
| 2 | +kind: StatefulSet |
| 3 | +metadata: |
| 4 | + name: {{ include "immutable-geth.fullname" . }} |
| 5 | + namespace: {{ .Release.Namespace }} |
| 6 | + labels: |
| 7 | + {{- include "immutable-geth.labels" . | nindent 4 }} |
| 8 | +spec: |
| 9 | + replicas: {{ .Values.replicaCount }} |
| 10 | + selector: |
| 11 | + matchLabels: |
| 12 | + {{- include "immutable-geth.selectorLabels" . | nindent 6 }} |
| 13 | + template: |
| 14 | + metadata: |
| 15 | + {{- with .Values.podAnnotations }} |
| 16 | + annotations: |
| 17 | + {{- toYaml . | nindent 8 }} |
| 18 | + {{- end }} |
| 19 | + labels: |
| 20 | + {{- include "immutable-geth.labels" . | nindent 8 }} |
| 21 | + {{- with .Values.podLabels }} |
| 22 | + {{- toYaml . | nindent 8 }} |
| 23 | + {{- end }} |
| 24 | + spec: |
| 25 | + securityContext: |
| 26 | + {{- toYaml .Values.podSecurityContext | nindent 8 }} |
| 27 | + serviceAccountName: {{ include "immutable-geth.serviceAccountName" . }} |
| 28 | + initContainers: |
| 29 | + - name: init |
| 30 | + image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}" |
| 31 | + command: |
| 32 | + - geth |
| 33 | + args: |
| 34 | + - immutable |
| 35 | + - bootstrap |
| 36 | + - rpc |
| 37 | + - --zkevm=testnet |
| 38 | + - --datadir={{ .Values.storage.path | quote }} |
| 39 | + volumeMounts: |
| 40 | + - mountPath: {{ .Values.storage.path | quote }} |
| 41 | + name: data |
| 42 | + containers: |
| 43 | + - name: {{ .Chart.Name }} |
| 44 | + securityContext: |
| 45 | + {{- toYaml .Values.securityContext | nindent 12 }} |
| 46 | + image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}" |
| 47 | + imagePullPolicy: {{ .Values.image.pullPolicy }} |
| 48 | + command: |
| 49 | + - geth |
| 50 | + args: |
| 51 | + - --zkevm=testnet |
| 52 | + - --config=/etc/geth/testnet-public.toml |
| 53 | + - --datadir={{ .Values.storage.path }} |
| 54 | + - --http |
| 55 | + - --http.port={{ .Values.service.http.port }} |
| 56 | + - --http.addr=0.0.0.0 |
| 57 | + - --http.corsdomain=* |
| 58 | + - --http.vhosts=* |
| 59 | + - --http.api=admin,engine,net,eth,web3,debug,miner |
| 60 | + - --gossipdefault |
| 61 | + - --disabletxpoolgossip |
| 62 | + - --rpcproxy |
| 63 | + ports: |
| 64 | + - name: http |
| 65 | + containerPort: {{ .Values.service.http.port }} |
| 66 | + protocol: TCP |
| 67 | + resources: |
| 68 | + {{- toYaml .Values.resources | nindent 12 }} |
| 69 | + volumeMounts: |
| 70 | + - mountPath: {{ .Values.storage.path | quote }} |
| 71 | + name: data |
| 72 | + volumeClaimTemplates: |
| 73 | + - metadata: |
| 74 | + name: data |
| 75 | + spec: |
| 76 | + accessModes: [ "ReadWriteOnce" ] |
| 77 | + resources: |
| 78 | + requests: |
| 79 | + storage: {{ .Values.storage.size }} |
0 commit comments