Running Your Own Mostro Node

Mostro v0.16.3 โ€” Community Guide ยท February 2026

1. What is Mostro and Why Should Your Community Run One?

Mostro is a peer-to-peer Bitcoin exchange that lets people buy and sell Bitcoin using local currencies (dollars, euros, pesos โ€” any currency) without needing to provide identity documents (KYC). Think of it as a decentralized marketplace where buyers and sellers can trade directly.

It works using two technologies:

Mostro acts as an escrow coordinator โ€” it holds the seller's Bitcoin in a temporary "lock box" (called a hold invoice) until the buyer confirms they've sent the local currency payment. Mostro never actually controls anyone's funds; it just holds them briefly during the trade.

Why Would Your Community Want to Run a Mostro Node?

How Mostro Works (Simplified)

  1. Alice wants to SELL Bitcoin for $50 USD โ†’ She creates an order on Mostro
  2. Bob wants to BUY Bitcoin with $50 USD โ†’ He sees Alice's order and takes it
  3. Mostro creates a "lock box" (hold invoice) โ†’ Alice sends her Bitcoin into the lock box
  4. Bob sends $50 to Alice via bank transfer, Zelle, cash, etc. โ†’ Bob clicks "Fiat Sent"
  5. Alice confirms she received the $50 โ†’ She clicks "Release"
  6. Mostro releases the Bitcoin from the lock box to Bob โ†’ Trade complete! โœ“

If something goes wrong, either party can open a dispute, and your community's assigned arbiters investigate and resolve it.

2. Prerequisites โ€” What You Need Before Starting

2.1 A Server (VPS)

A VPS (Virtual Private Server) is a computer in a data center that runs 24/7. You'll rent one to host your Mostro node.

ResourceMinimumRecommended
CPU2 vCPUs (shared)2+ vCPUs
RAM2 GB4 GB
Storage60 GB SSD100 GB SSD
Bandwidth3 TB/month3+ TB/month
OSUbuntu 22.04+ LTSUbuntu 24.04 LTS

Estimated monthly cost: $10โ€“$24/month.

Popular VPS providers:

๐Ÿ’ก Tip

Many VPS providers accept Bitcoin payments. Look for that option if you want to keep things consistent with the Bitcoin ethos.

2.2 A Lightning Network Node (LND)

To run Mostro, you need an LND node (Lightning Network Daemon) โ€” the specific Lightning software that Mostro works with.

OptionDifficultyCostNotes
Use an existing LND nodeEasyFreeBest if someone already runs one
Run LND on the same VPSHardSame VPS + liquidityRequires 4GB+ RAM
Node-in-a-boxMedium$200-600 + liquidityStart9, Umbrel, RaspiBlitz
StartOS with Mostro packageEasiest$300-600 + liquidityOne-click Mostro package
Voltage.cloudEasyFrom ~$20/monthHosted LND
โš ๏ธ Important

Mostro specifically requires LND (not CLN/Core Lightning, not Eclair, not LDK). Make sure your Lightning node runs LND.

What you need from your LND node:

2.3 Lightning Liquidity

To facilitate trades, your Lightning node needs channels with Bitcoin in them.

Trading VolumeSuggested LiquidityApprox. BTC
Small community1โ€“5 million sats0.01โ€“0.05 BTC
Medium community5โ€“20 million sats0.05โ€“0.20 BTC
Active community20โ€“100 million sats0.20โ€“1.0 BTC
๐Ÿ’ก Start Small

Start small, grow incrementally. Begin with enough for your community's initial needs. When traders report orders failing, that's your signal to add more.

2.4 Nostr Keys

Your Mostro node needs its own identity on the Nostr network.

โš ๏ธ Important

Never reuse Nostr keys between Mostro instances. Each node needs its own unique identity.

Generating secure Nostr keys locally with rana:

# Install Rust (if not already installed)
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
source ~/.cargo/env

# Install rana - local Nostr key generator
cargo install rana

# Generate a new key pair
rana

3. Step-by-Step Setup

All installation options share the same first steps. Then choose your preferred option:

Common Steps (for all 3 options)

Step 1: Connect to your VPS

ssh root@YOUR_VPS_IP_ADDRESS

Step 2: Update the system

# Download the latest package information
apt update

# Install all available updates
apt upgrade -y

Step 3: Install Docker and Docker Compose

๐Ÿ’ก Note

Docker is required for options A and B. If you are compiling manually (Option C), you can skip this step.

# Install Docker using the official convenience script
curl -fsSL https://get.docker.com | sh

# Verify Docker is installed
docker --version

# Verify Docker Compose
docker compose version

Step 4: Install additional tools

apt install -y git make

โœ… Common steps completed. Now choose your installation option:

