# Load Balanced RPC with alerts

This examples creates a single droplet in Digitalocean that:

  • runs the latest osmosisd binary
  • authomatically syncs the state from a pruned snapshot

# Usage

# Create DigitalOcean API Token

  1. Get an API token from here (opens new window)

  2. Export the token to an environment variable. Do not share this token as it gives access to your console.

export DIGITALOCEAN_TOKEN="your_personal_access_token"
1

# Create infrastructure

  1. Initialize terraform:
make init
1
  1. Create a plan:
make plan
1
  1. Inspect the plan and then deploy the infrastructure:
make apply
1
  1. Get ssh instructions:
terraform output --raw  ssh_help 
1

Expected output:

Get ssh key:
terraform output --raw private_key > droplet.key && chmod 600 droplet.key

Connect to the instancs:

ssh root@<IP> -i droplet.key
1
2
3
4
5
6
  1. Follow the instructions to ssh into the droplet:
terraform output --raw private_key > droplet.key && chmod 600 droplet.key

ssh root@<IP> -i droplet.key # <IP> will be the actual ip of the droplet
1
2
3

The nodes are configured to accept traffic to port 22 from anywhere which is not generally recommended for production setup.

Please setup firewall rules according to your needs.

  1. Wait for the node to be initialized. The droplets is initialized via the osmosis-installer (opens new window) which installs the necessary packages and statesync the node. You can follow the process with:
tail -f /var/log/cloud-init-output.log
1
  1. Play around with your osmosis node!

# Get started in Digitalocean

Get $100 in credit over 60 days through our referral link:

DigitalOcean Referral Badge (opens new window)