Skip to content

Instantly share code, notes, and snippets.

View systembell's full-sized avatar

Aaron Bell systembell

View GitHub Profile
#! /usr/bin/env python
import fileinput
import argparse
from operator import itemgetter
parser = argparse.ArgumentParser()
parser.add_argument('--target-mb', action = 'store', dest = 'target_mb', default = 61000, type = int)
parser.add_argument('vmtouch_output_file', action = 'store', nargs = '+')
args = parser.parse_args()
@systembell
systembell / gist:1665074
Created January 23, 2012 19:27 — forked from bpoweski/gist:974870
Route53 gem chef recipe
define :cname_record, :hostname => nil do
name = params[:name]
hostname = params[:hostname]
subdomain = name.split(".").tap(&:shift).join(".")
remote_file "/home/#{node[:owner_name]}/.route53" do
source "route53.yml"
cookbook 'supply_chain_db'
owner node[:owner_name]
group node[:owner_name]
@systembell
systembell / recipe.rb
Created November 9, 2011 19:19 — forked from casualjim/recipe.rb
S3 File Resource for Chef
# Source accepts the protocol region:// with the host as the bucket
# access_key_id and secret_access_key are just that
# for the eu-west-1 region:
s3_file "/var/bulk/the_file.tar.gz" do
source "s3-eu-west-1://your.bucket/the_file.tar.gz"
access_key_id your_key
secret_access_key your_secret
owner "root"
group "root"

Sinatra

ruby 1.9.2 + async_sinatra + thin thin start

ab -n 10000 -c 100 http://localhost:3000/
-> 49ms / request

Node

node server.js