Ruby On Rails in MAMP mySQL Snow Leopard

爷,独闯天下 提交于 2019-12-05 15:36:30

问题


I'm trying to find step-by-step instructions to run Ruby on Rails on MAMP server and use MAMP's mySQL database. I am on Snow Leopard also. I have read Hivelogic's article about this but I really don't want to compile rails, ruby and mySQL.

Anyone have any suggestions


回答1:


I can suggest this tutorial for you; Using Ruby MySQL Gem with MAMP 1.8.x on Snow Leopard




回答2:


It is very simple, just edit your socket to MAMP's mysql socket in your rail's /config/database.yml

development:
  adapter: mysql2
  encoding: utf8
  reconnect: false
  database: myproject_development
  pool: 5
  username: root
  password: root
  host: localhost
  socket: /Applications/MAMP/tmp/mysql/mysql.sock


来源:https://stackoverflow.com/questions/1955366/ruby-on-rails-in-mamp-mysql-snow-leopard

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!