These are the steps I took to install and run a nostr relay on a new server.
First, you'll need the server, this tutorial is using the most basic server Hetzner provides (CX11 - €4.15/mo), you don't need much. If you don't know where to get your server from and decide to go with Hetzner, consider using my affiliate link: https://hetzner.cloud/?ref=4FZql6rUwaeQ
Once you have your server running, log into it via SSH. I'm on a MacOS, so I'll use Terminal as my command line tool. open a new Terminal window and paste the following commands: