$ bundle install --local
Could not find mysql2-0.3.11 in any of the sources
Run `bundle install` to install missing gems.
mysql2-0.3.11 が不足しているようだ。
個別にインストールする。
$ gem install mysql2 -v 0.3.11
Building native extensions. This could take a while...
ERROR: Error installing mysql2:
ERROR: Failed to build gem native extension.
/Users/xxxx/.rbenv/versions/2.0.0-p247/bin/ruby extconf.rb
checking for rb_thread_blocking_region()... yes
checking for rb_wait_for_single_fd()... yes
checking for mysql_query() in -lmysqlclient... no
checking for main() in -lm... yes
...
$ brew install mysql55
==> Downloading http://downloads.mysql.com/archives/mysql-5.5/mysql-5.5.30.tar.gz
######################################################################## 100.0%
==> cmake . -DCMAKE_INSTALL_PREFIX=/usr/local/Cellar/mysql55/5.5.30 -DMYSQL_DATADIR=/usr/local/var/mysql55 -DINSTALL_MAN
==> make
==> make install
==> /usr/local/Cellar/mysql55/5.5.30/bin/mysql_install_db --verbose --user=xxxx --basedir=/usr/local/Cellar/mysql
If you are using a binary release, you must either be at the top
level of the extracted archive, or pass the --basedir option
pointing to that location.
READ THIS: https://github.com/mxcl/homebrew/wiki/troubleshooting
# Allow you to route based on whether a scope is *not* authenticated.
# You can optionally specify which scope.
#
# unauthenticated do
# as :user do
# root :to => 'devise/registrations#new'
# end
# end
#
今、個人的にPub-Subにハマっているので、インストールしてみる。
Mac OS Xでパッケージ管理にはhomebrewを使っていると、コマンド1行で終わる。
$brew install redis
dyld: DYLD_ environment variables being ignored because main executable (/usr/bin/sudo) is setuid or setgid
==> Downloading http://redis.googlecode.com/files/redis-2.6.14.tar.gz
######################################################################## 100.0%
==> make -C /private/tmp/redis-t51l/redis-2.6.14/src CC=cc
==> Caveats
To have launchd start redis at login:
ln -sfv /usr/local/opt/redis/*.plist ~/Library/LaunchAgents
Then to load redis now:
launchctl load ~/Library/LaunchAgents/homebrew.mxcl.redis.plist
Or, if you don't want/need launchctl, you can just run:
redis-server /usr/local/etc/redis.conf
==> Summary
/usr/local/Cellar/redis/2.6.14: 9 files, 760K, built in 10 seconds
何事も問題なくあっさりと10秒でインストールできた。
起動は手動でやりたいので、書いてある通り
$redis-server /usr/local/etc/redis.conf
[80525] 03 Jul 16:45:20.844 * Max number of open files set to 10032
_._
_.-``__ ''-._
_.-`` `. `_. ''-._ Redis 2.6.14 (00000000/0) 64 bit
.-`` .-```. ```\/ _.,_ ''-._
( ' , .-` | `, ) Running in stand alone mode
|`-._`-...-` __...-.``-._|'` _.-'| Port: 6379
| `-._ `._ / _.-' | PID: 80525
`-._ `-._ `-./ _.-' _.-'
|`-._`-._ `-.__.-' _.-'_.-'|
| `-._`-._ _.-'_.-' | http://redis.io
`-._ `-._`-.__.-'_.-' _.-'
|`-._`-._ `-.__.-' _.-'_.-'|
| `-._`-._ _.-'_.-' |
`-._ `-._`-.__.-'_.-' _.-'
`-._ `-.__.-' _.-'
`-._ _.-'
`-.__.-'
[80525] 03 Jul 16:45:20.846 # Server started, Redis version 2.6.14
[80525] 03 Jul 16:45:20.846 * The server is now ready to accept connections on port 6379