local.dev
The local.dev proxy provides automatic routing and load balancing for your local services.
Overview
The reverse proxy integrates with your development workflow to route traffic to your services.
Features
- Automatic discovery - Detects services automatically
- SSL termination - Handle HTTPS at the proxy
- Load balancing - Distribute traffic
- Middleware - Auth, rate limiting, etc.
Dashboard
Access the proxy dashboard:
http://proxy.local.test/dashboard/Configuration
Basic Router
# proxy/config.yml
http:
routers:
my-app:
rule: "Host(`app.local.test`)"
service: my-app
entryPoints:
- web
services:
my-app:
loadBalancer:
servers:
- url: "http://localhost:3000"With SSL
http:
routers:
my-app-secure:
rule: "Host(`app.local.test`)"
service: my-app
entryPoints:
- websecure
tls:
certResolver: localEntrypoints
| Name | Port | Protocol |
|---|---|---|
| web | 80 | HTTP |
| websecure | 443 | HTTPS |
Middleware
Basic Auth
http:
middlewares:
my-auth:
basicAuth:
users:
- "admin:$apr1$..."
routers:
my-app:
middlewares:
- my-authRate Limiting
http:
middlewares:
rate-limit:
rateLimit:
average: 100
burst: 50Best Practices
- Use labels - For Docker-based services
- Separate configs - One file per service
- Health checks - Monitor service availability
- Access logs - Enable for debugging