Skip to content

Commit

Permalink
feat(notebook): integrate jupyter notebook
Browse files Browse the repository at this point in the history
  • Loading branch information
tunahanertekin authored Jan 2, 2024
2 parents 142e0c0 + d6b2479 commit d9c973a
Show file tree
Hide file tree
Showing 34 changed files with 2,847 additions and 19 deletions.
37 changes: 25 additions & 12 deletions PROJECT
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ resources:
domain: roboscale.io
group: robot
kind: Robot
path: github.com/robolaunch/robot-operator/api/v1alpha1
path: github.com/robolaunch/robot-operator/pkg/api/roboscale.io/v1alpha1
version: v1alpha1
webhooks:
defaulting: true
Expand All @@ -24,7 +24,7 @@ resources:
domain: roboscale.io
group: robot
kind: DiscoveryServer
path: github.com/robolaunch/robot-operator/api/v1alpha1
path: github.com/robolaunch/robot-operator/pkg/api/roboscale.io/v1alpha1
version: v1alpha1
webhooks:
defaulting: true
Expand All @@ -37,7 +37,7 @@ resources:
domain: roboscale.io
group: robot
kind: ROSBridge
path: github.com/robolaunch/robot-operator/api/v1alpha1
path: github.com/robolaunch/robot-operator/pkg/api/roboscale.io/v1alpha1
version: v1alpha1
- api:
crdVersion: v1
Expand All @@ -46,7 +46,7 @@ resources:
domain: roboscale.io
group: robot
kind: BuildManager
path: github.com/robolaunch/robot-operator/api/v1alpha1
path: github.com/robolaunch/robot-operator/pkg/api/roboscale.io/v1alpha1
version: v1alpha1
webhooks:
defaulting: true
Expand All @@ -59,7 +59,7 @@ resources:
domain: roboscale.io
group: robot
kind: LaunchManager
path: github.com/robolaunch/robot-operator/api/v1alpha1
path: github.com/robolaunch/robot-operator/pkg/api/roboscale.io/v1alpha1
version: v1alpha1
webhooks:
defaulting: true
Expand All @@ -72,7 +72,7 @@ resources:
domain: roboscale.io
group: robot
kind: RobotDevSuite
path: github.com/robolaunch/robot-operator/api/v1alpha1
path: github.com/robolaunch/robot-operator/pkg/api/roboscale.io/v1alpha1
version: v1alpha1
webhooks:
defaulting: true
Expand All @@ -85,7 +85,7 @@ resources:
domain: roboscale.io
group: robot
kind: RobotVDI
path: github.com/robolaunch/robot-operator/api/v1alpha1
path: github.com/robolaunch/robot-operator/pkg/api/roboscale.io/v1alpha1
version: v1alpha1
webhooks:
defaulting: true
Expand All @@ -98,7 +98,7 @@ resources:
domain: roboscale.io
group: robot
kind: RobotIDE
path: github.com/robolaunch/robot-operator/api/v1alpha1
path: github.com/robolaunch/robot-operator/pkg/api/roboscale.io/v1alpha1
version: v1alpha1
webhooks:
defaulting: true
Expand All @@ -110,7 +110,7 @@ resources:
domain: roboscale.io
group: robot
kind: RobotArtifact
path: github.com/robolaunch/robot-operator/api/v1alpha1
path: github.com/robolaunch/robot-operator/pkg/api/roboscale.io/v1alpha1
version: v1alpha1
- api:
crdVersion: v1
Expand All @@ -119,7 +119,7 @@ resources:
domain: roboscale.io
group: robot
kind: WorkspaceManager
path: github.com/robolaunch/robot-operator/api/v1alpha1
path: github.com/robolaunch/robot-operator/pkg/api/roboscale.io/v1alpha1
version: v1alpha1
webhooks:
defaulting: true
Expand All @@ -132,7 +132,7 @@ resources:
domain: roboscale.io
group: robot
kind: MetricsExporter
path: github.com/robolaunch/robot-operator/api/v1alpha1
path: github.com/robolaunch/robot-operator/pkg/api/roboscale.io/v1alpha1
version: v1alpha1
- api:
crdVersion: v1
Expand All @@ -141,6 +141,19 @@ resources:
domain: roboscale.io
group: robot
kind: RelayServer
path: github.com/robolaunch/robot-operator/api/v1alpha1
path: github.com/robolaunch/robot-operator/pkg/api/roboscale.io/v1alpha1
version: v1alpha1
- api:
crdVersion: v1
namespaced: true
controller: true
domain: roboscale.io
group: robot
kind: Notebook
path: github.com/robolaunch/robot-operator/pkg/api/roboscale.io/v1alpha1
version: v1alpha1
webhooks:
defaulting: true
validation: true
webhookVersion: v1
version: "3"
468 changes: 468 additions & 0 deletions config/crd/bases/robot.roboscale.io_notebooks.yaml

Large diffs are not rendered by default.

