5 stable releases
1.1.1 | Feb 27, 2025 |
---|---|
1.1.0 | Jan 29, 2025 |
1.0.2 | Jan 19, 2025 |
1.0.0 | Jan 18, 2025 |
#1606 in Network programming
80 downloads per month
305KB
7.5K
SLoC
Infrarust
High-Performance Minecraft Reverse Proxy in Rust
Compatible with almost every Minecraft Versions + Modded Versions
[!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.
Key Features
- 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
- Performance Optimizations
- Connection Pooling
- Zero-copy packet forwarding
- Security Features
- Rate Limiting
- Basic DDoS Protection
- Basic Telemetry
Quick Start
Prerequisites
- Rust 1.80+ and Cargo
Installation
# From source
git clone https://github.com/shadowner/infrarust
cd infrarust
cargo build --release
# Or via cargo
cargo install infrarust
Basic Configuration
Create a config.yaml
file, known as the Proxy Configuration File:
bind: "0.0.0.0:25565"
domains:
- "minecraft.example.com"
And create your server configurations in the proxies
directory known as the Servier Configuration File:
domains:
- "hub.minecraft.example.com"
addresses:
- "localhost:25566"
proxyMode: "passthrough" # Options: passthrough, cllient-only, offline
Documentation
Visit infrarust.dev for complete documentation:
Telemetry & Monitoring
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.
Quick Start Monitoring
cd docker/monitoring
docker compose up -d
This will start:
- Grafana (http://localhost:3000)
- Prometheus (http://localhost:9090)
- Tempo (Traces)
- OpenTelemetry Collector
Available Metrics
- Connection metrics (active connections, errors, latency)
- Backend metrics (server status, response times)
- System metrics (CPU, memory, threads)
- Minecraft-specific metrics (protocol errors, player count)
Performance
Infrarust leverages Rust's performance capabilities:
- Minimal memory footprint
- 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.
Contributing
Contributions are welcome! Check out our Contributing Guidelines to get started.
Feel free to join our Discord if you have any question !
Similar Projects
License
Infrarust is licensed under the GNU Affero General Public License v3.0 - see the LICENSE file for details.
Dependencies
~26–40MB
~632K SLoC