mirror of
https://github.com/siderolabs/talos.git
synced 2025-08-25 16:41:12 +02:00
In order for other projects to make use of our APIs, they must not reside underneath the internal directory. This moves the protobuf definitions to a top-level "api" directory and scopes them according to their domain. This change also removes generated code from the gitignore file so that users don't have to generate the code themseleves. Signed-off-by: Andrew Rynhard <andrew@andrewrynhard.com>
30 lines
708 B
Protocol Buffer
30 lines
708 B
Protocol Buffer
syntax = "proto3";
|
|
|
|
package proto;
|
|
|
|
option go_package = "proto";
|
|
option java_multiple_files = true;
|
|
option java_outer_classname = "ApiProto";
|
|
option java_package = "com.proto";
|
|
|
|
import "google/protobuf/empty.proto";
|
|
import "google/protobuf/timestamp.proto";
|
|
|
|
// The Init service definition.
|
|
service Ntpd {
|
|
rpc Time(google.protobuf.Empty) returns (TimeReply);
|
|
rpc TimeCheck(TimeRequest) returns (TimeReply);
|
|
}
|
|
|
|
// The response message containing the ntp server
|
|
message TimeRequest {
|
|
string server = 1;
|
|
}
|
|
|
|
// The response message containing the ntp server, time, and offset
|
|
message TimeReply {
|
|
string server = 1;
|
|
google.protobuf.Timestamp localtime = 2;
|
|
google.protobuf.Timestamp remotetime = 3;
|
|
}
|