Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
64 changes: 31 additions & 33 deletions modules/hcp-dr-oadp-dpa.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -2,23 +2,21 @@
//
// * hosted_control_planes/hcp-disaster-recovery-oadp-auto.adoc

:_mod-docs-content-type: REFERENCE
:_mod-docs-content-type: PROCEDURE
[id="hcp-dr-oadp-dpa_{context}"]
= Automating the backup and restore process by using a DPA

[role="_abstract"]
You can automate parts of the backup and restore process by using a Data Protection Application (DPA). When you use a DPA, the steps to pause and restart the reconciliation of resources are automated. The DPA defines information including backup locations and Velero pod configurations.

You can create a DPA by defining a `DataProtectionApplication` object.

.Procedure

* If you use a bare-metal platform, you can create a DPA by completing the following steps:
* If you use bare metal, you can create a DPA by completing the following steps:

. Create a manifest file similar to the following example:
+
.Example `dpa.yaml` file
[%collapsible]
====
[source,yaml]
----
apiVersion: oadp.openshift.io/v1alpha1
Expand All @@ -30,34 +28,34 @@ spec:
backupLocations:
- name: default
velero:
provider: aws # <1>
provider: aws
default: true
objectStorage:
bucket: <bucket_name> # <2>
prefix: <bucket_prefix> # <3>
bucket: <bucket_name>
prefix: <bucket_prefix>
config:
region: minio # <4>
region: minio
profile: "default"
s3ForcePathStyle: "true"
s3Url: "<bucket_url>" # <5>
s3Url: "<bucket_url>"
insecureSkipTLSVerify: "true"
credential:
key: cloud
name: cloud-credentials
default: true
snapshotLocations:
- velero:
provider: aws # <1>
provider: aws
config:
region: minio # <4>
region: minio
profile: "default"
credential:
key: cloud
name: cloud-credentials
configuration:
nodeAgent:
enable: true
uploaderType: kopia #<6>
uploaderType: kopia
velero:
defaultPlugins:
- openshift
Expand All @@ -66,13 +64,15 @@ spec:
- hypershift
resourceTimeout: 2h
----
====
<1> Specify the provider for Velero. If you are using bare metal and MinIO, you can use `aws` as the provider.
<2> Specify the bucket name; for example, `oadp-backup`.
<3> Specify the bucket prefix; for example, `hcp`.
<4> The bucket region in this example is `minio`, which is a storage provider that is compatilble with the S3 API.
<5> Specify the URL of the S3 endpoint.
<6> Specify `kopia` as the uploader type. The `restic` uploader type is deprecated for {oadp-short} 1.5 and later.
+
* `spec.backupLocations.velero.provider` specifies the provider for Velero. If you are using bare metal and MinIO, you can use `aws` as the provider.
* `spec.backupLocations.velero.objectStorage.bucket` specifies the bucket name; for example, `oadp-backup`.
* `sepc.backupLocations.velero.objectStorage.prefix` specifies the bucket prefix; for example, `hcp`.
* `spec.backupLocations.velero.config.region` specifies the bucket region. In this example, the region is `minio`, which is a storage provider that is compatible with the S3 API.
* `spec.backupLocations.velero.config.s3Url` specifies the URL of the S3 endpoint.
* `spec.snapshotLocations.velero.provider` specifies the provider for Velero. If you are using bare metal and MinIO, you can use `aws` as the provider.
* `spec.snapshotLocations.velero.config.region` specifies the region. In this example, the region is `minio`, which is a storage provider that is compatible with the S3 API.
* `spec.configuration.nodeAgent.uploaderType` specifies `kopia` as the uploader type. The `restic` uploader type is deprecated for {oadp-short} 1.5 and later.

. Create the DPA object by running the following command:
+
Expand All @@ -87,9 +87,6 @@ After you create the `DataProtectionApplication` object, new `velero` deployment

. Create a manifest file similar to the following example:
+
.Example `dpa.yaml` file
[%collapsible]
====
[source,yaml]
----
apiVersion: oadp.openshift.io/v1alpha1
Expand All @@ -104,10 +101,10 @@ spec:
provider: aws
default: true
objectStorage:
bucket: <bucket_name> # <1>
prefix: <bucket_prefix> # <2>
bucket: <bucket_name>
prefix: <bucket_prefix>
config:
region: minio # <3>
region: minio
profile: "backupStorage"
credential:
key: cloud
Expand All @@ -116,15 +113,15 @@ spec:
- velero:
provider: aws
config:
region: minio # <3>
region: minio
profile: "volumeSnapshot"
credential:
key: cloud
name: cloud-credentials
configuration:
nodeAgent:
enable: true
uploaderType: kopia # <4>
uploaderType: kopia
velero:
defaultPlugins:
- openshift
Expand All @@ -133,11 +130,12 @@ spec:
- hypershift
resourceTimeout: 2h
----
====
<1> Specify the bucket name; for example, `oadp-backup`.
<2> Specify the bucket prefix; for example, `hcp`.
<3> The bucket region in this example is `minio`, which is a storage provider that is compatilble with the S3 API.
<4> Specify `kopia` as the uploader type. The `restic` uploader type is deprecated for {oadp-short} 1.5 and later.
+
* `spec.backupLocations.velero.objectStorage.bucket` specifies the bucket name; for example, `oadp-backup`.
* `spec.backupLocations.velero.objectStorage.prefix` specifies the bucket prefix; for example, `hcp`.
* `spec.backupLocations.velero.config.region` specifies the bucket region. The bucket region in this example is `minio`, which is a storage provider that is compatible with the S3 API.
* `spec.snapshotLocations.velero.config.region` specifies the region. The region in this example is `minio`, which is a storage provider that is compatible with the S3 API.
* `spec.configuration.nodeAgent.uploaderType` specifies `kopia` as the uploader type. The `restic` uploader type is deprecated for {oadp-short} 1.5 and later.

. Create the DPA resource by running the following command:
+
Expand Down