EntryPoints
EntryPoints define network entry points where Traefik listens for incoming connections.What is an EntryPoint?
An EntryPoint specifies:- Port to listen on (e.g.,
:80,:443) - Protocol to use (TCP or UDP)
- Address to bind to (optional, defaults to all interfaces)
EntryPoints are configured in static configuration and require a Traefik restart to change.
Basic Configuration
Address Format
Theaddress field follows this format:
- Port Only
- Specific IP
- TCP and UDP
Listen on all interfaces:
Common EntryPoint Configurations
HTTP and HTTPS
Standard web server setup:Custom Ports
Multiple Protocols
HTTP Configuration
HTTP-specific options for web traffic.Automatic HTTPS Redirect
Redirect all HTTP traffic to HTTPS:TLS Configuration
Configure TLS for HTTPS:- Let's Encrypt
- Custom Certificates
- TLS Options
Automatic certificates with ACME:
HTTP/2 and HTTP/3
HTTP/3 automatically creates a UDP listener on the same port as the TCP EntryPoint.
Middleware on EntryPoints
Apply middleware to all routers using an EntryPoint:Transport Configuration
Configure connection timeouts and lifecycle.Timeouts
duration
Maximum duration for reading request including body (default:
60s).duration
Maximum duration for writing response (default:
0s - no timeout).duration
Maximum duration for idle keep-alive connections (default:
180s).Graceful Shutdown
Keep-Alive Limits
Forwarded Headers
Trust proxy headers likeX-Forwarded-For:
- Trusted IPs
- Insecure Mode
Trust specific proxy IPs:
Proxy Protocol
Support HAProxy PROXY protocol:Proxy Protocol supports versions 1 and 2. The version is auto-detected.
Default EntryPoints
Mark EntryPoints as default for routers that don’t specify entryPoints:If no EntryPoint has
asDefault: true, routers listen on all EntryPoints by default.Advanced Features
ReusePort
Allow multiple Traefik processes to bind to the same port (Linux only):- Zero-downtime deployments
- Canary releases
- Load balancing across processes
Encoded Characters
Control handling of encoded characters in request paths:Path Sanitization
Real-World Examples
Production web server
Production web server
Complete production setup with security:
Multi-service architecture
Multi-service architecture
Multiple EntryPoints for different services:
Behind load balancer
Behind load balancer
Traefik behind AWS ALB or GCP Load Balancer:
Next Steps
Configure Routers
Create routing rules to match and forward requests
Setup TLS
Configure HTTPS certificates and TLS options