Warning
Infrarust is currently in active development. This project is a Rust implementation inspired by Infrared, focusing on performance and enhanced features.
A blazing fast Minecraft reverse proxy that allows you to expose multiple Minecraft servers through a single port. It uses domain/subdomain-based routing to direct clients to specific Minecraft servers.
- Efficient Reverse Proxy
- Wildcard Domain Support
- Multi-Domain Routing
- Direct IP Connection Support
- Authentication Modes
- ClientOnly Mode (only works with vanilla < 1.20)
- Passthrough Mode
- Offline Mode
- ServerOnly Mode
- Performance Optimizations
- Connection Pooling
- Zero-copy packet forwarding
- Status Caching
- Security Features
- Rate Limiting
- Basic DDoS Protection
- Advanced Ban System (IP, UUID, Username)
- Container Integration
- Docker Auto-Discovery
- Real-time Container Monitoring
- Command Line Interface
- Player Management
- Ban Management
- Status Monitoring
- Basic Telemetry and Monitoring
- Rust 1.84+ and Cargo
# From source
git clone https://github.com/shadowner/infrarust
cd infrarust
cargo build --release
# Or via cargo
cargo install infrarust
Create a config.yaml
file:
bind: "0.0.0.0:25565"
file_provider:
proxies_path: ["./proxies"]
watch: true # Enable hot-reload
And create your server configurations in the proxies
directory:
# proxies/my-server.yml
domains:
- "hub.minecraft.example.com"
addresses:
- "localhost:25566"
proxyMode: "passthrough" # Options: passthrough, client_only, offline, server_only
Visit infrarust.dev for complete documentation:
Infrarust can automatically detect and proxy Minecraft servers running in Docker containers:
docker_provider:
docker_host: "unix:///var/run/docker.sock"
label_prefix: "infrarust"
watch: true
Container configuration is done through Docker labels:
infrarust.enable=true
infrarust.domains=mc.example.com
Infrarust provides comprehensive telemetry through OpenTelemetry integration, including metrics, traces, and logs. The project includes a ready-to-use monitoring stack in the docker/monitoring directory.
cd docker/monitoring
docker compose up -d
This will start:
- Grafana (http://localhost:3000)
- Prometheus (http://localhost:9090)
- Tempo (Traces)
- OpenTelemetry Collector
- Connection metrics (active connections, errors, latency)
- Backend metrics (server status, response times)
- System metrics (CPU, memory, threads)
- Minecraft-specific metrics (protocol errors, player count)
Infrarust leverages Rust's performance capabilities:
- Minimal memory footprint (~10MB base)
- Low CPU utilization
- Efficient async I/O handling
- Zero-copy packet forwarding when possible
Note
This project was initiated as a learning experience in advanced Rust programming, with continuous improvements and optimizations expected as development progresses.
Contributions are welcome! Check out our Contributing Guidelines to get started.
Feel free to join our Discord if you have any questions!
Infrarust is licensed under the GNU Affero General Public License v3.0 - see the LICENSE file for details.