Skip to content

Instantly share code, notes, and snippets.

View denzuko's full-sized avatar
💬
linkedin.com/in/denzuko

Dwight Spencer denzuko

💬
linkedin.com/in/denzuko
View GitHub Profile
😱 Seriously?
😷 That's a bad look.
Burn it to the ground! 🔥
😠 Torvalds frowns at you.
🚶 Have you considered another career?
You must hate your coworkers. 👹
😡 You must hate yourself.
Ha! Yeah, that'll work. 😄
😕 Are you just hitting keys at random?
You code like a PM. 😐
coreos:
units:
- name: docker.service
command: start
- name: newrelic-client.service
command: start
content: |
[Unit]
Description=newrelic-client
if loadfont /boot/grub/font.pf2 ; then
insmod efi_gop
insmod efi_uga
insmod video_bochs
insmod video_cirrus
insmod gfxterm
insmod png
terminal_output gfxterm
fi
require 'sinatra'
require 'json'
require 'csv'
# Serve data as JSON
get '/hi/:name' do
name = params[:name]
content_type :json
{ :message => name }.to_json
end
@denzuko
denzuko / sar-statsd.rb
Last active August 29, 2015 14:19 — forked from noahhl/sar-statsd.rb
#!/usr/bin/env ruby
require 'socket'
STATSD_HOST = '127.0.0.1'
STATSD_PORT = 8125
NAMESPACE = "sysstat"
@hostname = `hostname -s`.chomp
@statsd = UDPSocket.new
@statsd.connect STATSD_HOST, STATSD_PORT
@denzuko
denzuko / install-elasticsearch-centos.sh
Last active August 29, 2015 14:27 — forked from ondrej-kvasnovsky/install-elasticsearch-centos.sh
Commands for ElasticSearch installation on CentOS 6.4
VERSION={VERSION:0.90.5}
PLUGINS=(
mobz/elasticsearch-head
karmi/elasticsearch-paramedic
)
# install missing libraries (if any)
sudo yum update
sudo yum install java-1.7.0-openjdk.x86_64 unzip mc wget curl
#!/bin/bash
#
# elasticsearch-backup-index.sh
#
# Push logstash index from yesterday to s3 with an accompanying restore script.
# http://logstash.net
# http://www.elasticsearch.org
# https://github.com/s3tools/s3cmd | http://s3tools.org/s3cmd
#
# Inspiration:
@denzuko
denzuko / trello_embeds.md
Last active August 26, 2015 16:28 — forked from danlec/trello_embeds.md
Examples of embedding images of public trello boards/cards in GitHub markdown

A Trello Board

[![Trello Development Board](https://trello.com/b/nC8QJJoZ.png)](https://trello.com/b/nC8QJJoZ)

Trello Development Board

A Trello Card

@denzuko
denzuko / ubuntu-mosquitto.yml
Created November 24, 2015 07:38 — forked from LTGIV/ubuntu-mosquitto.yml
Ansible playbook: install Mosquitto on Ubuntu (14.04 LTS) from PPA (alpha)
---
#
# Ansible playbook: install Mosquitto from PPA on Ubuntu v201502131346
# Louis T. Getterman IV (@LTGIV)
# www.GotGetLLC.com / www.opensour.cc
#
# Thanks to @jpmens for insight on cert locations ( https://twitter.com/jpmens/status/565513595644313600 )
#
# Example Usage:
# [user@host ~$] ansible-playbook /etc/ansible/playbooks/ubuntu-mosquitto.yml --extra-vars 'target=nameFromHostsFile'
@denzuko
denzuko / firebase_promise_wrapper.js
Created December 7, 2015 14:08 — forked from katowulf/firebase_promise_wrapper.js
Example of promise contracts for Firebase (using jQuery.Deferred)
/*
* Promise wrapper for Firebase
*
* Requires jQuery and underscore.js
*************************************/
(function ($) {
"use strict";
var undefined;
var FIREBASE_URL = 'https://YOURINSTANCE.firebaseio.com';