github.com/microsoft/moc@v0.17.1/rpc/cloudagent/cloud/kubernetes/moc_cloudagent_kubernetes.proto (about)

     1  // Copyright (c) Microsoft Corporation.
     2  // Licensed under the Apache v2.0 license.
     3  
     4  syntax = "proto3";
     5  option go_package = "github.com/microsoft/moc/rpc/cloudagent/cloud";
     6  package moc.cloudagent.kubernetes;
     7  
     8  import "google/protobuf/wrappers.proto";
     9  import "moc_common_common.proto";
    10  
    11  message KubernetesRequest {
    12  	repeated Kubernetes Kubernetess = 1;
    13  	Operation OperationType = 2;
    14  }
    15  
    16  message KubernetesResponse {
    17  	repeated Kubernetes Kubernetess = 1;
    18  	google.protobuf.BoolValue Result = 2;
    19  	string  Error = 3;
    20  }
    21  
    22  message StorageConfiguration {
    23  	string csi = 1;
    24  }
    25  
    26  message NetworkConfiguration {
    27  	string cni = 1;
    28  	string podCidr = 2;
    29  	string clusterCidr = 3;
    30  	// TODO: merge controlplane cidr and network
    31  	string controlPlaneCidr = 4;
    32  	string virtualnetwork = 5;
    33  	string loadBalancerVip = 6;
    34  	string loadBalancerMac = 7;
    35  }
    36  
    37  enum NodeType {
    38  	ControlPlane = 0;
    39  	LinuxWorker = 1;
    40  	WindowsWorker = 2;
    41  	LoadBalancer = 3;
    42  }
    43  
    44  enum ManagementStrategyType {
    45  	Pivoted = 0;
    46  	Distinct = 1;
    47  }
    48  
    49  message NodePoolConfiguration {
    50  	NodeType NodeType = 1;
    51  	string imagereference = 2;
    52  	int32 replicas = 3;
    53  	string VMSize = 4;
    54  }
    55  
    56  message SSHPublicKey {
    57  	string keyData = 1 [(sensitive) = true];
    58  }
    59  
    60  message ComputeConfiguration {
    61  	string cri = 1;
    62  	SSHPublicKey publicKey = 2;
    63  	repeated NodePoolConfiguration NodePools = 3;
    64  }
    65  
    66  message ClusterConfiguration {
    67  	string version = 1;
    68  }
    69  
    70  message ClusterAPIConfiguration {
    71  	string ConfigurationEndpoint = 1;         
    72  	string InfrastructureProviderVersion = 2; 
    73  	string BootstrapProviderVersion = 3;
    74  	string ControlPlaneProviderVersion = 4; 
    75  	string CoreProviderVersion = 5;
    76  }
    77  
    78  message ContainerRegistry {
    79  	string Name = 1;
    80  	string Username = 2 [(sensitive) = true];
    81  	string Password = 3 [(sensitive) = true];
    82  }
    83  
    84  message Kubernetes {
    85  	string name = 1;
    86  	string id = 2;
    87  	Status status = 4;
    88  	ClusterConfiguration cluster = 5;
    89  	NetworkConfiguration network = 6;
    90  	StorageConfiguration storage = 7;
    91  	ComputeConfiguration compute = 8;
    92  	string groupName = 9;
    93  	ManagementStrategyType managementStrategy = 10;
    94  	string locationName = 11;
    95  	bytes kubeConfig = 12;
    96  	ClusterAPIConfiguration capiConfig = 13;
    97  	ContainerRegistry containerRegistry = 14;
    98  	bytes deploymentManifest = 15;
    99  	Tags tags = 16;
   100  }
   101  
   102  service KubernetesAgent {
   103  	rpc Invoke(KubernetesRequest) returns (KubernetesResponse) {}
   104  }
   105