feat: new proto
This commit is contained in:
parent
d7190ebe79
commit
23d0ce66e9
5
Makefile
5
Makefile
|
@ -6,7 +6,7 @@ GOFMT ?= gofmt "-s"
|
||||||
GOFILES := $(shell find . -name "*.go")
|
GOFILES := $(shell find . -name "*.go")
|
||||||
LDFLAGS := -s -w
|
LDFLAGS := -s -w
|
||||||
VERSION="v1.0.1"
|
VERSION="v1.0.1"
|
||||||
DOCKER_REPO="code.30cm.net/permission"
|
DOCKER_REPO="reg.wang/app-cloudep-permission-service"
|
||||||
|
|
||||||
.PHONY: test
|
.PHONY: test
|
||||||
test: # 進行測試
|
test: # 進行測試
|
||||||
|
@ -42,10 +42,11 @@ run-docker: # 建立 rpc code
|
||||||
.PHONY: build-docker
|
.PHONY: build-docker
|
||||||
build-docker:
|
build-docker:
|
||||||
cp ./build/Dockerfile Dockerfile
|
cp ./build/Dockerfile Dockerfile
|
||||||
docker buildx build -t $(DOCKER_REPO):$(VERSION) --build-arg SSH_PRIVATE_KEY="$(cat ~/.ssh/ed_25519)" .
|
docker buildx build -t $(DOCKER_REPO):$(VERSION) --build-arg SSH_PRIVATE_KEY="$(cat ~/.ssh/id_ed25519)" .
|
||||||
rm -rf Dockerfile
|
rm -rf Dockerfile
|
||||||
@echo "Generate core-api files successfully"
|
@echo "Generate core-api files successfully"
|
||||||
|
|
||||||
|
|
||||||
.PHONY: mock-gen
|
.PHONY: mock-gen
|
||||||
mock-gen: # 建立 mock 資料
|
mock-gen: # 建立 mock 資料
|
||||||
mockgen -source=./pkg/domain/repository/token.go -destination=./pkg/mock/repository/token.go -package=mock
|
mockgen -source=./pkg/domain/repository/token.go -destination=./pkg/mock/repository/token.go -package=mock
|
||||||
|
|
|
@ -142,3 +142,9 @@ service TokenService {
|
||||||
// GetUserTokensByUID 取得目前所對應的 UID 所存在的 Tokens
|
// GetUserTokensByUID 取得目前所對應的 UID 所存在的 Tokens
|
||||||
rpc GetUserTokensByUID(QueryTokenByUIDReq) returns(Tokens);
|
rpc GetUserTokensByUID(QueryTokenByUIDReq) returns(Tokens);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// permission / role / role permission 相關
|
||||||
|
service PermissionService{
|
||||||
|
|
||||||
|
}
|
Loading…
Reference in New Issue