Path: blob/main/components/supervisor-api/control.proto
2492 views
// Copyright (c) 2020 Gitpod GmbH. All rights reserved. // Licensed under the GNU Affero General Public License (AGPL). // See License.AGPL.txt in the project root for license information. syntax = "proto3"; package supervisor; import "google/api/annotations.proto"; import "status.proto"; import "info.proto"; option go_package = "github.com/gitpod-io/gitpod/supervisor/api"; option java_package = "io.gitpod.supervisor.api"; // ControlService provides workspace-facing, misc control related services service ControlService { // ExposePort exposes a port rpc ExposePort(ExposePortRequest) returns (ExposePortResponse) {} // CreateSSHKeyPair Create a pair of SSH Keys and put them in ~/.ssh/authorized_keys, this will only be generated once in the entire workspace lifecycle rpc CreateSSHKeyPair(CreateSSHKeyPairRequest) returns (CreateSSHKeyPairResponse) { option (google.api.http) = { get: "/v1/ssh_keys/create" }; } // CreateDebugEnv creates a debug workspace envs rpc CreateDebugEnv(CreateDebugEnvRequest) returns (CreateDebugEnvResponse) {} // SendHeartBeat sends a heartbeat to server to keep the workspace alive rpc SendHeartBeat(SendHeartBeatRequest) returns (SendHeartBeatResponse) { option (google.api.http) = { get: "/v1/send_heartbeat" }; } } message ExposePortRequest { // local port uint32 port = 1; // external port if missing the the same as port reserved 2; } message ExposePortResponse {} message CreateSSHKeyPairRequest {} message CreateSSHKeyPairResponse { // Return privateKey for ws-proxy or web socket tunnels string private_key = 1; // Return hostKey used by client to verify fingerprint SSHPublicKey host_key = 2; // Return userName used by client to authenticate string user_name = 3; } message SSHPublicKey { string type = 1; string value = 2; } message CreateDebugEnvRequest { // workspace_type indicates whether it is a regular or prebuild workspace DebugWorkspaceType workspace_type = 1; // content_source indicates where the workspace content came from ContentSource content_source = 2; // workspace_url is an URL for which the workspace is accessed. string workspace_url = 3; // JSON serialized tasks to run string tasks = 4; // checkout_location is the path where we initialized the workspace content string checkout_location = 5; // workspace_location is the location of the IDE workspace string workspace_location = 6; // logLevel to use in a debug workspace. string logLevel = 7; } message CreateDebugEnvResponse { repeated string envs = 1; } message SendHeartBeatRequest {} message SendHeartBeatResponse {}