Skip to content

Instantly share code, notes, and snippets.

View jbehrends's full-sized avatar

Josh Behrends jbehrends

View GitHub Profile
@jbehrends
jbehrends / dockstar_LED
Last active December 14, 2015 03:39
Notes on how to control the Seagate Dockstar's LEDs under debian
The following syntax shows how to control both LEDs
echo [command] > /sys/class/leds/dockstar\:green\:health/trigger
echo [command] > /sys/class/leds/dockstar\:orange\:misc/trigger
In the above examples replace [command] with one of the following:
none - turns off the LED.
default-on - turns on the LED.
timer - allows you to set timed on/off lighting in milliseconds.
mmc0 - blinks the LED when the MMC card is accessed, similar to an HDD light on your computer.
nand-disk - blinks the LED when the NAND device is accessed, similar to an HDD light on your computer. (doesn't seem to work with USB mounted drives)
<LoadPlugin java>
</LoadPlugin>
<Plugin "java">
JVMArg "-Djava.class.path=/usr/share/collectd/java/collectd-api.jar:/usr/share/collectd/java/generic-jmx.jar"
LoadPlugin "org.collectd.java.GenericJMX"
<Plugin "GenericJMX">
################
# MBean blocks #
require 'rubygems'
require 'mechanize'
FIRST_NAME = 'FIRST_NAME'
LAST_NAME = 'LAST_NAME'
PHONE = 'PHONE'
EMAIL = 'EMAIL@provider.com'
PARTY_SIZE = 2
SCHEDULE_RANGE = { :start_time => '19:00', :end_time => '20:30' }
@jbehrends
jbehrends / sensu.erb
Created February 24, 2015 18:58
Sensu CLI script to set/remove stashes and check status of checks.
#!/usr/bin/env ruby
#
# DESCRIPTION:
# This script should be templated to a node via puppet/chef/other. This will
# allow you to silence/unsilence/check stashes/check sensu checks for the host
# the script is being ran from.
#
require 'rubygems'
require 'json'

Keybase proof

I hereby claim:

  • I am jbehrends on github.
  • I am behrends (https://keybase.io/behrends) on keybase.
  • I have a public key whose fingerprint is ADA5 8A9C 502C 3FEA 0036 2BC9 E3DB 148E 8078 93AF

To claim this, I am signing this object: