mirror of
https://github.com/wearepixel/pulsewise-collector.git
synced 2026-11-14 14:01:50 +00:00
feat: add PHP-FPM, nginx, SSL, and port monitoring
All four are opt-in via config file: - FPM_STATUS_URL — PHP-FPM pool stats (active/idle workers, slow requests, max children reached, accepted conn) - NGINX_STATUS_URL — nginx stub_status (active connections, reading/writing/waiting, accepts/handled/requests) - SSL_DOMAINS — TLS cert expiry check per domain (days left, valid, expires_at) - CHECK_PORTS — TCP port availability per port with known service name mapping Also refactors loadConfigFromFile to return *Config directly instead of a positional tuple.
This commit is contained in:
+43
-1
@@ -114,5 +114,47 @@
|
||||
"cpu_time": 890.12,
|
||||
"memory_bytes": 134217728
|
||||
}
|
||||
]
|
||||
],
|
||||
"fpm": {
|
||||
"pool": "www",
|
||||
"active_processes": 3,
|
||||
"idle_processes": 7,
|
||||
"total_processes": 10,
|
||||
"max_active_processes": 8,
|
||||
"max_children_reached": 0,
|
||||
"listen_queue": 0,
|
||||
"max_listen_queue": 2,
|
||||
"slow_requests": 0,
|
||||
"accepted_conn": 84291
|
||||
},
|
||||
"ssl": [
|
||||
{
|
||||
"domain": "example.com",
|
||||
"expires_at": "2026-06-01T12:00:00Z",
|
||||
"days_left": 95,
|
||||
"valid": true
|
||||
},
|
||||
{
|
||||
"domain": "api.example.com",
|
||||
"expires_at": "2026-06-01T12:00:00Z",
|
||||
"days_left": 95,
|
||||
"valid": true
|
||||
}
|
||||
],
|
||||
"ports": [
|
||||
{ "port": 22, "open": true, "service": "ssh" },
|
||||
{ "port": 80, "open": true, "service": "http" },
|
||||
{ "port": 443, "open": true, "service": "https" },
|
||||
{ "port": 3306, "open": true, "service": "mysql" },
|
||||
{ "port": 6379, "open": false, "service": "redis" }
|
||||
],
|
||||
"nginx": {
|
||||
"active_connections": 42,
|
||||
"reading": 1,
|
||||
"writing": 8,
|
||||
"waiting": 33,
|
||||
"accepts": 1847293,
|
||||
"handled": 1847293,
|
||||
"requests": 3921847
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user