Hi All,
I tried to request user to input username and password for the database
when deploy, therefore, in my capistrano task, I
task :create_database_user do
@username = Capistrano::CLI.password_prompt(''mysql_username:
'')
@password = Capistrano::CLI.password_prompt(''mysql_password:
'')
#@config = YAML::load( File.open(
"#{release_path}/config/config.yml"))[''production'']
@config["username"] = @username
@config["password"] = @password
end
However, File not found error occurs.
Actually, I want to save the input in the .yml file so that I can access
them before restart in the database.yml.
Or, Can I save the cap input into the database.yml directly before
restart?
How can I do that?
Thanks much!
Arthur
--
Posted via http://www.ruby-forum.com/.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Ruby on Rails: Talk" group.
To post to this group, send email to
rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
To unsubscribe from this group, send email to
rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---