diff --git a/public/s/css/f0ck.css b/public/s/css/f0ck.css index 871b74a..2972b5f 100644 --- a/public/s/css/f0ck.css +++ b/public/s/css/f0ck.css @@ -1213,3 +1213,12 @@ img.avatar { border-radius: 25px; margin-top: 1px; } + +/* log */ +div.logwrap { + height: auto; + text-align: left; +} +div.logwrap > p { + line-height: 0; +} diff --git a/src/inc/routes/admin.mjs b/src/inc/routes/admin.mjs index bd6006b..9838381 100644 --- a/src/inc/routes/admin.mjs +++ b/src/inc/routes/admin.mjs @@ -118,10 +118,10 @@ export default (router, tpl) => { }); router.get(/^\/admin\/log(\/)?$/, auth, async (req, res) => { - exec("journalctl -xu f0ck", (err, stdout) => { + exec("journalctl -qeu f0ck --no-pager", (err, stdout) => { res.reply({ body: tpl.render("admin/log", { - log: stdout.split("\n").slice(-500) + log: stdout.split("\n").slice(0, -1) }, req) }); }); diff --git a/views/admin/log.html b/views/admin/log.html index 242c604..06fa0b4 100644 --- a/views/admin/log.html +++ b/views/admin/log.html @@ -6,18 +6,6 @@
{{ line }}
@endeach - @endif -@include(main/footer) \ No newline at end of file +@include(main/footer)