jingyue/log-view-php
Laravel log viewer based on rap2hpoutre/laravel-log-viewer, with added navigation for logs stored in nested folders. Browse, search, and inspect Laravel/Lumen log files in your browser by routing to the controller—no public assets required.
storage/logs/). If the system uses microservices with distributed logging (e.g., ELK, Loki, or AWS CloudWatch), this package is not a fit—it assumes file-based log storage.SyslogHandler, SocketHandler). If logs are already centralized, this adds redundant overhead.tail -f, stern) or third-party dashboards (e.g., Sentry, Datadog), this may introduce unnecessary complexity.composer.json. Could conflict with project-specific Monolog versions.LogViewerController). Risk of namespace collisions if the project already has a LogViewer class.Allowed memory exhausted errors).log:read Artisan command).composer require jingyue/log-view-php --dev).LogViewerController to add:
auth:api middleware).throttle:60).routes/web.php:
Route::middleware(['auth:sanctum'])->get('/logs', [\Jingyue\LogViewer\Controller\LogViewerController::class, 'index']);
single, daily, syslog).SocketHandler for remote logging).storage/logs/. If using a custom path, override via config:
'log_viewer' => [
'log_path' => storage_path('custom-logs'),
]
log_max_files).| Failure Scenario | Impact | Mitigation |
|---|---|---|
| Log file corruption | UI shows garbled logs | Backup logs; use log:clear |
| PHP version incompatibility | Package fails to load | Downgrade PHP or patch manually |
| Route conflict | 404 or infinite loop | Rename controller or adjust namespace |
| Unauthenticated access | Logs exposed to public | Add middleware (auth, throttle) |
| Large log files | Memory exhaustion | Implement chunked reading |
How can I help you explore Laravel packages today?