-
Notifications
You must be signed in to change notification settings - Fork 363
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[velero] Add support for multiple backupstoragelocations and volumesn…
…apshotlocations (#413) * Add support for multiple backupstoragelocations and volumesnapshotlocations * Make BSL and VSL templates backwards compatible and preserve the default provider behavior * Fix ci lint failure * fix accessMode rendering * put values file back * remove configuration.provider * add logic for BSL and VSL names * remove names logic * update ct values * fix test values for BSL credential * add BSL provider to test values * move accessmode logic to helpers * fix: set credential when it's configured * ci: test multiple BSL/VSL * fix: fix linter error * ci: only support one default BSL * doc: update README * chore: add error message when the BSL/VSL configures as map Signed-off-by: Brandon Steinman <[email protected]> Co-authored-by: JenTing Hsiao <[email protected]>
- Loading branch information
Showing
8 changed files
with
88 additions
and
76 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,29 @@ | ||
{{- if .Values.snapshotsEnabled }} | ||
|
||
{{- if typeIs "[]interface {}" .Values.configuration.volumeSnapshotLocation }} | ||
{{- range .Values.configuration.volumeSnapshotLocation }} | ||
--- | ||
apiVersion: velero.io/v1 | ||
kind: VolumeSnapshotLocation | ||
metadata: | ||
name: {{ include "velero.volumeSnapshotLocation.name" . }} | ||
namespace: {{ .Release.Namespace }} | ||
name: {{ .name | default "default" }} | ||
namespace: {{ $.Release.Namespace }} | ||
annotations: | ||
"helm.sh/hook": post-install,post-upgrade,post-rollback | ||
"helm.sh/hook-delete-policy": before-hook-creation | ||
labels: | ||
app.kubernetes.io/name: {{ include "velero.name" . }} | ||
app.kubernetes.io/instance: {{ .Release.Name }} | ||
app.kubernetes.io/managed-by: {{ .Release.Service }} | ||
helm.sh/chart: {{ include "velero.chart" . }} | ||
app.kubernetes.io/name: {{ include "velero.name" $ }} | ||
app.kubernetes.io/instance: {{ $.Release.Name }} | ||
app.kubernetes.io/managed-by: {{ $.Release.Service }} | ||
helm.sh/chart: {{ include "velero.chart" $ }} | ||
spec: | ||
provider: {{ include "velero.volumeSnapshotLocation.provider" . }} | ||
{{- with .Values.configuration.volumeSnapshotLocation.config }} | ||
provider: {{ .provider }} | ||
{{- with .config }} | ||
config: | ||
{{- range $key, $value := . }} | ||
{{- $key | nindent 4 }}: {{ $value | quote }} | ||
{{- end }} | ||
{{- end -}} | ||
{{- end }} | ||
{{- end }} | ||
{{- end }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters