Skip to content

Instantly share code, notes, and snippets.

# Credits:
# Jason Pirkey, Táve Corporation, http://www.tave.com/
# Jeremy Mickelson, https://github.com/CyborgMaster
# See http://help.papertrailapp.com/kb/hosting-services/amazon-elastic-beanstalk
packages:
yum:
rubygems: []
ruby-devel: []
@hakobera
hakobera / papertrail.conf
Created June 12, 2014 07:12
.ebextensions for Papertrail
packages:
yum:
gcc-c++: []
make: []
ruby-devel: []
openssl-devel: []
rubygems:
remote_syslog: []
@hakobera
hakobera / ansible-td-agent.yml
Last active August 29, 2015 14:08
ansible playbook of td-agent2 for Ubuntu 14.04
---
# based on http://toolbelt.treasuredata.com/sh/install-ubuntu-trusty-td-agent2.sh
- name: add apt key
apt_key: url=http://packages.treasuredata.com/GPG-KEY-td-agent state=present
- name: add apt repository
apt_repository: repo='deb [arch=amd64] http://packages.treasuredata.com/2/ubuntu/trusty/ trusty contrib' state=present
- name: install td-agent
@hakobera
hakobera / Vagrantfile
Last active August 29, 2015 14:09
vagrant plane ubuntu 14.04 or 12.04
# -*- mode: ruby -*-
# vi: set ft=ruby :
# Vagrantfile API/syntax version. Don't touch unless you know what you're doing!
VAGRANTFILE_API_VERSION = "2"
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
config.vm.box = "ubuntu/trusty64"
config.vm.box_url = "https://cloud-images.ubuntu.com/vagrant/trusty/current/trusty-server-cloudimg-amd64-vagrant-disk1.box"
@hakobera
hakobera / gke_functions
Last active August 29, 2015 14:13
Shell function for Google Container Engine
#######################################################
# Google Container Engine helper functions
#
# Prerequisities
# - gcloud
# - jq
#######################################################
function create_network() {
network=$1
@hakobera
hakobera / hipchat.js
Last active August 29, 2015 14:13
HipChatClient for Google Apps Script
/**
* HipChat client for Google Apps Script.
* This code is based on node-hipchat https://github.com/nkohari/node-hipchat/blob/master/lib/hipchat.js
*/
(function(global) {
var HipChatClient = (function () {
HipChatClient.prototype.host = 'api.hipchat.com';
function HipChatClient(apikey) {
@hakobera
hakobera / .gitignore
Created March 20, 2015 09:45
2015/3/21 時雨祭デモアプリ
node_modules
*.log
@hakobera
hakobera / storage.js
Created May 1, 2011 14:08
LocalStorage Wrapper for enchant.js
/**
* enchant.js Save/Load module
*/
/**
* Namespace は適当に
*/
var Storage = {};
Storage.Event = {
@hakobera
hakobera / app.js
Created May 17, 2011 02:15
WebSocket(Socket.IO) で受け取った Data URL 形式の画像をダウンロードさせる
var express = require('express'),
io = require('socket.io'),
fs = require('fs');
var app = module.exports = express.createServer();
// Configuration
app.configure(function(){
app.set('views', __dirname + '/views');
@hakobera
hakobera / result.txt
Created August 8, 2011 07:02 — forked from koichik/0001-Fix-this.event.patch
Fix this.event
CPU: AMD Phenom(tm) II X6 1090T
MEM: 16GB
OS: CentOS 5.5
* test1.js
real 0m4.813s
user 0m4.790s
sys 0m0.011s