Skip to content

Instantly share code, notes, and snippets.

View sawanoboly's full-sized avatar
🤷‍♂️
🙃

Yukihiko SAWANOBORI sawanoboly

🤷‍♂️
🙃
View GitHub Profile
@sawanoboly
sawanoboly / Rakefile
Created October 5, 2011 05:26
Raketask: Create inet_interface for lxc containers.
## lxc-tool for natty
## Create inet_interface for lxc containers. (ignore the guest status)
## author [email protected]
## Usage: rake conf_ip RAKE_ENV=environment (default=default)
require 'pp'
require 'erb'
LXC_DIR = "/var/lib/lxc/"
rake_env = ENV['RAKE_ENV'] || "dafault"
@sawanoboly
sawanoboly / Rakefile
Created October 5, 2011 04:20
Raketask: copy sshdconfigs from host to all lxc Containers. (igunore guest status.)
## lxc-tool for natty
## copy sshdconfigs from host to all guests. (ignore the guest status)
## author [email protected]
## Usage: rake copyssh
require 'pp'
LXC_DIR = "/var/lib/lxc/"
rake_env = ENV['RAKE_ENV'] || "dafault"
@sawanoboly
sawanoboly / natty_rvm192
Created October 4, 2011 01:06
Debootstrapで作成したlxcのNattyコンテナにrvmでRuby1.9.2を入れるBootstrap
$ sudo echo deb-src http://archive.ubuntu.com/ubuntu natty main universe>> /etc/apt/sources.list
$ sudo apt-get -y update
$ sudo apt-get -y install git
$ sudo apt-get -y build-dep ruby1.9.1-full
$ sudo apt-get -y install build-essential bison openssl libreadline6 libreadline6-dev curl git-core zlib1g zlib1g-dev libssl-dev libyaml-dev libsqlite3-0 libsqlite3-dev sqlite3 libxml2-dev libxslt-dev autoconf libc6-dev ncurses-dev
$ sudo -s
# bash -s stable < <(curl -s https://raw.github.com/wayneeseguin/rvm/master/binscripts/rvm-installer )
## use older version rvm.