-
Notifications
You must be signed in to change notification settings - Fork 8
Add rhos-mcps support #124
base: lcore-migration
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -46,6 +46,9 @@ const ( | |
| // OKPContainerImage is the fall-back container image for OKP (Offline Knowledge Portal) | ||
| OKPContainerImage = "registry.redhat.io/offline-knowledge-portal/rhokp-rhel9:latest" | ||
|
|
||
| // MCPServerContainerImage is the fall-back container image for the MCP server | ||
| MCPServerContainerImage = "quay.io/openstack-lightspeed/rhos-mcps:latest" | ||
|
Comment on lines
+49
to
+50
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🩺 Stability & Availability | 🟠 Major 🧩 Analysis chain🏁 Script executed: sed -n '1,120p' api/v1beta1/openstacklightspeed_types.go && printf '\n---\n' && sed -n '300,360p' api/v1beta1/openstacklightspeed_types.goRepository: openstack-lightspeed/operator Length of output: 6783 🏁 Script executed: rg -n "MCPServerContainerImage|RELATED_IMAGE_MCP_SERVER_IMAGE_URL_DEFAULT|latest|rhos-mcps" api/v1beta1/openstacklightspeed_types.go api -SRepository: openstack-lightspeed/operator Length of output: 2317 🏁 Script executed: git diff --stat -- api/v1beta1/openstacklightspeed_types.go && printf '\n---\n' && git diff -- api/v1beta1/openstacklightspeed_types.go --unified=20Repository: openstack-lightspeed/operator Length of output: 172 🏁 Script executed: rg -n "RELATED_IMAGE_MCP_SERVER_IMAGE_URL_DEFAULT|MCPServerImageURL|MCPServerContainerImage|rhos-mcps" -S .Repository: openstack-lightspeed/operator Length of output: 1449 🏁 Script executed: rg -n "RELATED_IMAGE_.*IMAGE_URL_DEFAULT|RELATED_IMAGE_.*DEFAULT" -S config bundle manifests deploy api controllers | sed -n '1,220p'Repository: openstack-lightspeed/operator Length of output: 3145 🏁 Script executed: fd -a -t f 'csv|yaml|yml' config bundle manifests deploy . | sed -n '1,200p'Repository: openstack-lightspeed/operator Length of output: 10746 🏁 Script executed: #!/bin/bash
set -euo pipefail
echo "== related image refs =="
rg -n "RELATED_IMAGE_MCP_SERVER_IMAGE_URL_DEFAULT|RELATED_IMAGE_.*IMAGE_URL_DEFAULT" config bundle manifests deploy api controllers -S || true
echo
echo "== candidate manifest files =="
fd -a -t f 'csv|yaml|yml' config bundle manifests deploy . | sed -n '1,200p'Repository: openstack-lightspeed/operator Length of output: 13781 🏁 Script executed: #!/bin/bash
set -euo pipefail
echo "== related image refs =="
rg -n "RELATED_IMAGE_MCP_SERVER_IMAGE_URL_DEFAULT|RELATED_IMAGE_.*IMAGE_URL_DEFAULT" config bundle manifests deploy api controllers -S || true
echo
echo "== manifest files =="
git ls-files 'config/**' 'bundle/**' 'manifests/**' 'deploy/**' | sed -n '1,200p'Repository: openstack-lightspeed/operator Length of output: 5126 Pin the MCP sidecar image to an immutable release.
Suggested change- MCPServerContainerImage = "quay.io/openstack-lightspeed/rhos-mcps:latest"
+ MCPServerContainerImage = "quay.io/openstack-lightspeed/rhos-mcps:<release-or-digest>"🤖 Prompt for AI Agents |
||
|
|
||
| // MaxTokensForResponseDefault is the default maximum number of tokens that should be used for response | ||
| MaxTokensForResponseDefault = 2048 | ||
| ) | ||
|
|
@@ -220,6 +223,16 @@ type OpenStackLightspeedStatus struct { | |
| // ActiveOCPRAGVersion contains the OCP version being used for RAG configuration | ||
| // Will be one of: "4.16", "4.18", "latest", or empty if OCP RAG is disabled | ||
| ActiveOCPRAGVersion string `json:"activeOCPRAGVersion,omitempty"` | ||
|
|
||
| // +optional | ||
| // OpenStackReady indicates whether an OpenStackControlPlane was detected and | ||
| // is ready. When true, the OpenStack MCP tools are included in lightspeed-stack config. | ||
| OpenStackReady bool `json:"openStackReady,omitempty"` | ||
|
|
||
| // +optional | ||
| // ApplicationCredentialSecret is the name of the current AC secret in the | ||
| // OpenStack namespace. Tracked for rotation detection. | ||
| ApplicationCredentialSecret string `json:"applicationCredentialSecret,omitempty"` | ||
| } | ||
|
|
||
| // +kubebuilder:object:root=true | ||
|
|
@@ -244,6 +257,7 @@ type OpenStackLightspeedStatus struct { | |
| // +operator-sdk:csv:customresourcedefinitions:resources={{PersistentVolumeClaim,v1,openstack-lightspeed-database}} | ||
| // +operator-sdk:csv:customresourcedefinitions:resources={{ClusterRole,v1,lightspeed-app-server-sar-role}} | ||
| // +operator-sdk:csv:customresourcedefinitions:resources={{ClusterRoleBinding,v1,lightspeed-app-server-sar-role-binding}} | ||
| // +operator-sdk:csv:customresourcedefinitions:resources={{ConfigMap,v1,mcp-config}} | ||
| // +operator-sdk:csv:customresourcedefinitions:resources={{Subscription,v1alpha1}} | ||
| // +operator-sdk:csv:customresourcedefinitions:resources={{ClusterServiceVersion,v1alpha1}} | ||
| // +operator-sdk:csv:customresourcedefinitions:resources={{InstallPlan,v1alpha1}} | ||
|
|
@@ -283,6 +297,7 @@ type OpenStackLightspeedDefaults struct { | |
| ConsoleImageURL string | ||
| ConsoleImagePF5URL string | ||
| OKPImageURL string | ||
| MCPServerImageURL string | ||
| MaxTokensForResponse int | ||
| } | ||
|
|
||
|
|
@@ -306,6 +321,8 @@ func SetupDefaults() { | |
| "RELATED_IMAGE_CONSOLE_PF5_IMAGE_URL_DEFAULT", ConsoleContainerImagePF5), | ||
| OKPImageURL: util.GetEnvVar( | ||
| "RELATED_IMAGE_OKP_IMAGE_URL_DEFAULT", OKPContainerImage), | ||
| MCPServerImageURL: util.GetEnvVar( | ||
| "RELATED_IMAGE_MCP_SERVER_IMAGE_URL_DEFAULT", MCPServerContainerImage), | ||
| MaxTokensForResponse: MaxTokensForResponseDefault, | ||
| } | ||
|
|
||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thinking aloud (non-blocking): Don't we have to also update the rest of the repository so that it adheres to the operator-sdk version of
1.41.1? [1] If yes then it feels like a bigger task IMO and maybe something that should be done in a separate PR? Also probably something we should keep an eye on in the future.I generated a blank project with operator-sdk 1.41.1. to check for example the changes in
cmd/main.goand there are definitely some.[1] openstack-k8s-operators/openstack-operator@4648b04
[2] https://sdk.operatorframework.io/docs/upgrading-sdk-version/