Commit 6fe93abf authored by Dominik Hebeler's avatar Dominik Hebeler
Browse files

Der letzte Log wird direkt aus der Redis Datenbank geholt

parent e11b33f9
......@@ -94,10 +94,10 @@ class AdminInterface extends Controller
public function check ()
{
$q = "";
$logFile = "/var/log/metager/mg3.log";
if( file_exists($logFile) )
$redis = Redis::connection('redisLogs');
if($redis)
{
$q = exec("tail -n 1 $logFile");
$q = $redis->lrange("logs.search", -1, -1)[0];
$q = substr($q, strpos($q, "search=")+7);
}
return view('admin.check')
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment