Quick Start

Get your mining relay running in under 15 minutes.

Prerequisites

ComponentMinimum Requirement
Relay ServerLinux x86_64/ARM, 1 core / 512 MB RAM, public IP, ports 8555/9555 open
ClientLinux or Windows, same LAN as miners
MinersAny Stratum-compatible miner (BTC/ETH/LTC/KAS…)

Step 1 — Deploy the Server

The one-line installer downloads hr-server, writes /etc/hash-relay/server.toml, installs the web admin UI, and registers a system service.

# Install the relay server (interactive prompts for ports, DB, JWT secret)
curl -fsSL https://hashrelay.net/releases/scripts/install-server.sh | sudo sh

The server listens on TCP 8555 (encrypted tunnel) and UDP 9555 (QUIC). The REST API and web admin UI are served on port 8080.

Tip: Open 8555/tcp and 9555/udp in your firewall. Restrict 8080/tcp (admin) to trusted networks or a reverse proxy.

Step 2 — Install the Client

Create a client node on the server first (Web UI → Client Nodes) to obtain client_id and token. Then install the client on a machine in the same LAN as your miners.

Option A — Environment variables (recommended)

Replace every YOUR_* placeholder with your own values before running:

# Create a client node on the server first (Web UI → Client Nodes).
# Replace YOUR_* values below with your own before running.

curl -fsSL https://hashrelay.net/releases/scripts/install-client.sh | \
  sudo env \
    SERVER_ADDR=YOUR_SERVER_IP \
    TCP_PORT=8555 \
    QUIC_PORT=9555 \
    CLIENT_ID=YOUR_CLIENT_ID \
    TOKEN=YOUR_ACCESS_TOKEN \
    sh

# OpenWrt / already root: omit sudo — pipe to "env ... sh" instead

Option B — Interactive install

Omit the exports — the installer prompts for each value:

# Interactive install — the script prompts for each value.
curl -fsSL https://hashrelay.net/releases/scripts/install-client.sh | sudo sh

Option C — Install first, configure later

Run the one-line install, edit /etc/hash-relay/client.toml, then restart the service:

# Install first, edit config, then restart:
curl -fsSL https://hashrelay.net/releases/scripts/install-client.sh | sudo sh
# OpenWrt / already root: omit sudo on the line above

# Edit /etc/hash-relay/client.toml — set server_addr, tcp_port, quic_port, client_id, token
sudo nano /etc/hash-relay/client.toml

# Restart — Linux (systemd):
sudo systemctl restart hash-relay-client

# Restart — OpenWrt (procd):
/etc/init.d/hash-relay-client restart

Key fields in client.toml: server_addr, tcp_port, quic_port, client_id, and token. Local listen ports are pushed by the server automatically — no manual port setup on the client.

Step 3 — Configure a Pool Mapping

Pool and port mappings are managed from the server's web admin panel — no command line required.

  1. Open the admin panel at http://YOUR_SERVER:8080 and sign in. The default password is hash — you must change it on first login.
  2. Go to Pools → Add Pool, enter a name, coin, and the pool address (e.g. stratum.f2pool.com:3333), then save.
  3. Go to Port Mappings → Add Mapping, pick a local port (e.g. 13333) and select the pool you just created, then save. The mapping is pushed to the client over ConfigSync.

The mapping goes live instantly. Point your miners at CLIENT_IP:13333 — done!

Verify

Open the Dashboard (or Status) page in the admin panel. You should see your client online with an active heartbeat and the pool mapping live.