Guide: Metronome in Digital OceanThis guide will walk you through the steps to install Metronome in Digital Ocean, but the same steps can be used for any other cloud provider that you can ssh into.
Before you start
You need to create a Digital Ocean account first, if you haven't already, you can use this affiliate link to get a $200 in credit for 60 days.
Reverse proxy server
Metronome comes with Caddy configured as a reverse proxy with SSL termination to expose Metronome to the internet.You need a domain name to use with Metronome. You can use your existing domain and add an
to point to your Digital Ocean Droplet IP address.
1. Create a Digital Ocean DropletCreate an Ubuntu droplet. You can use the cheapest option, but make sure it has at least 2GB of RAM and 2 CPUs. At the end, it will depends on your ingestion rate.
2. Install Docker ComposeSSH into your droplet and install Docker Compose.
$apt install -y docker-compose
3. Assign a Reserved IP to your DropletAssign a reserved IP to your droplet. This will ensure that your droplet will always have the same IP address.
4. Configure your domain nameAdd an
record to your domain name to point to your droplet IP address. Such as
5. Clone the Metronome repositorySSH into your droplet and clone the Metronome repository.
$git clone https://github.com/metronome-sh/docker.git
6. Run the setup scriptTo create the necessary configuration files and start Metronome, run the setup script.
Metronome uses MaxMind GeoLite2 database to geolocate IP addresses. You need to create a free account on MaxMind and get a license key to use with Metronome.If you don't provide a license key, Metronome will still work, but it will not geolocate IP addresses.
This will create a
$./setup.sh --maxmind-license MAXMIND_LICENSE --url DOMAIN_NAME
file with the necessary configuration to start Metronome.
7. Start Metronome
After the migrations are set up and the server is running, you can access Metronome at
$docker-compose up -d; docker-compose logs --tail="all" -f
.You will be able to create the admin user when you access Metronome for the first time.
Updating Metronome self hostedTo update Metronome, you need to pull the updated docker images and restart the containers.
$docker pull metronomedotsh/metronome:latest
$docker-compose down && docker-compose up -d