$ sudo brew install mongodb
Error: You must `brew link go scons` before mongodb can be installed
と怒られたので、
$ sudo brew link go scons
$ sudo brew install mongodb
インストール完了。
インストール後のメッセージでこの様に出てくるので、
==> Caveats To have launchd start mongodb at login: ln -sfv /usr/local/opt/mongodb/*.plist ~/Library/LaunchAgents Then to load mongodb now: launchctl load ~/Library/LaunchAgents/homebrew.mxcl.mongodb.plist Or, if you don't want/need launchctl, you can just run: mongod --config /usr/local/etc/mongod.conf
以下を実行。
$ sudo ln -sfv /usr/local/opt/mongodb/*.plist ~/Library/LaunchAgents /Users/ken/Library/LaunchAgents/homebrew.mxcl.mongodb.plist -> /usr/local/opt/mongodb/homebrew.mxcl.mongodb.plist $ sudo launchctl load ~/Library/LaunchAgents/homebrew.mxcl.mongodb.plist
自動起動スクリプトが登録される。