unable to run a command in production

hi guys . i am trying to create a mailer in production i used this
command ruby script/generate mailer cronjob . when i run the command
it shows this error

config.load_once_paths is deprecated and removed in Rails 3, please
use autoload_once_paths instead
config.load_once_paths= is deprecated and removed in Rails 3, please
use autoload_once_paths= instead
config.load_paths is deprecated and removed in Rails 3, please use
autoload_paths instead
config.load_paths= is deprecated and removed in Rails 3, please use
autoload_paths= instead
/usr/local/lib/ruby/gems/1.8/gems/activerecord-2.3.14/lib/
active_record/connection_adapters/abstract/connection_specification.rb:
62:in `establish_connection': development database is not configured
(ActiveRecord::AdapterNotSpecified)
  from /usr/local/lib/ruby/gems/1.8/gems/activerecord-2.3.14/lib/
active_record/connection_adapters/abstract/connection_specification.rb:
55:in `establish_connection'
  from /usr/local/lib/ruby/gems/1.8/gems/rails-2.3.14/lib/
initializer.rb:438:in `initialize_database'
  from /usr/local/lib/ruby/gems/1.8/gems/rails-2.3.14/lib/
initializer.rb:141:in `process'
  from /usr/local/lib/ruby/gems/1.8/gems/rails-2.3.14/lib/
initializer.rb:113:in `send'
  from /usr/local/lib/ruby/gems/1.8/gems/rails-2.3.14/lib/
initializer.rb:113:in `run'
  from /home/classya/public_html/pegasus/config/environment.rb:5
  from /usr/local/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:
31:in `gem_original_require'
  from /usr/local/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:
31:in `require'
  from /usr/local/lib/ruby/gems/1.8/gems/rails-2.3.14/lib/commands/
generate.rb:1
  from /usr/local/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:
31:in `gem_original_require'
  from /usr/local/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:
31:in `require'
  from script/generate:3
help me out guys.

thanks in advance

Try
RAILS_ENV=production ruby script/generate mailer cronjob
that is how you would do it using rake at least.

Colin