LoginSignup
4
4

More than 5 years have passed since last update.

Otto dev sshしてからhostのMysqlへの接続

Last updated at Posted at 2015-10-03

Ottoを試してた時

MacOS X上にあるMariaDBへの接続したいなーっと思って。
HostのIPってどうやるのか調べてて、これでいけた。

netstat -rn | grep "^0.0.0.0 " | cut -d " " -f10

それをRailsのconfig/database.ymlに入れてみて、

development:
  <<: *default
  database: hoge_development
  host: 出てきたIP

これでOtto上から接続できた

4
4
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
4
4