Skip to content

[OSPRH-16305] Introduce OpenStackLightspeed#1495

Merged
openshift-merge-bot[bot] merged 1 commit into
openstack-k8s-operators:mainfrom
lpiwowar:lpiwowar/lightspeed-cr
Aug 15, 2025
Merged

[OSPRH-16305] Introduce OpenStackLightspeed#1495
openshift-merge-bot[bot] merged 1 commit into
openstack-k8s-operators:mainfrom
lpiwowar:lpiwowar/lightspeed-cr

Conversation

@lpiwowar

@lpiwowar lpiwowar commented Jun 23, 2025

Copy link
Copy Markdown
Contributor

Introduce the OpenStackLightspeed custom resource that manages the
deployment of Lightspeed-related functionalities. As of now, we expect
the OLS operator to be present in the cluster. Otherwise, enabling of
OpenStackLightspeed will fail. The Lightspeed functionalities can be
enabled through the OpenStackLightspeed as follows:

spec:
  llmEndpoint: <URL of the LLM>
  llmEndpointType: <endpoint type>
  llmCredentials: <secret containing token>
  modelName: <model name>
  tlsCACertBundle: <config map containg cert>

Only one OpenStackLightspeed CR can configure OpenStack Lightspeed at a
single time. If the user tries to manage the Lightspeed functionalities
through two or more OpenStackLightspeed instances, the user will be
warned, and the changes from the newest OpenStackLightspeed instance
will be ignored.

@openshift-ci

openshift-ci Bot commented Jun 23, 2025

Copy link
Copy Markdown
Contributor

Skipping CI for Draft Pull Request.
If you want CI signal for your change, please convert it to an actual PR.
You can still manually trigger a test run with /test all

@lpiwowar

Copy link
Copy Markdown
Contributor Author

/test all

@lpiwowar lpiwowar force-pushed the lpiwowar/lightspeed-cr branch from aaa290a to 31e3f58 Compare June 23, 2025 11:09
@lpiwowar

Copy link
Copy Markdown
Contributor Author

/test all

@lpiwowar lpiwowar force-pushed the lpiwowar/lightspeed-cr branch from 31e3f58 to ad47b46 Compare June 23, 2025 11:32
@lpiwowar

Copy link
Copy Markdown
Contributor Author

/test all

@ratailor ratailor left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please fix one minor nit in comment and other for adding the pattern, we replicated in all operators, when you respin the PR.

Comment thread apis/core/v1beta1/conditions.go Outdated
Comment thread controllers/lightspeed/openstacklightspeed_controller.go
@lpiwowar lpiwowar force-pushed the lpiwowar/lightspeed-cr branch 2 times, most recently from 743b77d to ad85e76 Compare June 24, 2025 17:23
@lpiwowar

Copy link
Copy Markdown
Contributor Author

/test all

@lpiwowar

Copy link
Copy Markdown
Contributor Author

/test openstack-operator-build-deploy-kuttl

@lpiwowar lpiwowar marked this pull request as ready for review June 25, 2025 10:41
@openshift-ci openshift-ci Bot requested review from abays and jpodivin June 25, 2025 10:42
@lpiwowar lpiwowar requested review from Akrog, csibbitt, dprince and umago and removed request for jpodivin June 25, 2025 10:42
@lpiwowar

Copy link
Copy Markdown
Contributor Author

This is the reason why the pre-commit checks are failing:

ERROR: "NoNewRequiredFields": crd/openstackcontrolplanes.core.openstack.org version/v1beta1 field/^.spec.openstacklightspeed.template.TLSCACertBundle is new and may not be required
ERROR: "NoNewRequiredFields": crd/openstackcontrolplanes.core.openstack.org version/v1beta1 field/^.spec.openstacklightspeed.template.llmCredentials is new and may not be required
ERROR: "NoNewRequiredFields": crd/openstackcontrolplanes.core.openstack.org version/v1beta1 field/^.spec.openstacklightspeed.template.llmEndpoint is new and may not be required
ERROR: "NoNewRequiredFields": crd/openstackcontrolplanes.core.openstack.org version/v1beta1 field/^.spec.openstacklightspeed.template.llmEndpointType is new and may not be required
ERROR: "NoNewRequiredFields": crd/openstackcontrolplanes.core.openstack.org version/v1beta1 field/^.spec.openstacklightspeed.template.modelName is new and may not be required
+ cleanup 

It is about the introduction of new required fields. The newly introduced fields are wrapped in Optional section so it should not break the backward compatibility for the OpenStackControlPlane. Unless I'm mistaken.

