2010年11月15日 星期一

rails environment

1.ruby on rails has three different environment

develpment for develop the application

test for unit testing use

production for online environment use

2.use config environment to custom the setting(mysql example)
#vim /cms/config/environment.rb

development:
adapter: mysql
encoding: utf8
reconnect: false
database: user_book
pool: 10
username: root
password: abc123
socket: /tmp/mysql.sock

沒有留言:

張貼留言