Skip to content

Commit 9ba68e1

Browse files
committed
cyborg: Add kuttl integration tests for Cyborg deployment
Add an end-to-end kuttl test suite for the Cyborg operator: - Cleanup step to delete any pre-existing Cyborg CR before the test - Deploy step creating a full Cyborg CR (cyborg-kuttl) - Assert step verifying all conditions are True on Cyborg, CyborgAPI, CyborgConductor and MariaDBDatabase CRs - Error step covering missing-dependency failure scenarios - Register cyborg container images (api, conductor, agent) as default RELATED_IMAGE env vars in the manager deployment - Enable ENABLE_CYBORG=true in the CI webhook deploy script Assisted-By: Claude Signed-off-by: Alfredo Moralejo <amoralej@redhat.com>
1 parent 289eab9 commit 9ba68e1

10 files changed

Lines changed: 603 additions & 0 deletions

File tree

Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -447,6 +447,7 @@ crd-schema-check: manifests
447447

448448
.PHONY: run_with_olm
449449
run_with_olm: export CATALOG_IMG=${CATALOG_IMAGE}
450+
run_with_olm: export ENABLE_CYBORG?=false
450451
run_with_olm: ## Install nova operator via olm
451452
# explicitly to delete any running nova-operator deployments from openstack-operator here as
452453
# label selectors can change and installing a service catalog/index like this alongside

ci/nova-operator-kuttl/deploy_webhooks.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,3 +19,4 @@
1919
script: make run_with_olm
2020
extra_args:
2121
CATALOG_IMAGE: "{{ nova_catalog_image }}"
22+
ENABLE_CYBORG: "true"

ci/olm.sh

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
ENABLE_CYBORG=${ENABLE_CYBORG:-false}
2+
13
cat > ci/olm.yaml <<EOF_CAT
24
---
35
apiVersion: v1
@@ -33,4 +35,8 @@ spec:
3335
channel: alpha
3436
source: nova-operator-index
3537
sourceNamespace: openstack-operators
38+
config:
39+
env:
40+
- name: ENABLE_CYBORG
41+
value: "${ENABLE_CYBORG}"
3642
EOF_CAT

config/default/manager_default_images.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,3 +21,9 @@ spec:
2121
value: quay.io/podified-antelope-centos9/openstack-nova-scheduler:current-podified
2222
- name: RELATED_IMAGE_NOVA_COMPUTE_IMAGE_URL_DEFAULT
2323
value: quay.io/podified-antelope-centos9/openstack-nova-compute:current-podified
24+
- name: RELATED_IMAGE_CYBORG_API_IMAGE_URL_DEFAULT
25+
value: quay.io/openstack.kolla/cyborg-api:master-rocky-10
26+
- name: RELATED_IMAGE_CYBORG_CONDUCTOR_IMAGE_URL_DEFAULT
27+
value: quay.io/openstack.kolla/cyborg-conductor:master-rocky-10
28+
- name: RELATED_IMAGE_CYBORG_AGENT_IMAGE_URL_DEFAULT
29+
value: quay.io/openstack.kolla/cyborg-agent:master-rocky-10
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
apiVersion: kuttl.dev/v1beta1
2+
kind: TestStep
3+
delete:
4+
- apiVersion: cyborg.openstack.org/v1beta1
5+
kind: Cyborg
6+
name: cyborg-kuttl
7+
namespace: nova-kuttl-default

0 commit comments

Comments
 (0)