I haven't found too much information on how to setup a Go service and Consul running on top of Docker using docker-compose
, so I decided to create this little example setup.
- Clone it and run
docker build -t mgyongyosi/weather .
inside the repository's folder - Start with
docker-compose up
- Check the Consul Web-UI on
localhost:8500/ui
- Check the Go service on
localhost:8080/
and the 'heartbeat' onlocalhost:8080/health
(it returns only200 OK
)