constellation/bootstrapper/initproto/init.proto

81 lines
3.0 KiB
Protocol Buffer
Raw Normal View History

2022-06-21 11:59:12 -04:00
syntax = "proto3";
package init;
import "internal/versions/components/components.proto";
2022-09-22 02:48:30 -04:00
option go_package = "github.com/edgelesssys/constellation/v2/bootstrapper/initproto";
2022-06-21 11:59:12 -04:00
service API {
rpc Init(InitRequest) returns (stream InitResponse);
2022-06-21 11:59:12 -04:00
}
// InitRequest is the rpc message sent to the Constellation bootstrapper to initiate the cluster bootstrapping.
2022-06-21 11:59:12 -04:00
message InitRequest {
reserved 4;
reserved "cloud_service_account_uri";
// KmsUri is an URI encoding access to the KMS service or master secret.
string kms_uri = 1;
// StorageUri is an URI encoding access to the storage service.
string storage_uri = 2;
// MeasurementSalt is a salt used to generate the clusterID for the initial bootstrapping node.
bytes measurement_salt = 3;
// KubernetesVersion is the version of Kubernetes to install.
string kubernetes_version = 5;
// ConformanceMode is a flag to indicate whether the cluster should be bootstrapped for Kubernetes conformance testing.
bool conformance_mode = 6;
// KubernetesComponents is a list of Kubernetes components to install.
repeated components.Component kubernetes_components = 7;
// InitSecret is a secret used to authenticate the initial bootstrapping node.
bytes init_secret = 8;
// ClusterName is the name of the cluster.
string cluster_name = 9;
// ApiserverCertSans is a list of Subject Alternative Names to add to the apiserver certificate.
repeated string apiserver_cert_sans = 10;
// ServiceCIDR is the CIDR to use for Kubernetes ClusterIPs.
string service_cidr = 11;
2022-06-21 11:59:12 -04:00
}
// InitResponse is the rpc message sent by the Constellation bootstrapper in response to the InitRequest.
2022-06-21 11:59:12 -04:00
message InitResponse {
oneof kind {
InitSuccessResponse init_success = 1;
InitFailureResponse init_failure = 2;
LogResponseType log = 3;
}
}
// InitSuccessResponse is the rpc message sent by the Constellation bootstrapper in response to the InitRequest when the bootstrapping was successful.
message InitSuccessResponse {
// Kubeconfig is the kubeconfig for the bootstrapped cluster.
bytes kubeconfig = 1;
// OwnerID is the owner ID of the bootstrapped cluster.
bytes owner_id = 2;
// ClusterID is the cluster ID of the bootstrapped cluster.
bytes cluster_id = 3;
2022-06-21 11:59:12 -04:00
}
// InitFailureResponse is the rpc message sent by the Constellation bootstrapper in response to the InitRequest when the bootstrapping failed.
message InitFailureResponse {
// Error is the error message.
string error = 1;
}
// LogResponseType is the rpc message sent by the Constellation bootstrapper to stream log messages.
message LogResponseType {
// Log are the journald logs of the node.
bytes log = 1;
}
// KubernetesComponent is a Kubernetes component to install.
message KubernetesComponent {
// Url to the component.
string url = 1;
// Hash of the component.
string hash = 2;
// InstallPath is the path to install the component to.
string install_path = 3;
// Extract is a flag to indicate whether the component should be extracted.
bool extract = 4;
}