Skip to content

Instantly share code, notes, and snippets.

@ShadySQL
Forked from jorihardman/sumo_logic.config
Created April 3, 2017 21:35
Show Gist options
  • Save ShadySQL/e0dcd09d3f259b6bd8a34c77003379c3 to your computer and use it in GitHub Desktop.
Save ShadySQL/e0dcd09d3f259b6bd8a34c77003379c3 to your computer and use it in GitHub Desktop.
Elastic Beanstalk Sumo Logic Config
# This will automatically install the Sumo Logic collector on AWS Elastic
# Beanstalk instances. Add this to the .ebextensions folder in your app root
# and edit L24-25 to match your Sumo Logic accessid and accesskey. To add or
# remove tracked files, simply add or remove source hashes to the sources
# array on L36.
packages:
rpm:
SumoCollector: https://collectors.sumologic.com/rest/download/rpm/64
services:
sysvinit:
collector:
enabled: true
ensureRunning: true
files:
- /etc/sumo.conf
files:
"/etc/sumo.conf":
mode: "000755"
owner: root
group: root
content: |
accessid=YOURACCESSID
accesskey=YOURACCESSKEY
rpmAutoStart=false
syncSources=/etc/sumo_sources.json
"/etc/sumo_sources.json":
mode: "000755"
owner: root
group: root
content: |
{
"api.version": "v1",
"sources": [
{
"sourceType": "LocalFile",
"name": "rails",
"pathExpression": "/var/log/puma/puma.log"
},
{
"sourceType": "LocalFile",
"name": "eb activity",
"pathExpression": "/var/log/eb-activity.log"
},
{
"sourceType": "LocalFile",
"name": "nginx access",
"pathExpression": "/var/log/nginx/access.log"
}
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment