Preq-reqs:
- You need a node
- Your node's OS should be Linux
- It should be a good Linux distro (Ubuntu 15.10)
- Not a bad one
- It should have Docker running
- It should be disposable
- It shouldn't have been previously traumatized
| # Based on a gist by benwtr (https://gist.github.com/benwtr/5691225) | |
| # Works with Slack -> Hubot -> Icinga | |
| #s | |
| # Description: | |
| # This script receives alerts in the format: | |
| # /usr/bin/curl -X POST \ | |
| # "${HUBOT_URL}/${SLACKCHANNEL}@conference.${TEAM}.xmpp.slack.com" \ | |
| # -d "type=host" \ | |
| # -d "notificationtype=${NOTIFICATIONTYPE}" \ | |
| # -d "host=${HOSTDISPLAYNAME}" \ |
| # Released by rdb under the Unlicense (unlicense.org) | |
| # Based on information from: | |
| # https://www.kernel.org/doc/Documentation/input/joystick-api.txt | |
| import os, struct, array | |
| from fcntl import ioctl | |
| # Iterate over the joystick devices. | |
| print('Available devices:') |
| name "mysql-ruby" | |
| version "2.9.1" | |
| dependency "ruby" | |
| dependency "rubygems" | |
| dependency "percona-dev" | |
| build do | |
| gem "install mysql -n #{install_dir}/bin --no-rdoc --no-ri -v #{version}" | |
| end |
| multiline { | |
| tags => ["rails"] | |
| pattern => "^Started" | |
| negate => true | |
| what => "previous" | |
| } |
| _ssh_auth_save() { | |
| ln -sf "$SSH_AUTH_SOCK" "$HOME/.ssh/ssh-auth-sock.$HOSTNAME" | |
| } | |
| alias screen='_ssh_auth_save ; export HOSTNAME=$(hostname) ; screen' | |
| alias tmux='_ssh_auth_save ; export HOSTNAME=$(hostname) ; tmux' |
| # Description: | |
| # This script receives pages in the formats | |
| # /usr/bin/curl -d host="$HOSTALIAS$" -d output="$SERVICEOUTPUT$" -d description="$SERVICEDESC$" -d type=service -d state="$SERVICESTATE$" $CONTACTADDRESS1$ | |
| # /usr/bin/curl -d host="$HOSTNAME$" -d output="$HOSTOUTPUT$" -d type=host -d state="$HOSTSTATE$" $CONTACTADDRESS1$ | |
| # | |
| # Author: | |
| # oremj | |
| irc = require('irc') |
| # Do not use this code in any production systems, really. | |
| # | |
| # Right now that that is out of the way, this is a hacked together | |
| # 'see if it can be done' Rails logger for Logstash. | |
| # | |
| # It is a first look to see what would need to be done to replace | |
| # standard rails logging with a nice logstash based solution. | |
| # | |
| # Current notes: | |
| # |
| #!/bin/sh | |
| ## | |
| # This is a script with usefull tips taken from: | |
| # https://github.com/mathiasbynens/dotfiles/blob/master/.osx | |
| # | |
| # Run in interactive mode with: | |
| # $ sh -c "$(curl -sL https://raw.github.com/gist/2108403/hack.sh)" | |
| # | |
| # or run it without prompt questions: |
| <!-- the env variables are controlled by Chef and passed in via -D on the java command-line --> | |
| <!-- This is using the appender here: https://github.com/t0xa/gelfj --> | |
| <appender name="graylog2" class="org.graylog2.log.GelfAppender"> | |
| <param name="graylogHost" value="${graylog.server}"/> | |
| <param name="originHost" value="${graylog.origin}"/> | |
| <param name="extractStacktrace" value="true"/> | |
| <param name="addExtendedInformation" value="true"/> | |
| <!-- The _web part is because a given app has multiple components --> | |
| <!-- This app might have a _web as well as an _batch component --> | |
| <param name="facility" value="${graylog.facility}_web"/> |