If you just want to visualize the Access Logs to have an overview of the visits? And what if you could do that from within your terminal and/or in your browser?
Introducing GoAccess.io! This tool is really handy and perfect to do that with no hassle.
Steps
Installation
Install the GoAccess locally. https://goaccess.io/download
It is available most of the Linux distribution, *BSD, even Slackware! Via Brew, or via Sources.
Just use it
Thanks to the upsun CLI:
upsun log access --tail 2>/dev/null | goaccess --log-format=COMBINED -
You will visualize in your terminal, or you can visualize it in your browser
upsun log access --tail 2>/dev/null | goaccess --log-format=COMBINED -o report.html --real-time-html -
And then just open the report.html file.
Bonus that’s realtime if you pass the option
--real-time-html
Advanced
If you want to have the full log, you can also download the full access.log
upsun ssh --all # to see the SSH_URL scp SSH_URL:/var/log/access.log . goaccess access.log --log-format=COMBINED -o report.html
That’s it!
Enjoy fancy Access Log visualization!
Comments
Please sign in to leave a comment.