Sem descrição

huangyan 078922e21c 日志,文件 há 11 meses atrás
.idea ff14ff36d7 hook há 11 meses atrás
configs 078922e21c 日志,文件 há 11 meses atrás
global 078922e21c 日志,文件 há 11 meses atrás
model 078922e21c 日志,文件 há 11 meses atrás
protobuf ff14ff36d7 hook há 11 meses atrás
simple_zap 078922e21c 日志,文件 há 11 meses atrás
utils 078922e21c 日志,文件 há 11 meses atrás
README.md ff14ff36d7 hook há 11 meses atrás
go.mod 078922e21c 日志,文件 há 11 meses atrás
go.sum 078922e21c 日志,文件 há 11 meses atrás
main.go 078922e21c 日志,文件 há 11 meses atrás

README.md

exhook-svr-go

This is a demo server written in go for exhook

Prerequisites

  • Go (any one of the three latest major)
  • Protocol buffer compiler, protoc For installation instructions, see Protocol Buffer Compiler Installation.
  • Go plugins for the protocol compiler:

    • Install the protocol compiler plugins for Go using the following commands:

      export GO111MODULE=on  # Enable module mode
      go install google.golang.org/protobuf/cmd/protoc-gen-go@latest
      go install google.golang.org/grpc/cmd/protoc-gen-go-grpc@latest
      
    • Update your PATH so that the protoc compiler can find the plugins:

      export PATH="$PATH:$(go env GOPATH)/bin"
      

Run

Try to compile the *.proto files:

protoc --go_out=. --go_opt=paths=source_relative \
    --go-grpc_out=. --go-grpc_opt=paths=source_relative \
    protobuf/exhook.proto

Run server

go run main.go