Forum: Ruby-Forum.com How to configure rforum with mailing lists

078a8121c81b252127770706f3409ec6?d=identicon&s=25 Richard Church (rchurch)
on 2006-05-27 22:38
I have installed rforum from SVN, but there doesn't seem to be any way
of linking it to mailing lists.

How is that part done?
078a8121c81b252127770706f3409ec6?d=identicon&s=25 Richard Church (rchurch)
on 2006-05-27 23:47
Richard Church wrote:

I followed the instructions here
http://www.ruby-forum.com/topic/52254#new to configure mailing list
connectivity.

However when I run it I get this error - it appears the script tries to
use the development.rb file.

Is there some reason it should be required, or is it simply a bug from a
development version?

/usr/local/lib/ruby/gems/1.8/gems/activerecord-1.14.2/lib/active_record/connection_adapters/abstract/connection_specification.rb:194:in
`establish_connection': development database is not configured
(ActiveRecord::AdapterNotSpecified)
        from
/usr/local/lib/ruby/gems/1.8/gems/activerecord-1.14.2/lib/active_record/connection_adapters/abstract/connection_specification.rb:185:in
`establish_connection'
        from
/usr/local/lib/ruby/gems/1.8/gems/rails-1.1.2/lib/initializer.rb:182:in
`initialize_database'
        from
/usr/local/lib/ruby/gems/1.8/gems/rails-1.1.2/lib/initializer.rb:84:in
`process'
        from
/usr/local/lib/ruby/gems/1.8/gems/rails-1.1.2/lib/initializer.rb:42:in
`send'
        from
/usr/local/lib/ruby/gems/1.8/gems/rails-1.1.2/lib/initializer.rb:42:in
`run'
        from ./script/../config/environment.rb:12
        from ./script/process_mails:11:in `require'
        from ./script/process_mails:11


>
> I have installed rforum from SVN, but there doesn't seem to be any way
> of linking it to mailing lists.
>
> How is that part done?
078a8121c81b252127770706f3409ec6?d=identicon&s=25 Richard Church (rchurch)
on 2006-05-28 00:44
Richard Church wrote:

After this I simply added a development section to database.yml to skip
the error.

It turns out that :SearchLike creates this error where as :SearchFerret
works correctly

Whether the result will be the same on the production database rather
than the development database is something I can't be sure off.

output from process_mails
=========================

Checking for new mails
Reading last update time from last_update.yaml...
done.
Updating index starting from Sat May 27 22:29:08 GMT 2006...
./script/process_mails:27:in `rebuild_index': wrong number of arguments
(1 for 0) (ArgumentError)
        from ./script/process_mails:27:in `do_update'
        from ./script/process_mails:74
        from ./script/process_mails:71:in `loop'
        from ./script/process_mails:71
3a83969376c805ef5b6042191fdb0ff3?d=identicon&s=25 Andreas S. (andreas)
on 2006-05-28 12:07
Richard Church wrote:
> Richard Church wrote:
>
> After this I simply added a development section to database.yml to skip
> the error.

You should switch to the production environment instead:

RAILS_ENV=production ./script/process_mails pathto/Maildir/cur 5

> ./script/process_mails:27:in `rebuild_index': wrong number of arguments

That is a bug in the SVN version. Please comment out the call to
rebuild_index when you are using SearchLike.
078a8121c81b252127770706f3409ec6?d=identicon&s=25 Richard Church (rchurch)
on 2006-05-28 14:25
Andreas S. wrote:

I began with the production version. I added the development section to
database.yml because the process_mail script referenced it and I wanted
to see the outcome if the phase completed.

What should I do to prevent the development version from being
referenced by the script? There has to be something in the configuration
causing the development database to be referenced by the script.

Do you have some idea of where I should look?

>> Richard Church wrote:
>>
>> After this I simply added a development section to database.yml to skip
>> the error.
>
> You should switch to the production environment instead:
>
> RAILS_ENV=production ./script/process_mails pathto/Maildir/cur 5
>
>> ./script/process_mails:27:in `rebuild_index': wrong number of arguments
>
> That is a bug in the SVN version. Please comment out the call to
> rebuild_index when you are using SearchLike.
3a83969376c805ef5b6042191fdb0ff3?d=identicon&s=25 Andreas S. (andreas)
on 2006-05-29 00:09
Richard Church wrote:

> What should I do to prevent the development version from being
> referenced by the script? There has to be something in the configuration
> causing the development database to be referenced by the script.

If you set the RAILS_ENV to production, the script won't reference the
development database:

>> RAILS_ENV=production ./script/process_mails pathto/Maildir/cur 5
078a8121c81b252127770706f3409ec6?d=identicon&s=25 rchurch (Guest)
on 2006-06-01 09:10
I had to set uncomment this setting in environment.rb to get it to work.
The rforum is working on a Plesk domain and that could be the reason why

ENV['RAILS_ENV'] = 'production'

Andreas S. wrote:
> Richard Church wrote:
>
>> What should I do to prevent the development version from being
>> referenced by the script? There has to be something in the configuration
>> causing the development database to be referenced by the script.
>
> If you set the RAILS_ENV to production, the script won't reference the
> development database:
>
>>> RAILS_ENV=production ./script/process_mails pathto/Maildir/cur 5
Please log in before posting. Registration is free and takes only a minute.
Existing account

NEW: Do you have a Google/GoogleMail, Yahoo or Facebook account? No registration required!
Log in with Google account | Log in with Yahoo account | Log in with Facebook account
No account? Register here.