deploy guide

Run it yourself

On your own laptop, a spare mini-PC, or a cheap VPS. Most flexible, cheapest, most fiddly. Pick this if you like owning the whole stack. total time: depends on your setup.

Before you start, you'll need:
1

Check your Node version

node --version

You need 22.6 or higher. The bot uses Node's native TypeScript support, which needs this version.

If you're on an older version, grab the latest LTS from nodejs.org, or use nvm if you want to manage multiple versions.

2

Unzip your bundle

unzip justthetips-bot.zip
cd justthetips

Everything's in there — bot source, your config, your thank-yous.

3

Install dependencies

npm install

This takes 30-60 seconds.

4

Get a public HTTPS URL

Wallets refuse plain-HTTP links, so the bot needs HTTPS. Three options:

Option A: Cloudflare Tunnel (free, easy)

Install cloudflared, then:

cloudflared tunnel --url http://localhost:3000

Cloudflare prints a URL like https://random-words-12345.trycloudflare.com. Copy that into config.env as your API_PUBLIC_URL.

Option B: ngrok (free for casual use)

ngrok http 3000

Copy the https URL it gives you.

Option C: your own domain + Caddy

If you own a domain pointing at your VPS, use Caddy as a reverse proxy. Caddy auto-renews your Let's Encrypt certs. A minimal Caddyfile:

yourbot.example.com {
  reverse_proxy localhost:3000
}
reminder Whichever option you pick, update API_PUBLIC_URL in config.env to match.
5

Start the bot

npm start

The bot logs its startup and eventually prints api server listening.

6

Check it works

Open http://localhost:3000/check — or visit your public URL's /check path if the tunnel is up.

🎉 all green? your bot is live.

Keeping it running

If you close your terminal, the bot stops. For a bot you actually use, pick one:

pm2 (easy, cross-platform)

npm install -g pm2
pm2 start npm --name justthetips -- start
pm2 save
pm2 startup  # follow the output to auto-start on reboot

systemd (proper, Linux only)

Create /etc/systemd/system/justthetips.service:

[Unit]
Description=justthetips bot
After=network.target

[Service]
Type=simple
WorkingDirectory=/home/you/justthetips
ExecStart=/usr/bin/npm start
Restart=on-failure
User=you

[Install]
WantedBy=multi-user.target

Then:

sudo systemctl enable --now justthetips
sudo systemctl status justthetips
sudo journalctl -u justthetips -f   # watch logs

Updates later

When a new version drops:

  1. Download the new tarball
  2. Unzip into a fresh folder
  3. Copy your config.env and thankyous.json into it
  4. npm install, then restart however you're running it