Translate a CiviProxy logfile into JSON format.
Go to file
Marc Koch eeeeccbf8c
⬇️ downgrade minimal Python version
2022-10-27 22:41:26 +02:00
.idea 🎉 Initial commit 2022-10-27 20:56:50 +02:00
civiproxy_logs2json 🎉 Initial commit 2022-10-27 20:56:50 +02:00
tests 🎉 Initial commit 2022-10-27 20:56:50 +02:00
.gitignore 🎉 Initial commit 2022-10-27 20:56:50 +02:00
LICENSE 🎉 Initial commit 2022-10-27 20:56:50 +02:00
README.md 🎉 Initial commit 2022-10-27 20:56:50 +02:00
setup.py ⬇️ downgrade minimal Python version 2022-10-27 22:41:26 +02:00

README.md

CiviProxy_Logs2Json

Translate a CiviProxy logfile into JSON format.

Installation

pyton3 -m pip install civiproxy_logs2json

Example Usage

Pass logfile as positional argument:

cpl2j /var/www/proxy_logs/proxy.log

Pipe logfile into program:

cat proxy.log | cpl2j 

Set JSON indentation to two spaces:

cat proxy.log | cpl2j -s 2 

Tip

Use VisiData to explore the data in a very comfortable way: /var/www/proxy_logs/proxy.log

cpl2j /var/www/proxy_logs/proxy.log | vd -f json