Comment thread controllers/lightspeed/openstacklightspeed_controller.go
Comment thread controllers/core/openstackcontrolplane_controller.go Outdated

@lpiwowar lpiwowar left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One question related to the OpenStackLightspeed image. If somebody who is working on the openstack-operator has a perspective on this it would be really appreciated!:)

Comment thread pkg/lightspeed/funcs.go Outdated
@lpiwowar lpiwowar requested review from dprince and stuggi June 30, 2025 16:03

@stuggi stuggi left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

maybe a general question for my understanding of OpenStackLightspeed. is it intended that it talks to the openstack api of the ctlplane it gets installed with?

Comment thread apis/lightspeed/v1beta1/openstacklightspeed_types.go Outdated
Comment thread apis/lightspeed/v1beta1/webhook_suite_test.go
Comment thread pkg/lightspeed/funcs.go Outdated
Comment thread pkg/lightspeed/funcs.go Outdated
Comment thread pkg/lightspeed/funcs.go Outdated
@lpiwowar

lpiwowar commented Jul 4, 2025

Copy link
Copy Markdown
Contributor Author

Is it intended that it talks to the openstack api of the ctlplane it gets installed with?

@stuggi: Not right now, but this might come in the future.

@lpiwowar

Copy link
Copy Markdown
Contributor Author

/retest

1 similar comment
@lpiwowar

Copy link
Copy Markdown
Contributor Author

/retest

@lpiwowar lpiwowar requested a review from stuggi July 31, 2025 11:56
@lpiwowar lpiwowar force-pushed the lpiwowar/lightspeed-cr branch from 289da51 to 9d4c0a2 Compare August 1, 2025 12:19
@softwarefactory-project-zuul

Copy link
Copy Markdown

Build failed (check pipeline). Post recheck (without leading slash)
to rerun all jobs. Make sure the failure cause has been resolved before
you rerun jobs.

https://softwarefactory-project.io/zuul/t/rdoproject.org/buildset/637258ceae09405f853596ef5420d4b8

✔️ openstack-k8s-operators-content-provider SUCCESS in 3h 18m 13s
✔️ podified-multinode-edpm-deployment-crc SUCCESS in 1h 13m 13s
✔️ cifmw-crc-podified-edpm-baremetal SUCCESS in 1h 34m 20s
✔️ adoption-standalone-to-crc-ceph-provider SUCCESS in 3h 02m 39s
openstack-operator-tempest-multinode RETRY_LIMIT in 3m 39s

@lpiwowar

lpiwowar commented Aug 1, 2025

Copy link
Copy Markdown
Contributor Author

recheck

/retest

@lpiwowar

lpiwowar commented Aug 1, 2025

Copy link
Copy Markdown
Contributor Author

@dprince if you could please take a look once you have time, all the @stuggi's comments should be addressed 🙏

TestTobikoImage *string `json:"testTobikoImage,omitempty"`
TestHorizontestImage *string `json:"testHorizontestImage,omitempty"`
TestAnsibletestImage *string `json:"testAnsibletestImage,omitempty"`
OpenstackLightspeedImage *string `json:"openstackLightspeedImage,omitempty"`

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it would be good to drop the parameter from the OpenStackVersion and Controlplane resources and just have Lightspeed obtain its Image directly from the ENV variable. This would also work in the case where Lightspeed gets installed ahead of the Controlplane if that use case materializes.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It has already been dropped from the OpenStackControlplane and regarding the OpenStackVersion, the code is written in such a way that it will work in both case:

  • when OpenStackVersion is present, we use an image from OpenStackVersion
  • when OpenStackVersion is not present, we fall back to the default image specified through the ENV variable

Is there any specific problem with this I'm not seeing? I'm just trying to understand.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just for the record, the OpenStackVersion section was removed as well with the recent update.

@lpiwowar lpiwowar requested a review from dprince August 1, 2025 17:41
@lpiwowar lpiwowar force-pushed the lpiwowar/lightspeed-cr branch from 9d4c0a2 to ee8f7a8 Compare August 11, 2025 12:48
@softwarefactory-project-zuul

Copy link
Copy Markdown

Build failed (check pipeline). Post recheck (without leading slash)
to rerun all jobs. Make sure the failure cause has been resolved before
you rerun jobs.

https://softwarefactory-project.io/zuul/t/rdoproject.org/buildset/c282b3ccca9148d7be294f483154c3aa

