feat: add server.workspaceDefaultPlugins field to CheCluster schema

Signed-off-by: David Kwon <dakwon@redhat.com>
pull/1249/head
David Kwon 2021-12-13 13:28:17 -05:00 committed by David Kwon
parent aa0c0da8ef
commit 1637ead003
9 changed files with 120 additions and 4 deletions

View File

@ -341,6 +341,9 @@ type CheClusterSpecServer struct {
// The Che server route custom settings.
// +optional
CheServerRoute RouteCustomSettings `json:"cheServerRoute,omitempty"`
// Default plug-ins applied to Devworkspaces.
// +optional
WorkspacesDefaultPlugins []WorkspacesDefaultPlugins `json:"workspacesDefaultPlugins,omitempty"`
}
// +k8s:openapi-gen=true
@ -546,6 +549,13 @@ type ResourcesCustomSettings struct {
Limits Resources `json:"limits,omitempty"`
}
type WorkspacesDefaultPlugins struct {
// The editor id to specify default plug-ins for.
Editor string `json:"editor,omitempty"`
// Default plug-in ids and uris for the specified editor.
Plugins []string `json:"plugins,omitempty"`
}
// List of resources
type Resources struct {
// Memory, in bytes. (500Gi = 500GiB = 500 * 1024 * 1024 * 1024)

View File

@ -545,6 +545,13 @@ func (in *CheClusterSpecServer) DeepCopyInto(out *CheClusterSpecServer) {
}
in.CheServerIngress.DeepCopyInto(&out.CheServerIngress)
in.CheServerRoute.DeepCopyInto(&out.CheServerRoute)
if in.WorkspacesDefaultPlugins != nil {
in, out := &in.WorkspacesDefaultPlugins, &out.WorkspacesDefaultPlugins
*out = make([]WorkspacesDefaultPlugins, len(*in))
for i := range *in {
(*in)[i].DeepCopyInto(&(*out)[i])
}
}
}
// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CheClusterSpecServer.
@ -708,3 +715,23 @@ func (in *SftpServerConfing) DeepCopy() *SftpServerConfing {
in.DeepCopyInto(out)
return out
}
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *WorkspacesDefaultPlugins) DeepCopyInto(out *WorkspacesDefaultPlugins) {
*out = *in
if in.Plugins != nil {
in, out := &in.Plugins, &out.Plugins
*out = make([]string, len(*in))
copy(*out, *in)
}
}
// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new WorkspacesDefaultPlugins.
func (in *WorkspacesDefaultPlugins) DeepCopy() *WorkspacesDefaultPlugins {
if in == nil {
return nil
}
out := new(WorkspacesDefaultPlugins)
in.DeepCopyInto(out)
return out
}

View File

@ -126,7 +126,7 @@ metadata:
operators.operatorframework.io/project_layout: go.kubebuilder.io/v3
repository: https://github.com/eclipse-che/che-operator
support: Eclipse Foundation
name: eclipse-che-preview-openshift.v7.41.0-386.next-all-namespaces
name: eclipse-che-preview-openshift.v7.41.0-387.next-all-namespaces
namespace: placeholder
spec:
apiservicedefinitions: {}
@ -1466,4 +1466,4 @@ spec:
maturity: stable
provider:
name: Eclipse Foundation
version: 7.41.0-386.next-all-namespaces
version: 7.41.0-387.next-all-namespaces

View File

@ -993,6 +993,22 @@ spec:
placeholders, such as che-workspace-<username>. In that case,
a new namespace will be created for each user or workspace.
type: string
workspacesDefaultPlugins:
description: Default plug-ins applied to Devworkspaces.
items:
properties:
editor:
description: The editor id to specify default plug-ins
for.
type: string
plugins:
description: Default plug-in ids and uris for the specified
editor.
items:
type: string
type: array
type: object
type: array
type: object
storage:
description: Configuration settings related to the persistent storage

View File

@ -126,7 +126,7 @@ metadata:
operators.operatorframework.io/project_layout: go.kubebuilder.io/v3
repository: https://github.com/eclipse-che/che-operator
support: Eclipse Foundation
name: eclipse-che-preview-openshift.v7.41.0-386.next
name: eclipse-che-preview-openshift.v7.41.0-387.next
namespace: placeholder
spec:
apiservicedefinitions: {}
@ -1466,4 +1466,4 @@ spec:
maturity: stable
provider:
name: Eclipse Foundation
version: 7.41.0-386.next
version: 7.41.0-387.next

View File

@ -993,6 +993,22 @@ spec:
placeholders, such as che-workspace-<username>. In that case,
a new namespace will be created for each user or workspace.
type: string
workspacesDefaultPlugins:
description: Default plug-ins applied to Devworkspaces.
items:
properties:
editor:
description: The editor id to specify default plug-ins
for.
type: string
plugins:
description: Default plug-in ids and uris for the specified
editor.
items:
type: string
type: array
type: object
type: array
type: object
storage:
description: Configuration settings related to the persistent storage

View File

@ -956,6 +956,21 @@ spec:
placeholders, such as che-workspace-<username>. In that case,
a new namespace will be created for each user or workspace.
type: string
workspacesDefaultPlugins:
description: Default plug-ins applied to Devworkspaces.
items:
properties:
editor:
description: The editor id to specify default plug-ins for.
type: string
plugins:
description: Default plug-in ids and uris for the specified
editor.
items:
type: string
type: array
type: object
type: array
type: object
storage:
description: Configuration settings related to the persistent storage

View File

@ -989,6 +989,22 @@ spec:
placeholders, such as che-workspace-<username>. In that case,
a new namespace will be created for each user or workspace.
type: string
workspacesDefaultPlugins:
description: Default plug-ins applied to Devworkspaces.
items:
properties:
editor:
description: The editor id to specify default plug-ins
for.
type: string
plugins:
description: Default plug-in ids and uris for the specified
editor.
items:
type: string
type: array
type: object
type: array
type: object
storage:
description: Configuration settings related to the persistent storage

View File

@ -989,6 +989,22 @@ spec:
placeholders, such as che-workspace-<username>. In that case,
a new namespace will be created for each user or workspace.
type: string
workspacesDefaultPlugins:
description: Default plug-ins applied to Devworkspaces.
items:
properties:
editor:
description: The editor id to specify default plug-ins
for.
type: string
plugins:
description: Default plug-in ids and uris for the specified
editor.
items:
type: string
type: array
type: object
type: array
type: object
storage:
description: Configuration settings related to the persistent storage