Skip to content
This repository was archived by the owner on Mar 3, 2026. It is now read-only.

Commit a3e89ef

Browse files
eiabeatsudmi
andauthored
feat: load keys from HashiCorp Vault (#639)
* chore(deps): update image tag to v3.1.8 * feat: load keys from HashiCorp Vault * chore: update chart versions --------- Co-authored-by: Dmitri Tsumak <tsumak.dmitri@gmail.com>
1 parent d41770d commit a3e89ef

File tree

5 files changed

+32
-3
lines changed

5 files changed

+32
-3
lines changed

charts/v3-operator/Chart.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
apiVersion: v2
22
name: v3-operator
3-
version: 3.4.0
4-
appVersion: v3.0.3
3+
version: 3.5.0
4+
appVersion: v3.1.8
55
description: Operator hosted service for Stakewise V3 protocol.
66
type: application
77
icon: https://storage.googleapis.com/stakewise-charts/stakewise.png

charts/v3-operator/README.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,9 @@ Kubernetes secrets are used to store sensitive information related to the v3-ope
2222
kubectl create secret generic v3-operator-deposit-data --from-file=/home/username/.stakewise/0xeefffd4c23d2e8c845870e273861e7d60df49663/deposit_data.json
2323
kubectl create secret generic v3-operator-keystores-data --from-file=/home/username/.stakewise/0xeefffd4c23d2e8c845870e273861e7d60df49663/keystores
2424
kubectl create secret generic v3-operator-wallet-data --from-file=/home/username/.stakewise/0xeefffd4c23d2e8c845870e273861e7d60df49663/wallet
25+
26+
# optional if you are using HashiCorp Vault
27+
kubectl create secret generic v3-operator-hcv-token --from-literal=token=<insert token here>
2528
```
2629

2730
> Replace `0xeefffd4c23d2e8c845870e273861e7d60df49663` with the actual vault contract address

charts/v3-operator/templates/statefulset.yaml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,12 +94,25 @@ spec:
9494
- --remote-signer-url
9595
- {{ .Values.settings.remoteDbConfig.remoteSignerUrl }}
9696
{{- end }}
97+
{{- if .Values.settings.hcVaultConfig.enabled }}
98+
- --hashi-vault-url
99+
- {{ .Values.settings.hcVaultConfig.hcVaultUrl }}
100+
- --hashi-vault-token
101+
- $(HASHICORP_VAULT_TOKEN)
102+
- --hashi-vault-key-path
103+
- {{ .Values.settings.hcVaultConfig.hcVaultKeyPath }}
104+
{{- end }}
97105
{{- range .Values.settings.extraFlags }}
98106
- {{ . }}
99107
{{- end }}
100108
env:
101109
- name: PYTHONPATH
102110
value: "."
111+
- name: HASHICORP_VAULT_TOKEN
112+
valueFrom:
113+
secretKeyRef:
114+
name: {{ .Values.settings.hcVaultConfig.hcVaultTokenSecretName }}
115+
key: token
103116
envFrom:
104117
- configMapRef:
105118
name: {{ include "common.names.fullname" . }}

charts/v3-operator/templates/validate.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,3 +9,9 @@
99
{{- if not .Values.settings.vault }}
1010
{{- fail ".Values.settings.vault is empty" }}
1111
{{- end }}
12+
13+
{{- if .Values.settings.hcVaultConfig.enabled -}}
14+
{{- if not .Values.settings.hcVaultConfig.hcVaultTokenSecretName }}
15+
{{- fail ".Values.settings.hcVaultConfig.hcVaultTokenSecretName is empty" }}
16+
{{- end }}
17+
{{- end }}

charts/v3-operator/values.yaml

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ serviceAccount:
5757
image:
5858
registry: "europe-west4-docker.pkg.dev"
5959
repository: "stakewiselabs/public/v3-operator"
60-
tag: "v3.0.3"
60+
tag: "v3.1.8"
6161
pullPolicy: IfNotPresent
6262
pullSecrets: []
6363

@@ -105,6 +105,13 @@ settings:
105105
dbUrl: "postgresql://postgres:postgres@localhost/operator"
106106
remoteSignerUrl: "http://web3signer:6174"
107107

108+
# Whether to receive keystores from HashiCorp Vault
109+
hcVaultConfig:
110+
enabled: false
111+
hcVaultUrl: "http://vault:8200"
112+
hcVaultTokenSecretName: ""
113+
hcVaultKeyPath: "stakewise"
114+
108115
# If specified, deposit data will be obtained from the secret
109116
depositDataSecretName: ""
110117
# If specified, keystores will be obtained from the secret

0 commit comments

Comments
 (0)