All files / apps/web/src/backoffice/pages Logs.jsx

0% Statements 0/1
100% Branches 0/0
0% Functions 0/1
0% Lines 0/1

Press n or j to go to the next uncovered block, b, p or k for the previous block.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82                                                                                                                                                                   
import { Activity, Server, Database, Cpu } from 'lucide-react';
 
export default function SystemLogs() {
  return (
    <div className="space-y-6">
      <div>
        <h2 className="text-2xl font-bold text-gray-900">Logs & Monitoring</h2>
        <p className="text-gray-600">Surveillance et logs système</p>
      </div>
 
      {/* System Resources */}
      <div className="grid grid-cols-1 md:grid-cols-4 gap-6">
        <div className="bg-white rounded-lg shadow p-6">
          <div className="flex items-center space-x-3">
            <Cpu className="w-8 h-8 text-blue-500" />
            <div>
              <p className="text-sm text-gray-600">CPU</p>
              <p className="text-2xl font-bold">45%</p>
            </div>
          </div>
        </div>
        
        <div className="bg-white rounded-lg shadow p-6">
          <div className="flex items-center space-x-3">
            <Database className="w-8 h-8 text-green-500" />
            <div>
              <p className="text-sm text-gray-600">Mémoire</p>
              <p className="text-2xl font-bold">62%</p>
            </div>
          </div>
        </div>
        
        <div className="bg-white rounded-lg shadow p-6">
          <div className="flex items-center space-x-3">
            <Server className="w-8 h-8 text-purple-500" />
            <div>
              <p className="text-sm text-gray-600">Disque</p>
              <p className="text-2xl font-bold">38%</p>
            </div>
          </div>
        </div>
        
        <div className="bg-white rounded-lg shadow p-6">
          <div className="flex items-center space-x-3">
            <Activity className="w-8 h-8 text-red-500" />
            <div>
              <p className="text-sm text-gray-600">Requêtes/min</p>
              <p className="text-2xl font-bold">1,284</p>
            </div>
          </div>
        </div>
      </div>
 
      {/* Logs */}
      <div className="bg-white rounded-lg shadow">
        <div className="px-6 py-4 border-b border-gray-200">
          <h3 className="text-lg font-medium text-gray-900">Logs Récents</h3>
        </div>
        <div className="p-6">
          <div className="space-y-2 font-mono text-sm">
            <div className="p-2 bg-green-50 text-green-800 rounded">
              <span className="font-bold">[INFO]</span> 2024-01-15 10:30:45 - Crawler job completed: 42 pages crawled
            </div>
            <div className="p-2 bg-blue-50 text-blue-800 rounded">
              <span className="font-bold">[INFO]</span> 2024-01-15 10:28:12 - File extraction started: document.pdf
            </div>
            <div className="p-2 bg-yellow-50 text-yellow-800 rounded">
              <span className="font-bold">[WARN]</span> 2024-01-15 10:25:33 - High memory usage detected
            </div>
            <div className="p-2 bg-green-50 text-green-800 rounded">
              <span className="font-bold">[INFO]</span> 2024-01-15 10:22:18 - User login: admin@nooloom.io
            </div>
            <div className="p-2 bg-red-50 text-red-800 rounded">
              <span className="font-bold">[ERROR]</span> 2024-01-15 10:20:05 - Failed to connect to Bright Data
            </div>
          </div>
        </div>
      </div>
    </div>
  );
}