Everyones needs are different. I'm building a members area that hooks into vb on the user and usergroup (vb subscription changes users primary group)
So for now I'm happy to prompt for a login and keep a separate cookie for the rails app. Not ideal but it works for my scenario.
Achieving this is quite straight forward, I've established a second connection in database.yml then created a user model.rb file. Within this we do:
Code:
class User < ActiveRecord::Base
#Class to access the forums user table.
establish_connection :forums
set_table_name 'user'
set_primary_key 'userid'
/snip
Now model behaves like a normal AR model.
So using the mot basic parts from acts as authenticated I rolled my own sessions / login pages and then I used this
Code:
Digest::MD5.hexdigest(Digest::MD5.hexdigest(password)+salt)
to authenticate against the vb user table. All profile management is done via vb.
I would at some point like to logout of the member app when you logout of vb... But as it's a separate app on a separate sub-domain, I'm happy to leave them separate for the moment and focus on getting a working functional site out.
Of course the established connection makes it quite easy to lift out information from vb, which I think is easier than writing and calling api wrappers on vb code. More so as I've got so dam rusty on php... We used active resource for a few projects before dropping it in favor of establishing connections and masking remote tables this way. Everyone's needs are different...
HTH