forked from helm/charts
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[stable/velero] Upgrade Ark 0.10.x to Velero 0.11 (helm#12031)
* Change Ark to Velero and upgrade from 0.10.1 to 0.11.0 Signed-off-by: Joe Gorse <[email protected]> * Change velero.heptio.com to velero.io Signed-off-by: Joe Gorse <[email protected]> * Add CRD for serverstatusrequest Fix version number of velero. Signed-off-by: Aman Wangde <[email protected]> * Change namespace to 'velero' Signed-off-by: Aman Wangde <[email protected]> * Fix README for upgrade instructions Signed-off-by: Joe Gorse <[email protected]> * Add Ark back in Signed-off-by: Ethan Kaley <[email protected]> * Deprecate the stable/Ark chart Signed-off-by: Joe Gorse <[email protected]> * Fix version issues Signed-off-by: Ethan Kaley <[email protected]> * Remove references to v0.10.x Signed-off-by: Joe Gorse <[email protected]> * Fix indentation issue and add to restic-daemonset tpl Signed-off-by: Joe Gorse <[email protected]> * Add missing newline Move commented value example Signed-off-by: Joe Gorse <[email protected]> * Bump Ark chart version for deprecation Signed-off-by: Ethan Kaley <[email protected]> * Fix labels (helm#1) * Fix labels Signed-off-by: Ethan Kaley <[email protected]> Signed-off-by: Joe Gorse <[email protected]> * Use include instead of template function Signed-off-by: Reinhard Nägele <[email protected]> * Remove variables Signed-off-by: Reinhard Nägele <[email protected]> * Use with and nindent Signed-off-by: Reinhard Nägele <[email protected]> * Update API versions Signed-off-by: Reinhard Nägele <[email protected]> * Updated Ark chart to a patch bump Signed-off-by: Joe Gorse <[email protected]> * Add comments and fix NOTES template Signed-off-by: Joe Gorse <[email protected]> * Fix deployment template for podAnnotations Signed-off-by: Ethan Kaley <[email protected]>
- Loading branch information
1 parent
992003f
commit 7b68258
Showing
30 changed files
with
899 additions
and
7 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,14 @@ | ||
apiVersion: v1 | ||
appVersion: 0.10.2 | ||
description: A Helm chart for ark | ||
## This Ark chart is deprecated because Ark has been renamed to Velero as of Velero version 0.11.0. | ||
## This chart is no longer maintained. Use the stable/velero chart for future work. | ||
## Please see the Helm deprecation policy in the PROCESSES.md file. | ||
deprecated: true | ||
description: DEPRECATED A Helm chart for ark | ||
name: ark | ||
version: 4.2.1 | ||
version: 4.2.2 | ||
home: https://github.com/heptio/ark | ||
icon: https://cdn-images-1.medium.com/max/1600/1*-9mb3AKnKdcL_QD3CMnthQ.png | ||
sources: | ||
- https://github.com/heptio/ark | ||
maintainers: | ||
- name: domcar | ||
email: [email protected] | ||
- name: unguiculus | ||
email: [email protected] | ||
tillerVersion: ">=2.10.0" |
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 |
---|---|---|
@@ -0,0 +1,21 @@ | ||
# Patterns to ignore when building packages. | ||
# This supports shell glob matching, relative path matching, and | ||
# negation (prefixed with !). Only one pattern per line. | ||
.DS_Store | ||
# Common VCS dirs | ||
.git/ | ||
.gitignore | ||
.bzr/ | ||
.bzrignore | ||
.hg/ | ||
.hgignore | ||
.svn/ | ||
# Common backup files | ||
*.swp | ||
*.bak | ||
*.tmp | ||
*~ | ||
# Various IDEs | ||
.project | ||
.idea/ | ||
*.tmproj |
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 |
---|---|---|
@@ -0,0 +1,15 @@ | ||
apiVersion: v1 | ||
appVersion: 0.11.0 | ||
description: A Helm chart for velero | ||
name: velero | ||
version: 1.0.0 | ||
home: https://github.com/heptio/velero | ||
icon: https://cdn-images-1.medium.com/max/1600/1*-9mb3AKnKdcL_QD3CMnthQ.png | ||
sources: | ||
- https://github.com/heptio/velero | ||
maintainers: | ||
- name: domcar | ||
email: [email protected] | ||
- name: unguiculus | ||
email: [email protected] | ||
tillerVersion: ">=2.10.0" |
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 |
---|---|---|
@@ -0,0 +1,85 @@ | ||
# Velero-server | ||
|
||
This helm chart installs Velero version v0.11.0 | ||
https://github.com/heptio/velero/tree/v0.11.0 | ||
|
||
|
||
## Upgrading to v0.11.0 | ||
|
||
As of v0.11.0, Heptio Ark has become Velero. | ||
|
||
The [instructions found here](https://heptio.github.io/velero/v0.11.0/migrating-to-velero) will assist you in upgrading from Ark to Velero | ||
|
||
## Prerequisites | ||
|
||
### Secret for cloud provider credentials | ||
Velero server needs an IAM service account in order to run, if you don't have it you must create it. | ||
Please follow the official documentation: https://heptio.github.io/velero/v0.11.0/install-overview | ||
|
||
Don't forget the step to create the secret | ||
``` | ||
kubectl create secret generic cloud-credentials --namespace <VELERO_NAMESPACE> --from-file cloud=credentials-velero | ||
``` | ||
|
||
### Configuration | ||
Please change the values.yaml according to your setup | ||
See here for the official documentation https://heptio.github.io/velero/v0.11.0/install-overview | ||
|
||
Parameter | Description | Default | Required | ||
--- | --- | --- | --- | ||
`cloudprovider` | Cloud provider | `nil` | yes | ||
`bucket` | Object storage where to store backups | `nil` | yes | ||
`region` | AWS region | `nil` | only if using AWS | ||
`apitimeout` | Api Timeout | `nil` | only if using Azure | ||
`credentials` | Credentials | `nil` | Yes (not required for kube2iam) | ||
`backupSyncPeriod` | How frequently Velero queries the object storage to make sure that the appropriate Backup resources have been created for existing backup files. | `60m` | yes | ||
`gcSyncPeriod` | How frequently Velero queries the object storage to delete backup files that have passed their TTL. | `60m` | yes | ||
`scheduleSyncPeriod` | How frequently Velero checks its Schedule resource objects to see if a backup needs to be initiated | `1m` | yes | ||
`restoreOnlyMode` | When RestoreOnly mode is on, functionality for backups, schedules, and expired backup deletion is turned off. Restores are made from existing backup files in object storage. | `false` | yes | ||
|
||
Parameter | Description | Default | ||
--- | --- | --- | ||
`image.repository` | Image repository | `gcr.io/heptio-images/velero` | ||
`image.tag` | Image tag | `v0.11.0` | ||
`image.pullPolicy` | Image pull policy | `IfNotPresent` | ||
`podAnnotations` | Annotations for the Velero server pod | `{}` | ||
`rbac.create` | If true, create and use RBAC resources | `true` | ||
`rbac.server.serviceAccount.create` | Whether a new service account name that the server will use should be created | `true` | ||
`rbac.server.serviceAccount.name` | Service account to be used for the server. If not set and `rbac.server.serviceAccount.create` is `true` a name is generated using the fullname template | `` | ||
`resources` | Resource requests and limits | `{}` | ||
`initContainers` | InitContainers and their specs to start with the deployment pod | `[]` | ||
`tolerations` | List of node taints to tolerate | `[]` | ||
`nodeSelector` | Node labels for pod assignment | `{}` | ||
`configuration.backupStorageLocation.name` | The name of the cloud provider that will be used to actually store the backups (`aws`, `azure`, `gcp`) | `` | ||
`configuration.backupStorageLocation.bucket` | The storage bucket where backups are to be uploaded | `` | ||
`configuration.backupStorageLocation.config.region` | The cloud provider region (AWS only) | `` | ||
`configuration.backupStorageLocation.config.s3ForcePathStyle` | Set to `true` for a local storage service like Minio | `` | ||
`configuration.backupStorageLocation.config.s3Url` | S3 url (primarily used for local storage services like Minio) | `` | ||
`configuration.backupStorageLocation.config.kmsKeyId` | KMS key for encryption (AWS only) | `` | ||
`configuration.backupStorageLocation.prefix` | The directory inside a storage bucket where backups are to be uploaded | `` | ||
`configuration.backupSyncPeriod` | How frequently Velero queries the object storage to make sure that the appropriate Backup resources have been created for existing backup files | `60m` | ||
`configuration.extraEnvVars` | Key/values for extra environment variables such as AWS_CLUSTER_NAME, etc | `{}` | ||
`configuration.provider` | The name of the cloud provider where you are deploying velero to (`aws`, `azure`, `gcp`) | | ||
`configuration.restoreResourcePriorities` | An ordered list that describes the order in which Kubernetes resource objects should be restored | `namespaces,persistentvolumes,persistentvolumeclaims,secrets,configmaps,serviceaccounts,limitranges,pods` | ||
`configuration.restoreOnlyMode` | When RestoreOnly mode is on, functionality for backups, schedules, and expired backup deletion is turned off. Restores are made from existing backup files in object storage | `false` | ||
`configuration.volumeSnapshotLocation.name` | The name of the cloud provider the cluster is using for persistent volumes, if any | `{}` | ||
`configuration.volumeSnapshotLocation.config.region` | The cloud provider region (AWS only) | `` | ||
`configuration.volumeSnapshotLocation.config.apiTimeout` | The API timeout (`azure` only) | | ||
`credentials.existingSecret` | If specified and `useSecret` is `true`, uses an existing secret with this name instead of creating one | `` | ||
`credentials.useSecret` | Whether a secret should be used. Set this to `false` when using `kube2iam` | `true` | ||
`credentials.secretContents` | Contents for the credentials secret | `{}` | ||
`deployRestic` | If `true`, enable restic deployment | `false` | ||
`metrics.enabled` | Set this to `true` to enable exporting Prometheus monitoring metrics | `false` | ||
`metrics.scrapeInterval` | Scrape interval for the Prometheus ServiceMonitor | `30s` | ||
`metrics.serviceMonitor.enabled` | Set this to `true` to create ServiceMonitor for Prometheus operator | `false` | ||
`metrics.serviceMonitor.additionalLabels` | Additional labels that can be used so ServiceMonitor will be discovered by Prometheus | `{}` | ||
`schedules` | A dict of schedules | `{}` | ||
|
||
|
||
## How to | ||
``` | ||
helm install --name velero --namespace velero ./velero | ||
``` | ||
|
||
## Remove heptio/velero | ||
Remember that when you remove Velero all backups remain untouched |
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 |
---|---|---|
@@ -0,0 +1,15 @@ | ||
Check that the velero is up and running: | ||
|
||
kubectl get deployment/{{ .Release.Name }} -n {{ .Release.Namespace }} | ||
|
||
Check that the secret has been created: | ||
|
||
kubectl get secret/{{ include "velero.fullname" . }} -n {{ .Release.Namespace }} | ||
|
||
Check that the secret has been created: | ||
|
||
Once velero server is up and running you need the client before you can use it | ||
1. wget https://github.com/heptio/velero/releases/download/{{ .Values.image.tag }}/velero-{{ .Values.image.tag }}-darwin-amd64.tar.gz | ||
2. tar -xvf velero-{{ .Values.image.tag }}-darwin-amd64.tar.gz -C velero-client | ||
|
||
More info on the official site: https://github.com/heptio/velero#install-client |
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 |
---|---|---|
@@ -0,0 +1,54 @@ | ||
{{/* vim: set filetype=mustache: */}} | ||
{{/* | ||
Expand the name of the chart. | ||
*/}} | ||
{{- define "velero.name" -}} | ||
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" -}} | ||
{{- end -}} | ||
|
||
{{/* | ||
Create a default fully qualified app name. | ||
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec). | ||
If release name contains chart name it will be used as a full name. | ||
*/}} | ||
{{- define "velero.fullname" -}} | ||
{{- if .Values.fullnameOverride -}} | ||
{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" -}} | ||
{{- else -}} | ||
{{- $name := default .Chart.Name .Values.nameOverride -}} | ||
{{- if contains $name .Release.Name -}} | ||
{{- .Release.Name | trunc 63 | trimSuffix "-" -}} | ||
{{- else -}} | ||
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}} | ||
{{- end -}} | ||
{{- end -}} | ||
{{- end -}} | ||
|
||
{{/* | ||
Create chart name and version as used by the chart label. | ||
*/}} | ||
{{- define "velero.chart" -}} | ||
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" -}} | ||
{{- end -}} | ||
|
||
{{/* | ||
Create the name of the service account to use for creating or deleting the velero server | ||
*/}} | ||
{{- define "velero.serverServiceAccount" -}} | ||
{{- if .Values.serviceAccount.server.create -}} | ||
{{ default (printf "%s-%s" (include "velero.fullname" .) "server") .Values.serviceAccount.server.name }} | ||
{{- else -}} | ||
{{ default "default" .Values.serviceAccount.server.name }} | ||
{{- end -}} | ||
{{- end -}} | ||
|
||
{{/* | ||
Create the name for the credentials secret. | ||
*/}} | ||
{{- define "velero.secretName" -}} | ||
{{- if .Values.credentials.existingSecret -}} | ||
{{- .Values.credentials.existingSecret -}} | ||
{{- else -}} | ||
{{- include "velero.fullname" . -}} | ||
{{- 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
apiVersion: apiextensions.k8s.io/v1beta1 | ||
kind: CustomResourceDefinition | ||
metadata: | ||
name: backups.velero.io | ||
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" . }} | ||
annotations: | ||
"helm.sh/hook": crd-install | ||
"helm.sh/hook-delete-policy": "before-hook-creation" | ||
spec: | ||
group: velero.io | ||
version: v1 | ||
scope: Namespaced | ||
names: | ||
plural: backups | ||
kind: Backup |
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 |
---|---|---|
@@ -0,0 +1,46 @@ | ||
apiVersion: velero.io/v1 | ||
kind: BackupStorageLocation | ||
metadata: | ||
name: default | ||
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" . }} | ||
spec: | ||
{{- with .Values.configuration }} | ||
{{- with .backupStorageLocation }} | ||
provider: {{ .name }} | ||
objectStorage: | ||
bucket: {{ .bucket }} | ||
{{- with .prefix }} | ||
prefix: {{ . }} | ||
{{- end }} | ||
{{- with .config }} | ||
config: | ||
{{- with .region }} | ||
region: {{ . }} | ||
{{- end }} | ||
{{- with .s3ForcePathStyle }} | ||
s3ForcePathStyle: {{ . | quote }} | ||
{{- end }} | ||
{{- with .s3Url }} | ||
s3Url: {{ . }} | ||
{{- end }} | ||
{{- with .kmsKeyId }} | ||
kmsKeyId: {{ . }} | ||
{{- end }} | ||
{{- with .resourceGroup }} | ||
resourceGroup: {{ . }} | ||
{{- end }} | ||
{{- with .storageAccount }} | ||
storageAccount: {{ . }} | ||
{{- end }} | ||
{{- if .publicUrl }} | ||
{{- with .publicUrl }} | ||
publicUrl: {{ . }} | ||
{{- 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
apiVersion: apiextensions.k8s.io/v1beta1 | ||
kind: CustomResourceDefinition | ||
metadata: | ||
name: backupstoragelocations.velero.io | ||
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" . }} | ||
annotations: | ||
"helm.sh/hook": crd-install | ||
"helm.sh/hook-delete-policy": "before-hook-creation" | ||
spec: | ||
group: velero.io | ||
version: v1 | ||
scope: Namespaced | ||
names: | ||
plural: backupstoragelocations | ||
kind: BackupStorageLocation |
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 |
---|---|---|
@@ -0,0 +1,19 @@ | ||
apiVersion: apiextensions.k8s.io/v1beta1 | ||
kind: CustomResourceDefinition | ||
metadata: | ||
name: deletebackuprequests.velero.io | ||
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" . }} | ||
annotations: | ||
"helm.sh/hook": crd-install | ||
"helm.sh/hook-delete-policy": "before-hook-creation" | ||
spec: | ||
group: velero.io | ||
version: v1 | ||
scope: Namespaced | ||
names: | ||
plural: deletebackuprequests | ||
kind: DeleteBackupRequest |
Oops, something went wrong.