Compare commits
5 Commits
83ebab1cc6
...
master
| Author | SHA1 | Date | |
|---|---|---|---|
| 2cdd6874b4 | |||
| f248c19b07 | |||
| c400d2d58b | |||
|
0405aba995
|
|||
|
d3f2d336a0
|
44
.drone.yml
44
.drone.yml
@@ -6,7 +6,7 @@ name: generate-go-grpc
|
||||
steps:
|
||||
- name: clone-external
|
||||
image: alpine/git
|
||||
commands:
|
||||
commands:
|
||||
- git clone https://${GIT_USER}:${GIT_PASS}@git.itzana.me/StrafesNET/go-grpc.git
|
||||
environment:
|
||||
GIT_USER:
|
||||
@@ -46,7 +46,7 @@ name: generate-rust-grpc
|
||||
steps:
|
||||
- name: clone-external
|
||||
image: alpine/git
|
||||
commands:
|
||||
commands:
|
||||
- git clone https://${GIT_USER}:${GIT_PASS}@git.itzana.me/StrafesNET/rust-grpc.git
|
||||
environment:
|
||||
GIT_USER:
|
||||
@@ -78,43 +78,3 @@ trigger:
|
||||
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
---
|
||||
kind: pipeline
|
||||
type: docker
|
||||
name: generate-python-grpc
|
||||
|
||||
steps:
|
||||
- name: clone-external
|
||||
image: alpine/git
|
||||
commands:
|
||||
- git clone https://$GIT_USER:$GIT_PASS@git.itzana.me/StrafesNET/python-grpc.git
|
||||
environment:
|
||||
GIT_USER:
|
||||
from_secret: GIT_USER
|
||||
GIT_PASS:
|
||||
from_secret: GIT_PASS
|
||||
|
||||
- name: generate
|
||||
image: registry.itzana.me/strafesnet/tools/python-grpc:latest
|
||||
commands:
|
||||
- scripts/python-gen.sh
|
||||
|
||||
- name: commit
|
||||
image: alpine/git
|
||||
commands:
|
||||
- cd python-grpc
|
||||
- git add *
|
||||
- 'git commit -m "Autogenerated update for ${DRONE_COMMIT_LINK}" || true'
|
||||
- git push https://$GIT_USER:$GIT_PASS@git.itzana.me/StrafesNET/python-grpc.git --all
|
||||
environment:
|
||||
GIT_USER:
|
||||
from_secret: GIT_USER
|
||||
GIT_PASS:
|
||||
from_secret: GIT_PASS
|
||||
|
||||
trigger:
|
||||
ref:
|
||||
- refs/heads/master
|
||||
|
||||
image_pull_secrets:
|
||||
- dockerconfigjson
|
||||
14
auth.proto
14
auth.proto
@@ -11,6 +11,7 @@ service AuthService {
|
||||
rpc GetGroupRole(IdMessage) returns (RoleReponse);
|
||||
rpc ValidateSession(IdMessage) returns (ValidateResponse);
|
||||
rpc GetAuthMetadata(google.protobuf.Empty) returns (AuthMetadataResponse);
|
||||
rpc GetAvatars(AvatarListRequest) returns (AvatarListResponse);
|
||||
}
|
||||
|
||||
message IdMessage {
|
||||
@@ -43,3 +44,16 @@ message AuthMetadataResponse {
|
||||
string AccountURL = 3;
|
||||
}
|
||||
|
||||
message AvatarListRequest {
|
||||
repeated uint64 UserIDs = 1;
|
||||
}
|
||||
|
||||
message AvatarItem {
|
||||
uint64 UserID = 1;
|
||||
string AvatarURL = 2;
|
||||
}
|
||||
|
||||
message AvatarListResponse {
|
||||
repeated AvatarItem Avatars = 1;
|
||||
}
|
||||
|
||||
|
||||
@@ -50,9 +50,9 @@ message MapfixResponse {
|
||||
uint64 Submitter = 7;
|
||||
uint64 AssetID = 8;
|
||||
uint64 AssetVersion = 9;
|
||||
uint64 ValidatedAssetID = 10;
|
||||
uint64 ValidatedAssetVersion = 11;
|
||||
uint64 UploadedAssetID = 12;
|
||||
optional uint64 ValidatedAssetID = 10;
|
||||
optional uint64 ValidatedAssetVersion = 11;
|
||||
uint64 TargetAssetID = 12;
|
||||
MapfixStatus StatusID = 13;
|
||||
}
|
||||
|
||||
|
||||
@@ -12,8 +12,11 @@ service MapsService {
|
||||
rpc Delete(MapId) returns (NullResponse);
|
||||
rpc List(ListRequest) returns (MapList);
|
||||
rpc IncrementLoadCount(MapId) returns (NullResponse);
|
||||
rpc GetSnfmDownloadUrl(MapId) returns (SnfmDownloadUrl);
|
||||
}
|
||||
|
||||
message SnfmDownloadUrl { string Url = 1; }
|
||||
|
||||
message MapIdList { repeated int64 ID = 1; }
|
||||
|
||||
message MapId { int64 ID = 1; }
|
||||
|
||||
@@ -1,6 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
mkdir -p strafesnet
|
||||
cp *.proto strafesnet/
|
||||
python3 -m grpc_tools.protoc -I./strafesnet --python_out=./python-grpc/strafesnet --grpc_python_out=./python-grpc/strafesnet *.proto
|
||||
sed -i 's/^\(import.*pb2\)/from . \1/g' ./python-grpc/strafesnet/*.py
|
||||
@@ -49,9 +49,9 @@ message SubmissionResponse {
|
||||
uint64 Submitter = 9;
|
||||
uint64 AssetID = 10;
|
||||
uint64 AssetVersion = 11;
|
||||
uint64 ValidatedAssetID = 12;
|
||||
uint64 ValidatedAssetVersion = 13;
|
||||
uint64 UploadedAssetID = 14;
|
||||
optional uint64 ValidatedAssetID = 12;
|
||||
optional uint64 ValidatedAssetVersion = 13;
|
||||
optional uint64 UploadedAssetID = 14;
|
||||
SubmissionStatus StatusID = 15;
|
||||
}
|
||||
|
||||
|
||||
@@ -11,6 +11,7 @@ service UsersService {
|
||||
rpc Create(UserRequest) returns (IdMessage);
|
||||
rpc Delete(IdMessage) returns (NullResponse);
|
||||
rpc List(ListRequest) returns (UserList);
|
||||
rpc SearchByUsername(SearchByUsernameRequest) returns (UserList);
|
||||
}
|
||||
|
||||
message IdList {
|
||||
@@ -55,6 +56,11 @@ message Pagination {
|
||||
int32 Number = 2;
|
||||
}
|
||||
|
||||
message SearchByUsernameRequest {
|
||||
string Query = 1;
|
||||
Pagination Page = 2;
|
||||
}
|
||||
|
||||
message NullResponse {
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user