Follow the steps to install Go if you do not already have it.
Follow the steps to install Docker if you do not already have it.
Set up GOPROXY for AKS
Note that we use the remote aks middleware. This middleware is responsible for features such as logging, retry, and input validation. To learn more, please visit the repo.
./init.sh
# Follow instructions from the scripts to create the api module, etc.
There is a simple way to run the MyGreeter service, after everything has been properly generated. Inside the MyGreeter directory, you can run the client, demoserver and server.
To run the server:
go run go.goms.io/aks/rp/mygreeterv3/server/cmd/server start
By default the server starts in port localhost:50051
and the enable-azureSDK-calls flag is set to false.
To run the server with the azureSDK calls enabled:
go run go.goms.io/aks/rp/mygreeterv3/server/cmd/server start --enable-azureSDK-calls true --subscription-id <sub_id>
By default, the sayHello calls are served directly by the server. In order to forward the call to the demoserver:
go run go.goms.io/aks/rp/mygreeterv3/server/cmd/server start --remote-addr <remote_addr>
To run the client:
go run go.goms.io/aks/rp/mygreeterv3/server/cmd/client hello
By default the client sends messages to port localhost:50051
. This can be changed by running
go run go.goms.io/aks/rp/mygreeterv3/server/cmd/client hello --remote-addr <remote_addr>
To run the demoserver, you must use a different port than the server is already using, so you can send messages to the demoserver from the server.
To run the demoserver:
go run go.goms.io/aks/rp/mygreeterv3/server/cmd/demoserver start
To run the demoserver in a particular port:
go run go.goms.io/aks/rp/mygreeterv3/server/cmd/demoserver start --port <local_port>
You can run help on every command in order to get more information on how to use them.
Examples:
go run go.goms.io/aks/rp/mygreeterv3/server/cmd/client help
go run go.goms.io/aks/rp/mygreeterv3/server/cmd/demoserver start -h
git clean -xdf
sudo rm -rf ~/.aksbuilder
To view your service in Azure Data Explorer (ADX), follow ADX dashboard creation/update instructions.