Skip to content

Commit

Permalink
add yurthub and yurt-controller-manager config
Browse files Browse the repository at this point in the history
simplify excluded nodes and failed nodes
typofix

Signed-off-by: nunu <shaoqiang.chen@intel.com>
  • Loading branch information
gnunu committed Jul 28, 2021
1 parent d04632d commit 37b8e02
Showing 1 changed file with 17 additions and 13 deletions.
30 changes: 17 additions & 13 deletions docs/proposals/20210722-openyurt-convertor-operator.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ To make OpenYurt translation easy for user, i.e., as automative as possible.
### Goals
* Convert nodes automatically
* Revert nodes automatically
* Translated OpenYurt cluster should be the same as through Yurtcutl or doing manually
* Translated OpenYurt cluster should be the same as through yurtctl or doing manually

### Non-Goals/Future Work

Expand All @@ -71,6 +71,7 @@ This is an operator, with CRD and Controller.

CRD's definition:

```go
type ComponentConfig struct {
Enabled bool `json:"enebled,omitempty"`
Version string `json:"version,omitempty"`
Expand All @@ -90,23 +91,26 @@ type FailedNode struct {

// YurtClusterSpec defines the desired state of YurtCluster
type YurtClusterSpec struct {
CloudNodes NodeSpec `json:"cloudNodes,omitempty"`
EdgeNodes NodeSpec `json:"edgeNodes,omitempty"`
TunnelServiceVersion ComponentConfig `json:"yurtTunnelVersion,omitempty"`
AppManagerVersion ComponentConfig `json:"appMangerVersion,omitempty"`
CloudNodes NodeSpec `json:"cloudNodes,omitempty"`
EdgeNodes NodeSpec `json:"edgeNodes,omitempty"`
YurtHub ComponentConfig `json:"yurtHub,omitempty"`
YurtControllerManager ComponentConfig `json:"yurtControllerManager,omitempty"`
TunnelService ComponentConfig `json:"yurtTunnel,omitempty"`
AppManager ComponentConfig `json:"appManger,omitempty"`
}

// YurtClusterStatus defines the observed state of YurtCluster
type YurtClusterStatus struct {
ConvertedCloudNodes []string `json:"convertedCloudNodes,omitempty"`
ConvertedEdgeNodes []string `json:"convertedEdgeNodes,omitempty"`
YurtTunnelVersion ComponentConfig `json:"yurtTunnelVersion,omitempty"`
AppManagerVersion ComponentConfig `json:"appMangerVersion,omitempty"`
ExcludedCloudNodes []string `json:"excludedCloudNodes,omitempty"`
ExcludedEdgeNodes []string `json:"excludedEdgeNodes,omitempty"`
FailedCloudNodes []FailedNode `json:"failedCloudNodes,omitempty"`
FailedEdgeNodes []FailedNode `json:"failedEdgeNodes,omitempty"`
ConvertedCloudNodes []string `json:"convertedCloudNodes,omitempty"`
ConvertedEdgeNodes []string `json:"convertedEdgeNodes,omitempty"`
YurtHub ComponentConfig `json:"yurtHub,omitempty"`
YurtControllerManager ComponentConfig `json:"yurtControllerManager,omitempty"`
YurtTunnel ComponentConfig `json:"yurtTunnel,omitempty"`
AppManager ComponentConfig `json:"appManger,omitempty"`
ExcludedNodes []string `json:"excludedNodes,omitempty"`
FailedNodes []FailedNode `json:"failedNodes,omitempty"`
}
```

The CRD would be enforced to have a cluster singleton CR semantics, through patched name validation for CRD definition. (for kubebuilder, under config/crd/patches)

Expand Down

0 comments on commit 37b8e02

Please sign in to comment.