Skip to content

Instantly share code, notes, and snippets.

Keybase proof

I hereby claim:

  • I am takus on github.
  • I am takus (https://keybase.io/takus) on keybase.
  • I have a public key ASDcc39Zy8aSz1G8JQhpgJVMgKfe2Ee0ZCR2nuVgOX70Ago

To claim this, I am signing this object:

@takus
takus / fluent.conf
Created June 1, 2016 04:25
Configuration for monitoring Fluentd by Datadog
<match smartnews.user_activity>
type copy
<store>
type flowcounter
count_keys *
unit second
aggregate all
tag fluentd.flowcounter.smartnews.user_activity
@label @dogstatsd
</store>
@takus
takus / ic.coffee
Created July 5, 2016 02:59
Manage incidents with Incident Commandar System.
# Description:
# Manage incidents with Incident Commandar System.
# Commands:
# bot 110 ic me - Start an incident management and assign 'me' as the Incident Commandar
moment = require('moment')
module.exports = (robot) ->
robot.respond /110 ic me/i, (res) ->
FROM perl:latest
RUN cpanm install Starlet
ADD oversleep.psgi /oversleep.psgi
EXPOSE 5000
CMD ["plackup", "-p", "5000", "-s", "Starlet", "--max-workers=8", "/oversleep.psgi"]
<source>
type forward
port 24224
</source>
<source>
type monitor_agent
port 24220
</source>
@takus
takus / Vagrantfile
Created July 26, 2013 02:22
Vagrantfile for chef cookbook test
# -*- mode: ruby -*-
# vi: set ft=ruby :
Vagrant.configure("2") do |config|
config.vm.box = "opscode-centos-6.4"
config.vm.box_url = "https://opscode-vm-bento.s3.amazonaws.com/vagrant/opscode_centos-6.4_provisionerless.box"
config.vm.network :private_network, ip: "192.168.33.10"
config.vm.provider :virtualbox do |vb|
@takus
takus / sigalrm.pl
Created March 26, 2013 04:53
Time::HiRes::alarm(0); しないと意図しない箇所で die する例
#!/usr/bin/env perl
use strict;
use warnings;
use POSIX qw(SIGALRM);
use Time::HiRes;
print "begin\n";
eval {
@takus
takus / install-homebrew.sh
Created December 14, 2012 18:54
install homebrew.
#!/bin/sh
#### UNINSTALL MacPorts
# save installed package by MacPorts before uninstall
sudo port installed > ~/myports.log
# Uninstall MacPorts
# You should also remove /opt/local/bin & /opt/local/sbin in your PATH
sudo port -f uninstall installed
@takus
takus / mq_install.sh
Created December 3, 2012 21:52 — forked from iwata/mqh_install.sh
Installing MySQL5.1 & Q4M on MacOSX Lion
#!/bin/zsh
MYSQL_VERSION=5.1.65
if [ `which perl` = "/usr/bin/perl" ]; then
echo -n -e "\e[1;31mUSING SYSTEM PERL OK? [y/n]\e[m: "
read ANSWER
if [ "$ANSWER" != "y" ]; then
exit 255
fi
@takus
takus / redmine2dailyreport.pl
Created November 30, 2012 18:11
generates daily report from redmine issues
#!/usr/bin/env perl
use strict;
use warnings;
use utf8;
binmode STDOUT, ":utf8";
use Config::Pit;
use Redmine::API;
use Encode;