Lantern - Configuration (Remote)
Configure Lantern for remote server deployment with Docker or direct binary installation on managed infrastructure.
This page concerns running Lantern on a remote server. For local computer deployment, see Configuration (Local).
Important Security Note
Always restrict access to Lantern's services via firewall rules or other methods. Leaving Lantern exposed to the public Internet is not recommended .
Supported Installation Methods
When installing Lantern on a remote server, there are two options:
Docker
Recommended
Fastest and easiest method. Hosts local web configuration tool at localhost:8080.
Binary
Direct binary saves memory. Transfer config file from local setup.
Docker Install
When installing using Docker, it hosts its own local version of the web configuration tool. You'll need to connect to this instead of the public configurator. Make sure your VPS has port 8080 open to you — check your firewall rules.
We strongly recommend using an IP whitelist to control access. Otherwise, anyone with your VPS IP can reconfigure Lantern and extract your API key.
An alternate method is setting up a proxy using an SSH tunnel, avoiding opening port 8080 entirely. Some useful information on this is available here.
Once you can load the web configuration tool, instructions are the same as for running Lantern locally.
Binary Install
When you execute the Lantern binary the first time, it will wait to receive a valid configuration file.
The web configuration tool will not work in this case, since it's designed for local configuration.
The simplest solution is to run the Lantern binary on your local computer and configure it as desired. The configuration is saved to config.json in the same directory. Copy that file to your server in the same directory as the Lantern binary.
When you run Lantern on the server, it will use that config file and work normally.
You'll need to know how to use the scp command to copy files to your server. If Lantern fails to run, make sure you marked it as executable, e.g. with chmod +x lantern-linux-amd64
Security Reminder
Only allow access to Lantern's services to local applications or whitelisted IPs, for example by defining firewall rules. Exposing Lantern to the public web is not recommended . Note: Lantern needs to receive inbound traffic on port 8080, 8081 and 8090, and send outbound traffic to the Internet on ports 443, 8080 and 8081.
Open the section overview for the broader context, live navigation, and interactive code examples.
Continue in this section
- Lantern - WebSocket Support — Lantern supports Solana WebSocket methods for real-time account and program subscriptions on a local caching stack.
- Lantern - Yellowstone gRPC Support — Lantern supports Yellowstone gRPC for efficient account and owner subscriptions with reduced bandwidth usage.
- Lantern - Runtime Behavior — Learn how Lantern behaves during startup, runtime requests, network failures, and shutdown or restart cycles.
- Lantern - Benchmarking — Learn how to benchmark Lantern performance with the open-source RPC testing suite and compare local-cache throughput.
- Lantern - FAQ — Frequently asked questions about Lantern installation, usage, performance, cost, and troubleshooting.
- Lantern - Known Issues — Known issues and platform-specific considerations when running Lantern on Windows, macOS, and Linux.