vgo-docker-example
vgo-docker-example copied to clipboard
An example of how to use vgo (https://research.swtch.com/vgo-tour) + Docker together.
vgo-docker-example
A straightforward example of how to:
- Build Go applications using vgo
- Write a Dockerfile that uses vgo as part of it's build process.
- Copy the build artifact to a minimal Docker image the leverages the google/distroless image.
The end result? Reproducible builds and small images.
Installing
Get the package:
go get github.com/elithrar/vgo-docker-example
Build it:
docker build -t vgo-docker-example:latest .
Run it:
docker run vgo-docker-example:latest
The vgo-docker-example
runs a simple web server using gorilla/mux.
License
BSD licensed. See the LICENSE file for details.