✔️ openstack-k8s-operators-content-provider SUCCESS in 2h 35m 42s
podified-multinode-edpm-deployment-crc FAILURE in 1h 32m 41s
cifmw-crc-podified-edpm-baremetal FAILURE in 1h 37m 51s
adoption-standalone-to-crc-ceph-provider FAILURE in 2h 20m 39s
openstack-operator-tempest-multinode FAILURE in 1h 34m 26s

@lpiwowar

Copy link
Copy Markdown
Contributor Author

/retest-required

@lpiwowar

Copy link
Copy Markdown
Contributor Author

recheck

@lpiwowar

Copy link
Copy Markdown
Contributor Author

/retest-required

@lpiwowar lpiwowar force-pushed the lpiwowar/lightspeed-cr branch 2 times, most recently from 46e9015 to 7cc36da Compare August 14, 2025 12:00
Introduce the OpenStackLightspeed custom resource that manages the
deployment of Lightspeed-related functionalities. As of now, we expect
the OLS operator to be present in the cluster. Otherwise, enabling of
OpenStackLightspeed will fail. The Lightspeed functionalities can be
enabled through the OpenStackLightspeed as follows:

spec:
  llmEndpoint: <URL of the LLM>
  llmEndpointType: <endpoint type>
  llmCredentials: <secret containing token>
  modelName: <model name>
  tlsCACertBundle: <config map containg cert>

Only one OpenStackLightspeed CR can configure OpenStack Lightspeed at a
single time. If the user tries to manage the Lightspeed functionalities
through two or more OpenStackLightspeed instances, the user will be
warned, and the changes from the newest OpenStackLightspeed instance
will be ignored.
@lpiwowar lpiwowar force-pushed the lpiwowar/lightspeed-cr branch from 7cc36da to 8362b19 Compare August 14, 2025 12:02
@softwarefactory-project-zuul

Copy link
Copy Markdown

Build failed (check pipeline). Post recheck (without leading slash)
to rerun all jobs. Make sure the failure cause has been resolved before
you rerun jobs.

https://softwarefactory-project.io/zuul/t/rdoproject.org/buildset/3aa21f78ca1b4b33807b7695597436f6

✔️ openstack-k8s-operators-content-provider SUCCESS in 1h 55m 46s
✔️ podified-multinode-edpm-deployment-crc SUCCESS in 1h 17m 40s
✔️ cifmw-crc-podified-edpm-baremetal SUCCESS in 1h 19m 36s
adoption-standalone-to-crc-ceph-provider RETRY_LIMIT in 7m 36s
✔️ openstack-operator-tempest-multinode SUCCESS in 1h 39m 44s

@lpiwowar

Copy link
Copy Markdown
Contributor Author

recheck

@softwarefactory-project-zuul

Copy link
Copy Markdown

Build failed (check pipeline). Post recheck (without leading slash)
to rerun all jobs. Make sure the failure cause has been resolved before
you rerun jobs.

https://softwarefactory-project.io/zuul/t/rdoproject.org/buildset/d9217dbd32ae42519c3801bd06c25d64

✔️ openstack-k8s-operators-content-provider SUCCESS in 3h 29m 54s
✔️ podified-multinode-edpm-deployment-crc SUCCESS in 1h 10m 39s
✔️ cifmw-crc-podified-edpm-baremetal SUCCESS in 1h 24m 36s
✔️ adoption-standalone-to-crc-ceph-provider SUCCESS in 3h 08m 58s
openstack-operator-tempest-multinode RETRY_LIMIT in 9m 05s

@lpiwowar

Copy link
Copy Markdown
Contributor Author

recheck
/retest-required

@openshift-ci openshift-ci Bot added the lgtm label Aug 15, 2025
@openshift-ci

openshift-ci Bot commented Aug 15, 2025

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: dprince, lpiwowar

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-merge-bot openshift-merge-bot Bot merged commit 35723e2 into openstack-k8s-operators:main Aug 15, 2025
9 checks passed
umago added a commit to umago/osls-operator that referenced this pull request Oct 14, 2025
This patch introduces the existing OpenStack Lightspeed API from
openstack-k8s-operators/openstack-operator#1495

Co-authored-by: Lukáš Piwowarski <lpiwowar@redhat.com>
Signed-off-by: Lucas Alvares Gomes <lucasagomes@gmail.com>
umago added a commit to umago/osls-operator that referenced this pull request Oct 14, 2025
This patch introduces the existing
OpenStack Lightspeed Controller code from
openstack-k8s-operators/openstack-operator#1495

Co-authored-by: Lukáš Piwowarski <lpiwowar@redhat.com>
Signed-off-by: Lucas Alvares Gomes <lucasagomes@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants