Pocket ID is a lightweight, self-hosted OIDC identity provider written in Go. It runs on port 1411 and handles authentication for every application in your stack that delegates SSO to it. That makes it uniquely critical: if Pocket ID goes down, users can't log in to any connected app. Vigilmon gives you the visibility you need — checking the auth server, OIDC discovery document, token endpoint, and audit log service before your users notice anything is wrong.
What You'll Set Up
- HTTP uptime monitor for the Pocket ID web server
- OIDC discovery endpoint health check
- OAuth2 token issuance endpoint monitor
- User account management API monitor
- Client app registration health check
- Audit log service availability monitor
Prerequisites
- Pocket ID running and accessible (default port 1411)
- A free Vigilmon account
Step 1: Monitor the Pocket ID Web Server
Pocket ID's web interface and API both run on port 1411. Start with a basic uptime check:
- Log in to vigilmon.online and click Add Monitor.
- Set Type to
HTTP / HTTPS. - Enter the URL:
http://your-server:1411(or your domain if you proxy Pocket ID behind nginx/Caddy). - Set Check interval to
1 minute. - Set Expected HTTP status to
200. - Click Save.
If you proxy Pocket ID behind a reverse proxy, use the public URL instead of the direct port:
https://auth.yourdomain.com
A 200 response on the root path confirms the Go HTTP server is alive and the reverse proxy is correctly forwarding traffic.
Step 2: Monitor the OIDC Discovery Endpoint
The OIDC discovery document at /.well-known/openid-configuration is the first thing every OIDC client fetches. If this endpoint returns an error, all client apps that auto-configure via discovery will break immediately.
- In Vigilmon, click Add Monitor → HTTP / HTTPS.
- URL:
https://auth.yourdomain.com/.well-known/openid-configuration - Set Check interval to
1 minute. - Set Expected HTTP status to
200. - Under Response validation, add a body contains check for
"issuer". - Click Save.
The body check ensures Pocket ID is returning a valid JSON document with the issuer field — not a cached error page from a misconfigured proxy.
Verify the endpoint manually before adding the monitor:
curl -s https://auth.yourdomain.com/.well-known/openid-configuration | jq .issuer
# "https://auth.yourdomain.com"
Step 3: Monitor the OAuth2 Token Issuance Endpoint
The /api/oidc/token endpoint processes every login. A slow or unresponsive token endpoint means users see login failures even when the UI loads fine.
- Add a new HTTP / HTTPS monitor.
- URL:
https://auth.yourdomain.com/api/oidc/token - Set Expected HTTP status to
400(the endpoint rejects unauthenticated GET requests with 400 or 405, confirming the server is up and routing correctly without needing real credentials). - Set Check interval to
1 minute. - Click Save.
This "probe for a known error" pattern is common for auth endpoints — you verify the server is alive and responding without triggering actual authentication logic.
Alternatively, if you have a test client configured in Pocket ID, use the client credentials flow:
curl -s -X POST https://auth.yourdomain.com/api/oidc/token \
-d "grant_type=client_credentials&client_id=test&client_secret=secret" \
| jq .token_type
# "Bearer"
Use this as a synthetic transaction monitored via a Vigilmon webhook or external script calling the Vigilmon heartbeat API.
Step 4: Monitor the User Account Management API
Pocket ID exposes a REST API for user and client management. Monitor the health of this API:
- Add a new HTTP / HTTPS monitor.
- URL:
https://auth.yourdomain.com/api/health(or/api/if Pocket ID doesn't expose a dedicated health route — check its current version's API docs). - If no dedicated health endpoint exists, monitor the admin UI path instead:
https://auth.yourdomain.com/admin - Set Expected HTTP status to
200. - Click Save.
Check the Pocket ID API documentation for the version you're running to confirm available health or status endpoints, as these may change between releases.
Step 5: Monitor Client App Registration Health
Pocket ID stores client registrations — if the underlying SQLite database becomes corrupted or the file system fills up, client lookups will start failing even though the HTTP server is still responding.
Add a monitor that checks a client-specific OIDC endpoint to verify the data layer is intact:
- In Pocket ID admin, note the client ID of a registered app (e.g.
my-app). - Add an HTTP / HTTPS monitor for the JWKS endpoint:
https://auth.yourdomain.com/api/oidc/jwks - Set Expected HTTP status to
200. - Add a body contains check for
"keys". - Click Save.
The JWKS endpoint requires Pocket ID to load its signing keys from storage. A failed JWKS response often indicates a storage or key-loading issue before any login attempt fails.
Step 6: Monitor the Audit Log Service
Pocket ID logs authentication events. While a failing audit log won't immediately prevent logins, it's an early warning that disk space or file I/O is degrading. Monitor disk health on the host Pocket ID runs on:
Use a cron heartbeat to confirm Pocket ID's log rotation or a companion health script is running:
- In Vigilmon, click Add Monitor → Cron Heartbeat.
- Set the expected ping interval to
60minutes. - Copy the heartbeat URL:
https://vigilmon.online/heartbeat/abc123. - Add a cron job on your Pocket ID host:
# /etc/cron.hourly/pocket-id-health
#!/bin/bash
# Check Pocket ID is responding and disk has headroom
if curl -sf http://localhost:1411/.well-known/openid-configuration > /dev/null; then
DISK_USAGE=$(df /var/lib/pocket-id | awk 'NR==2{print $5}' | tr -d '%')
if [ "$DISK_USAGE" -lt 85 ]; then
curl -s https://vigilmon.online/heartbeat/abc123
fi
fi
This heartbeat only fires when both the OIDC discovery endpoint responds and disk usage is below 85%. Silence triggers a Vigilmon alert.
Step 7: Configure Alert Channels
Because Pocket ID is the authentication layer for other services, alerts need to be immediate:
- Go to Alert Channels in Vigilmon and add Slack, PagerDuty, or email.
- Set Consecutive failures before alert to
1on the OIDC discovery and token endpoint monitors — don't wait for a second failure when auth is broken. - Set it to
2on the web server monitor (a single missed probe may be a transient network hiccup).
Set up a dedicated Pocket ID alert channel group so auth alerts are never buried in general infrastructure noise.
Summary
| Monitor | Target | What It Catches |
|---|---|---|
| Web server | https://auth.yourdomain.com | Pocket ID process crash, proxy misconfiguration |
| OIDC discovery | /.well-known/openid-configuration | Client auto-configuration failures |
| Token endpoint | /api/oidc/token | Login failures, token issuance errors |
| JWKS endpoint | /api/oidc/jwks | Key loading / storage failures |
| Cron heartbeat | Heartbeat URL | Disk full, audit log failure, process hanging |
Pocket ID's simplicity — a single Go binary, SQLite storage — is a feature, but it means there's no built-in health dashboard. With Vigilmon checking every layer of the auth stack, you'll know about identity provider failures before any of your users hit a login error.