A template for running gRPC implementations.
-
Clone this repository
-
Run the following to install protocol compiler plugins
go install google.golang.org/protobuf/cmd/[email protected]
go install google.golang.org/grpc/cmd/[email protected]
- Update GO ENV path:
export PATH="$PATH:$(go env GOPATH)/bin"
-
Edit the
.proto
file as per your liking -
Run the following command
protoc --go_out=. --go_opt=paths=source_relative \
--go-grpc_out=. --go-grpc_opt=paths=source_relative \
proto/*.proto
-
Add implementations to
client.go
andserver.go
-
Finally , Run
go run server/server.go
go run client/client.go