Note
This repo is a example for this article https://arisharyanto.medium.com/best-way-to-structuring-golang-code-6e619e70ce38
$ docker-compose up -d
follow this http://google.github.io/proto-lens/installing-protoc.html to install protobuf in your PC
and then run this in you cli
$ go install google.golang.org/protobuf/cmd/protoc-gen-go@latest
$ go install google.golang.org/grpc/cmd/protoc-gen-go-grpc@latest
open bash_profile file
$ nano ~/.bash_profile
add this code inside
export GO_PATH=~/go
export PATH=$PATH:/$GO_PATH/bin
then save.
and then run this
$ source ~/.bash_profile
$ protoc -I./proto --go_out=./proto --go-grpc_out=./proto ./proto/*.proto
$ go run cmd/*.go