Skip to content

Instantly share code, notes, and snippets.

View ssplatt's full-sized avatar

Brett Taylor ssplatt

  • Picwell
  • Philadelphia, PA
View GitHub Profile
@ssplatt
ssplatt / ge_slots_to_dashing.py
Created October 2, 2014 15:51
post number of used slots from GridEngine to Dashing
#!/bin/env python
# stats to dashing
import subprocess
import re
import httplib
import json
# config variables
# dashing host
@ssplatt
ssplatt / http_traffic.json
Created November 5, 2014 16:19
Kibana HTTP Traffic dashboard
{
"title": "HTTP Traffic",
"services": {
"query": {
"list": {
"0": {
"query": "*",
"alias": "",
"color": "#7EB26D",
"id": 0,
@ssplatt
ssplatt / ssh_traffic.json
Created November 5, 2014 16:21
Kibana SSH Traffic dashboard
{
"title": "SSH Traffic",
"services": {
"query": {
"list": {
"0": {
"query": "*",
"alias": "",
"color": "#7EB26D",
"id": 0,
@ssplatt
ssplatt / elasticsearch.json
Created May 12, 2015 19:03
elasticsearch template for Zenoss ControlCenter
{
"ID": "",
"Name": "Elasticsearch (latest)",
"Description": "Elasticsearch",
"Services": [
{
"Name": "Elasticsearch (latest)",
"Command": "",
"Description": "Elasticsearch",
"Tags": null,
@ssplatt
ssplatt / logstash.json
Created May 12, 2015 19:07
logstash template for Zenoss ControlCenter
{
"ID": "",
"Name": "Logstash (latest)",
"Description": "Logstash",
"Services": [
{
"Name": "Logstash (latest)",
"Command": "",
"Description": "Logstash",
"Tags": null,
@ssplatt
ssplatt / gist:8ba50b6dcdaec5969d2b
Last active August 29, 2015 14:25
ganglia cpu user graph in dashing
require 'httparty'
require 'addressable/uri'
# cpu_user url
uri_cpu = Addressable::URI.escape "http://localhost/ganglia/graph.php?r=hour&title=&vl=&x=&n=&hreg[]=compute&mreg[]=cpu_user&gtype=stack&glegend=hide&aggregate=1&embed=1&_=1410463742829&json=1"
SCHEDULER.every '15s', :first_in => 0 do |job|
points = []
response = HTTParty.get(uri_cpu)
response.each do |host|
@ssplatt
ssplatt / ganglia_mem.rb
Last active August 29, 2015 14:25
ganglia mem data to dashing
require 'httparty'
require 'addressable/uri'
uri = Addressable::URI.escape "graph.php?r=hour&c=Cluster&m=load_one&s=by+name&mc=2&g=mem_report&json=1"
SCHEDULER.every '15s', :first_in => 0 do |job|
points = []
response = HTTParty.get(uri)
response.take(4).each do |data|
step = 0
@ssplatt
ssplatt / jira_service.j2
Created October 12, 2015 18:43
JIRA systemd service file jinja template
[Unit]
{% from "jira/map.jinja" import jira with context %}
Description=JIRA Issue Tracker
After=syslog.target
After=network.target
[Service]
ExecStart={{ jira.install_dir }}/bin/start-jira.sh
ExecStop={{ jira.install_dir }}/bin/stop-jira.sh
RemainAfterExit=yes
<table style="border-collapse: collapse; margin: 0px auto; padding: 0px;">
<thead style="background: silver; font-size: 1.5em; font-weight: bold; padding: 5px; border-bottom: 2px solid grey;">This is the heading</thead>
<tbody>
<tr>
<td style="border: 0px; padding: 5px; border: 1px solid grey;">things</td>
<td style="border: 0px; padding: 5px; border: 1px solid grey;">more things</td>
</tr>
</tbody>
</table>
salt:
mirrors:
- ftp.us.debian.org
- ftp.uk.debian.org
- ftp.ua.debian.org
locations:
- us
- uk
- ua