I recently gave a presentation on how you can use Consul (http://consul.io) for all your service discovery needs in a microservice architecture. The presentation contains a couple of extensive demos whose sources and explanations can be found here: https://github.com/josdirksen/next-build-consul
There are also a couple of articles on this site that further explain the concepts shown in this presentation:
Feel free to use anything from this presentation! Should you have any questions just let me know.