tutorial

TubeArchivist Monitoring with Vigilmon: Health, Queue & Elasticsearch Alerts

Monitor your self-hosted TubeArchivist instance with Vigilmon — track the /api/ping health endpoint, web UI availability, Celery task queue, Redis, and Elasticsearch cluster status.

Your TubeArchivist server is quietly processing a backlog of YouTube downloads when Elasticsearch runs out of heap and the whole service silently dies. No alerts fire. Hours later you realize nothing has downloaded and the web UI is returning 502. For self-hosted archivers, silent failures are the norm — until you add external monitoring.

TubeArchivist is a self-hosted YouTube archiver that indexes your video library through Elasticsearch and processes downloads via Celery workers backed by Redis. Vigilmon provides external monitoring that catches failures in each of these layers — the HTTP API, the web interface, and the background services — before you notice a gap in your archive.

This tutorial walks you through monitoring TubeArchivist end-to-end with Vigilmon.

What You'll Build

  • A Vigilmon HTTP monitor on TubeArchivist's /api/ping health endpoint
  • A web UI availability monitor with keyword verification
  • A Celery task queue health check via the API
  • Redis and Elasticsearch status monitoring
  • SSL certificate expiry alerts

Prerequisites

  • A running TubeArchivist instance (typically on port 8000 behind a reverse proxy)
  • A free account at vigilmon.online

Step 1: Monitor the /api/ping Endpoint

TubeArchivist exposes a dedicated health endpoint at /api/ping. It returns {"ping": "pong"} when the Django backend is operational and authenticated API requests are being served.

Test it from your terminal:

curl https://tubearchivist.yourdomain.com/api/ping \
  -H "Authorization: Token YOUR_API_TOKEN"

Expected response:

{"ping": "pong"}

To obtain your API token: open TubeArchivist → Settings → User → API Token. The token is static and doesn't expire.

Set up the Vigilmon monitor:

  1. Log in to Vigilmon and click New Monitor → HTTP.
  2. Set URL to https://tubearchivist.yourdomain.com/api/ping.
  3. Set Check interval to 60 seconds.
  4. Under Advanced → Request Headers, add:
    • Authorization: Token YOUR_API_TOKEN
  5. Set Expected status code to 200.
  6. Under Advanced → Keyword check, add:
    • Keyword present: pong
  7. Save the monitor.

Vigilmon now polls the TubeArchivist API from multiple geographic regions every minute.


Step 2: Monitor Web UI Availability

The /api/ping endpoint confirms the Django backend is alive, but doesn't verify the web interface is rendering. A failed npm build, a broken static file serve, or a misconfigured Nginx location block can leave the API healthy while the UI is unreachable.

Add a keyword monitor on the web UI:

  1. Click New Monitor → HTTP in Vigilmon.
  2. Set URL to https://tubearchivist.yourdomain.com/ (your TubeArchivist homepage).
  3. Set Expected status code to 200.
  4. Under Advanced → Keyword check, configure:
    • Keyword present: TubeArchivist
  5. Save.

The TubeArchivist login page and dashboard include the application name in the HTML response. If the Vue.js frontend fails to load or the static files are missing, this check fails independently of the API monitor.


Step 3: Monitor Celery Task Queue Health

TubeArchivist relies on Celery workers to process all download and indexing tasks. A stalled Celery queue means no new downloads complete and no metadata gets indexed — but the web UI may still appear operational.

TubeArchivist exposes task status through its API. Monitor the download queue endpoint:

  1. Click New Monitor → HTTP in Vigilmon.
  2. Set URL to:
    https://tubearchivist.yourdomain.com/api/task/
    
  3. Under Advanced → Request Headers, add:
    • Authorization: Token YOUR_API_TOKEN
  4. Set Expected status code to 200.
  5. Under Advanced → Keyword check:
    • Keyword present: task_id
  6. Save.

This confirms the Celery task management API is responding. A Celery worker crash or Redis connection failure causes this endpoint to degrade or return errors before your downloads stop silently.


Step 4: Monitor Elasticsearch Cluster Status

Elasticsearch is TubeArchivist's search and index backend. If Elasticsearch goes red (data loss, out of heap, cluster partition), TubeArchivist cannot serve search results or index new downloads, even if the web UI loads.

Monitor Elasticsearch health directly:

  1. Click New Monitor → HTTP in Vigilmon.
  2. Set URL to:
    http://your-elasticsearch-host:9200/_cluster/health
    
  3. Set Expected status code to 200.
  4. Under Advanced → Keyword check:
    • Keyword present: green
    • Keyword absent: red
  5. Save.

When the cluster transitions from green to yellow (replica shards missing) or red (primary shards missing), the keyword check fires. A yellow cluster usually means a single-node deployment losing a replica — non-critical but worth knowing. Red means data unavailability.

If Elasticsearch is on an internal network not exposed externally, add a monitor on TubeArchivist's /api/stats/ endpoint instead, which reflects index health indirectly.


Step 5: SSL Certificate Monitoring

TubeArchivist is typically served over HTTPS via Nginx or Caddy. An expired certificate breaks access from every client — browsers, the mobile app, and Plex-style integrations alike.

Vigilmon automatically monitors SSL certificate validity on all HTTPS monitors. Configure dedicated expiry alerts:

  1. Open any of your HTTPS TubeArchivist monitors in Vigilmon.
  2. Go to Settings → SSL.
  3. Enable Alert when certificate expires within 14 days.
  4. Optionally enable Alert when certificate expires within 30 days for early warning.

You'll receive alerts like:

⚠️  SSL Warning: tubearchivist.yourdomain.com
Certificate expires in 9 days (2026-07-14)

For Let's Encrypt via Certbot or Caddy: renewal failures are silent until browsers reject connections. Vigilmon catches this before your archive becomes inaccessible.


Step 6: Alert Channels

Go to Notifications → New Channel in Vigilmon and configure your preferred alert delivery:

  • Email — immediate alerts to your inbox
  • Webhook — forward to Discord, Slack, or ntfy.sh for push notifications

A TubeArchivist downtime alert in Discord looks like:

🔴 DOWN: tubearchivist.yourdomain.com/api/ping (HTTP 502)
TubeArchivist API health check failed
Region: US-East
Triggered: 2026-01-15 03:22 UTC

What You've Built

| Scenario | How Vigilmon catches it | |---|---| | Django/Gunicorn process crash | /api/ping returns non-200 or connection refused | | Reverse proxy (Nginx/Caddy) down | HTTPS monitor detects 502 or TLS error | | Web UI frontend broken | Keyword monitor on homepage fails | | Celery workers stalled | Task queue API monitor returns error | | Elasticsearch cluster degraded or red | Cluster health keyword check fires | | SSL certificate expired or expiring | SSL expiry alert triggers at threshold |


Self-hosting TubeArchivist gives you ownership over your video archive — but the system has more moving parts than a typical web app. Vigilmon monitors each layer from outside your network, from multiple regions, with no agents to install.

Start monitoring your TubeArchivist instance today — register free at vigilmon.online.

Monitor your app with Vigilmon

Free plan — 5 monitors, no credit card required. Up and running in 60 seconds.

Start free →