Sign inSign up

amineloop/lrm-node

By amineloop

•Updated about 1 year ago

Self-hosted relay server for Mirror (Unity) using Light Reflective Mirror. (NAT punch disabled).

Image
Networking
1

1.0K

amineloop/lrm-node repository overview

⁠🚀 Light Reflective Mirror Relay (LRM) – Docker Image

Self-hosted relay server for Light Reflective Mirror (LRM)⁠
Easily run your own relay to allow P2P hosting, server lists and relay connections with Mirror Networking.

⚠️ NAT Punchthrough is disabled in this build (I couldn’t get it stable).
The relay-only mode works perfectly fine for hosting/joining by code.


⁠🚀 Quick Start

docker run -d \
  -p 8080:8080 \
  -p 7777:7777/udp \
  amineloop/lrm-node:latest

➡️ Relay now available at:

  • Endpoint API: http://<your-server-ip>:8080
  • Relay Port: 7777/udp

⁠⚙️ Configuration

Environment variables you can override:

VariableDefaultDescription
AUTH_KEYSecret Auth KeyAuthentication key (must match client)
TRANSPORT_CLASSkcp2k.KcpTransportTransport class (KCP, Telepathy, SimpleWeb)
TRANSPORT_DLLMultiCompiled.dllDLL used for transport
TRANSPORT_PORT7777Main data port
ENDPOINT_PORT8080HTTP endpoint / server list
ENABLE_NATPUNCH_SERVERfalseNAT punchthrough (disabled)

⁠📦 Docker Compose Example

version: "3.8"
services:
  lrm-node:
    image: amineloop/lrm-node:latest
    container_name: lrm-node
    restart: unless-stopped
    ports:
      - "8080:8080"
      - "7777:7777/udp"
    environment:
      AUTH_KEY: "CHANGE_ME_SECRET"
      TRANSPORT_CLASS: "kcp2k.KcpTransport"
      ENABLE_NATPUNCH_SERVER: "false"

⁠🛡️ Security Notes

  • Always set your own AUTH_KEY to prevent abuse.
  • If public-facing: consider running behind Nginx + HTTPS for the endpoint (port 8080).
  • Relay handles ~200 CCU on a small VPS ($5 cloud instance).

⁠🤝 Credits

Derek-R-S - which maintained and developed it until v12.

Cooper - Assisted with development and made some wonderful features! He's also active in the discord to help answer questions and help with issues.

Maqsoom & JesusLuvsYooh - Both really active testers and have been testing it since I pitched the idea. They tested almost all versions of DRM and I am sure they will test the crap out of LRM!

All Mirror Transport Creators! - They made all the transports that this thing relies on! Especially the Simple Web Transport by default!

  • Dockerization & packaging by amineloop.

Tag summary

Content type

Image

Digest

sha256:fd9ede6bb…

Size

88.3 MB

Last updated

about 1 year ago

docker pull amineloop/lrm-node