mteu / typo3-monitoring
Exposes health status information of selected components in your TYPO3 instance to be integrated in external monitoring
Installs: 2
Dependents: 0
Suggesters: 0
Security: 0
Stars: 2
Watchers: 0
Forks: 1
Open Issues: 4
Type:typo3-cms-extension
Requires
- php: ~8.3.0 || ~8.4.0
- ext-intl: *
- psr/http-message: ^2.0
- typo3/cms-backend: ~13.4.12
- typo3/cms-core: ~13.4.12
- typo3/cms-install: ~13.4.12
Requires (Dev)
- a9f/typo3-fractor: ^0.5.0
- armin/editorconfig-cli: ^2.0
- eliashaeussler/version-bumper: ^3.0
- ergebnis/composer-normalize: ^2.28
- helmich/typo3-typoscript-lint: ^3.0
- mteu/zealous-stan: ^0.6.3
- phpstan/extension-installer: *
- phpstan/phpstan: ^2.1
- phpunit/phpcov: ^10.0
- phpunit/phpunit: ^11.5
- roave/security-advisories: dev-latest
- saschaegerer/phpstan-typo3: ^2.1
- shipmonk/composer-dependency-analyser: *
- ssch/typo3-rector: ^3.6
- typo3/coding-standards: ^0.8.0
- typo3/tailor: ^1.7
- typo3/testing-framework: ^9.0
- dev-main
- 0.2.1
- 0.2.0
- 0.1.0
- dev-feature/make-initial-authorizers-optional
- dev-renovate/phpunit-phpunit-12.x
- dev-renovate/phpunit-phpcov-11.x
- dev-renovate/patch-phpstan-packages
- dev-task/remove-unused-packages
- dev-task/language-washing
- dev-task/remove-version-from-composer-package
- dev-bugfix/avoid-exception-for-missing-secret
- dev-task/reduce-executions
- dev-task/simplify-result
- dev-docs/typo3-badges
- dev-bugfix/fix-release-workflow
- dev-bugfix/fix-ter-upload-workflow
- dev-task/configure-version-bumper
- dev-task/publish-to-ter
- dev-task/report-code-coverage
- dev-bugfix/show-auth-header-name
- dev-docs/add-qlty-badge
This package is auto-updated.
Last update: 2025-07-17 22:08:06 UTC
README
TYPO3 Monitoring
This packages provides the TYPO3 CMS Extension EXT:monitoring
which extends the CMS with a monitoring system that
gives an insight into the health state of custom TYPO3 components through an API endpoint and a CLI command, e.g. for
post-deployment checks.
Warning
This package is still in early development and must be considered unfit for production use. Bear with me. We'll get there.
🚀 Features
- Extensible monitoring system with automatic service discovery (using DI) for custom authorization and monitoring checks.
- Supports caching for expensive monitoring operations
- Delivers health reports in three ways:
- JSON response: Returns structured responses for the overall health status
- CLI command: Command-line interface for running monitoring checks
- Backend Module: TYPO3 backend module
🔥 Quick Start
Installation
Install via Composer:
composer require mteu/typo3-monitoring
Configuration
-
Configure the extension in the TYPO3 backend:
- Go to Admin Tools → Settings → Extension Configuration
- Select
monitoring
- Set the monitoring endpoint path (default:
/monitor/health
) - Configure a secret for HMAC authentication
-
Or better yet configure the settings programmatically:
# config/system/settings.php <?php return [ // .. 'EXTENSIONS' => [ 'monitoring' => [ 'api' => [ 'endpoint' => '/monitor/health', 'secret' => 'foobarsecret', ], ], ], // .. ];
-
Access your monitoring endpoint while authenticated as backend user with the role of Admin or System Maintainer:
https://<your-site>/monitor/health
Authentication
This extension ships two authentication methods natively:
Admin User Authentication
Access the endpoint while logged in as a TYPO3 backend administrator.
Token-based Authentication
Add the X-TYPO3-MONITORING-AUTH
header with an HMAC signature:
curl -s -H "X-TYPO3-MONITORING-AUTH: <auth-token>" \ https://<your-site>/monitor/health | jq '.'
📝 Response Format
The monitoring endpoint returns JSON with the following structure:
{ "isHealthy": true, "services": { "service_one": "healthy", "service_two": "healthy", "service_three": "healthy" } }
isHealthy
: Overall health status (boolean)services
: Object with individual service statuses ("healthy" or "unhealthy")
HTTP status codes:
200
All services healthy401
Unauthorized access403
Unsupported protocol503
One or more services unhealthy
🧑💻 Development
Creating Custom Providers
Implement the MonitoringProvider
interface:
<?php use mteu\Monitoring\Provider\MonitoringProvider; use mteu\Monitoring\Result\MonitoringResult; use Symfony\Component\DependencyInjection\Attribute\AutoconfigureTag; #[AutoconfigureTag(tag: 'monitoring.provider')] final class MyMonitoringProvider implements MonitoringProvider { public function getName(): string { return 'MyService'; } public function getDescription(): string { return 'Monitors my custom service'; } public function isActive(): bool { return true; } public function execute(): MonitoringResult { // Your monitoring logic here return new MonitoringResult( $this->getName(), true, ); } }
Creating Custom Authorizers
Implement the Authorizer
interface:
<?php use mteu\Monitoring\Authorization\Authorizer; use Psr\Http\Message\ServerRequestInterface; use Symfony\Component\DependencyInjection\Attribute\AutoconfigureTag; #[AutoconfigureTag(tag: 'monitoring.authorizer')] final class MyAuthorizer implements Authorizer { public function isAuthorized(ServerRequestInterface $request): bool { // Your authorization logic here return true; } public function getPriority(): int { return 100; // Higher priority = checked first } }
🤝 Contributing
Contributions are very welcome! Please have a look at the Contribution Guide. It lays out the workflow of submitting new features or bugfixes.
📙 Documentation
Please have a look at the official extension documentation. It provides a detailed look into the possibilities you have in extending and customizing this extension for your specific TYPO3 components.
🔒 Security
Please refer to our security policy if you discover a security vulnerability in this extension. Be warned, though. I cannot afford bounty. This is private project.
💛 Acknowledgements
This extension is inspired by cpsit/monitoring
and its generic approach to offer an extensible provider
interface. I've transformed and extended the underlying concept into a TYPO3 specific implementation.
⭐ License
This extension is licensed under the GPL-2.0-or-later license.
💬 Support
For issues and feature requests, please use the GitHub issue tracker.