Skip to main content

Python utility to parse log files and send them to a Sentry server.

Project description

==========
pylogwatch
==========
Log file parser, which sends the contents of log files to a centralized Sentry server. Meant for periodic execution via cron.

Config
==========
So far the config format is quite simple. It currently looks like this:
::
DEBUG=True

RAVEN = {
'dsn':'<RAVEN_DSN_URL>',
}

# List of files to monitor and their associated formatters
FILE_FORMATTERS = {
'/var/log/syslog': ('formatters.base.SysLogDateFormatter',
'formatters.base.SysLogProcFormatter',),

'/var/log/auth.log': ('formatters.base.SysLogDateFormatter',
'formatters.base.SysLogProcFormatter',),

'/var/log/apache/error.log': ('formatters.web.ApacheErrorLogFormatter',),

}


DB
==========
PyLogWatch will automaticall create a SQLite database in the folder where the Config File resides.

Execution
==========
To start pylogwatch simply use the '-c' switch to indicate the path to the configuration file:

pylog.py -c /path/to/pylogconf.py

Caveats
==========
Keep in mind that PyLogWatch uses a regular Python file as a configuration. This means that giving write access
to the config file is equivalent to giving execuion privileges for custom Python code. Keep your configuration files
adequately protected

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

PyLogWatch-0.1.9-alpha2.tar.gz (19.3 kB view details)

Uploaded Source

File details

Details for the file PyLogWatch-0.1.9-alpha2.tar.gz.

File metadata

File hashes

Hashes for PyLogWatch-0.1.9-alpha2.tar.gz
Algorithm Hash digest
SHA256 15d67db76f0a83422c578bbc74b68fd54b01059a35482f86ad10ebdf7eaa1d9a
MD5 b5d582971f66b50ae05d69625dc71d8d
BLAKE2b-256 6b82f73b597df382bc361dd15e232cf19b1c2a7188986ffa235d5c31b91c06dd

See more details on using hashes here.

Provenance

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page