-
Notifications
You must be signed in to change notification settings - Fork 0
/
configurator.proto
110 lines (87 loc) · 2.37 KB
/
configurator.proto
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
syntax = "proto3";
//protoc --go_out=. --go_opt=paths=source_relative --go-grpc_out=. --go-grpc_opt=paths=source_relative ./proto/configurator.proto
// protoc -I=. configurator.proto \
// --js_out=import_style=commonjs,binary:./ts \
// --grpc-web_out=import_style=typescript,mode=grpcweb:./ts
// protoc -I=. --ts_out ./ts --proto_path . configurator.proto
option go_package = "github.com/easytech-international-sdn-bhd/sqlaccounting/proto";
package proto;
message TaskClientRequest {
int32 db = 1;
string addr = 2;
string username = 3;
string password = 4;
}
message CreateRequest {
string username = 1;
string password = 2;
string url = 3;
string appName = 4;
}
message IsDcfParsableRequest {
string dcfPath = 1;
}
message Database {
string database = 1;
string companyName = 2;
string remark = 3;
string version = 4;
string dbUsername = 5;
string dbPassword = 6;
}
message IsDcfParsableResponse {
repeated Database database = 1;
}
message TempPathRequest {
string tempPath = 1;
}
message PatchUrlRequest {
string patchUrl = 1;
}
message HookUrlRequest {
string hookUrl = 1;
}
message ReachableRequest {
string url = 1;
}
message LoginConfiguratorRequest {
string username = 1;
string password = 2;
}
message PluginResult {
string name = 1;
string error = 2;
}
message PluginResponse {
repeated PluginResult res = 1;
}
message GcpCredentialsRequest {
string jsonData = 1;
}
message GcpProjectIdRequest {
string projectId = 1;
}
message IdResponse {
string serviceId = 1;
}
message ClientId {
string id = 1;
}
message Empty {
}
service SetupConfigurator {
rpc Create(CreateRequest) returns (Empty);
rpc IsDcfParsable(IsDcfParsableRequest) returns (IsDcfParsableResponse);
rpc SetDatabase(Database) returns (Empty);
rpc SetTempPath(TempPathRequest) returns (Empty);
rpc SetPatchUrl(PatchUrlRequest) returns (Empty);
rpc SetHookUrl(HookUrlRequest) returns (Empty);
rpc IsReachable(ReachableRequest) returns (Empty);
rpc LoginConfigurator(LoginConfiguratorRequest) returns (Empty);
rpc InstallPlugins(Empty) returns(PluginResponse);
rpc UninstallPlugins(Empty) returns(PluginResponse);
rpc SetTaskClientConfig(TaskClientRequest) returns (Empty);
rpc SetGpcCredentials(GcpCredentialsRequest) returns (Empty);
rpc SetGcpProjectId(GcpProjectIdRequest) returns (Empty);
rpc GetServiceId(Empty) returns (IdResponse);
}