Giter Club home page Giter Club logo

ansible-papertrail's Introduction

ansible-papertrail

An Ansible role for installing Papertrail.

Role Variables

  • papertrail_version - Release of remote_syslog2 to use
  • papertrail_ca_bundle_checksum - Checksum for Papertrail CA bundle (default: sha256:7019189e20ed695e9092e67d91a3b37249474f4c4c6355193ce6d2cb648f147c)
  • papertrail_conf - Application logs configuration file (default: /etc/log_files.yml)
  • papertrail_host - Host for Papertrail's logging endpoint (default: logs2.papertrail.com)
  • papertrail_port - Port for Papertrail's logging endpoint (default: 45551)
  • papertrail_preserve_fqdn - Configure if rsyslog need to respect FQDN (default: off)

Usage

Ensure that papertrail_host and papertrail_port are set to the endpoints provided to your account by Papertrail. Both can be found in the user account settings.

In addition, this role does not attempt to setup any configuration for application logs. Only system logs are shipped to Papertrail by default (via Rsyslog). If you want to ship a custom set of application logs, wrap this role with a project specific role that templates the papertrail_conf file. Generally, this is /etc/log_files.yml and looks like this inside:

files:
  - /var/log/httpd/access_log
  - /var/log/httpd/error_log
  - /opt/misc/*.log
  - /home/**/*.log
  - /var/log/mysqld.log
  - /var/run/mysqld/mysqld-slow.log
exclude_files:
  - old
  - 200\d
hostname: www42  # override OS hostname
exclude_patterns:
  - exclude this
  - \d+ things
destination:
  host: logs.papertrailapp.com
  port: 12345   # NOTE: change this to YOUR papertrail port!
  protocol: tls
new_file_check_interval: "10" # Check every 10 seconds

Example Playbook

See the examples directory.

ansible-papertrail's People

Contributors

dfeyer avatar flibbertigibbet avatar hectcastro avatar notthatbreezy avatar tnation14 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.