53 changes: 53 additions & 0 deletions config/crd/bases/robot.roboscale.io_robotartifacts.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -256,6 +256,59 @@ spec:
description: If `true`, a Cloud IDE will be provisioned inside
development suite.
type: boolean
notebookEnabled:
description: If `true`, a Notebook will be provisioned inside
development suite.
type: boolean
notebookTemplate:
description: Configurational parameters of Notebook. Applied if
`.spec.notebookEnabled` is set to `true`.
properties:
display:
description: Notebook connects an X11 socket if it's set to
`true` and a target Notebook resource is set in labels with
key `robolaunch.io/target-vdi`. Applications that requires
GUI can be executed such as VLC.
type: boolean
ingress:
description: '[*alpha*] Notebook will create an Ingress resource
if `true`.'
type: boolean
privileged:
description: If `true`, containers of Notebook will be privileged
containers. It can be used in physical instances where it's
necessary to access I/O devices on the host machine. Not
recommended to activate this field on cloud instances.
type: boolean
resources:
description: Resource limitations of Notebook.
properties:
cpu:
description: CPU resource limit.
pattern: ^([0-9])+(m)$
type: string
gpuCore:
description: GPU core number that will be allocated.
type: integer
gpuInstance:
default: nvidia.com/gpu
description: GPU instance that will be allocated. eg.
nvidia.com/mig-1g.5gb. Defaults to "nvidia.com/gpu".
type: string
memory:
description: Memory resource limit.
pattern: ^([0-9])+(Mi|Gi)$
type: string
type: object
serviceType:
default: NodePort
description: Service type of Notebook. `ClusterIP` and `NodePort`
is supported.
enum:
- ClusterIP
- NodePort
type: string
type: object
remoteIDEEnabled:
description: If `true`, a relay server for remote Cloud IDE will
be provisioned inside development suite.
Expand Down
112 changes: 112 additions & 0 deletions config/crd/bases/robot.roboscale.io_robotdevsuites.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,58 @@ spec:
description: If `true`, a Cloud IDE will be provisioned inside development
suite.
type: boolean
notebookEnabled:
description: If `true`, a Notebook will be provisioned inside development
suite.
type: boolean
notebookTemplate:
description: Configurational parameters of Notebook. Applied if `.spec.notebookEnabled`
is set to `true`.
properties:
display:
description: Notebook connects an X11 socket if it's set to `true`
and a target Notebook resource is set in labels with key `robolaunch.io/target-vdi`.
Applications that requires GUI can be executed such as VLC.
type: boolean
ingress:
description: '[*alpha*] Notebook will create an Ingress resource
if `true`.'
type: boolean
privileged:
description: If `true`, containers of Notebook will be privileged
containers. It can be used in physical instances where it's
necessary to access I/O devices on the host machine. Not recommended
to activate this field on cloud instances.
type: boolean
resources:
description: Resource limitations of Notebook.
properties:
cpu:
description: CPU resource limit.
pattern: ^([0-9])+(m)$
type: string
gpuCore:
description: GPU core number that will be allocated.
type: integer
gpuInstance:
default: nvidia.com/gpu
description: GPU instance that will be allocated. eg. nvidia.com/mig-1g.5gb.
Defaults to "nvidia.com/gpu".
type: string
memory:
description: Memory resource limit.
pattern: ^([0-9])+(Mi|Gi)$
type: string
type: object
serviceType:
default: NodePort
description: Service type of Notebook. `ClusterIP` and `NodePort`
is supported.
enum:
- ClusterIP
- NodePort
type: string
type: object
remoteIDEEnabled:
description: If `true`, a relay server for remote Cloud IDE will be
provisioned inside development suite.
Expand Down Expand Up @@ -221,6 +273,66 @@ spec:
description: '[*alpha*] Indicates if RobotDevSuite is attached to
a Robot and actively provisioned it''s resources.'
type: boolean
notebookStatus:
description: Status of Notebook.
properties:
connections:
additionalProperties:
type: string
description: Address of the robot service that can be reached
from outside.
type: object
resource:
description: Generic status for any owned resource.
properties:
created:
description: Shows if the owned resource is created.
type: boolean
phase:
description: Phase of the owned resource.
type: string
reference:
description: Reference to the owned resource.
properties:
apiVersion:
description: API version of the referent.
type: string
fieldPath:
description: 'If referring to a piece of an object instead
of an entire object, this string should contain a valid
JSON/Go field access statement, such as desiredState.manifest.containers[2].
For example, if the object reference is to a container
within a pod, this would take on a value like: "spec.containers{name}"
(where "name" refers to the name of the container that
triggered the event) or if no container name is specified
"spec.containers[2]" (container with index 2 in this
pod). This syntax is chosen only to have some well-defined
way of referencing a part of an object. TODO: this design
is not final and this field is subject to change in
the future.'
type: string
kind:
description: 'Kind of the referent. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
type: string
name:
description: 'Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names'
type: string
namespace:
description: 'Namespace of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/'
type: string
resourceVersion:
description: 'Specific resourceVersion to which this reference
is made, if any. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#concurrency-control-and-consistency'
type: string
uid:
description: 'UID of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#uids'
type: string
type: object
x-kubernetes-map-type: atomic
required:
- created
type: object
type: object
phase:
description: Phase of RobotDevSuite.
type: string
Expand Down
Loading

0 comments on commit d9c973a

Please sign in to comment.