tutorial

Monitoring Laminar CI with Vigilmon: Web UI, Job Completion Heartbeats, Process Health & SSL Alerts

How to monitor Laminar CI (lightweight self-hosted CI) with Vigilmon — web UI availability, job completion heartbeats, laminard process health checks, and SSL certificate alerts.

Laminar CI is a lightweight, self-hosted continuous integration system that runs on bare Linux servers without containers or external databases. Its simplicity is its strength — a single laminard daemon manages the job queue, runs scripts from a well-known directory, and serves a real-time status UI. But that simplicity also means there's no built-in uptime monitoring: if laminard crashes or the job queue stalls, you won't know until a developer notices their push hasn't triggered a build. Vigilmon fills that gap with external uptime checks, process heartbeats, job completion signals, and SSL certificate alerts.

What You'll Build

  • An HTTP monitor for the Laminar status web UI
  • A process health heartbeat confirming laminard is running
  • A job queue heartbeat to catch stalled or empty queues
  • A job completion heartbeat for end-to-end CI verification
  • SSL certificate expiry alerts

Prerequisites

  • Laminar CI installed (laminard running as a systemd service or similar)
  • Job scripts configured in /var/lib/laminar/cfg/jobs/
  • A domain or hostname accessible over HTTPS (via Nginx or Caddy reverse proxy)
  • A free account at vigilmon.online

Step 1: Monitor the Laminar Web UI

Laminar serves a real-time status dashboard on port 8080 by default (or behind your reverse proxy). This is your team's primary window into job status and recent build history:

  1. Log in to VigilmonAdd Monitor → HTTP.
  2. URL: https://ci.yourdomain.com (or http://ci-host:8080 if no TLS termination).
  3. Check interval: 120 seconds.
  4. Expected status: 200.
  5. Label: Laminar Web UI
  6. Click Save.

Laminar's web UI is served directly by laminard — no separate web server process. A 200 response confirms the daemon is alive and the HTTP listener is responding. Unlike heavier CI systems, Laminar has no separate application server to crash independently.


Step 2: Monitor the Laminar Status Endpoint

Laminar exposes a JSON status endpoint at /api/jobs that returns recent job run data. This is more diagnostic than the HTML dashboard because it returns structured data you can parse to verify the system is actively processing:

  1. Add Monitor → HTTP.
  2. URL: https://ci.yourdomain.com/api/jobs
  3. Check interval: 60 seconds.
  4. Expected status: 200.
  5. Label: Laminar API Status
  6. Click Save.
# Verify the API endpoint manually
curl -s https://ci.yourdomain.com/api/jobs | python3 -m json.tool
# Returns JSON list of recent jobs with status, start time, result

A 200 with JSON output confirms the API layer is serving job data. If laminard is in an error state (e.g., RPC socket unavailable), this endpoint returns an error even when the HTML UI partially renders from a cached response.


Step 3: Process Health Heartbeat

Since Laminar is a single daemon, checking the process is the most direct health signal. Set up a systemd-based heartbeat from the Laminar host:

#!/bin/bash
# /etc/cron.d/laminar-process — runs every 5 minutes

if systemctl is-active --quiet laminard; then
  curl -fsS -X POST https://vigilmon.online/api/heartbeat/YOUR-PROCESS-HEARTBEAT-ID
fi

Or if running Laminar without systemd, check the process directly:

#!/bin/bash
# /etc/cron.d/laminar-process — runs every 5 minutes

if pgrep -x laminard > /dev/null; then
  curl -fsS -X POST https://vigilmon.online/api/heartbeat/YOUR-PROCESS-HEARTBEAT-ID
fi

In Vigilmon:

  1. Add Monitor → Heartbeat.
  2. Expected interval: 5 minutes.
  3. Grace period: 15 minutes.
  4. Label: Laminar Process Health

This heartbeat is your crash detector. If laminard exits due to a segfault, OOM kill, or configuration error, the heartbeat stops within the grace period and Vigilmon alerts you — even if your reverse proxy still serves a cached response.


Step 4: Job Queue Heartbeat

A stalled queue means builds are accepted but never executing — usually caused by a full workspace disk, a lock held by a crashed job, or a misconfigured job script that always exits non-zero. Monitor the queue with a script that verifies jobs are actively processing:

#!/bin/bash
# /etc/cron.d/laminar-queue — runs every 10 minutes

# Check that the laminar RPC socket is accepting connections
if laminarc show-jobs 2>/dev/null | head -1 | grep -qE "(queued|running|done)"; then
  curl -fsS -X POST https://vigilmon.online/api/heartbeat/YOUR-QUEUE-HEARTBEAT-ID