Option A: Docker Hub (Fastest โ€” Recommended)

Run Mostro directly from Docker Hub without cloning the repository or compiling.

Step 5: Create configuration directory

mkdir -p ~/mostro-config/lnd

Step 6: Get the configuration template

curl -sL https://raw.githubusercontent.com/MostroP2P/mostro/v0.16.3/settings.tpl.toml \
  -o ~/mostro-config/settings.toml

Step 7: Copy LND credentials

cp /path/to/your/tls.cert ~/mostro-config/lnd/tls.cert
cp /path/to/your/admin.macaroon ~/mostro-config/lnd/admin.macaroon

Step 8: Edit the configuration

nano ~/mostro-config/settings.toml

Required changes:

[lightning]
lnd_cert_file = '/config/lnd/tls.cert'
lnd_macaroon_file = '/config/lnd/admin.macaroon'
lnd_grpc_host = 'https://host.docker.internal:10009'

[database]
url = "sqlite:///config/mostro.db"

[nostr]
nsec_privkey = 'YOUR_NSEC_KEY_HERE'
relays = ['wss://relay.mostro.network', 'wss://nos.lol']

[mostro]
fee = 0.006
max_order_amount = 1000000
min_payment_amount = 100
fiat_currencies_accepted = ['USD', 'EUR']

Step 9: Fix permissions

โš ๏ธ Important

Avoid chmod 777. Use least privilege.

sudo chown -R 1000:1000 ~/mostro-config
chmod 700 ~/mostro-config
chmod 600 ~/mostro-config/settings.toml
chmod 600 ~/mostro-config/lnd/admin.macaroon

Step 10: Run the container

If LND is on the same VPS:

docker run -d --name mostro \
  --restart unless-stopped \
  --add-host=host.docker.internal:host-gateway \
  -v ~/mostro-config:/config \
  mostrop2p/mostro:v0.16.3

If LND is on a different server:

docker run -d --name mostro \
  --restart unless-stopped \
  -v ~/mostro-config:/config \
  mostrop2p/mostro:v0.16.3

Step 11: Check the logs

docker logs -f mostro

Look for these messages:

๐Ÿ’ก Troubleshooting

If you see Permission denied (os error 13), re-apply permissions: chown -R 1000:1000 ~/mostro-config and restart: docker restart mostro.

๐ŸŽ‰ Congratulations! If you see successful connections in the logs, your Mostro node is running!

Updating (Docker Hub)

export MOSTRO_TAG=v0.16.3
docker pull mostrop2p/mostro:$MOSTRO_TAG
docker stop mostro
docker rm mostro
docker run -d --name mostro \
  --restart unless-stopped \
  --add-host=host.docker.internal:host-gateway \
  -v ~/mostro-config:/config \
  mostrop2p/mostro:$MOSTRO_TAG
๐Ÿ”’ Security Note

Prefer explicit version tags (e.g., mostrop2p/mostro:v0.16.3) over :latest for controlled updates.

Option B: Docker Build (Build image locally)

Step 5: Download Mostro

cd /opt
git clone https://github.com/MostroP2P/mostro.git
cd mostro

Step 6: Set up configuration files

cd docker
mkdir -p config
cp ../settings.tpl.toml config/settings.toml

Step 7: Edit the configuration file

nano config/settings.toml

Edit the same settings as Option A, Step 8.

Step 8: Build the Docker image

cd ..
LND_CERT_FILE=/root/.lnd/tls.cert \
LND_MACAROON_FILE=/root/.lnd/data/chain/bitcoin/mainnet/admin.macaroon \
make docker-build

Step 9: Set Database Password (Optional)

# Create docker/.env file
echo "MOSTRO_DB_PASSWORD='YourStrongPassword'" > docker/.env

Step 10: Start Mostro

make docker-up

# Check if running
docker compose -f compose.yml ps

# View logs
docker compose -f compose.yml logs -f mostro

๐ŸŽ‰ Congratulations! If you see successful connections, your Mostro node is running!

Option C: Native Build (For Technical Operators)

Step 5: Install Rust

curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
source /root/.cargo/env
rustc --version
cargo --version
โš ๏ธ Important

Do NOT install Rust via apt install rustc. Always use rustup. The system package is often outdated.

Step 6: Install build dependencies

apt install -y cmake build-essential libsqlite3-dev libssl-dev \
  pkg-config git sqlite3 protobuf-compiler

Step 7: Download and compile Mostro

cd /opt
git clone https://github.com/MostroP2P/mostro.git
cd mostro
cargo build --release
๐Ÿ’ก Tip

If compilation fails due to low RAM, add swap space:

fallocate -l 2G /swapfile
chmod 600 /swapfile
mkswap /swapfile
swapon /swapfile

