Pastefy is a clean, open-source alternative to Pastebin — a Go backend with a React/TypeScript frontend that supports syntax highlighting, encrypted pastes, folders, link shortening, OAuth2 login, and a full REST API. Once you host it yourself, no one else is watching it for you. Vigilmon gives you uptime monitoring, API response-time tracking, database health checks, and TLS certificate alerts so you know the moment something goes wrong.
What You'll Set Up
- HTTP uptime monitor for the Pastefy web interface (port 5000)
- Paste creation API endpoint response-time tracking (
POST /api/paste) - Paste retrieval endpoint health check
- Encrypted paste service (client-side handshake) verification
- User authentication service check (OAuth2/local login endpoint)
- Folder management API health
- Link shortener service check
- Admin panel accessibility monitor
- Cron heartbeat for the expired-paste cleanup job
- SSL/TLS certificate expiry alert
Prerequisites
- Pastefy running and accessible (default port 5000)
- A free Vigilmon account
Step 1: Monitor the Pastefy Web Interface
The most critical check is whether the Pastefy frontend is responding.
- Log in to vigilmon.online and click Add Monitor.
- Set Type to
HTTP / HTTPS. - Enter your Pastefy URL:
https://paste.yourdomain.com. - Set Check interval to
1 minute. - Set Expected HTTP status to
200. - Click Save.
If Pastefy sits behind a reverse proxy (nginx, Caddy), this monitor catches proxy failures and application crashes in the same check.
Step 2: Track Paste Creation API Response Times
The POST /api/paste endpoint is the core action users take. Slow response times here directly affect every paste submission.
- Click Add Monitor → HTTP / HTTPS.
- Set URL to
https://paste.yourdomain.com/api/paste. - Set Method to
POST. - Add the header
Content-Type: application/json. - Set Request body to:
{"content": "vigilmon-health-check", "type": "text"}
- Set Expected HTTP status to
200or201. - Enable Response time alerting and set a threshold of
2000 ms. - Click Save.
This confirms that paste creation — including any database write — completes within your SLA.
Step 3: Monitor the Paste Retrieval Endpoint
Reads should be faster than writes. Create a dedicated monitor for an existing paste:
- Create a test paste manually and copy its ID (e.g.
abc123). - Add a monitor for
https://paste.yourdomain.com/api/paste/abc123. - Set Method to
GET, Expected status to200. - Set a response-time alert at
1000 ms.
If paste retrieval slows down while creation stays fast, you likely have a read-path issue (caching, index degradation, or replica lag if using read replicas).
Step 4: Verify the Encrypted Paste Service
Pastefy encrypts pastes client-side using a key embedded in the URL fragment. The server never sees the plaintext, but the API endpoint still handles the ciphertext store and retrieve cycle. Add a monitor that confirms the /api/paste endpoint accepts the encrypted flag:
- Add an HTTP monitor for
https://paste.yourdomain.com/api/paste. - Set Method to
POST, body:
{"content": "dGVzdA==", "type": "text", "encrypted": true}
- Set Expected status to
200or201.
A failure here means encrypted paste users get errors even though regular pastes may still work.
Step 5: Check the Authentication Endpoint
Pastefy supports local accounts and OAuth2 providers (GitHub, GitLab, etc.). Monitor the login endpoint to catch auth-service outages:
- Add an HTTP monitor for
https://paste.yourdomain.com/api/user/login(or the OAuth2 redirect URL your instance uses). - Set Method to
GET, Expected status to200or302(redirect to provider). - Label it Auth service.
An unreachable login endpoint locks users out even when paste creation still works.
Step 6: Monitor Folder Management and the Link Shortener
Pastefy's folder API and link shortener are secondary services but power important workflows.
Folder API:
- Add an HTTP monitor for
https://paste.yourdomain.com/api/folder. - Set Method to
GET, Expected status to200or401(unauthenticated request is still a healthy response).
Link shortener:
- Add an HTTP monitor for
https://paste.yourdomain.com/s(the shortener base path). - Set Expected status to
200or301.
Step 7: Confirm Admin Panel Accessibility
The admin panel at /admin lets you manage users and system settings. An inaccessible admin panel means you can't respond to abuse or configuration issues:
- Add an HTTP monitor for
https://paste.yourdomain.com/admin. - Set Expected status to
200or302(redirect to login is healthy;500is not). - Set Check interval to
5 minutes— admin panel checks are lower priority than API checks.
Step 8: Heartbeat for the Expired-Paste Cleanup Job
Pastefy can delete pastes after a set expiry. This runs as a background cron job. If the job stops running, expired pastes accumulate and storage fills up silently.
- In Vigilmon, click Add Monitor → Cron Heartbeat.
- Set the expected ping interval to match your cleanup schedule (e.g.
60minutes). - Copy the heartbeat URL:
https://vigilmon.online/heartbeat/YOUR_ID.
Add the ping to your cleanup script or cron entry:
# Example: run every hour
0 * * * * /usr/local/bin/pastefy-cleanup && curl -s https://vigilmon.online/heartbeat/YOUR_ID
Or if you run Pastefy via Docker and the cleanup is a scheduled container command:
# docker-compose.yml (example cron container)
command: >
sh -c "pastefy-cleanup && curl -s https://vigilmon.online/heartbeat/YOUR_ID"
If the job crashes mid-run, it never sends the ping and Vigilmon alerts after the expected interval.
Step 9: SSL/TLS Certificate Expiry Alert
- Open the web-interface monitor from Step 1.
- Enable Monitor SSL certificate.
- Set Alert when certificate expires in less than
21 days. - Click Save.
Let's Encrypt renewal is automatic only if your ACME client and port 80 challenge are both healthy. A 21-day window gives you time to investigate and renew manually before users see browser warnings.
Step 10: Configure Alert Channels
- Go to Alert Channels in Vigilmon and connect Slack, email, or a webhook.
- On the paste creation and retrieval monitors, set Consecutive failures before alert to
2— transient network blips should not page you. - On the heartbeat monitor, keep it at
1— a missed cleanup job should alert immediately.
Summary
| Monitor | Target | What It Catches |
|---|---|---|
| Web interface | https://paste.yourdomain.com | App crash, proxy failure |
| Paste creation API | POST /api/paste | DB write failure, slow performance |
| Paste retrieval | GET /api/paste/:id | Read-path degradation |
| Encrypted paste | POST /api/paste (encrypted flag) | Encrypted paste flow broken |
| Auth endpoint | /api/user/login | Login service down |
| Folder API | GET /api/folder | Folder feature broken |
| Link shortener | GET /s | Shortener broken |
| Admin panel | GET /admin | Admin inaccessible |
| Cleanup heartbeat | Cron heartbeat URL | Expired-paste job not running |
| SSL certificate | paste.yourdomain.com | TLS cert expiry |
Pastefy gives you a self-hosted paste service with real privacy guarantees — but self-hosted means self-monitored. With Vigilmon watching every layer from the web UI to the cleanup cron, you catch failures before your users do.