Skip to content

Commit

Permalink
Deploy recipe CRD in all DR environments
Browse files Browse the repository at this point in the history
Recently the recipe CRD[1] became required if kube object protection is
enabled, so we must have it in the test environment unless we disable
the feature. Disabling the feature is not a good idea since we will want
to be able to test imperative apps or declerative apps that need recipes
(e.g. kubvirt with DataVolumeTemplate).

[1] https://github.com/RamenDR/recipe/blob/main/config/crd/bases/ramendr.openshift.io_recipes.yaml

Signed-off-by: Nir Soffer <nsoffer@redhat.com>
  • Loading branch information
nirs authored and raghavendra-talur committed Nov 30, 2023
1 parent 5cdc7eb commit e709cd0
Show file tree
Hide file tree
Showing 5 changed files with 26 additions and 0 deletions.
22 changes: 22 additions & 0 deletions test/addons/recipe/start
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
#!/usr/bin/env python3

# SPDX-FileCopyrightText: The RamenDR authors
# SPDX-License-Identifier: Apache-2.0

import os
import sys

from drenv import kubectl

if len(sys.argv) != 2:
sys.exit(f"Usage: {sys.argv[0]} cluster")

os.chdir(os.path.dirname(__file__))
cluster = sys.argv[1]

print("Deploying recipe crd")
kubectl.apply(
"--kustomize",
"https://github.com/RamenDR/recipe.git/config/crd?ref=main&timeout=120s",
context=cluster,
)
1 change: 1 addition & 0 deletions test/envs/regional-dr-external.yaml.example
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ templates:
- addons:
- name: ocm-cluster
args: ["$name", "hub"]
- name: recipe
- addons:
- name: cert-manager
- name: csi-addons
Expand Down
1 change: 1 addition & 0 deletions test/envs/regional-dr-hubless.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ templates:
- name: olm
- name: minio
- name: velero
- name: recipe

profiles:
- name: "dr1"
Expand Down
1 change: 1 addition & 0 deletions test/envs/regional-dr-kubevirt.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ templates:
- name: ocm-cluster
args: ["$name", "hub"]
- name: cdi
- name: recipe
- addons:
- name: csi-addons
- name: olm
Expand Down
1 change: 1 addition & 0 deletions test/envs/regional-dr.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ templates:
- addons:
- name: ocm-cluster
args: ["$name", "hub"]
- name: recipe
- addons:
- name: csi-addons
- name: olm
Expand Down

0 comments on commit e709cd0

Please sign in to comment.