fi

Alternatively, use the HTTP API to check for recent activity:

#!/bin/bash
# /etc/cron.d/laminar-queue — runs every 10 minutes

RECENT=$(curl -s https://ci.yourdomain.com/api/jobs \
  | python3 -c "
import sys, json, time
jobs = json.load(sys.stdin)
# Check for any job completed in the last 30 minutes
recent = [j for j in jobs if j.get('started', 0) > time.time() - 1800]
print(len(recent))
" 2>/dev/null || echo "0")

if [ "${RECENT:-0}" -ge 1 ] 2>/dev/null; then
  curl -fsS -X POST https://vigilmon.online/api/heartbeat/YOUR-QUEUE-HEARTBEAT-ID
fi

In Vigilmon:

  1. Add Monitor → Heartbeat.
  2. Expected interval: 10 minutes.
  3. Grace period: 30 minutes.
  4. Label: Laminar Job Activity

Tune the grace period to your team's commit frequency. A 30-minute grace period catches queues stalled for more than half an hour without generating false alerts during quiet periods.


Step 5: SSL Certificate Alerts

If Laminar is exposed via an Nginx or Caddy reverse proxy with TLS termination, certificate expiry will break all HTTPS access to the dashboard and API:

  1. Add Monitor → SSL Certificate.
  2. Domain: ci.yourdomain.com
  3. Alert when expiry is within: 30 days.
  4. Alert again: 14 days, 7 days, 3 days.
  5. Click Save.

Laminar itself has no TLS support — it delegates to the reverse proxy. The SSL monitor catches expiry before Caddy's (or Nginx's) auto-renewal fails silently, leaving the certificate expired.


Step 6: Job Completion Heartbeat

Add a Vigilmon heartbeat call at the end of a critical Laminar job script to confirm end-to-end CI execution — not just that laminard is running, but that it's successfully completing builds:

#!/bin/bash
# /var/lib/laminar/cfg/jobs/build-main.run

set -e

cd /srv/app
git pull origin main
npm ci
npm test

# Notify Vigilmon on successful completion
curl -fsS -X POST https://vigilmon.online/api/heartbeat/YOUR-BUILD-HEARTBEAT-ID

In Vigilmon:

  1. Add Monitor → Heartbeat.
  2. Expected interval: Match your job trigger frequency (e.g., 60 minutes if triggered hourly via cron, or 120 minutes for less active repos).
  3. Grace period: 30 minutes.
  4. Label: Laminar Build Completion

Because the set -e directive causes the script to exit immediately on any error, the heartbeat only fires when every preceding command succeeds. Failed test suites or broken git pulls will silence the heartbeat and trigger a Vigilmon alert.


Step 7: Disk Space Check for Laminar Workspace

Laminar stores job workspaces, artifacts, and logs in /var/lib/laminar/. A full disk silently kills all new job runs without any visible error in the UI:

#!/bin/bash
# /etc/cron.d/laminar-disk — runs every 15 minutes

USED=$(df /var/lib/laminar --output=pcent | tail -1 | tr -d ' %')

if [ "${USED:-100}" -lt 85 ] 2>/dev/null; then
  curl -fsS -X POST https://vigilmon.online/api/heartbeat/YOUR-DISK-HEARTBEAT-ID
fi

In Vigilmon:

  1. Add Monitor → Heartbeat.
  2. Expected interval: 15 minutes.
  3. Grace period: 30 minutes.
  4. Label: Laminar Disk Space

When disk usage reaches 85%, the heartbeat stops and Vigilmon alerts you before the filesystem fills completely and starts failing job runs.


Common Laminar CI Failure Modes and What Vigilmon Catches

| Scenario | Vigilmon monitor | |---|---| | laminard process crash | Process heartbeat stops within 5 min grace period | | RPC socket becomes unavailable | Job queue heartbeat stops | | Workspace disk full | Disk space heartbeat stops | | Job scripts consistently failing | Build completion heartbeat goes silent | | SSL certificate expires | SSL monitor alerts at 30 days | | Reverse proxy misconfiguration | Web UI HTTP monitor fires | | System OOM kills laminard | Process heartbeat stops; systemd check fails | | Job queue stalled by a stuck lock | Job activity heartbeat stops | | Network partition from monitoring | All monitors fire simultaneously |


Laminar CI's minimal footprint makes it ideal for small teams and single-server setups where heavyweight CI systems are overkill. Vigilmon extends that simplicity with external observability — watching the daemon, job activity, disk health, build completion, and SSL certificate so you know immediately when something stops working.

Start monitoring Laminar CI in under 5 minutes — 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 →