This repository contains a simple and easy example about Traefik Proxy v3 using Docker Compose and Kubernetes.
Before getting started, make sure you have the following installed on your machine:
- Docker
- Docker Compose
or
- Kubernetes
- Helm
-
Clone this repository to your local machine:
git clone https://github.com/garovu/traefik-proxy-example.git
-
Navigate to the project directory:
cd traefik-proxy-example/docker
-
Customize the Traefik configuration in the
traefik.yaml
file according to your needs. -
Start the Traefik proxy:
docker-compose up -d
-
Verify that the Traefik proxy is running by accessing the Traefik dashboard at
http://localhost:8080
.Checking first example by going to
http:localhost:80
which will be point to thewhoami
container. More about docker provider. -
Start monitoring cluster (just metrics at this time):
docker-compose -f monitoring-compose -d
-
Grafana Dashboard:
localhost:3000
-
Prometheus :
localhost:9090
-
-
Stop this compose and remove containers.
docker-compose down docker-compose -f monitoring-compose.yaml down
- *updating
The traefik.yaml
file contains the configuration for the Traefik proxy. You can modify this file to customize the proxy behavior, such as adding additional middleware, defining routing rules, or enabling TLS.
For more information on how to configure Traefik, refer to the official documentation.
Contributions are welcome! If you have any improvements or bug fixes, feel free to open a pull request.
This project is licensed under the MIT License.