mirror of
https://github.com/siderolabs/talos.git
synced 2025-09-30 18:21:11 +02:00
This option must be defined at the proto level in order to have an import path that is reasonably usable Signed-off-by: Eddie Zaneski <eddiezane@gmail.com> Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
34 lines
810 B
Protocol Buffer
34 lines
810 B
Protocol Buffer
syntax = "proto3";
|
|
|
|
package time;
|
|
|
|
option go_package = "github.com/siderolabs/talos/pkg/machinery/api/time";
|
|
option java_package = "dev.talos.api.time";
|
|
|
|
import "common/common.proto";
|
|
import "google/protobuf/empty.proto";
|
|
import "google/protobuf/timestamp.proto";
|
|
|
|
// The time service definition.
|
|
service TimeService {
|
|
rpc Time(google.protobuf.Empty) returns (TimeResponse);
|
|
rpc TimeCheck(TimeRequest) returns (TimeResponse);
|
|
}
|
|
|
|
// The response message containing the ntp server
|
|
message TimeRequest {
|
|
string server = 1;
|
|
}
|
|
|
|
message Time {
|
|
common.Metadata metadata = 1;
|
|
string server = 2;
|
|
google.protobuf.Timestamp localtime = 3;
|
|
google.protobuf.Timestamp remotetime = 4;
|
|
}
|
|
|
|
// The response message containing the ntp server, time, and offset
|
|
message TimeResponse {
|
|
repeated Time messages = 1;
|
|
}
|