Modern HTTP Reverse proxy and load balacning that makes deploying microservices easy.
- Traefik used as reverse proxy
- Configure microservices with automatic service discovery
- Automatic loadbalancing of each service with multiple containers
Docker & GIT needs to be configured
docker-compose up -d- Will start all application togetherdocker-compose up -d --build- Rebuild if you have file changesdocker-compose up -d proxydocker-compose up -d pinodocker-compose up -d minodocker-compose up -d whoamidocker-compose up -d --scale whoami=2- Automatic load-balancing by traefik for two containers for the same service.
- Pino service -
curl -H Host:pino.docker.localhost http://127.0.0.1:3000 - Mino service -
curl -H Host:mino.docker.localhost http://127.0.0.1:3000 - Inter service communication -
curl -H Host:pino.docker.localhost http://127.0.0.1:3000/mino
- Req to pino serice -
curl -H Host:pino.docker.localhost http://127.0.0.1:3000 - Req to whoami service -
curl -H Host:whoami.docker.localhost http://127.0.0.1:3000
- Use service name and internal port.
- Service discovery on traefik routes & services - JSON data link
- Traefik dashboard
- Load balancing and reverse proxy with traefik
-
docker network prune- This will remove all networks not used by at least one container.