chart: load secrets into env vars

This commit is contained in:
c9s 2020-12-17 14:09:22 +08:00
parent 83cdf7dff9
commit bee06ea192
5 changed files with 28 additions and 16 deletions

View File

@ -231,6 +231,12 @@ streambook.BindStream(stream)
- /auth 92463901
- done! your session will route to telegram
## Helm Chart
```
kubectl create secret generic bbgo --from-env-file .env.local
```
## Support
### By contributing pull requests

View File

@ -51,6 +51,13 @@ spec:
- name: config-volume
mountPath: /config
{{- if .Values.dotenv.secret }}
# the "env" entries will override the environment variables from envFrom.
envFrom:
- secretRef:
name: {{ .Values.dotenv.secret }}
{{- end }}
volumes:
- name: config-volume
configMap:

View File

@ -15,7 +15,10 @@ nameOverride: ""
fullnameOverride: ""
configmap:
file: "config/bbgo.yaml"
file: "config/bollgrid.yaml"
dotenv:
secret: "bbgo"
serviceAccount:
# Specifies whether a service account should be created

View File

@ -39,10 +39,6 @@ sessions:
exchange: max
envVarPrefix: max
binance:
exchange: binance
envVarPrefix: binance
backtest:
# for testing max draw down (MDD) at 03-12
# see here for more details

View File

@ -18,9 +18,9 @@ notifications:
pnL: "bbgo-pnl"
sessions:
binance:
exchange: binance
envVarPrefix: binance
# binance:
# exchange: binance
# envVarPrefix: binance
max:
exchange: max
@ -38,10 +38,10 @@ riskControls:
BTCUSDT:
# basic risk control order executor
basic:
minQuoteBalance: 100.0
maxBaseAssetBalance: 3.0
minBaseAssetBalance: 0.0
maxOrderAmount: 2000.0
minQuoteBalance: 1000.0
maxBaseAssetBalance: 0
minBaseAssetBalance: 1.0
maxOrderAmount: 3000.0
backtest:
# for testing max draw down (MDD) at 03-12
@ -62,7 +62,7 @@ exchangeStrategies:
- on: max
bollgrid:
symbol: BTCUSDT
interval: 5m
gridNumber: 20
quantity: 0.01
profitSpread: 30.0
interval: 1h
gridNumber: 100
quantity: 0.002
profitSpread: 10.0