This solution contains the gRPC Server implemented in Go.
There is also a node.js package that can be installed run a node server and client (but is not referenced below).
The Dockerfile in the /go directory will create a golang image with:
- Environment variables set appropriately for Azure
- Latest version of Go, a copy of the BlobProxy source code, and an installation of the BlobProxy
- Server port exposed and set to launch on container startup
- Create the image from Dockerfile: 'docker install -t server_image'
- Next, start the server container: 'docker run -it -p 1337:1337 --name Server server_image'
- Run the command: "docker inspect -f '{{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}' Server" (We will use this to connect the client container)
Similar to above, but start with the Dockerfile in /go/client
- Create the image from Dockerfile: 'docker install -t client_image'
- Next, start the server container: 'docker run -it -P client_image <blob.key> '
You should see the results of the blob data printed to the screen.
The node.js client can quickly be used to test the server by running: 'node client <blob.key>'
Go makes it very easy to compile and test our project. In the github.com/weichel/BlobProxy directory, run the command: "go test -v ."