# Vexon Stratum

Vexon Stratum is the mining server component used by Vexon Pool. It builds a
single Stratum binary for Blake256r14-compatible ASIC mining through the Vexon
Core getwork path.

This repository intentionally excludes:

- compiled binaries and object files
- live pool configs
- logs
- wallet, RPC, SQL, certificate, and server secrets
- blockchain data

## Build

```bash
make clean
make
```

The build produces:

```text
./stratum
```

## Install On A Vexon Pool Server

Clone and install:

```bash
cd /root
git clone https://github.com/vexonexchange-sudo/vexon-stratum.git
cd /root/vexon-stratum
sudo bash install-vexon-stratum.sh
```

The installer:

- builds `./stratum`
- backs up existing `/opt/vexon-pool/stratum/VexonStratum` binaries
- installs the binary as `/opt/vexon-pool/stratum/VexonStratum`
- installs the same binary as `/opt/vexon-pool/stratum-config/VexonStratum`
- restarts the `Vexon_Stratum` screen session with `/opt/vexon-pool/stratum-config/vexon.conf`

Optional environment variables:

```bash
STRATUM_CONFIG_NAME=vexon \
STRATUM_DIR=/opt/vexon-pool/stratum \
STRATUM_CONFIG_DIR=/opt/vexon-pool/stratum-config \
SCREEN_NAME=Vexon_Stratum \
sudo -E bash install-vexon-stratum.sh
```

## Runtime Config

The live config should be generated by `vexon-pool-deploy` and kept outside this
repository because it contains deployment credentials.

Stable Vexon ASIC options:

```ini
[STRATUM]
algo = decred
difficulty = 256
max_ttf = 1000000000
decred_relaxed_extranonce = 1
decred_block_submit_diff = 503382015

[WALLETS]
include = VEX
```

The compatibility fields in the runtime config are protocol selectors only. They
are not public project names or coin identities.
