Deployment Modes
Monolythium supports two primary deployment modes for running validator and RPC nodes. This guide helps you choose the right approach for your use case.
Overview
| Mode | Best For | Complexity | Production Ready |
|---|---|---|---|
| Host-Native | Production validators, bare-metal deployments | Medium | Yes |
| Docker | Development, testing, quick prototypes | Low | Yes |
Both modes are fully supported and maintained. Your choice depends on operational preferences, infrastructure requirements, and team expertise.
Comparison Table
| Aspect | Host-Native | Docker |
|---|---|---|
| Process Manager | systemd | docker-compose |
| Binary Location | /usr/local/bin/monod | Inside container |
| Data Directory | ~/.monod/ (host) | Volume-mounted from host |
| Key Storage | Host filesystem | Container filesystem (volume-backed) |
| Upgrades | Cosmovisor or manual | Replace container image |
| Resource Control | systemd limits | Docker limits (--memory, --cpus) |
| Network Ports | Direct host binding | Docker port mapping |
| Logging | journalctl | docker logs + journalctl |
| Backup/Restore | Direct filesystem access | Volume backup |
| Tooling | monoctl (Mono Commander) | monoctl docker commands |
| Multi-Node | Multiple systemd units | docker-compose scale |
| Prerequisites | Go 1.24+ (if building) | Docker, docker-compose |
Decision Tree
Choose Host-Native If:
- You are running a production validator with strict uptime requirements
- Your infrastructure uses bare-metal servers or VMs without Docker
- You prefer systemd for process management and logging
- You need direct control over binary versions and dependencies
- Your team has experience with Linux system administration
- You want to use Cosmovisor for automatic upgrades
Choose Docker If:
- You are developing or testing Monolythium integrations
- You want a quick setup without installing system dependencies
- Your infrastructure is container-based (Kubernetes, ECS, etc.)
- You prefer declarative configuration via docker-compose
- You need to run multiple isolated nodes on the same host
- Your team has Docker expertise
- You are running on macOS (systemd not available)
Mode-Specific Guides
Host-Native Deployment
Full guide: Linux Host-Native Installation
Quick summary:
- Install Go 1.24+ or download pre-built binary
- Create dedicated
monoduser (recommended) - Initialize node with
monod init - Configure systemd service
- Join network using
monoctl join - Start service with
systemctl start monod
Key commands:
# Using Mono Commander
monoctl monod install
monoctl join --network Sprintnet
monoctl systemd install --user monod
# Manual systemd
sudo systemctl daemon-reload
sudo systemctl enable monod
sudo systemctl start monod
Docker Deployment
Full guide: Docker Node Deployment
Quick summary:
- Install Docker and docker-compose
- Initialize Docker setup with
monoctl docker init - Configure environment variables and ports
- Start node with
monoctl docker up - Monitor logs with
monoctl docker logs
Key commands:
# Using Mono Commander (Recommended)
monoctl docker init --network Sprintnet
monoctl docker up
monoctl docker status
monoctl docker logs --follow
monoctl docker restart
monoctl docker upgrade --version latest
# Direct docker-compose
docker-compose up -d
docker-compose logs -f monod
macOS users must use Docker mode as systemd is not available on macOS. Use the monoctl docker commands for all node operations.
Hybrid Approach
Some operators run different modes for different purposes:
- Validator: Host-native for maximum control and performance
- RPC/Archive Node: Docker for easier scaling and management
- Development: Docker for rapid iteration and testing
This is a valid strategy that leverages the strengths of each approach.
Migration Between Modes
Host-Native to Docker
- Stop the host-native service:
sudo systemctl stop monod - Back up
~/.monod/directory - Initialize Docker setup:
monoctl docker init --network <NETWORK> - Copy data directory to Docker volume:
cp -r ~/.monod/ /var/lib/docker/volumes/monod-data/ - Start Docker node:
monoctl docker up -d
Docker to Host-Native
- Stop Docker containers:
monoctl docker down - Copy data from volume:
docker cp monod:/root/.monod ~/.monod - Install
monodbinary: Installation Guide - Configure systemd service:
monoctl systemd install - Start service:
sudo systemctl start monod
Performance Considerations
Host-Native
- Pros: Lower overhead, direct system access, fine-grained resource control
- Cons: Requires more manual configuration, dependency management
Docker
- Pros: Isolated environment, consistent across platforms, easy rollback
- Cons: Small performance overhead (~1-3%), additional abstraction layer
For production validators, host-native is recommended to minimize any potential performance impact. For RPC nodes and development, Docker's convenience often outweighs the minimal overhead.
Security Considerations
Host-Native
- Keys stored in
~/.monod/keyring-backend-* - Access controlled via filesystem permissions
- Requires careful user/group management
- Direct exposure to host system
Docker
- Keys stored in container filesystem (volume-backed)
- Container isolation provides additional security boundary
- Easier to implement network segmentation
- Requires proper volume permission management
Both modes support hardware security modules (HSM) for validator signing keys when configured appropriately.
Next Steps
Choose your deployment mode and follow the corresponding guide:
- Host-Native: Linux Host-Native Installation
- Docker: Docker Node Deployment
- Tooling: Mono Commander - Works with both modes
After deployment: