diff --git a/go/config/edge_node_cluster.pb.go b/go/config/edge_node_cluster.pb.go index 6acab7eb..97c40f54 100644 --- a/go/config/edge_node_cluster.pb.go +++ b/go/config/edge_node_cluster.pb.go @@ -28,7 +28,9 @@ type ClusterType int32 const ( ClusterType_CLUSTER_TYPE_UNSPECIFIED ClusterType = 0 - // cluster with only native kubernetes orchestration for user applications + // cluster with only native kubernetes orchestration for user applications. + // To be phased out; prefer CLUSTER_TYPE_REPLICATED_STORAGE with + // EdgeNodeCluster.enable_native_k8s_orchestration = true. ClusterType_CLUSTER_TYPE_K3S_BASE ClusterType = 1 // cluster with orchestration by EVE APIs for user applications ClusterType_CLUSTER_TYPE_REPLICATED_STORAGE ClusterType = 2 @@ -269,6 +271,12 @@ type EdgeNodeCluster struct { // removed (e.g. after a "replace node" operation in the UI). // Workers are not listed here. MasterNodeUuids []string `protobuf:"bytes,13,rep,name=master_node_uuids,json=masterNodeUuids,proto3" json:"master_node_uuids,omitempty"` + // When true, EVE enables native Kubernetes orchestration for user + // workloads in addition to EVE-API-managed scheduling. This provides + // the same capability that CLUSTER_TYPE_K3S_BASE offered, but as an + // opt-in flag on a CLUSTER_TYPE_REPLICATED_STORAGE cluster. + // Requires cluster_type = CLUSTER_TYPE_REPLICATED_STORAGE. + EnableNativeK8SOrchestration bool `protobuf:"varint,14,opt,name=enable_native_k8s_orchestration,json=enableNativeK8sOrchestration,proto3" json:"enable_native_k8s_orchestration,omitempty"` } func (x *EdgeNodeCluster) Reset() { @@ -387,6 +395,13 @@ func (x *EdgeNodeCluster) GetMasterNodeUuids() []string { return nil } +func (x *EdgeNodeCluster) GetEnableNativeK8SOrchestration() bool { + if x != nil { + return x.EnableNativeK8SOrchestration + } + return false +} + var File_config_edge_node_cluster_proto protoreflect.FileDescriptor var file_config_edge_node_cluster_proto_rawDesc = []byte{ @@ -407,7 +422,7 @@ var file_config_edge_node_cluster_proto_rawDesc = []byte{ 0x20, 0x03, 0x28, 0x0b, 0x32, 0x2c, 0x2e, 0x6f, 0x72, 0x67, 0x2e, 0x6c, 0x66, 0x65, 0x64, 0x67, 0x65, 0x2e, 0x65, 0x76, 0x65, 0x2e, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x2e, 0x4c, 0x6f, 0x61, 0x64, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x72, 0x49, 0x6e, 0x74, 0x65, 0x72, 0x66, 0x61, - 0x63, 0x65, 0x52, 0x0a, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x66, 0x61, 0x63, 0x65, 0x73, 0x22, 0x94, + 0x63, 0x65, 0x52, 0x0a, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x66, 0x61, 0x63, 0x65, 0x73, 0x22, 0xdb, 0x05, 0x0a, 0x0f, 0x45, 0x64, 0x67, 0x65, 0x4e, 0x6f, 0x64, 0x65, 0x43, 0x6c, 0x75, 0x73, 0x74, 0x65, 0x72, 0x12, 0x21, 0x0a, 0x0c, 0x63, 0x6c, 0x75, 0x73, 0x74, 0x65, 0x72, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x63, 0x6c, 0x75, 0x73, 0x74, 0x65, @@ -449,24 +464,28 @@ var file_config_edge_node_cluster_proto_rawDesc = []byte{ 0x65, 0x72, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x2a, 0x0a, 0x11, 0x6d, 0x61, 0x73, 0x74, 0x65, 0x72, 0x5f, 0x6e, 0x6f, 0x64, 0x65, 0x5f, 0x75, 0x75, 0x69, 0x64, 0x73, 0x18, 0x0d, 0x20, 0x03, 0x28, 0x09, 0x52, 0x0f, 0x6d, 0x61, 0x73, 0x74, 0x65, 0x72, 0x4e, 0x6f, 0x64, 0x65, - 0x55, 0x75, 0x69, 0x64, 0x73, 0x2a, 0x84, 0x01, 0x0a, 0x0b, 0x43, 0x6c, 0x75, 0x73, 0x74, 0x65, - 0x72, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1c, 0x0a, 0x18, 0x43, 0x4c, 0x55, 0x53, 0x54, 0x45, 0x52, - 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, - 0x44, 0x10, 0x00, 0x12, 0x19, 0x0a, 0x15, 0x43, 0x4c, 0x55, 0x53, 0x54, 0x45, 0x52, 0x5f, 0x54, - 0x59, 0x50, 0x45, 0x5f, 0x4b, 0x33, 0x53, 0x5f, 0x42, 0x41, 0x53, 0x45, 0x10, 0x01, 0x12, 0x23, - 0x0a, 0x1f, 0x43, 0x4c, 0x55, 0x53, 0x54, 0x45, 0x52, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x52, - 0x45, 0x50, 0x4c, 0x49, 0x43, 0x41, 0x54, 0x45, 0x44, 0x5f, 0x53, 0x54, 0x4f, 0x52, 0x41, 0x47, - 0x45, 0x10, 0x02, 0x12, 0x17, 0x0a, 0x0f, 0x43, 0x4c, 0x55, 0x53, 0x54, 0x45, 0x52, 0x5f, 0x54, - 0x59, 0x50, 0x45, 0x5f, 0x48, 0x41, 0x10, 0x03, 0x1a, 0x02, 0x08, 0x01, 0x2a, 0x41, 0x0a, 0x08, - 0x48, 0x41, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x65, 0x12, 0x19, 0x0a, 0x15, 0x48, 0x41, 0x5f, 0x53, - 0x43, 0x48, 0x45, 0x4d, 0x45, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, - 0x44, 0x10, 0x00, 0x12, 0x1a, 0x0a, 0x16, 0x48, 0x41, 0x5f, 0x53, 0x43, 0x48, 0x45, 0x4d, 0x45, - 0x5f, 0x4b, 0x33, 0x53, 0x5f, 0x45, 0x4d, 0x42, 0x45, 0x44, 0x44, 0x45, 0x44, 0x10, 0x01, 0x42, - 0x3d, 0x0a, 0x15, 0x6f, 0x72, 0x67, 0x2e, 0x6c, 0x66, 0x65, 0x64, 0x67, 0x65, 0x2e, 0x65, 0x76, - 0x65, 0x2e, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x5a, 0x24, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, - 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x6c, 0x66, 0x2d, 0x65, 0x64, 0x67, 0x65, 0x2f, 0x65, 0x76, 0x65, - 0x2d, 0x61, 0x70, 0x69, 0x2f, 0x67, 0x6f, 0x2f, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x62, 0x06, - 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x55, 0x75, 0x69, 0x64, 0x73, 0x12, 0x45, 0x0a, 0x1f, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x5f, + 0x6e, 0x61, 0x74, 0x69, 0x76, 0x65, 0x5f, 0x6b, 0x38, 0x73, 0x5f, 0x6f, 0x72, 0x63, 0x68, 0x65, + 0x73, 0x74, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, 0x1c, + 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x4e, 0x61, 0x74, 0x69, 0x76, 0x65, 0x4b, 0x38, 0x73, 0x4f, + 0x72, 0x63, 0x68, 0x65, 0x73, 0x74, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2a, 0x84, 0x01, 0x0a, + 0x0b, 0x43, 0x6c, 0x75, 0x73, 0x74, 0x65, 0x72, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1c, 0x0a, 0x18, + 0x43, 0x4c, 0x55, 0x53, 0x54, 0x45, 0x52, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x55, 0x4e, 0x53, + 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x19, 0x0a, 0x15, 0x43, 0x4c, + 0x55, 0x53, 0x54, 0x45, 0x52, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x4b, 0x33, 0x53, 0x5f, 0x42, + 0x41, 0x53, 0x45, 0x10, 0x01, 0x12, 0x23, 0x0a, 0x1f, 0x43, 0x4c, 0x55, 0x53, 0x54, 0x45, 0x52, + 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x52, 0x45, 0x50, 0x4c, 0x49, 0x43, 0x41, 0x54, 0x45, 0x44, + 0x5f, 0x53, 0x54, 0x4f, 0x52, 0x41, 0x47, 0x45, 0x10, 0x02, 0x12, 0x17, 0x0a, 0x0f, 0x43, 0x4c, + 0x55, 0x53, 0x54, 0x45, 0x52, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x48, 0x41, 0x10, 0x03, 0x1a, + 0x02, 0x08, 0x01, 0x2a, 0x41, 0x0a, 0x08, 0x48, 0x41, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x65, 0x12, + 0x19, 0x0a, 0x15, 0x48, 0x41, 0x5f, 0x53, 0x43, 0x48, 0x45, 0x4d, 0x45, 0x5f, 0x55, 0x4e, 0x53, + 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x1a, 0x0a, 0x16, 0x48, 0x41, + 0x5f, 0x53, 0x43, 0x48, 0x45, 0x4d, 0x45, 0x5f, 0x4b, 0x33, 0x53, 0x5f, 0x45, 0x4d, 0x42, 0x45, + 0x44, 0x44, 0x45, 0x44, 0x10, 0x01, 0x42, 0x3d, 0x0a, 0x15, 0x6f, 0x72, 0x67, 0x2e, 0x6c, 0x66, + 0x65, 0x64, 0x67, 0x65, 0x2e, 0x65, 0x76, 0x65, 0x2e, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x5a, + 0x24, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x6c, 0x66, 0x2d, 0x65, + 0x64, 0x67, 0x65, 0x2f, 0x65, 0x76, 0x65, 0x2d, 0x61, 0x70, 0x69, 0x2f, 0x67, 0x6f, 0x2f, 0x63, + 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( diff --git a/proto/config/edge_node_cluster.proto b/proto/config/edge_node_cluster.proto index 100c6afc..9aa595a3 100644 --- a/proto/config/edge_node_cluster.proto +++ b/proto/config/edge_node_cluster.proto @@ -12,7 +12,9 @@ import "evecommon/acipherinfo.proto"; enum ClusterType { CLUSTER_TYPE_UNSPECIFIED = 0; - // cluster with only native kubernetes orchestration for user applications + // cluster with only native kubernetes orchestration for user applications. + // To be phased out; prefer CLUSTER_TYPE_REPLICATED_STORAGE with + // EdgeNodeCluster.enable_native_k8s_orchestration = true. CLUSTER_TYPE_K3S_BASE = 1; // cluster with orchestration by EVE APIs for user applications @@ -86,4 +88,11 @@ message EdgeNodeCluster { // removed (e.g. after a "replace node" operation in the UI). // Workers are not listed here. repeated string master_node_uuids = 13; + + // When true, EVE enables native Kubernetes orchestration for user + // workloads in addition to EVE-API-managed scheduling. This provides + // the same capability that CLUSTER_TYPE_K3S_BASE offered, but as an + // opt-in flag on a CLUSTER_TYPE_REPLICATED_STORAGE cluster. + // Requires cluster_type = CLUSTER_TYPE_REPLICATED_STORAGE. + bool enable_native_k8s_orchestration = 14; } diff --git a/python/config/edge_node_cluster_pb2.py b/python/config/edge_node_cluster_pb2.py index 1bd4ca44..e4716507 100644 --- a/python/config/edge_node_cluster_pb2.py +++ b/python/config/edge_node_cluster_pb2.py @@ -14,7 +14,7 @@ from evecommon import acipherinfo_pb2 as evecommon_dot_acipherinfo__pb2 -DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x1e\x63onfig/edge_node_cluster.proto\x12\x15org.lfedge.eve.config\x1a\x1b\x65vecommon/acipherinfo.proto\"F\n\x15LoadBalancerInterface\x12\x16\n\x0einterface_name\x18\x01 \x01(\t\x12\x15\n\raddress_cidrs\x18\x02 \x03(\t\"W\n\x13LoadBalancerService\x12@\n\ninterfaces\x18\x01 \x03(\x0b\x32,.org.lfedge.eve.config.LoadBalancerInterface\"\xd7\x03\n\x0f\x45\x64geNodeCluster\x12\x14\n\x0c\x63luster_name\x18\x01 \x01(\t\x12\x12\n\ncluster_id\x18\x02 \x01(\t\x12\x19\n\x11\x63luster_interface\x18\x03 \x01(\t\x12\x19\n\x11\x63luster_ip_prefix\x18\x04 \x01(\t\x12\x16\n\x0eis_worker_node\x18\x05 \x01(\x08\x12\x16\n\x0ejoin_server_ip\x18\x06 \x01(\t\x12\x43\n\x17\x65ncrypted_cluster_token\x18\x07 \x01(\x0b\x32\".org.lfedge.eve.common.CipherBlock\x12\x38\n\x0c\x63luster_type\x18\x08 \x01(\x0e\x32\".org.lfedge.eve.config.ClusterType\x12\x1b\n\x13tie_breaker_node_id\x18\t \x01(\t\x12\x32\n\tha_scheme\x18\x0b \x01(\x0e\x32\x1f.org.lfedge.eve.config.HAScheme\x12I\n\x15load_balancer_service\x18\x0c \x01(\x0b\x32*.org.lfedge.eve.config.LoadBalancerService\x12\x19\n\x11master_node_uuids\x18\r \x03(\t*\x84\x01\n\x0b\x43lusterType\x12\x1c\n\x18\x43LUSTER_TYPE_UNSPECIFIED\x10\x00\x12\x19\n\x15\x43LUSTER_TYPE_K3S_BASE\x10\x01\x12#\n\x1f\x43LUSTER_TYPE_REPLICATED_STORAGE\x10\x02\x12\x17\n\x0f\x43LUSTER_TYPE_HA\x10\x03\x1a\x02\x08\x01*A\n\x08HAScheme\x12\x19\n\x15HA_SCHEME_UNSPECIFIED\x10\x00\x12\x1a\n\x16HA_SCHEME_K3S_EMBEDDED\x10\x01\x42=\n\x15org.lfedge.eve.configZ$github.com/lf-edge/eve-api/go/configb\x06proto3') +DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x1e\x63onfig/edge_node_cluster.proto\x12\x15org.lfedge.eve.config\x1a\x1b\x65vecommon/acipherinfo.proto\"F\n\x15LoadBalancerInterface\x12\x16\n\x0einterface_name\x18\x01 \x01(\t\x12\x15\n\raddress_cidrs\x18\x02 \x03(\t\"W\n\x13LoadBalancerService\x12@\n\ninterfaces\x18\x01 \x03(\x0b\x32,.org.lfedge.eve.config.LoadBalancerInterface\"\x80\x04\n\x0f\x45\x64geNodeCluster\x12\x14\n\x0c\x63luster_name\x18\x01 \x01(\t\x12\x12\n\ncluster_id\x18\x02 \x01(\t\x12\x19\n\x11\x63luster_interface\x18\x03 \x01(\t\x12\x19\n\x11\x63luster_ip_prefix\x18\x04 \x01(\t\x12\x16\n\x0eis_worker_node\x18\x05 \x01(\x08\x12\x16\n\x0ejoin_server_ip\x18\x06 \x01(\t\x12\x43\n\x17\x65ncrypted_cluster_token\x18\x07 \x01(\x0b\x32\".org.lfedge.eve.common.CipherBlock\x12\x38\n\x0c\x63luster_type\x18\x08 \x01(\x0e\x32\".org.lfedge.eve.config.ClusterType\x12\x1b\n\x13tie_breaker_node_id\x18\t \x01(\t\x12\x32\n\tha_scheme\x18\x0b \x01(\x0e\x32\x1f.org.lfedge.eve.config.HAScheme\x12I\n\x15load_balancer_service\x18\x0c \x01(\x0b\x32*.org.lfedge.eve.config.LoadBalancerService\x12\x19\n\x11master_node_uuids\x18\r \x03(\t\x12\'\n\x1f\x65nable_native_k8s_orchestration\x18\x0e \x01(\x08*\x84\x01\n\x0b\x43lusterType\x12\x1c\n\x18\x43LUSTER_TYPE_UNSPECIFIED\x10\x00\x12\x19\n\x15\x43LUSTER_TYPE_K3S_BASE\x10\x01\x12#\n\x1f\x43LUSTER_TYPE_REPLICATED_STORAGE\x10\x02\x12\x17\n\x0f\x43LUSTER_TYPE_HA\x10\x03\x1a\x02\x08\x01*A\n\x08HAScheme\x12\x19\n\x15HA_SCHEME_UNSPECIFIED\x10\x00\x12\x1a\n\x16HA_SCHEME_K3S_EMBEDDED\x10\x01\x42=\n\x15org.lfedge.eve.configZ$github.com/lf-edge/eve-api/go/configb\x06proto3') _globals = globals() _builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals) @@ -25,14 +25,14 @@ DESCRIPTOR._serialized_options = b'\n\025org.lfedge.eve.configZ$github.com/lf-edge/eve-api/go/config' _CLUSTERTYPE.values_by_name["CLUSTER_TYPE_HA"]._options = None _CLUSTERTYPE.values_by_name["CLUSTER_TYPE_HA"]._serialized_options = b'\010\001' - _globals['_CLUSTERTYPE']._serialized_start=722 - _globals['_CLUSTERTYPE']._serialized_end=854 - _globals['_HASCHEME']._serialized_start=856 - _globals['_HASCHEME']._serialized_end=921 + _globals['_CLUSTERTYPE']._serialized_start=763 + _globals['_CLUSTERTYPE']._serialized_end=895 + _globals['_HASCHEME']._serialized_start=897 + _globals['_HASCHEME']._serialized_end=962 _globals['_LOADBALANCERINTERFACE']._serialized_start=86 _globals['_LOADBALANCERINTERFACE']._serialized_end=156 _globals['_LOADBALANCERSERVICE']._serialized_start=158 _globals['_LOADBALANCERSERVICE']._serialized_end=245 _globals['_EDGENODECLUSTER']._serialized_start=248 - _globals['_EDGENODECLUSTER']._serialized_end=719 + _globals['_EDGENODECLUSTER']._serialized_end=760 # @@protoc_insertion_point(module_scope)