Skip to content

Commit

Permalink
Merge pull request #19 from ricoberger/add-deployment-strategy-to-hel…
Browse files Browse the repository at this point in the history
…m-chart

Add vaule to set deployment strategy to Helm chart
  • Loading branch information
ricoberger authored Oct 17, 2019
2 parents 6029e69 + c0f1251 commit 0076da9
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 5 deletions.
1 change: 1 addition & 0 deletions charts/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
| Value | Description | Default |
| ----- | ----------- | ------- |
| `replicaCount` | Number of replications which should be created. | `1` |
| `deploymentStrategy` | Deployment strategy which should be used. | `{}` |
| `image.repository` | The repository of the Docker image. | `ricoberger/vault-secrets-operator` |
| `image.tag` | The tag of the Docker image which should be used. | `1.3.1` |
| `image.pullPolicy` | The pull policy for the Docker image, | `IfNotPresent` |
Expand Down
6 changes: 3 additions & 3 deletions charts/vault-secrets-operator/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -63,9 +63,9 @@ Inject extra environment variables populated by secrets, if populated.
{{- range .environmentVars }}
- name: {{ .envName }}
valueFrom:
secretKeyRef:
name: {{ .secretName }}
key: {{ .secretKey }}
secretKeyRef:
name: {{ .secretName }}
key: {{ .secretKey }}
{{- end -}}
{{- end -}}
{{- end -}}
Expand Down
8 changes: 6 additions & 2 deletions charts/vault-secrets-operator/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,10 @@ metadata:
{{ include "vault-secrets-operator.labels" . | indent 4 }}
spec:
replicas: {{ .Values.replicaCount }}
{{- with .Values.deploymentStrategy }}
strategy:
{{- toYaml . | nindent 4 }}
{{- end }}
selector:
matchLabels:
app.kubernetes.io/name: {{ include "vault-secrets-operator.name" . }}
Expand All @@ -16,10 +20,10 @@ spec:
app.kubernetes.io/name: {{ include "vault-secrets-operator.name" . }}
app.kubernetes.io/instance: {{ .Release.Name }}
spec:
{{- with .Values.imagePullSecrets }}
{{- with .Values.imagePullSecrets }}
imagePullSecrets:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- end }}
serviceAccountName: {{ template "vault-secrets-operator.serviceAccountName" . }}
containers:
- name: {{ .Chart.Name }}
Expand Down
1 change: 1 addition & 0 deletions charts/vault-secrets-operator/values.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
replicaCount: 1
deploymentStrategy: {}

image:
repository: ricoberger/vault-secrets-operator
Expand Down

0 comments on commit 0076da9

Please sign in to comment.