Skip to content

Hosting

AstorisTheBrave edited this page Jun 21, 2026 · 2 revisions

Hosting on bot panels (Pterodactyl, PebbleHost, Ori, Railway)

Docker bot panels run your bot in a container with limited inbound ports and varied config injection. Argus works on all of them; the right setup depends on what your host allows. Ready-made files live in examples/hosting/.

The two things that vary

  1. Inbound ports. Pterodactyl/PebbleHost give one primary allocation as SERVER_PORT (more only if the admin raises the limit); Railway gives a dynamic PORT plus a domain you generate; some panels expose nothing useful.
  2. Config injection. Some have an env-var UI; some only let you upload files or set a start command; the strictest only run one fixed entrypoint.

Argus is built for this: it resolves the port as ARGUS_PORT -> SERVER_PORT -> PORT -> 9191 and the host as ARGUS_HOST -> SERVER_IP -> 0.0.0.0, and Argus(bot) loads a .env at startup when the argus-dpy[dotenv] extra is installed.

Decision tree

  • Can't / won't expose a port? Push out. Recommended on locked hosts.
  • Have a reachable allocation and your own Prometheus? Bind it and scrape.
  • No env-var UI? Upload a .env, or use the start shim if even the start command is fixed.

Push (recommended) — no inbound port

A Discord bot is outbound-only, and so are these two paths:

# OTLP to a collector / Grafana Cloud  (pip install "argus-dpy[otlp]")
ARGUS_OTLP_ENDPOINT=https://otlp.collector:4317 python bot.py

# or report to an Argus Fleet control plane on a VPS (one pane, many bots)
ARGUS_FLEET_URL=http://fleet-host:9190 ARGUS_FLEET_TOKEN=secret python bot.py

# or push to a Prometheus Pushgateway (pure-Prometheus stack, no scrape)
ARGUS_PUSHGATEWAY_URL=http://pushgateway:9091 python bot.py

All work through NAT and need no allocation. The Pushgateway push is additive (/metrics is still served), pushes every ARGUS_PUSHGATEWAY_INTERVAL seconds (default 15) grouped by cluster, and takes optional basic auth (ARGUS_PUSHGATEWAY_USERNAME/ARGUS_PUSHGATEWAY_PASSWORD). See OTLP and Fleet.

Scrape — bind the host's allocation

On Pterodactyl/PebbleHost, Argus binds SERVER_PORT automatically, so you set nothing. Point Prometheus at node-ip:allocated-port. Set ARGUS_DASHBOARD_AUTH_TOKEN whenever the port is publicly reachable - an open dashboard on a shared node is an abuse surface (see Security).

Per-host

Pterodactyl / PebbleHost

Import pterodactyl-egg.json (Panel -> Nests -> Import Egg). It exposes the ARGUS_* variables and installs argus-dpy[dotenv,otlp]. No env-var UI? Upload a .env over FTP. PebbleHost's "Open Additional Ports" gives you more allocations if you need a separate metrics port.

Ori-class (start file only)

Upload a .env and run start_shim.py as the entrypoint with BOT_FILE=your_bot.py - it loads the .env and execs your bot. (Often unnecessary now that Argus auto-loads .env and auto-detects the port; reach for it only when the start command is not editable.)

Railway

Bots need no port. Set secrets in the Variables tab (sealed for production); a .env is not needed. To scrape, bind PORT (auto-detected) and Generate Domain. See railway.json.

Security

Prefer push (no port at all). If you must bind a public allocation, set ARGUS_DASHBOARD_AUTH_TOKEN and treat the URL as a credential. Argus strips its version banner, sends security headers, caps the request body, and bounds the SSE stream regardless.

Clone this wiki locally