kalakotra/silverstripe-monitoring-admin

SilverStripe 6 monitoring – active pull collector and CMS admin UI

Maintainers

Package info

github.com/kalakotra/silverstripe-monitoring-admin

Type:silverstripe-vendormodule

pkg:composer/kalakotra/silverstripe-monitoring-admin

Statistics

Installs: 0

Dependents: 0

Suggesters: 0

Stars: 0

Open Issues: 0

1.0.0 2026-04-22 07:33 UTC

This package is auto-updated.

Last update: 2026-05-12 13:57:44 UTC


README

Active pull collector and CMS admin interface for the SilverStripe 6 monitoring system.
It periodically pulls data from passive client endpoints.

Installation

composer require kalakotra/silverstripe-monitoring-admin
vendor/bin/sake dev/build flush=1

Set Up a New Client

  1. On the client site, install kalakotra/silverstripe-monitoring-client
  2. Set MONITORING_SECRET_KEY in the client's .env
  3. On the admin site, open /admin/monitoringAdd Project
  4. Enter:
    • Title – the client name
    • Endpoint URLhttps://client.example/
    • Secret Key – the MONITORING_SECRET_KEY value from the client's .env
  5. Save, then run a manual pull or wait for cron

Crontab Configuration (on the admin site)

Option A - run sake directly (recommended if you have SSH)

# Every hour - pulls data from all projects
0 * * * * /usr/bin/php /var/www/html/vendor/bin/sake dev/tasks/MonitoringPullTask >> /var/log/monitoring-pull.log 2>&1

Option B - curl the sake task URL

0 * * * * curl -s "https://admin-page.com/dev/tasks/MonitoringPullTask" > /dev/null 2>&1

Option C - cPanel Cron Jobs

Frequency Command
Every hour curl -s "https://admin-page.com/dev/tasks/MonitoringPullTask"

Note: dev/tasks is available by default only from 127.0.0.1 or for admins.
For a curl request from an external IP, add that IP to the DevAdmin.allowed_ips YAML configuration.

Manual Pull (for testing)

vendor/bin/sake dev/tasks/MonitoringPullTask

Status Logic

State Color Condition
Online green Pull within 25h
Warning yellow Pull older than 25h and newer than 48h
Offline red Pull older than 48h or never ran

Errors are counted in ConsecutiveErrors and shown next to the status badge as (Nx).

Collected Data

Category Fields
Versions PHP, SilverStripe framework, recipe-cms
Content Total pages, published, draft, broken links, DB objects, tables
Users Total members, admins
Environment live/dev/test, base URL, locale
System Memory limit, max execution time, free/total disk

Struktura

src/
├── Admin/
│   └── MonitoringAdmin.php           # ModelAdmin – /admin/monitoring
├── Model/
│   └── Project.php                   # DataObject + status/disk badge
├── Service/
│   └── ProjectPullService.php        # Guzzle pull logika
└── Task/
    └── MonitoringPullTask.php        # BuildTask for cron
_config/
└── routes.yml