Skip to content
Sumologic module
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
lib/puppet/reports
manifests
spec
tests
.fixtures.yml
.gitignore
.travis.yml
Gemfile
Gemfile.lock
README.md
Rakefile
metadata.json

README.md

Build Status

sumologic

Table of Contents

  1. Overview
  2. Module Description - What the module does and why it is useful
  3. Setup - The basics of getting started with sumologic
  4. Development - Guide for contributing to the module

Overview

A module that installs report processors capable of sending puppet logs to sumologic.

Module Description

This module will install the sumologic_stdout and sumologic_json report handlers. It also contains puppet code to manage all of the settings required by them.

sumologic_json Will use danzilio/report_all_the_things to turn the report into a massive JSON file and send that to a specified URL. It is important to note that using this handler will mean that reports are approx 460Kb each and will add up.

sumologic_stdout Just sends the logs generated by the run to sumologic. This is the same as what you would see in the console.

Setup

The report handlers can be set up manually or using the supplied puppet code:

Manual Setup

To use this module you will need a couple of things, firstly your report handler of choice will need to be added to the puppet.conf:

reports = sumologic_json,console,puppetdb

You will also need to create a sumologic.yaml at you confdir (usually /etc/puppetlabs/puppet) that looks like this:

---
:sumologic_url: '[url_goes_here]'

Automated setup

I have included a class that cal do all of this for you:

Class: sumologic::report_handler

It is important to note that this class requires a restart of the puppet server. This can be implemented with something like this:

class { 'sumologic::report_handler':
  notify => Service['pe-puppetserver'],
}

Parameters

report_url

Address to send the reports to

mode

stdout or json. Which underlying report handler to use. Stdout will send only the messages that were printed to stdout for each report while json will send the entire puppet report as a JSON file, note that this is approx 430Kb per report but contains awesome info.

Examples

class { 'sumologic':
  report_url => 'https://reports.somewhere.com/some/api/endpoint',
  mode       => 'json',
}

Development

  1. Fork this repo
  2. Write a failing test
  3. Make changes
  4. Open a pull request
You can’t perform that action at this time.