Skip to content
lime-redPublic

About

No description, website, or topics provided.

Resources

Stars

1 star

Watchers

1 watching

Forks

Latest commit

ย 

History

398 Commits

Folders and files

NameName
Last commit message
Last commit date
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

Nova Hub

Modern routing hub and spoke router for Solar Realms games: Barren Realms Elite (BRE) and Falcons Eye (FE)

Features

  • ๐ŸŒ Hub-and-Spoke Routing: Centralized packet routing for multiple BBS nodes
  • ๐Ÿ” OAuth Authentication: Secure client credentials flow for API access
  • ๐Ÿ“Š Web Dashboard: Real-time monitoring and statistics
  • ๐Ÿ”„ Real-time Updates: WebSocket support for live notifications
  • โš ๏ธ Sequence Validation: Automatic detection of missing packets
  • ๐ŸŽฎ Multi-Game Support: Handles both BRE and FE leagues
  • ๐Ÿ“ฆ Dosemu Integration: Processes packets via Dosemu

Quick Start

For detailed instructions, see docs/QUICKSTART.md

Hub Server

# Install dependencies (exactly the versions in uv.lock)
uv sync

# Create data directory
mkdir -p ./data

# Initialize database
.venv/bin/alembic upgrade head

# Create admin user
.venv/bin/python create_admin_sql.py

# Start server
.venv/bin/uvicorn main:app --reload

Access the web interface at: http://localhost:8000

Log in as admin with the password create_admin_sql.py printed. There is no default password.

Sysops sign in through an identity provider once [identity] is set in config.toml; see Sysop accounts.

Client Setup

See the nova-client directory for the full client with daemon support.

cd ../nova-client

# Install dependencies
pip install -r requirements.txt

# Configure client
cp config.toml.example config.toml
# Edit with your client credentials from hub admin

# Test run
python client.py

# Or run as daemon for continuous operation
python daemon.py

Architecture

โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚   Clients   โ”‚ (Multiple BBSs)
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”˜
       โ”‚ HTTPS/OAuth
       โ†“
โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚      Nova Hub Server        โ”‚
โ”‚  โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”    โ”‚
โ”‚  โ”‚  Web UI (Dashboard) โ”‚    โ”‚
โ”‚  โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜    โ”‚
โ”‚  โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”    โ”‚
โ”‚  โ”‚  Packet API         โ”‚    โ”‚
โ”‚  โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜    โ”‚
โ”‚  โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”    โ”‚
โ”‚  โ”‚  Dosemu Processing  โ”‚    โ”‚
โ”‚  โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜    โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
       โ”‚
       โ†“
   SQLite DB

Documentation

Packet Format

Packets follow the naming convention: <league><game><source><dest>.<seq>

Example: 555B0201.001

  • League: 555 (BRE League 555)
  • Game: B (BRE) or F (FE)
  • Source BBS: 02 (hex)
  • Destination BBS: 01 (hex)
  • Sequence: 001 (000-999, wraps)

Testing

# Hub tests. They build their own config from config.toml.example, so no
# config.toml is needed; the live rig tree skips itself off novatest-hl.
.venv/bin/pytest tests/

The clients are tested in nova-client against its mock hub, python/tests/mock_server.py, which both the Python and PowerShell suites use. A change to the Service API belongs in that mock too.

Configuration

Hub Server (config.toml)

[server]
host = "0.0.0.0"
port = 8000

[hub]
bbs_name = "My Hub"
bbs_index = "01"

[database]
path = "./data/nova-hub.db"

[dosemu]
dosemu_path = "/usr/bin/dosemu"
# ... see config.toml.example for full options

Client (nova-client/config.toml)

[hub]
url = "https://hub.example.com"
client_id = "your_client_id"
client_secret = "your_secret"

[bbs]
name = "My BBS"

[leagues.BRE.555]
enabled = true
bbs_index = 2                           # Your BBS ID for this league (1-255)
outbound_dir = "/path/to/bre/outbound"
inbound_dir = "/path/to/bre/inbound"

Database Migrations

# Create new migration after model changes
alembic revision --autogenerate -m "Description"

# Apply migrations
alembic upgrade head

# Rollback
alembic downgrade -1

Deployment

Systemd Service (Hub)

# See deploy/ directory for Ansible playbook and service template
sudo cp deploy/nova-hub.service.j2 /etc/systemd/system/nova-hub.service  # edit paths first
sudo systemctl enable nova-hub
sudo systemctl start nova-hub

Reverse Proxy (Caddy)

hub.example.com {
    reverse_proxy localhost:8000
}

Troubleshooting

Authentication Issues

If you can't create admin user or login fails:

# Use the SQL-based admin creation script
.venv/bin/python create_admin_sql.py

# Or verify user exists
sqlite3 ./data/nova-hub.db "SELECT * FROM sysop_users;"

Dosemu Issues

  1. Ensure Dosemu 2.x is installed
  2. Check file permissions on dosemu directories
  3. Verify game executables are in correct paths
  4. Check logs in data/logs/dosemu/

Client Connection Issues

  1. Verify hub URL is correct
  2. Check client credentials
  3. Ensure firewall allows outbound HTTPS
  4. Check client logs for errors

Sequence Gaps

Sequence gaps can occur due to:

  • Network issues during upload
  • Client crashes mid-transfer
  • Hub processing errors

Check the Alerts page in the web UI for details.

License

MIT -- see LICENSE.

Credits

Created for the BBS community to facilitate Inter-BBS leagues for:

  • Barren Realms Elite (BRE) by Mehul Patel
  • Falcons Eye (FE) by Mehul Patel

Support

For issues or questions, please open an issue on GitHub.

About

No description, website, or topics provided.

Resources

Stars

1 star

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages