1. change RAIlS_ROOT to Rails.root.
2. add more doc