Skip to content

Instantly share code, notes, and snippets.

@sowawa
sowawa / .recipe
Created April 28, 2012 03:45
Installing rails 4.0.0 beta
thumbnail: http://pds.exblog.jp/pds/1/201101/16/02/d0055302_13383029.jpg
video: http://www.youtube.com/watch?v=UE27t_LJpx0
@sowawa
sowawa / README.md
Created April 25, 2012 17:14
Rackhub 2nd generation

Gist一枚でわかる、Rackhub 2nd generation!

「巷で人気?のプログラミング言語」をひと通りインストールした プログラマのためのホスティングサービスRackhubの環境の新バージョンをリリースしました。

前回からいくつかのアーキテクチャの変更を行い、より使いやすくて安定した環境をお手軽に使えるようになりました。 大きな変更は、これまではコンテナ型仮想化を使っていましたが KVMによるフルバーチャライズド環境になりました。 KVM自体は、もうめずらしくもなんともない技術なので特筆することはとくにないと思うのですが、コンテナ型環境の抱える問題との決別をという意味では、良い変更になったのではないかと思います。

@sowawa
sowawa / file_list.diff
Created April 8, 2012 01:49
git diff kernel 2.6.36 at fe4d2ca
diff --git a/fs/aufs/branch.c b/fs/aufs/branch.c
index 55a8fab..4687a35 100644
--- a/fs/aufs/branch.c
+++ b/fs/aufs/branch.c
@@ -851,13 +851,12 @@ static unsigned long long au_farray_cb(void *a,
{
unsigned long long n;
struct file **p, *f;
- struct list_head *head;
+ struct super_block *sb = arg;
@sowawa
sowawa / vfs_statfs.diff
Created April 8, 2012 01:48
git diff kernel 2.6.36 at 3cafe1c
diff --git a/fs/aufs/branch.c b/fs/aufs/branch.c
index 9cd242e..a72836f 100644
--- a/fs/aufs/branch.c
+++ b/fs/aufs/branch.c
@@ -321,11 +321,11 @@ static int au_wbr_init(struct au_branch *br, struct super_block *sb,
* a limit for rmdir/rename a dir
* cf. AUFS_MAX_NAMELEN in include/linux/aufs_type.h
*/
- h_dentry = path->dentry;
- err = vfs_statfs(h_dentry, &kst);
@sowawa
sowawa / my.cnf
Created April 1, 2012 11:48
mysql config for rackhub
# Example MySQL config file for small systems.
#
# This is for a system with little memory (<= 64M) where MySQL is only used
# from time to time and it's important that the mysqld daemon
# doesn't use much resources.
#
# MySQL programs look for option files in a set of
# locations which depend on the deployment platform.
# You can copy this option file to one of those
# locations. For information about these locations, see:
@sowawa
sowawa / default
Created March 31, 2012 12:33
rackhub nginx default config
erver {
listen 80;
server_name localhost;
#charset koi8-r;
#access_log logs/host.access.log main;
location / {
root html;
@sowawa
sowawa / README.md
Created March 25, 2012 11:21
Lokka install

Lokka installer.

bash -s stable < <(curl -s https://raw.github.com/gist/2193002/install.sh)
@sowawa
sowawa / README.md
Created March 23, 2012 13:34
bundle install
bundle install --without production staging
@sowawa
sowawa / README.md
Created March 23, 2012 11:24
use okura!

http://d.hatena.ne.jp/gnarl/20120319/1332153697

cd
git clone git://gist.github.com/2169750.git try_okura
cd try_okura
gem install okura
wget "http://sourceforge.jp/frs/redir.php?m=jaist&f=%2Fnaist-jdic%2F53500%2Fmecab-naist-jdic-0.6.3b-20111013.tar.gz" -O mecab-naist-jdic-0.6.3b-20111013.tar.gz
okura compile mecab-naist-jdic-0.6.3b-20111013/ okura-dic
ruby play_okura.rb
@sowawa
sowawa / README.md
Created March 22, 2012 08:43
building authorized_keys gem.

building authorized_keys gem.

git clone https://sowawa@github.com/sowawa/authorized_keys.git
cd authorized_keys
gem install bundler
bundle install
rspec spec
gem build authorized_keys.gemspec
gem install authorized_keys-1.1.1.gem