Step 8โ€“10: Install, initialize, and clean

install target/release/mostrod /usr/local/bin
cargo install sqlx-cli --version 0.6.2
./init_db.sh
cargo clean  # Saves 2+ GB

Step 11โ€“12: Create user and configure

adduser --disabled-login mostro
mkdir -p /opt/mostro
cp settings.tpl.toml /opt/mostro/settings.toml
nano /opt/mostro/settings.toml

Edit the same settings as Option A, Step 8.

Step 13โ€“15: Test, permissions, and systemd service

# Test run
/usr/local/bin/mostrod -d /opt/mostro

# Set permissions
chown -R mostro:mostro /opt/mostro

Create the systemd service:

# /etc/systemd/system/mostro.service
[Unit]
Description=Mostro daemon
After=network.target

[Service]
Type=simple
User=mostro
WorkingDirectory=/home/mostro
Environment=RUST_LOG=info
ExecStart=/usr/local/bin/mostrod -d /opt/mostro
Restart=on-failure

[Install]
WantedBy=multi-user.target
systemctl daemon-reload
systemctl enable mostro.service
systemctl start mostro.service
systemctl status mostro.service

๐ŸŽ‰ Congratulations! Your Mostro node is running as a system service!

4. Configuration In Depth

4.1 Fees โ€” How You Earn Revenue

[mostro]
fee = 0.006
dev_fee_percentage = 0.30

Trading fee (fee): Percentage charged per trade, split between buyer and seller.

Development fee (dev_fee_percentage): A percentage of your fee earnings that goes to Mostro development.

4.2 Order Limits and Currencies

[mostro]
max_order_amount = 1000000
min_payment_amount = 100
fiat_currencies_accepted = ['USD', 'EUR', 'ARS', 'CUP']

4.3 Node Profile (Optional but Recommended)

[mostro]
name = "LatAm Mostro"
about = "P2P Bitcoin exchange for Latin America. Spanish support."
picture = "https://example.com/your-logo.png"
website = "https://your-community-site.com"

4.4 Timing and Expiration

[mostro]
expiration_hours = 24        # How long an order stays open
expiration_seconds = 900     # Time for taker to complete (15 min)
hold_invoice_expiration_window = 300  # Hold invoice validity (5 min)

4.5 Anti-Spam

[mostro]
pow = 0  # 0 = disabled; 10-20 = moderate. Start with 0.

5. Operating Your Mostro Node

5.1 How Disputes Work

Disputes are your most important operational responsibility.

When do disputes happen?

The dispute process:

  1. User opens a dispute โ€” Either party clicks "Dispute" in their client
  2. Mostro flags the order โ€” Status changes to "Dispute", funds remain locked
  3. Arbiter takes the case โ€” An admin assigned to your node investigates
  4. Investigation โ€” Communicates with both parties, requests evidence
  5. Resolution โ€” Arbiter decides: settle to buyer, or refund to seller
โš ๏ธ Important

Choose arbiters carefully. They have power to decide where locked funds go. Pick trusted, impartial community members. Having 2โ€“3 arbiters is recommended.

5.2 Mostrix โ€” Your Admin Tool

Mostrix is a terminal-based (TUI) client for dispute resolution. If you run a Mostro node, you need Mostrix.

# Install dependencies
sudo apt install -y cmake build-essential pkg-config

# Clone and build
git clone https://github.com/MostroP2P/mostrix.git
cd mostrix
cargo build --release
cargo run

Configure Mostrix for admin mode in ~/.mostrix/settings.toml:

mostro_pubkey = "YOUR_MOSTRO_PUBKEY_HEX"
nsec_privkey = "nsec1your_personal_key"
admin_privkey = "nsec1your_admin_key"
relays = ["wss://relay.mostro.network", "wss://nos.lol"]
currencies = ["USD", "EUR", "ARS"]
user_mode = "admin"

5.3 mostro-watchdog โ€” Dispute Notifications

mostro-watchdog monitors your Mostro node for disputes and sends instant alerts to Telegram. Essential for fast response times.

git clone https://github.com/MostroP2P/mostro-watchdog.git
cd mostro-watchdog
cargo build --release
cp config.example.toml config.toml
nano config.toml
[mostro]
pubkey = "YOUR_MOSTRO_PUBKEY"

[nostr]
relays = ["wss://relay.mostro.network", "wss://nos.lol"]

[telegram]
bot_token = "YOUR_BOT_TOKEN"
chat_id = "YOUR_CHAT_ID"
๐Ÿ’ก Tip

Run mostro-watchdog as a systemd service alongside your Mostro node for 24/7 monitoring.

./target/release/mostro-watchdog

๐ŸŽ‰ You're all set! Welcome to the Mostro network.