You use vanilla ssh to authorize the ghost of a customer account?
ssh foo.example.com #uses private/public key per conf file
*enter password*
cd app
ruby script/console
irb > u = User.find_by_email "customer@example.net"
irb > u.authorize_ghosting! "Reason for log goes here."
* you'll want to incognito mode the URL returned here*
irb > exit
exitThis is something I would wrap a simple CLI around, and then kick myself in the tukhus for having ever used the language's interactive client to make raw database queries and edits on the production server.
User.find_by_email(ARGV[0]).authorize_ghosting!(ARGV[1])
Oh, yes, so much better. patio11 should totally switch to using this. And then pay me my $1000 consulting fee.> DB queries, even through the ORM, is basically considered a raw database query, and is strictly forbidden
You can run raw DB queries against read-only credentials.