Skip to content

Instantly share code, notes, and snippets.

@hakobera
hakobera / Gemfile
Last active Dec 14, 2016
Ruby と tumugi によるデータパイプライン構築
View Gemfile
source "https://rubygems.org"
gem "tumugi", "~> 0.6.3"
@hakobera
hakobera / deis_run.py
Last active Dec 14, 2016
Helper script to run rails console on deis
View deis_run.py
#!/usr/bin/env python
import subprocess
import docker
import dockerpty
from os import path
import argparse
def get_hosts_list(filename):
hosts_list = []
@hakobera
hakobera / .gitignore
Created Mar 20, 2015
2015/3/21 時雨祭デモアプリ
View .gitignore
node_modules
*.log
@hakobera
hakobera / hipchat.js
Last active Aug 29, 2015
HipChatClient for Google Apps Script
View hipchat.js
/**
* 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 / gke_functions
Last active Aug 29, 2015
Shell function for Google Container Engine
View gke_functions
#######################################################
# Google Container Engine helper functions
#
# Prerequisities
# - gcloud
# - jq
#######################################################
function create_network() {
network=$1
@hakobera
hakobera / Vagrantfile
Last active Aug 29, 2015
vagrant plane ubuntu 14.04 or 12.04
View Vagrantfile
# -*- 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 / ansible-td-agent.yml
Last active Aug 29, 2015
ansible playbook of td-agent2 for Ubuntu 14.04
View ansible-td-agent.yml
---
# 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
View bqgas-sample.gs.js
/*
* dependencies:
* Momement: 'MHMchiX6c1bwSqGM1PZiW_PxhMjh3Sh48'
*/
/**
* @see https://developers.google.com/apps-script/reference/mail/mail-app
*/
function sendMail(recipients, subject, doc) {
var attachment = doc.getAs('application/pdf');
You can’t perform that action at this time.