feat(crds): add AppDefinition v1beta11 with sidecars field#11
feat(crds): add AppDefinition v1beta11 with sidecars field#11CodeByNikolas merged 1 commit intomainfrom
Conversation
Adds v1beta11 as the new storage version for the AppDefinition CRD. v1beta11 extends v1beta10 with a 'sidecars' array field (SidecarSpec) supporting: name, image, port, languages, cpu/memory limits+requests, and mountWorkspace. v1beta10 remains served but is no longer storage. Part of the external-LS sidecar redesign (EduIDE-Cloud PR eclipse-theia#70).
📝 WalkthroughWalkthroughThe Helm chart for theia-cloud-crds is updated with a patch version bump and new appVersion field. A new CRD version (v1beta11) is introduced with comprehensive OpenAPI schema validation for app definitions, including properties for image management, resource limits, networking, and monitoring configuration. Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Poem
🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
📝 Coding Plan
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment Tip CodeRabbit can scan for known vulnerabilities in your dependencies using OSV Scanner.OSV Scanner will automatically detect and report security vulnerabilities in your project's dependencies. No additional configuration is required. |
There was a problem hiding this comment.
🧹 Nitpick comments (1)
charts/theia-cloud-crds/templates/appdefinition-spec-resource.yaml (1)
48-51: Minor: Port validation inconsistency with sidecars.The main spec
portallowsminimum: 0while the sidecarport(line 110) requiresminimum: 1. Port 0 typically means "OS-assigned port" which is unusual for a defined service endpoint. Consider aligning both tominimum: 1for consistency, unless port 0 has a specific use case here.Suggested alignment
port: type: integer - minimum: 0 + minimum: 1 maximum: 65535🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@charts/theia-cloud-crds/templates/appdefinition-spec-resource.yaml` around lines 48 - 51, Align the port validation ranges so they are consistent: change the main spec field "port" validation (shown in appdefinition-spec-resource.yaml) to use minimum: 1 to match the sidecar "port" validation (sidecar.port) unless you have a deliberate reason to allow 0; update the YAML schema entry for the top-level/spec "port" to minimum: 1 so both definitions require ports >= 1.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Nitpick comments:
In `@charts/theia-cloud-crds/templates/appdefinition-spec-resource.yaml`:
- Around line 48-51: Align the port validation ranges so they are consistent:
change the main spec field "port" validation (shown in
appdefinition-spec-resource.yaml) to use minimum: 1 to match the sidecar "port"
validation (sidecar.port) unless you have a deliberate reason to allow 0; update
the YAML schema entry for the top-level/spec "port" to minimum: 1 so both
definitions require ports >= 1.
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro
Run ID: c44b27f6-d8f8-4b15-b5e8-4dfff05dbd02
📒 Files selected for processing (2)
charts/theia-cloud-crds/Chart.yamlcharts/theia-cloud-crds/templates/appdefinition-spec-resource.yaml
Summary
v1beta11as the new storage version for theAppDefinitionCRDv1beta11extendsv1beta10with asidecarsarray field, where each entry is aSidecarSpecwith:name,image,port,languages,cpuLimit,memoryLimit,cpuRequest,memoryRequest,mountWorkspacev1beta10remains served (backward-compatible for existing resources) but is no longer the storage version1.2.0-next.1Context
Part of the external-LS sidecar redesign tracked in EduIDE-Cloud PR eclipse-theia#70. The operator now reads
sidecarsfromAppDefinitionSpec(v1beta11) to create per-language-server sidecar Deployments and Services alongside the Theia IDE pod. The CRD must registerv1beta11on the cluster before the new deployment chart (EduIDE-deployment PR eclipse-theia#73) can be installed.Testing
After this PR's preview chart publishes (
1.2.0-next.1.pr-<N>):Then verify:
kubectl api-resources --api-group=theia.cloudshowsAppDefinitionwithv1beta11.Summary by CodeRabbit
Chores
New Features