Skip to content

Commit

Permalink
Add options field to CRDs (#55)
Browse files Browse the repository at this point in the history
This field can be used by adopters to pass arbitrary data to the operator.
Field is added to all three CRDs for maximum configurability.
Bumped version number to `Session.v1beta8`, `Workspace.v1beta5` and `AppDefinition.v1beta10`.
  • Loading branch information
sgraband authored Apr 18, 2024
1 parent 27f6585 commit 92d88b5
Show file tree
Hide file tree
Showing 6 changed files with 220 additions and 7 deletions.
4 changes: 3 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
# Changelog

<!-- ## [0.11.0] - estimated 2024-07 -->
## [0.11.0] - estimated 2024-07

- [theia-cloud-crds] Add option field to CRDs and increase version to `Session.v1beta8`, `Workspace.v1beta5` and `AppDefinition.v1beta10` [#55](https://github.com/eclipsesource/theia-cloud-helm/pull/55) | [#293](https://github.com/eclipsesource/theia-cloud/pull/293)

## [0.10.0] - 2024-04-02

Expand Down
2 changes: 1 addition & 1 deletion charts/theia-cloud-crds/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ type: application
# This is the chart version. This version number should be incremented each time you make changes
# to the chart and its templates, including the app version.
# Versions are expected to follow Semantic Versioning (https://semver.org/)
version: 0.11.0-next.0
version: 0.11.0-next.1

# This is the version number of the application being deployed. This version number should be
# incremented each time you make changes to the application. Versions are not expected to
Expand Down
4 changes: 2 additions & 2 deletions charts/theia-cloud-crds/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# theia-cloud-crds

![Version: 0.11.0-next.0](https://img.shields.io/badge/Version-0.11.0--next.0-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 0.11.0-next](https://img.shields.io/badge/AppVersion-0.11.0--next-informational?style=flat-square)
![Version: 0.11.0-next.1](https://img.shields.io/badge/Version-0.11.0--next.1-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 0.11.0-next](https://img.shields.io/badge/AppVersion-0.11.0--next-informational?style=flat-square)

A Helm chart for the custom resource definitions (CRDs) of Theia Cloud

Expand All @@ -13,4 +13,4 @@ A Helm chart for the custom resource definitions (CRDs) of Theia Cloud
| conversion.image | string | `"theiacloud/theia-cloud-conversion-webhook:0.11.0-next"` | The image of the webhook container |

----------------------------------------------
Autogenerated from chart metadata using [helm-docs v1.13.1](https://github.com/norwoodj/helm-docs/releases/v1.13.1)
Autogenerated from chart metadata using [helm-docs v1.12.0](https://github.com/norwoodj/helm-docs/releases/v1.12.0)
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,102 @@ spec:
- ad
scope: Namespaced
versions:
- name: v1beta9
- name: v1beta10
served: true
storage: true
# subresources describes the subresources for custom resources.
subresources:
# status enables the status subresource.
status: {}
schema:
openAPIV3Schema:
type: object
properties:
spec:
type: object
x-kubernetes-validations:
- rule: "self.minInstances <= self.maxInstances"
message: "minInstances should be less or equal than maxInstances."
properties:
name:
type: string
pattern: "^[a-z0-9A-Z-_]+$"
image:
type: string
imagePullPolicy:
type: string
enum: ["Always", "IfNotPresent", "Never"]
pullSecret:
type: string
uid:
type: integer
port:
type: integer
minimum: 0
maximum: 65535
ingressname:
type: string
minInstances:
type: integer
maxInstances:
type: integer
timeout:
type: integer
requestsMemory:
type: string
requestsCpu:
type: string
limitsMemory:
type: string
limitsCpu:
type: string
downlinkLimit:
type: integer
uplinkLimit:
type: integer
mountPath:
type: string
monitor:
type: object
properties:
port:
type: integer
activityTracker:
type: object
properties:
timeoutAfter:
type: integer
notifyAfter:
type: integer
options:
type: object
additionalProperties:
x-kubernetes-int-or-string: true
required:
- name
- image
- uid
- port
- ingressname
- minInstances
- maxInstances
- requestsCpu
- requestsMemory
- limitsMemory
- limitsCpu
status:
type: object
properties:
operatorStatus:
type: string
operatorMessage:
type: string
required:
- spec
- name: v1beta9
served: true
storage: false
# subresources describes the subresources for custom resources.
subresources:
# status enables the status subresource.
status: {}
Expand Down
63 changes: 62 additions & 1 deletion charts/theia-cloud-crds/templates/session-spec-resource.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,71 @@ spec:
singular: session
scope: Namespaced
versions:
- name : v1beta7
- name : v1beta8
served: true
storage: true
# subresources describes the subresources for custom resources.
subresources:
# status enables the status subresource.
status: {}
schema:
openAPIV3Schema:
type: object
properties:
spec:
type: object
properties:
name:
type: string
pattern: '^[a-z0-9A-Z-_]+$'
workspace:
type: string
appDefinition: # cached from workspace
type: string
pattern: '^[a-z0-9A-Z-_]+$'
user: # cached from workspace
type: string
sessionSecret:
type: string
options:
type: object
additionalProperties:
x-kubernetes-int-or-string: true
envVars:
type: object
additionalProperties:
x-kubernetes-int-or-string: true
envVarsFromConfigMaps:
type: array
items:
type: string
envVarsFromSecrets:
type: array
items:
type: string
required:
- name
- user
- appDefinition
status:
type: object
properties:
operatorStatus:
type: string
operatorMessage:
type: string
url:
type: string
error:
type: string
lastActivity:
type: integer
required:
- spec
- name : v1beta7
served: true
storage: false
# subresources describes the subresources for custom resources.
subresources:
# status enables the status subresource.
status: {}
Expand Down
60 changes: 59 additions & 1 deletion charts/theia-cloud-crds/templates/workspace-spec-resource.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,68 @@ spec:
- ws
scope: Namespaced
versions:
- name : v1beta4
- name : v1beta5
served: true
storage: true
# subresources describes the subresources for custom resources.
subresources:
# status enables the status subresource.
status: {}
schema:
openAPIV3Schema:
type: object
properties:
spec:
type: object
properties:
name:
type: string
pattern: '^[a-z0-9A-Z-_]+$'
label:
type: string
appDefinition: # last app definition that ran on this workspace
type: string
pattern: '^[a-z0-9A-Z-_]+$'
user: # user who created the workspace
type: string
storage:
type: string
options:
type: object
additionalProperties:
x-kubernetes-int-or-string: true
required:
- name
- user
status:
type: object
properties:
operatorStatus:
type: string
operatorMessage:
type: string
volumeClaim:
type: object
properties:
status:
type: string
message:
type: string
volumeAttach:
type: object
properties:
status:
type: string
message:
type: string
error:
type: string
required:
- spec
- name : v1beta4
served: true
storage: false
# subresources describes the subresources for custom resources.
subresources:
# status enables the status subresource.
status: {}
Expand Down

0 comments on commit 92d88b5

Please sign in to comment.