This is the companion project for the post on the codecentric blog. You can use it to follow along and setup your own environment to play with Traefik.
Vagrant uses the ansible provisioner to bootstrap the machines. Have a look into the provision directory for details. The main entry file for the server and client are a good starting point.
It will create two virtual machines as a server and a client. The server will host a DNS server and a Traefik server. The client is configured to use the previously created DNS resolver.
To get started make sure you have Vagrant installed on your machine. Once you are ready to go you can set the environment up:
vagrant up
This will create the two virtual machines with the name server and client.
Now you can test the configuration
vagrant ssh client
Now you work within the context of the test DNS Server and the demo Traefik instance.
Now you access the whoami docker container on the server
curl whoami.server.test
You can access the traefik Dashboard from the browser of your host machine.
The port 8080 is explicitly exposed from the server. You can only have a look at the dashboard.